Package jmri.jmrix.rps
Class Transmitter
java.lang.Object
jmri.jmrix.rps.Transmitter
- All Implemented Interfaces:
EventListener,ThrottleListener
Represents an RPS transmitter, generally a locomotive.
The "ID" is used to identify this transmitter in RPS. The "rosterName" is the name (ID) of the roster entry this was originally created from.
-
Nested Class Summary
Nested classes/interfaces inherited from interface jmri.ThrottleListener
ThrottleListener.DecisionType -
Field Summary
FieldsModifier and TypeFieldDescription(package private) int(package private) String(package private) Measurement(package private) boolean(package private) boolean(package private) boolean(package private) String(package private) DccThrottle -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) booleanintgetId()(package private) DccThrottlebooleanbooleanisPolled()voidnotifyDecisionRequired(LocoAddress address, ThrottleListener.DecisionType question) No steal or share decisions made locallyvoidnotifyFailedThrottleRequest(LocoAddress address, String reason) Get notification that an attempt to request a throttle has failed.voidGet notification that a throttle has been found as requested.voidsetAddress(int address) voidvoidvoidsetLongAddress(boolean longAddress) voidsetPolled(boolean polled) voidsetRosterName(String rosterName)
-
Field Details
-
id
-
rosterName
-
longAddress
boolean longAddress -
address
int address -
polled
boolean polled -
lastMeasurement
-
throttle
-
needReqThrottle
boolean needReqThrottle
-
-
Constructor Details
-
Transmitter
Transmitter(String id, boolean polled, int address, boolean longAddress)
-
-
Method Details
-
getId
-
setId
-
getRosterName
-
setRosterName
-
isLongAddress
-
setLongAddress
-
getAddress
-
setAddress
-
isPolled
-
setPolled
-
setLastMeasurement
-
getLastMeasurement
-
getThrottle
-
checkInit
boolean checkInit() -
notifyThrottleFound
Description copied from interface:ThrottleListenerGet notification that a throttle has been found as requested.- Specified by:
notifyThrottleFoundin interfaceThrottleListener- Parameters:
t- the throttle with the requested address
-
notifyFailedThrottleRequest
Description copied from interface:ThrottleListenerGet notification that an attempt to request a throttle has failed.- Specified by:
notifyFailedThrottleRequestin interfaceThrottleListener- Parameters:
address- address of the failed requestreason- failure cause
-
notifyDecisionRequired
No steal or share decisions made locallyGet notification that a throttle request is in use by another device, and a "steal", "share", or "steal/share" decision may be required.
- Specified by:
notifyDecisionRequiredin interfaceThrottleListener- Parameters:
address- The LocoAddress that needs the decision.question- The question being asked, steal / cancel, share / cancel, steal / share / cancel
-