net.wimpi.modbus.msg
Class ModbusResponse

java.lang.Object
  extended by net.wimpi.modbus.msg.ModbusMessageImpl
      extended by net.wimpi.modbus.msg.ModbusResponse
All Implemented Interfaces:
Transportable, ModbusMessage
Direct Known Subclasses:
ExceptionResponse, ReadCoilsResponse, ReadInputDiscretesResponse, ReadInputRegistersResponse, ReadMultipleRegistersResponse, WriteCoilResponse, WriteMultipleCoilsResponse, WriteMultipleRegistersResponse, WriteSingleRegisterResponse

public abstract class ModbusResponse
extends ModbusMessageImpl

Abstract class implementing a ModbusResponse. This class provides specialised implementations with the functionality they have in common.

Version:
@version@ (@date@)
Author:
Dieter Wimberger

Constructor Summary
ModbusResponse()
           
 
Method Summary
static ModbusResponse createModbusResponse(int functionCode)
          Factory method creating the required specialized ModbusResponse instance.
 
Methods inherited from class net.wimpi.modbus.msg.ModbusMessageImpl
getDataLength, getFunctionCode, getHexMessage, getOutputLength, getProtocolID, getTransactionID, getUnitID, isHeadless, readData, readFrom, setDataLength, setHeadless, setProtocolID, setTransactionID, setUnitID, writeData, writeTo
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ModbusResponse

public ModbusResponse()
Method Detail

createModbusResponse

public static ModbusResponse createModbusResponse(int functionCode)
Factory method creating the required specialized ModbusResponse instance.

Parameters:
functionCode - the function code of the response as int.
Returns:
a ModbusResponse instance specific for the given function code.


Copyright © 2010. All Rights Reserved.