public class StatusSerializer extends AbstractRmiListener implements RmiErrorListener, Initializable
GuiderInfos.| Modifier and Type | Class and Description |
|---|---|
static class |
StatusSerializer.FromLog
Reads a log file of the adapter and tries to construct serialized guider
info out of it.
|
static class |
StatusSerializer.Run
Runs the status serializer.
|
static class |
StatusSerializer.Test
Test the class by serializing a single guider info,
acquire20060408-0014-0000-reduced.fits
|
PropertyResources.Load, PropertyResources.URLResource| Modifier and Type | Field and Description |
|---|---|
private static String |
DEFADAPTERMASTER
Default binding name for the adapter master.
|
private static File |
DEFSAVEPATH
Default save path directory.
|
private String |
fitshead
The truncated serialize-file name.
|
static String |
KEY_ADAPTERMASTER
The key denoting a comma-separated list of error casters.
|
static String |
KEY_SAVEPATH
The directory where we serialize guider infos into.
|
private GuiderInfo |
serial
The re-used container for incoming status messages.
|
KEY_ALIVE, KEY_EXPORTPORT, KEY_INIT, KEY_LISTENERNAME, KEY_RETRY, KEY_RETRYSLEEP, KEY_SHUTDOWNDELAYKEY_NOINITONCREATE, POSTFIX_ALPHABET, POSTFIX_BYTES, POSTFIX_DIR, POSTFIX_EXT, POSTFIX_FILE, POSTFIX_LIST, POSTFIX_MODTIME, POSTFIX_URLKEY_LISTSEPARATOR, KEY_MAPKEYVALUECHAR, KEY_MAPSEPARATORKEY_URLRESOURCES, KEY_URLUSECONFIG, KEY_URLUSECURRENT, KEY_URLUSEHOMECONFIG, KEY_CLASS| Constructor and Description |
|---|
StatusSerializer(Map info)
Constructs a new message logger.
|
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
deregisterAtCaster(RmiCaster rmi,
Class single)
Deregisters at caster.
|
void |
init()
Register at the appropriate casters found in the various lists.
|
protected boolean |
registerAtCaster(RmiCaster rmi,
Class single)
Registers at the specified caster if the caster is one of the four
possible caster instances this class listens to.
|
void |
rmiErrorOccured(ErrorEvent ee)
The receiving edge of the error listener.
|
private static void |
serialize(GuiderInfo gi,
File path)
Serializes the current
GuiderInfo object using the fitsheader
truncated file name, append #GUIDERINFOEXTENSION and serializes
it into KEY_SAVEPATH. |
allBound, blockBinding, blockBinding, disconnect, exit, getIP, getListenerName, isConnected, listenerName, releaseBinding, releaseBinding, rescanned, startBinding, startBindingcontainsRemoteProperty, getRemoteProperties, getRemoteProperty, setRemotePropertyclone, createFrom, createFrom, createFrom, createInstance, getApplet, getAsResources, getLocate, getPropertiesToKey, getPropertiesToKey, getResource, getResourceAsStream, getResourceFromKey, getResources, hasLocalURLs, initProperties, keyCreate, keyCreate, reload, setAppletaugment, augment, 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, parseObject, reload, removeProperty, requires, setObject, setProperties, setProperty, stringProperties, toStringequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetListenerNamedisconnect, isConnecteddefaultBoolean, 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, stringPropertiespublic static final String KEY_ADAPTERMASTER
public static final String KEY_SAVEPATH
private static final String DEFADAPTERMASTER
private static final File DEFSAVEPATH
private GuiderInfo serial
private String fitshead
public StatusSerializer(Map info) throws RemoteException
RemoteExceptionpublic void init()
init in interface Initializablepublic void rmiErrorOccured(ErrorEvent ee) throws RemoteException
GuiderInfo with it.rmiErrorOccured in interface RmiErrorListenerRemoteExceptionprotected boolean registerAtCaster(RmiCaster rmi, Class single)
registerAtCaster in class AbstractRmiListenerprotected boolean deregisterAtCaster(RmiCaster rmi, Class single)
deregisterAtCaster in class AbstractRmiListenerprivate static void serialize(GuiderInfo gi, File path) throws IOException
GuiderInfo object using the fitsheader
truncated file name, append #GUIDERINFOEXTENSION and serializes
it into KEY_SAVEPATH.IOException