com.sun.media.jsdt.impl
Interface AbstractManageableProxy

All Known Subinterfaces:
AbstractByteArrayProxy, AbstractChannelProxy, AbstractSessionProxy, AbstractTokenProxy
All Known Implementing Classes:
com.sun.media.jsdt.template.ManageableProxy

public abstract interface AbstractManageableProxy

JSDT client-side abstract proxy manageable parent class.

Version:
1.5 - 7th January 1999
Author:
Rich Burridge

Method Summary
 void addListener(java.util.EventListener listener, char listenerType)
           addListener add a listener to this manageable object.
 void changeListenerMask(java.util.EventListener listener, int eventMask, boolean disable)
           changeListenerMask enables or disables certain events for this JSDT listener.
 void changeManagerMask(com.sun.media.jsdt.JSDTManager manager, int eventMask, boolean disable, char objectType)
           changeManagerMask enables or disables certain events for this JSDT Manager.
 void destroy(com.sun.media.jsdt.Client client, char objectType)
           destroy this Manageable object.
 void expel(com.sun.media.jsdt.Client[] clients, char objectType)
           expel Clients from this Manageable object.
 java.lang.Object getProxy()
           getProxy get a handle to the client-side proxy for this manageable object.
 com.sun.media.jsdt.Session getSession()
           get the name of the Session that this manageable object belongs to.
 void initProxy(java.lang.String name, SessionImpl session, java.lang.Object object)
           initProxy initialise the client-side proxy for this manageable object.
 void invite(com.sun.media.jsdt.Client[] clients, char objectType)
           invite Clients to join this Manageable object.
 boolean isManaged(char objectType, java.lang.String objectName)
           test whether this managed object actually has a manager associated with it.
 void join(com.sun.media.jsdt.Client client, boolean authenticate, char objectType)
           join a Client to this Manageable object.
 void leave(com.sun.media.jsdt.Client client, char objectType)
           removes a Client from this Manageable object.
 java.lang.String[] listClientNames(char objectType)
           list the names of the Clients who are joined to this Manageable object.
 void removeListener(java.util.EventListener listener, char listenerType)
           removeListener remove a listener from this manageable object.
 

Method Detail

initProxy

public void initProxy(java.lang.String name,
                      SessionImpl session,
                      java.lang.Object object)
initProxy initialise the client-side proxy for this manageable object.
Parameters:
name - the name of the manageable proxy being constructed.
session - the client-side session the manageable object belongs to.
object - the client-side manageable object.

getProxy

public java.lang.Object getProxy()
getProxy get a handle to the client-side proxy for this manageable object.
Returns:
the client-side proxy for this manageable object.

getSession

public com.sun.media.jsdt.Session getSession()
get the name of the Session that this manageable object belongs to. If this method is applied to a Session, a reference to itself is returned.
Returns:
the name of the Session that this manageable object belongs to.

addListener

public void addListener(java.util.EventListener listener,
                        char listenerType)
                 throws com.sun.media.jsdt.ConnectionException,
                        com.sun.media.jsdt.NoSuchByteArrayException,
                        com.sun.media.jsdt.NoSuchChannelException,
                        com.sun.media.jsdt.NoSuchSessionException,
                        com.sun.media.jsdt.NoSuchTokenException,
                        com.sun.media.jsdt.TimedOutException
addListener add a listener to this manageable object.
Parameters:
listener - the listener for this manageable object.
listenerType - the type of listener. This will be one of: SessionImpl.M_Session, ChannelImpl.M_Channel, ByteArrayImpl.M_ByteArray or TokenImpl.M_Token.
Throws:
com.sun.media.jsdt.ConnectionException - if a connection error occured.
com.sun.media.jsdt.NoSuchByteArrayException - if this ByteArray doesn't exist
com.sun.media.jsdt.NoSuchChannelException - if this Channel doesn't exist.
com.sun.media.jsdt.NoSuchSessionException - if this Session doesn't exist.
com.sun.media.jsdt.NoSuchTokenException - if this Token doesn't exist.
com.sun.media.jsdt.TimedOutException - if no reply was received for this operation in the given timeout period.

