|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectutil.PropertyContainer
util.PropertyResources
util.PropertyBundles
util.rmi.RmiPropertyContainer
util.rmi.AbstractRmiListener
stella.MessageListener
public class MessageListener
A class to use as message listener. Depending on the various keys,
KEY_COMMAND, KEY_ACKNOWLEDGE, KEY_DONE,
KEY_ERROR, KEY_DATA, KEY_SERIAL, and
KEY_WEATHER this logger registers itself at the appropriate
rmi-casters. Any message received from the casters is dumped into the
Syslog.
| Nested Class Summary | |
|---|---|
static class |
MessageListener.Run
Runs the message listener. |
| Nested classes/interfaces inherited from class util.PropertyResources |
|---|
PropertyResources.URLResource |
| Field Summary | |
|---|---|
private static boolean |
DEFBIND
The default binding behaviour. |
private static String |
DEFBINDNAME
The default binding name. |
static String |
KEY_ACKNOWLEDGE
The key denoting a comma-separated list of acknowledge casters. |
static String |
KEY_BIND
The key matching the default command casting binding. |
static String |
KEY_BINDNAME
The key in the properties defining the binding name of this caster. |
static String |
KEY_COMMAND
The key denoting a comma-separated list of command casters. |
static String |
KEY_DATA
The key denoting a comma-separated list of data casters. |
static String |
KEY_DONE
The key denoting a comma-separated list of done casters. |
static String |
KEY_ERROR
The key denoting a comma-separated list of error casters. |
static String |
KEY_SERIAL
The key denoting a comma-separated list of serial casters. |
static String |
KEY_WEATHER
The key denoting a comma-separated list of weather casters. |
| 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.PropertyBundles |
|---|
KEY_LOCALECOUNTRY, KEY_LOCALELANGUAGE, KEY_RESOURCEBUNDLES |
| Fields inherited from class util.PropertyResources |
|---|
KEY_NOINITONCREATE, localurl, locate, POSTFIX_DIR, POSTFIX_EXT, POSTFIX_FILE, POSTFIX_LIST, POSTFIX_URL, urlset |
| Fields inherited from class util.PropertyContainer |
|---|
KEY_LISTSEPARATOR, KEY_MAPKEYVALUECHAR, KEY_MAPSEPARATOR |
| Fields inherited from interface util.ResourceSupplying |
|---|
KEY_URLRESOURCES, KEY_URLUSECONFIG, KEY_URLUSECURRENT, KEY_URLUSEHOME |
| Fields inherited from interface util.PropertySupplying |
|---|
CONFIG, KEY_CLASS |
| Constructor Summary | |
|---|---|
MessageListener(Map info)
Constructs a new message logger. |
|
| Method Summary | |
|---|---|
boolean |
accepts(CommandEvent ce)
A message listener accepts all command event types. |
protected boolean |
deregisterAtCaster(RmiCaster rmi,
Class service)
Deregisters at caster. |
void |
exit()
The exit-cleaning functionality. |
void |
init()
Register at the appropriate casters found in the various lists. |
private void |
register(String list,
Class casterclass)
Registers at a caster list. |
protected boolean |
registerAtCaster(RmiCaster rmi,
Class service)
Registers at the specified caster if the caster is one of the four possible caster instances this class listens to. |
void |
rmiCommand(CommandEvent ce)
The receiving edge of the command listener. |
void |
rmiDataAvailable(DataEvent de)
The receiving edge of the data listener. |
void |
rmiErrorOccured(ErrorEvent ee)
The receiving edge of the error listener. |
void |
rmiGotAcknowledge(AcknowledgeEvent ae)
The receiving edge of the acknowledge listener. |
void |
rmiGotDone(DoneEvent de)
The receiving edge of the done listener. |
void |
rmiSerial(SerialEvent se)
The receiving edge of the serial listener. |
void |
rmiWeatherChanged(WeatherEvent we)
The receiving edge of weather events. |
| Methods inherited from class util.rmi.AbstractRmiListener |
|---|
allBound, blockBinding, blockBinding, disconnect, getIP, getListenerName, isConnected, listenerName, releaseBinding, releaseBinding, rescanned, startBinding, startBinding |
| Methods inherited from class util.rmi.RmiPropertyContainer |
|---|
containsRemoteProperty, getRemoteProperties, getRemoteProperty, setRemoteProperty |
| Methods inherited from class util.PropertyBundles |
|---|
clone, getLocalized, getLocalized, getLocalizedString, getLocalizedString, loadResource |
| Methods inherited from class util.PropertyResources |
|---|
createFrom, createFrom, createFrom, getApplet, getAsResources, getLocalClassLoader, getPropertiesToKey, getPropertiesToKey, getResource, getResourceAsStream, getResourceFromKey, getResources, keyCreate, keyCreate, reload, setApplet |
| Methods inherited from class util.PropertyContainer |
|---|
augment, augment, augment, defaultBoolean, defaultChar, defaultDouble, defaultFloat, defaultInt, defaultLong, defaultObject, defaultObject, defaultProperties, defaultProperty, getAsBoolean, getAsChar, getAsDouble, getAsEnums, getAsFloat, getAsInt, getAsList, getAsLong, getAsMap, getAsMap, getAsObject, getAsObject, getProperties, getProperty, has, isNew, parseObject, reload, removeProperty, setObject, setProperties, setProperty, stringProperties, toString |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface util.rmi.RmiEventListener |
|---|
getListenerName |
| Methods inherited from interface util.rmi.RmiListener |
|---|
disconnect, isConnected |
| Methods inherited from interface util.ResourceSupplying |
|---|
getResource, getResourceAsStream, getResources |
| Methods inherited from interface util.PropertySupplying |
|---|
defaultBoolean, defaultChar, defaultDouble, defaultFloat, defaultInt, defaultLong, defaultObject, defaultObject, defaultProperties, defaultProperty, getAsBoolean, getAsChar, getAsDouble, getAsFloat, getAsInt, getAsList, getAsLong, getAsMap, getAsObject, getAsObject, getProperties, getProperty, has, parseObject, removeProperty, setObject, setProperty, stringProperties |
| Field Detail |
|---|
public static final String KEY_COMMAND
public static final String KEY_ERROR
public static final String KEY_DONE
public static final String KEY_ACKNOWLEDGE
public static final String KEY_DATA
public static final String KEY_SERIAL
public static final String KEY_WEATHER
public static final String KEY_BINDNAME
public static final String KEY_BIND
private static final String DEFBINDNAME
private static final boolean DEFBIND
| Constructor Detail |
|---|
public MessageListener(Map info)
throws RemoteException
RemoteException| Method Detail |
|---|
public void init()
init in interface Initializableinit in class PropertyResourcespublic void exit()
exit in interface ExitCleaningexit in class AbstractRmiListener
public boolean accepts(CommandEvent ce)
throws RemoteException
accepts in interface RmiCommandListenerRemoteException
public void rmiCommand(CommandEvent ce)
throws RemoteException
rmiCommand in interface RmiCommandListenerRemoteException
public void rmiGotAcknowledge(AcknowledgeEvent ae)
throws RemoteException
rmiGotAcknowledge in interface RmiAcknowledgeListenerRemoteException
public void rmiGotDone(DoneEvent de)
throws RemoteException
rmiGotDone in interface RmiDoneListenerRemoteException
public void rmiErrorOccured(ErrorEvent ee)
throws RemoteException
rmiErrorOccured in interface RmiErrorListenerRemoteException
public void rmiDataAvailable(DataEvent de)
throws RemoteException
rmiDataAvailable in interface RmiDataListenerRemoteException
public void rmiSerial(SerialEvent se)
throws RemoteException
rmiSerial in interface RmiSerialListenerRemoteException
public void rmiWeatherChanged(WeatherEvent we)
throws RemoteException
rmiWeatherChanged in interface RmiWeatherListenerRemoteException
protected boolean registerAtCaster(RmiCaster rmi,
Class service)
registerAtCaster in class AbstractRmiListener
protected boolean deregisterAtCaster(RmiCaster rmi,
Class service)
deregisterAtCaster in class AbstractRmiListener
private void register(String list,
Class casterclass)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||