|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjmri.jmrix.AbstractMRTrafficController
jmri.jmrix.AbstractMRNodeTrafficController
public abstract class AbstractMRNodeTrafficController
Abstract Traffic Controller base class for those implementations that track a set of nodes.
The nodes are descendents of AbstractNode.
Provides node management services, but no additional protocol.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class jmri.jmrix.AbstractMRTrafficController |
|---|
AbstractMRTrafficController.RcvNotifier, AbstractMRTrafficController.XmtNotifier |
| Field Summary | |
|---|---|
protected int |
maxNode
|
protected int |
minNode
|
| Fields inherited from class jmri.jmrix.AbstractMRTrafficController |
|---|
allowUnexpectedReply, cmdListeners, controller, IDLESTATE, istream, mCurrentMode, mCurrentState, mLastSender, mWaitBeforePoll, NORMALMODE, NOTIFIEDSTATE, OKSENDMSGSTATE, ostream, PROGRAMINGMODE, replyInDispatch, WAITMSGREPLYSTATE, WAITREPLYINNORMMODESTATE, WAITREPLYINPROGMODESTATE, xmtRunnable |
| Constructor Summary | |
|---|---|
AbstractMRNodeTrafficController()
Creates a new instance of AbstractMRNodeTrafficController |
|
| Method Summary | |
|---|---|
void |
deleteNode(int nodeAddress)
Public method to delete a Serial node by node address |
protected boolean |
getMustInit(int i)
Does this node need to have initialization data sent? |
AbstractNode |
getNode(int index)
Public method to return the Serial node with a given index Note: To cycle through all nodes, begin with index=0, and increment your index at each call. |
AbstractNode |
getNodeFromAddress(int addr)
Public method to identify a SerialNode from its node address Note: 'addr' is the node address, numbered from 0. |
int |
getNumNodes()
Get the number of currently registered nodes |
protected void |
init(int minNode,
int maxNode)
Initialize based on number of first and last nodes |
void |
registerNode(AbstractNode node)
Public method to register a Serial node |
protected void |
setMustInit(AbstractNode node,
boolean v)
|
protected void |
setMustInit(int i,
boolean v)
Mark whether this node needs to have initialization data sent |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected int minNode
protected int maxNode
| Constructor Detail |
|---|
public AbstractMRNodeTrafficController()
| Method Detail |
|---|
protected void init(int minNode,
int maxNode)
protected boolean getMustInit(int i)
protected void setMustInit(int i,
boolean v)
protected void setMustInit(AbstractNode node,
boolean v)
public int getNumNodes()
public void registerNode(AbstractNode node)
public AbstractNode getNode(int index)
public AbstractNode getNodeFromAddress(int addr)
public void deleteNode(int nodeAddress)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||