|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectutil.PropertyContainer
util.rmi.RmiPropertyContainer
util.rmi.AbstractRmiListener
stella.rmi.AbstractRmiCasterAndListener
public abstract class AbstractRmiCasterAndListener
The common base class for all classes that are both, casters and listeners.
It is an extension to AbstractRmiListener and has all methods of
AbstractRmiCaster copied into it.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class util.PropertyContainer |
|---|
PropertyContainer.URLResource |
| Field Summary | |
|---|---|
private List<ErrorListener> |
errlist
The vector containing local error listeners. |
private List<RmiErrorListener> |
rmilist
The vector containing rmi error listeners. |
| Fields inherited from class util.rmi.AbstractRmiListener |
|---|
KEY_ALIVE, KEY_EXPORTPORT, KEY_INIT, KEY_LISTENERNAME, KEY_RETRY, KEY_RETRYSLEEP, KEY_SHUTDOWNDELAY |
| Fields inherited from class util.PropertyContainer |
|---|
KEY_LISTSEPARATOR, KEY_LOCALECOUNTRY, KEY_LOCALELANGUAGE, KEY_MAPKEYVALUECHAR, KEY_MAPSEPARATOR, KEY_NOINITONCREATE, KEY_RESOURCEBUNDLES |
| Fields inherited from interface util.PropertyBearing |
|---|
CONFIG, KEY_CLASS, KEY_URLRESOURCES, KEY_URLUSECONFIG, KEY_URLUSECURRENT, KEY_URLUSEHOME |
| Constructor Summary | |
|---|---|
protected |
AbstractRmiCasterAndListener(Map prop)
Constructs a new rmi-caster. |
| Method Summary | |
|---|---|
void |
addErrorListener(ErrorListener ear)
Registers an error event listener to this property container. |
void |
addRmiErrorListener(RmiErrorListener ear)
Registers a rmi error event listener to this property container. |
boolean |
bindToRegistry()
Binds this class's casting capabilities to a running registry. |
void |
exit()
Removes my rmi error listeners. |
String |
getBindName()
Tries to retrieve my binding name. |
boolean |
isValid()
The method for listeners to check if the remote reference is still valid. |
protected void |
notifyErrorListener(ErrorEvent ee,
List<ErrorListener> local,
List<RmiErrorListener> remote)
Notifies all registered ErrorListeners. |
void |
removeErrorListener(ErrorListener ear)
Deregisters an error event listener from this property container. |
void |
removeRmiErrorListener(RmiErrorListener ear)
Deregisters an rmi error event listener from this property container. |
void |
sendError(ErrorEvent ee)
Sends the error message directly. |
void |
sendError(String mess)
Wraps the argumental String into an error message and passes it to the error listeners. |
void |
sendError(Throwable thrown)
Wraps the argumental THrowable into an error message and passes it to the error listeners. |
void |
sendStatus(ErrorEvent ee)
Sends the status event back to registered listeners. |
void |
sendStatus(List stati)
Processes an entire list of status messages that should be sent to the error listeners. |
void |
sendStatus(String mess)
Wraps the argumental String into an error message and passes it to the error listeners. |
boolean |
unbindFromRegistry()
Unbinds this repository from the registry. |
| Methods inherited from class util.rmi.AbstractRmiListener |
|---|
allBound, blockBinding, blockBinding, deregisterAtCaster, disconnect, getIP, getListenerName, isConnected, listenerName, registerAtCaster, releaseBinding, releaseBinding, rescanned, startBinding, startBinding |
| Methods inherited from class util.rmi.RmiPropertyContainer |
|---|
containsRemoteProperty, getRemoteProperties, getRemoteProperty, setRemoteProperty |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private List<ErrorListener> errlist
private List<RmiErrorListener> rmilist
| Constructor Detail |
|---|
protected AbstractRmiCasterAndListener(Map prop)
| Method Detail |
|---|
public void exit()
exit in interface ExitCleaningexit in class AbstractRmiListener
public boolean isValid()
throws RemoteException
isValid in interface RmiCasterRemoteException
public boolean bindToRegistry()
throws RemoteException
bindToRegistry in interface RmiCasterRemoteException
public boolean unbindFromRegistry()
throws RemoteException
unbindFromRegistry in interface RmiCasterRemoteExceptionpublic String getBindName()
#mycast is a subclass of
AbstractRmiCaster this is no problem.
public void addErrorListener(ErrorListener ear)
public void removeErrorListener(ErrorListener ear)
public void addRmiErrorListener(RmiErrorListener ear)
throws RemoteException
addRmiErrorListener in interface RmiErrorCasterRemoteException
public void removeRmiErrorListener(RmiErrorListener ear)
throws RemoteException
removeRmiErrorListener in interface RmiErrorCasterRemoteExceptionpublic void sendError(Throwable thrown)
public void sendError(String mess)
public void sendError(ErrorEvent ee)
sendError in interface ErrorSendingpublic void sendStatus(String mess)
public void sendStatus(List stati)
public void sendStatus(ErrorEvent ee)
ReceiverTorso.processCommand(stella.CommandEvent, int) method.notifyErrorListener(stella.ErrorEvent, java.util.List, java.util.List) method.
protected void notifyErrorListener(ErrorEvent ee,
List<ErrorListener> local,
List<RmiErrorListener> remote)
ee - The ErrorEvent to pass to the Listeners.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||