removeListener

public void removeListener(java.util.EventListener listener,
                           char listenerType)
                    throws com.sun.media.jsdt.ConnectionException,
                           com.sun.media.jsdt.NoSuchByteArrayException,
                           com.sun.media.jsdt.NoSuchChannelException,
                           com.sun.media.jsdt.NoSuchListenerException,
                           com.sun.media.jsdt.NoSuchSessionException,
                           com.sun.media.jsdt.NoSuchTokenException,
                           com.sun.media.jsdt.TimedOutException
removeListener remove a listener from this manageable object.
Parameters:
listener - the listener for this manageable object.
listenerType - the type of listener. This will be one of: SessionImpl.M_Session, ChannelImpl.M_Channel, ByteArrayImpl.M_ByteArray or TokenImpl.M_Token.
Throws:
com.sun.media.jsdt.ConnectionException - if a connection error occured.
com.sun.media.jsdt.NoSuchByteArrayException - if this ByteArray doesn't exist
com.sun.media.jsdt.NoSuchChannelException - if this Channel doesn't exist.
com.sun.media.jsdt.NoSuchListenerException - if this Listener doesn't exist.
com.sun.media.jsdt.NoSuchSessionException - if this Session doesn't exist.
com.sun.media.jsdt.NoSuchTokenException - if this Token doesn't exist.
com.sun.media.jsdt.TimedOutException - if no reply was received for this operation in the given timeout period.

changeListenerMask

public void changeListenerMask(java.util.EventListener listener,
                               int eventMask,
                               boolean disable)
                        throws com.sun.media.jsdt.NoSuchSessionException,
                               com.sun.media.jsdt.NoSuchChannelException,
                               com.sun.media.jsdt.NoSuchByteArrayException,
                               com.sun.media.jsdt.NoSuchTokenException,
                               com.sun.media.jsdt.NoSuchListenerException
changeListenerMask enables or disables certain events for this JSDT listener.
Parameters:
listener - the listener whose event mask is being changed.
eventMask - the mask of events to be enabled or disabled.
disable - if set true, then disable these events for this listener, else enable them.
Throws:
com.sun.media.jsdt.NoSuchSessionException - if this Session doesn't exist.
com.sun.media.jsdt.NoSuchByteArrayException - if this ByteArray doesn't exist.
com.sun.media.jsdt.NoSuchChannelException - if this Channel doesn't exist.
com.sun.media.jsdt.NoSuchTokenException - if this Token doesn't exist.
com.sun.media.jsdt.NoSuchListenerException - if this Listener doesn't exist.

changeManagerMask

public void changeManagerMask(com.sun.media.jsdt.JSDTManager manager,
                              int eventMask,
                              boolean disable,
                              char objectType)
                       throws com.sun.media.jsdt.ConnectionException,
                              com.sun.media.jsdt.NoSuchSessionException,
                              com.sun.media.jsdt.NoSuchChannelException,
                              com.sun.media.jsdt.NoSuchByteArrayException,
                              com.sun.media.jsdt.NoSuchTokenException,
                              com.sun.media.jsdt.NoSuchManagerException,
                              com.sun.media.jsdt.TimedOutException
changeManagerMask enables or disables certain events for this JSDT Manager.
Parameters:
manager - the manager whose event mask is being changed.
eventMask - the mask of events to be enabled or disabled.
disable - if set true, then disable these events for this manager, else enable them.
objectType - the type of the manageable object. This will be one of: SessionImpl.M_Session, ChannelImpl.M_Channel, ByteArrayImpl.M_ByteArray or TokenImpl.M_Token.
Throws:
com.sun.media.jsdt.ConnectionException - if a connection error occured.
com.sun.media.jsdt.NoSuchSessionException - if this Session doesn't exist.
com.sun.media.jsdt.NoSuchByteArrayException - if this ByteArray doesn't exist.
com.sun.media.jsdt.NoSuchChannelException - if this Channel doesn't exist.
com.sun.media.jsdt.NoSuchTokenException - if this Token doesn't exist.
com.sun.media.jsdt.NoSuchManagerException - if this Manager doesn't exist.
com.sun.media.jsdt.TimedOutException - if no reply was received for this operation in the given timeout period.

expel

public void expel(com.sun.media.jsdt.Client[] clients,
                  char objectType)
           throws com.sun.media.jsdt.ConnectionException,
                  com.sun.media.jsdt.InvalidClientException,
                  com.sun.media.jsdt.NoSuchSessionException,
                  com.sun.media.jsdt.NoSuchChannelException,
                  com.sun.media.jsdt.NoSuchByteArrayException,
                  com.sun.media.jsdt.NoSuchClientException,
                  com.sun.media.jsdt.NoSuchTokenException,
                  com.sun.media.jsdt.PermissionDeniedException,
                  com.sun.media.jsdt.TimedOutException
expel Clients from this Manageable object.

This method should only be called by the manager for this object. An indication is delivered to each listener of this Manageable object, for each Client expelled.

Parameters:
clients - the list of Clients to be expelled from this object.
objectType - the type of the manageable object. This will be one of: SessionImpl.M_Session, ChannelImpl.M_Channel, ByteArrayImpl.M_ByteArray or TokenImpl.M_Token.
Throws:
com.sun.media.jsdt.ConnectionException - if a connection error occured.
com.sun.media.jsdt.InvalidClientException - if the Client is invalid is some way (ie. its getName() method returns null).
com.sun.media.jsdt.NoSuchSessionException - if this Session doesn't exist.
com.sun.media.jsdt.NoSuchByteArrayException - if this ByteArray doesn't exist.
com.sun.media.jsdt.NoSuchClientException - if this Client doesn't exist.
com.sun.media.jsdt.NoSuchChannelException - if this Channel doesn't exist.
com.sun.media.jsdt.NoSuchTokenException - if this Token doesn't exist.
com.sun.media.jsdt.PermissionDeniedException - if this Client doesn't have permission for this operation.
com.sun.media.jsdt.TimedOutException - if no reply was received for this operation in the given timeout period.

invite

public void invite(com.sun.media.jsdt.Client[] clients,
                   char objectType)
            throws com.sun.media.jsdt.ConnectionException,
                   com.sun.media.jsdt.InvalidClientException,
                   com.sun.media.jsdt.NoSuchSessionException,
                   com.sun.media.jsdt.NoSuchChannelException,
                   com.sun.media.jsdt.NoSuchByteArrayException,
                   com.sun.media.jsdt.NoSuchClientException,
                   com.sun.media.jsdt.NoSuchTokenException,
                   com.sun.media.jsdt.PermissionDeniedException,
                   com.sun.media.jsdt.TimedOutException
invite Clients to join this Manageable object.

This method should only be called by the manager for this object. An indication is delivered to each listener of this Manageable object, for each Client invited.

Parameters:
clients - the list of Clients to be invited to join this object.
objectType - the type of the manageable object. This will be one of: SessionImpl.M_Session, ChannelImpl.M_Channel, ByteArrayImpl.M_ByteArray or TokenImpl.M_Token.
Throws:
com.sun.media.jsdt.ConnectionException - if a connection error occured.
com.sun.media.jsdt.InvalidClientException - if the Client is invalid is some way (ie. its getName() method returns null).
com.sun.media.jsdt.NoSuchSessionException - if this Session doesn't exist.
com.sun.media.jsdt.NoSuchByteArrayException - if this ByteArray doesn't exist.
com.sun.media.jsdt.NoSuchClientException - if this Client doesn't exist.
com.sun.media.jsdt.NoSuchChannelException - if this Channel doesn't exist.
com.sun.media.jsdt.NoSuchTokenException - if this Token doesn't exist.
com.sun.media.jsdt.PermissionDeniedException - if this Client doesn't have permission for this operation.
com.sun.media.jsdt.TimedOutException - if no reply was received for this operation in the given timeout period.

destroy

