com.sun.media.jsdt.event
Class ClientEvent

java.lang.Object
  |
  +--java.util.EventObject
        |
        +--com.sun.media.jsdt.event.ClientEvent

public class ClientEvent
extends java.util.EventObject
implements com.sun.media.jsdt.impl.JSDTDebugFlags

The Client event. Client events are created for the following actions:

 - when a Client has been invited to join a ByteArray.
 - when a Client has been expelled from a ByteArray.
 - when a Client has been invited to join a Channel.
 - when a Client has been expelled from a Channel.
 - when a Client has been invited to join a Session.
 - when a Client has been expelled from a Session.
 - when a Client has been invited to join a Token.
 - when a Client has been expelled from a Token.
 - when a Client has been given a Token.
 

Since:
JSDT 1.0
Version:
1.5 - 7th January 1999
Author:
Rich Burridge
See Also:
Serialized Form

Field Summary
static int BYTEARRAY_EXPELLED
          The Client ByteArray expelled event type.
static int BYTEARRAY_INVITED
          The Client ByteArray invited event type.
static int CHANNEL_EXPELLED
          The Client Channel expelled event type.
static int CHANNEL_INVITED
          The Client Channel invited event type.
protected  java.lang.String resourceName
          The name of the resource that this event occured on.
static int SESSION_EXPELLED
          The Client Session expelled event type.
static int SESSION_INVITED
          The Client Session invited event type.
static int TOKEN_EXPELLED
          The Client Token expelled event type.
static int TOKEN_GIVEN
          The Client Token given event type.
static int TOKEN_INVITED
          The Client Token invited event type.
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
ClientEvent(Session session, Client client, java.lang.String resourceName, int type)
           constructor for the ClientEvent class.
 
Method Summary
 java.lang.String getResourceName()
           get the name of the resource for this event.
 Session getSession()
           get the Session associated with this event.
 java.lang.String toString()
           toString print a short description of this Client event.
 
Methods inherited from class java.util.EventObject
getSource
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

BYTEARRAY_INVITED

public static final int BYTEARRAY_INVITED
The Client ByteArray invited event type.

BYTEARRAY_EXPELLED

public static final int BYTEARRAY_EXPELLED
The Client ByteArray expelled event type.

CHANNEL_INVITED

public static final int CHANNEL_INVITED
The Client Channel invited event type.

CHANNEL_EXPELLED

public static final int CHANNEL_EXPELLED
The Client Channel expelled event type.

SESSION_INVITED

public static final int SESSION_INVITED
The Client Session invited event type.

SESSION_EXPELLED

public static final int SESSION_EXPELLED
The Client Session expelled event type.

TOKEN_INVITED

public static final int TOKEN_INVITED
The Client Token invited event type.

TOKEN_EXPELLED

public static final int TOKEN_EXPELLED
The Client Token expelled event type.

TOKEN_GIVEN

public static final int TOKEN_GIVEN
The Client Token given event type.

resourceName

protected java.lang.String resourceName
The name of the resource that this event occured on.
Constructor Detail

ClientEvent

public ClientEvent(Session session,
                   Client client,
                   java.lang.String resourceName,
                   int type)
constructor for the ClientEvent class. A new client event is generated for a specific client when there has been a change in the clients status (when it's been invited to join, or expelled from a ByteArray, Channel, Session or Token).
Parameters:
client - the Client associated with this Client event.
resourceName - the name of the ByteArray/Channel/Session/Token.
type - the type of event.
Method Detail

getSession

public Session getSession()
get the Session associated with this event.
Returns:
the Session associated with this event.

getResourceName

public java.lang.String getResourceName()
get the name of the resource for this event. The resource will be the ByteArray, Channel, Session or Token that the Client has been invited to join or has been expelled from.
Returns:
the name of the resource for this event.

toString

public java.lang.String toString()
toString print a short description of this Client event.
Returns:
a String containing a description of this Client event.
Overrides:
toString in class java.util.EventObject
Since:
JSDT 1.3