Package jmri.jmrix.marklin
Class MarklinReply
- java.lang.Object
-
- jmri.jmrix.AbstractMessage
-
- jmri.jmrix.AbstractMRReply
-
- jmri.jmrix.marklin.MarklinReply
-
- All Implemented Interfaces:
Message
public class MarklinReply extends AbstractMRReply
Carries the reply to an MarklinMessage.
-
-
Field Summary
-
Fields inherited from class jmri.jmrix.AbstractMRReply
DEFAULTMAXSIZE
-
Fields inherited from class jmri.jmrix.AbstractMessage
_dataChars, _nDataChars
-
-
Constructor Summary
Constructors Constructor Description MarklinReply()
MarklinReply(int[] d)
MarklinReply(java.lang.String s)
MarklinReply(MarklinReply l)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description long
getAddress()
int[]
getCanAddress()
int[]
getCanData()
int
getCanDataLength()
int
getCommand()
int
getElement(int n)
Get a particular element in a Message.int[]
getHash()
int
getPriority()
boolean
isResponse()
boolean
isUnsolicited()
Get flag for Unsolicited.int
maxSize()
protected int
skipPrefix(int index)
java.lang.String
toMonitorString()
java.lang.String
toString()
int
value()
-
Methods inherited from class jmri.jmrix.AbstractMRReply
flush, getOpCode, isBinary, isRetransmittableErrorMsg, match, pollValue, setBinary, setElement, setOpCode, setUnsolicited, skipWhiteSpace
-
Methods inherited from class jmri.jmrix.AbstractMessage
equals, getNumDataElements, hashCode
-
-
-
-
Constructor Detail
-
MarklinReply
public MarklinReply()
-
MarklinReply
public MarklinReply(java.lang.String s)
-
MarklinReply
public MarklinReply(MarklinReply l)
-
MarklinReply
public MarklinReply(int[] d)
-
-
Method Detail
-
maxSize
public int maxSize()
- Overrides:
maxSize
in classAbstractMRReply
-
skipPrefix
protected int skipPrefix(int index)
- Specified by:
skipPrefix
in classAbstractMRReply
-
value
public int value()
- Overrides:
value
in classAbstractMRReply
-
getElement
public int getElement(int n)
Description copied from class:AbstractMessage
Get a particular element in a Message.- Specified by:
getElement
in interfaceMessage
- Overrides:
getElement
in classAbstractMessage
- Parameters:
n
- Element Index.- Returns:
- single element of message.
-
isUnsolicited
public boolean isUnsolicited()
Description copied from class:AbstractMRReply
Get flag for Unsolicited.- Overrides:
isUnsolicited
in classAbstractMRReply
- Returns:
- true if Unsolicited, else false.
-
toString
public java.lang.String toString()
- Specified by:
toString
in interfaceMessage
- Overrides:
toString
in classAbstractMRReply
-
toMonitorString
public java.lang.String toMonitorString()
- Returns:
- a human-readable representation of the message.
-
isResponse
public boolean isResponse()
-
getCanDataLength
public int getCanDataLength()
-
getCanData
public int[] getCanData()
-
getCanAddress
public int[] getCanAddress()
-
getAddress
public long getAddress()
-
getPriority
public int getPriority()
-
getCommand
public int getCommand()
-
getHash
public int[] getHash()
-
-