|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjmri.jmrix.sprog.update.SprogVersionQuery
public class SprogVersionQuery
Get the firmware version of the attached SPROG
| Nested Class Summary | |
|---|---|
(package private) static class |
SprogVersionQuery.QueryState
|
| Field Summary | |
|---|---|
(package private) static org.slf4j.Logger |
log
|
protected static int |
LONG_TIMEOUT
|
(package private) String |
replyString
|
protected static SprogVersionQuery |
self
|
(package private) static SprogVersionQuery.QueryState |
state
|
(package private) static SprogTrafficController |
tc
|
(package private) static Timer |
timer
|
(package private) static SprogVersion |
ver
|
protected static Vector<SprogVersionListener> |
versionListeners
|
| Constructor Summary | |
|---|---|
SprogVersionQuery()
|
|
| Method Summary | |
|---|---|
protected void |
addSprogVersionListener(SprogVersionListener l)
|
static SprogVersionQuery |
instance()
static function returning the SprogVersionQuery instance to use. |
void |
notifyMessage(SprogMessage m)
SprogListener notify Message not used |
void |
notifyReply(SprogReply m)
SprogListener notify Reply listens to replies and looks for version reply |
protected static void |
notifyVersion(SprogVersion v)
Notify all registered listeners of the SPROG version |
void |
removeSprogVersionListener(SprogVersionListener l)
|
static void |
requestVersion(SprogVersionListener l)
|
protected static void |
restartTimer(int delay)
Internal routine to handle timer starts & restarts |
protected static void |
startLongTimer()
Internal routine to restart timer with a long delay |
protected void |
stopTimer()
Internal routine to stop timer, as all is well |
protected static void |
timeout()
Internal routine to handle a timeout |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
String replyString
static SprogTrafficController tc
static SprogVersion ver
static SprogVersionQuery.QueryState state
protected static final int LONG_TIMEOUT
static Timer timer
protected static final Vector<SprogVersionListener> versionListeners
protected static volatile SprogVersionQuery self
static org.slf4j.Logger log
| Constructor Detail |
|---|
public SprogVersionQuery()
| Method Detail |
|---|
protected void addSprogVersionListener(SprogVersionListener l)
public void removeSprogVersionListener(SprogVersionListener l)
public static SprogVersionQuery instance()
public static void requestVersion(SprogVersionListener l)
protected static void notifyVersion(SprogVersion v)
v - public void notifyMessage(SprogMessage m)
notifyMessage in interface SprogListenerm - public void notifyReply(SprogReply m)
notifyReply in interface SprogListenerm - protected static void timeout()
protected static void startLongTimer()
protected void stopTimer()
protected static void restartTimer(int delay)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||