public void destroy(com.sun.media.jsdt.Client client,
                    char objectType)
             throws com.sun.media.jsdt.ConnectionException,
                    com.sun.media.jsdt.InvalidClientException,
                    com.sun.media.jsdt.NoSuchSessionException,
                    com.sun.media.jsdt.NoSuchChannelException,
                    com.sun.media.jsdt.NoSuchByteArrayException,
                    com.sun.media.jsdt.NoSuchClientException,
                    com.sun.media.jsdt.NoSuchTokenException,
                    com.sun.media.jsdt.PermissionDeniedException,
                    com.sun.media.jsdt.TimedOutException
destroy this Manageable object.

An indication is delivered to each listener of this Manageable object, that it has been destroyed. If this is for a ByteArray, Channel or Token in a managed Session, then the Client is authenticated to determine if it is permitted to do this operation.

Parameters:
client - the Client wishing to destroy this object.
objectType - the type of the manageable object. This will be one of: SessionImpl.M_Session, ChannelImpl.M_Channel, ByteArrayImpl.M_ByteArray or TokenImpl.M_Token.
Throws:
com.sun.media.jsdt.ConnectionException - if a connection error occured.
com.sun.media.jsdt.InvalidClientException - if the Client is invalid is some way (ie. its getName() method returns null).
com.sun.media.jsdt.NoSuchSessionException - if this Session doesn't exist.
com.sun.media.jsdt.NoSuchChannelException - if this Channel doesn't exist.
com.sun.media.jsdt.NoSuchByteArrayException - if this ByteArray doesn't exist.
com.sun.media.jsdt.NoSuchClientException - if this Client doesn't exist.
com.sun.media.jsdt.NoSuchTokenException - if this Token doesn't exist.
com.sun.media.jsdt.PermissionDeniedException - if this Client doesn't have permission for this operation.
com.sun.media.jsdt.TimedOutException - if no reply was received for this operation in the given timeout period.

isManaged

public boolean isManaged(char objectType,
                         java.lang.String objectName)
                  throws com.sun.media.jsdt.ConnectionException,
                         com.sun.media.jsdt.NoSuchSessionException,
                         com.sun.media.jsdt.NoSuchChannelException,
                         com.sun.media.jsdt.NoSuchByteArrayException,
                         com.sun.media.jsdt.NoSuchTokenException,
                         com.sun.media.jsdt.TimedOutException
test whether this managed object actually has a manager associated with it.
Parameters:
objectType - the type of the manageable object. This will be one of: SessionImpl.M_Session, ChannelImpl.M_Channel, ByteArrayImpl.M_ByteArray or TokenImpl.M_Token.
objectName - the name of the manageable object.
Throws:
com.sun.media.jsdt.ConnectionException - if a connection error occured.
com.sun.media.jsdt.NoSuchSessionException - if this Session doesn't exist.
com.sun.media.jsdt.NoSuchChannelException - if this Channel doesn't exist.
com.sun.media.jsdt.NoSuchByteArrayException - if this ByteArray doesn't exist.
com.sun.media.jsdt.NoSuchTokenException - if this Token doesn't exist.
com.sun.media.jsdt.TimedOutException - if no reply was received for this operation in the given timeout period.

join

public void join(com.sun.media.jsdt.Client client,
                 boolean authenticate,
                 char objectType)
          throws com.sun.media.jsdt.ConnectionException,
                 com.sun.media.jsdt.InvalidClientException,
                 com.sun.media.jsdt.NoSuchByteArrayException,
                 com.sun.media.jsdt.NoSuchChannelException,
                 com.sun.media.jsdt.NoSuchClientException,
                 com.sun.media.jsdt.NoSuchSessionException,
                 com.sun.media.jsdt.NoSuchTokenException,
                 com.sun.media.jsdt.PermissionDeniedException,
                 com.sun.media.jsdt.NameInUseException,
                 com.sun.media.jsdt.TimedOutException
join a Client to this Manageable object.

If this is a managed object, then the Client is authenticated to determine if it is permitted to do this operation.

