uk.org.ogsadai.sessions
Class SessionEvent

java.lang.Object
  |
  +--java.util.EventObject
        |
        +--uk.org.ogsadai.sessions.SessionEvent
All Implemented Interfaces:
java.io.Serializable

public class SessionEvent
extends java.util.EventObject

An event representing some kind of interaction involving an InternalSession object.

Author:
The OGSA-DAI Project Team
See Also:
Serialized Form

Field Summary
private static java.lang.String COPYRIGHT_NOTICE
          Copyright statement
private  SessionParticipant mParticipant
          The session participant involved in the event, if one was involved
private static long serialVersionUID
          Required to get rid of Java serialization warning
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
SessionEvent(InternalSession source)
          Constructs a SessionEvent representing an interaction with a session.
SessionEvent(InternalSession source, SessionParticipant participant)
          Constructs a SessionEvent representing an interaction between a session and a session participant.
 
Method Summary
 InternalSession getInternalSession()
          Returns the InternalSession that originated the event.
 SessionParticipant getSessionParticipant()
          Returns the SessionParticipant that was involved in the event, or null if no participant was involved.
 boolean hasParticipant()
          Indicates whether or not the session event involved an interaction between a session and session participant.
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

COPYRIGHT_NOTICE

private static final java.lang.String COPYRIGHT_NOTICE
Copyright statement

See Also:
Constant Field Values

serialVersionUID

private static final long serialVersionUID
Required to get rid of Java serialization warning

See Also:
Constant Field Values

mParticipant

private SessionParticipant mParticipant
The session participant involved in the event, if one was involved

Constructor Detail

SessionEvent

public SessionEvent(InternalSession source)
Constructs a SessionEvent representing an interaction with a session.

Parameters:
source - The Session object that originated the event.

SessionEvent

public SessionEvent(InternalSession source,
                    SessionParticipant participant)
Constructs a SessionEvent representing an interaction between a session and a session participant.

Parameters:
source - The Session object that originated the event.
participant - The SessionParticipant involved in the event.
Method Detail

getInternalSession

public InternalSession getInternalSession()
Returns the InternalSession that originated the event.

Returns:
session.

getSessionParticipant

public SessionParticipant getSessionParticipant()
Returns the SessionParticipant that was involved in the event, or null if no participant was involved.

Returns:
session participant.

hasParticipant

public boolean hasParticipant()
Indicates whether or not the session event involved an interaction between a session and session participant.

Returns:
true if so, otherwise false.