类 ModbusMessage
java.lang.Object
com.huangjian.modbus4j.msg.ModbusMessage
- 直接已知子类:
ModbusRequest,ModbusResponse
Abstract ModbusMessage class.
-
字段概要
字段 -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明protected boolean[]convertToBooleans(byte[] data) convertToBooleans.protected byte[]convertToBytes(boolean[] bdata) convertToBytes.protected byte[]convertToBytes(short[] sdata) convertToBytes.protected short[]convertToShorts(byte[] data) convertToShorts.abstract bytegetFunctionCode.intGetter for the fieldslaveId.final voidwrite.protected abstract voidwriteImpl.
-
字段详细资料
-
slaveId
protected int slaveId
-
-
构造器详细资料
-
ModbusMessage
Constructor for ModbusMessage.
- 参数:
slaveId- a int.- 抛出:
ModbusTransportException- if any.
-
-
方法详细资料
-
getSlaveId
public int getSlaveId()Getter for the field
slaveId.- 返回:
- a int.
-
getFunctionCode
public abstract byte getFunctionCode()getFunctionCode.
- 返回:
- a byte.
-
write
write.
- 参数:
queue- aByteQueueobject.
-
writeImpl
writeImpl.
- 参数:
queue- aByteQueueobject.
-
convertToBytes
protected byte[] convertToBytes(boolean[] bdata) convertToBytes.
- 参数:
bdata- an array ofobjects.引用无效
boolean- 返回:
- an array of
objects.
引用无效
byte
-
convertToBytes
protected byte[] convertToBytes(short[] sdata) convertToBytes.
- 参数:
sdata- an array ofobjects.引用无效
short- 返回:
- an array of
objects.
引用无效
byte
-
convertToBooleans
protected boolean[] convertToBooleans(byte[] data) convertToBooleans.
- 参数:
data- an array ofobjects.引用无效
byte- 返回:
- an array of
objects.
引用无效
boolean
-
convertToShorts
protected short[] convertToShorts(byte[] data) convertToShorts.
- 参数:
data- an array ofobjects.引用无效
byte- 返回:
- an array of
objects.
引用无效
short
-