|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
The internal interface for all objects acting as sessions.
It extends the Session
interface, which is the safe
view given to session participants. A number of additional methods
are defined for admitting and releasing session participants,
managing the lifetime of the session, and registering session
listeners.
Method Summary | |
void |
addSessionListener(SessionListener listener)
Registers a session listener with the session. |
void |
admit(SessionParticipant participant)
Admits a new session participant to the session. |
void |
cleanUp()
Cleans up the session before it is made eligible for garbage collection. |
int |
countParticants()
Returns the number of session participants that are currently joined to the session. |
SessionSettings |
getSettings()
Returns a SessionSettings object encapsulating the
settings for this session. |
void |
release(SessionParticipant participant)
Releases the specified session participant from the session. |
Methods inherited from interface uk.org.ogsadai.sessions.Session |
addExternalInput, addExternalOutput, containsAttribute, countAttributes, getAttribute, getAttributeNames, getAttributeValue, getExternalInput, getExternalOutput, getID, getProperties, getRequestStatus, hasExternalInput, hasExternalOutput, removeAttribute, removeExternalInput, removeExternalOutput, setAttribute |
Method Detail |
public void addSessionListener(SessionListener listener)
listener
- The SessionListener
to register.public void admit(SessionParticipant participant) throws SessionJoinDeniedException, SessionJoinException
After this method has been invoked, the session participant is said to have joined the session.
participant
- The SessionParticipant
to join.
SessionJoinDeniedException
- if there is an
application-specific reason why the participant is not allowed
to join.
SessionJoinException
- if there is an internal problem that
occurs during the join.
java.lang.IllegalArgumentException
- if participant
is
null
public void cleanUp()
public int countParticants()
public SessionSettings getSettings()
SessionSettings
object encapsulating the
settings for this session.
public void release(SessionParticipant participant) throws SessionReleaseException
After this method has been invoked, the session participant is said to have left the session. It must be responsible for no further interactions with the session. If the specified session participant is not currently a participant of this session then nothing happens.
participant
- The SessionParticipant
to release.
SessionReleaseException
- if there is an internal problem that
occurs during the release.
java.lang.IllegalArgumentException
- if participant
is
null
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |