类 BinaryLocator
BinaryLocator class.
-
字段概要
从类继承的字段 com.huangjian.modbus4j.locator.BaseLocator
offset, range -
构造器概要
构造器构造器说明BinaryLocator(int slaveId, int range, int offset) Constructor for BinaryLocator.BinaryLocator(int slaveId, int range, int offset, int bit) Constructor for BinaryLocator. -
方法概要
修饰符和类型方法说明bytesToValueRealOffset(byte[] data, int offset) bytesToValueRealOffset.intgetBit()Getter for the fieldbit.intgetDataType.intgetRegisterCount.static booleanisBinaryRange(int range) isBinaryRange.toString()protected voidvalidate()validate.short[]valueToShorts(Boolean value) valueToShorts.从类继承的方法 com.huangjian.modbus4j.locator.BaseLocator
bytesToValue, coilStatus, createLocator, createLocator, createLocator, createLocator, getEndOffset, getOffset, getRange, getSlaveId, holdingRegister, holdingRegisterBit, inputRegister, inputRegisterBit, inputStatus, validate
-
构造器详细资料
-
BinaryLocator
public BinaryLocator(int slaveId, int range, int offset) Constructor for BinaryLocator.
- 参数:
slaveId- a int.range- a int.offset- a int.
-
BinaryLocator
public BinaryLocator(int slaveId, int range, int offset, int bit) Constructor for BinaryLocator.
- 参数:
slaveId- a int.range- a int.offset- a int.bit- a int.
-
-
方法详细资料
-
isBinaryRange
public static boolean isBinaryRange(int range) isBinaryRange.
- 参数:
range- a int.- 返回:
- a boolean.
-
validate
protected void validate()validate.
-
getBit
public int getBit()Getter for the field
bit.- 返回:
- a int.
-
getDataType
public int getDataType()getDataType.
- 指定者:
getDataType在类中BaseLocator<Boolean>- 返回:
- a int.
-
getRegisterCount
public int getRegisterCount()getRegisterCount.
- 指定者:
getRegisterCount在类中BaseLocator<Boolean>- 返回:
- a int.
-
toString
-
bytesToValueRealOffset
bytesToValueRealOffset.
- 指定者:
bytesToValueRealOffset在类中BaseLocator<Boolean>- 参数:
data- an array ofobjects.引用无效
byteoffset- a int.- 返回:
- a T object.
-
valueToShorts
valueToShorts.
- 指定者:
valueToShorts在类中BaseLocator<Boolean>- 参数:
value- a T object.- 返回:
- an array of
objects.
引用无效
short
-