Parameters:
client - the Client wishing to join this Manageable object.
authenticate - set true if this Client should be authenticated.
objectType - the type of the manageable object. This will be one of: SessionImpl.M_Session, ChannelImpl.M_Channel, ByteArrayImpl.M_ByteArray or TokenImpl.M_Token.
Throws:
com.sun.media.jsdt.ConnectionException - if a connection error occured.
com.sun.media.jsdt.InvalidClientException - if the Client is invalid is some way (ie. its getName() method returns null).
com.sun.media.jsdt.NoSuchByteArrayException - if this ByteArray doesn't exist.
com.sun.media.jsdt.NoSuchChannelException - if this Channel doesn't exist.
com.sun.media.jsdt.NoSuchClientException - if this Client doesn't exist.
com.sun.media.jsdt.NoSuchSessionException - if this Session doesn't exist.
com.sun.media.jsdt.NoSuchTokenException - if this Token doesn't exist.
com.sun.media.jsdt.PermissionDeniedException - if this Client doesn't have permission for this operation.
com.sun.media.jsdt.NameInUseException - if a Client with this name is already joined to this Manageable object.
com.sun.media.jsdt.TimedOutException - if no reply was received for this operation in the given timeout period.

leave

public void leave(com.sun.media.jsdt.Client client,
                  char objectType)
           throws com.sun.media.jsdt.ConnectionException,
                  com.sun.media.jsdt.InvalidClientException,
                  com.sun.media.jsdt.NoSuchByteArrayException,
                  com.sun.media.jsdt.NoSuchChannelException,
                  com.sun.media.jsdt.NoSuchClientException,
                  com.sun.media.jsdt.NoSuchSessionException,
                  com.sun.media.jsdt.NoSuchTokenException,
                  com.sun.media.jsdt.TimedOutException
removes a Client from this Manageable object. This Client will no longer be known to this object. Listeners of this object will be sent an indication when this happens.
Parameters:
client - the Client in question.
objectType - the type of the manageable object. This will be one of: SessionImpl.M_Session, ChannelImpl.M_Channel, ByteArrayImpl.M_ByteArray or TokenImpl.M_Token.
Throws:
com.sun.media.jsdt.ConnectionException - if a connection error occured.
com.sun.media.jsdt.InvalidClientException - if the Client is invalid is some way (ie. its getName() method returns null).
com.sun.media.jsdt.NoSuchByteArrayException - if this ByteArray doesn't exist.
com.sun.media.jsdt.NoSuchChannelException - if this Channel doesn't exist.
com.sun.media.jsdt.NoSuchClientException - if this Client doesn't exist.
com.sun.media.jsdt.NoSuchSessionException - if this Session doesn't exist.
com.sun.media.jsdt.NoSuchTokenException - if this Token doesn't exist.
com.sun.media.jsdt.TimedOutException - if no reply was received for this operation in the given timeout period.

listClientNames

public java.lang.String[] listClientNames(char objectType)
                                   throws com.sun.media.jsdt.ConnectionException,
                                          com.sun.media.jsdt.NoSuchSessionException,
                                          com.sun.media.jsdt.NoSuchChannelException,
                                          com.sun.media.jsdt.NoSuchByteArrayException,
                                          com.sun.media.jsdt.NoSuchTokenException,
                                          com.sun.media.jsdt.TimedOutException
list the names of the Clients who are joined to this Manageable object.
Parameters:
objectType - the type of the manageable object. This will be one of: SessionImpl.M_Session, ChannelImpl.M_Channel, ByteArrayImpl.M_ByteArray or TokenImpl.M_Token.
Returns:
a sorted array of names of Clients currently joined to this object.
Throws:
com.sun.media.jsdt.ConnectionException - if a connection error occured.
com.sun.media.jsdt.NoSuchByteArrayException - if this ByteArray doesn't exist.
com.sun.media.jsdt.NoSuchChannelException - if this Channel doesn't exist.
com.sun.media.jsdt.NoSuchSessionException - if this Session doesn't exist.
com.sun.media.jsdt.NoSuchTokenException - if this Token doesn't exist. in the given timeout period.
com.sun.media.jsdt.TimedOutException - if no reply was received for this operation in the given timeout period.