Cumulus4j API
(1.1.0)

org.cumulus4j.keymanager
Class SessionManager

java.lang.Object
  extended by org.cumulus4j.keymanager.SessionManager

public class SessionManager
extends Object

Manager for Sessions.

There is one SessionManager for each AppServer and KeyStore. It provides the functionality to open and close sessions, expire them automatically after a certain time etc.

This is not API! Use the classes and interfaces provided by org.cumulus4j.keymanager.api instead.

Author:
Marco หงุ่ยตระกูล-Schulze - marco at nightlabs dot de

Constructor Summary
SessionManager(KeyStore keyStore)
           
 
Method Summary
 Session acquireSession(String userName, char[] password)
          Create a new unlocked session or open (unlock) a cached & currently locked session.
 String getCryptoSessionIDPrefix()
           
 KeyStore getKeyStore()
           
 Session getSessionForCryptoSessionID(String cryptoSessionID)
           
protected  long nextCryptoSessionSerial()
           
protected  void onDestroySession(Session session)
           
protected  void onReacquireSession(Session session)
           
 void onReleaseSession(Session session)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SessionManager

public SessionManager(KeyStore keyStore)
Method Detail

nextCryptoSessionSerial

protected long nextCryptoSessionSerial()

getCryptoSessionIDPrefix

public String getCryptoSessionIDPrefix()

getKeyStore

public KeyStore getKeyStore()

onReacquireSession

protected void onReacquireSession(Session session)

acquireSession

public Session acquireSession(String userName,
                              char[] password)
                       throws AuthenticationException
Create a new unlocked session or open (unlock) a cached & currently locked session.

Returns:
the Session.
Throws:
AuthenticationException - if the login fails

onDestroySession

protected void onDestroySession(Session session)

getSessionForCryptoSessionID

public Session getSessionForCryptoSessionID(String cryptoSessionID)

onReleaseSession

public void onReleaseSession(Session session)

Cumulus4j API
(1.1.0)

Copyright © 2013 NightLabs Consulting GmbH. All Rights Reserved.