com.eurotech.framework.protocol.modbus
Enum ModbusProtocolErrorCode

java.lang.Object
  extended by java.lang.Enum<ModbusProtocolErrorCode>
      extended by com.eurotech.framework.protocol.modbus.ModbusProtocolErrorCode
All Implemented Interfaces:
Serializable, Comparable<ModbusProtocolErrorCode>

public enum ModbusProtocolErrorCode
extends Enum<ModbusProtocolErrorCode>

ProtocolErrorCode holds the enumeration of valid error codes for the exception message. For each defined enum value, a corresponding message should be defined in the properties bundle named: ProtocolExceptionMessagesBundle.properties.


Enum Constant Summary
CONNECTION_FAILURE
           
INVALID_CONFIGURATION
           
INVALID_DATA_ADDRESS
           
INVALID_DATA_LENGTH
           
INVALID_DATA_TYPE
           
METHOD_NOT_SUPPORTED
           
NOT_AVAILABLE
           
NOT_CONNECTED
           
RESPONSE_TIMEOUT
           
TRANSACTION_FAILURE
           
 
Method Summary
static ModbusProtocolErrorCode valueOf(String name)
          Returns the enum constant of this type with the specified name.
static ModbusProtocolErrorCode[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

INVALID_CONFIGURATION

public static final ModbusProtocolErrorCode INVALID_CONFIGURATION

INVALID_DATA_ADDRESS

public static final ModbusProtocolErrorCode INVALID_DATA_ADDRESS

INVALID_DATA_TYPE

public static final ModbusProtocolErrorCode INVALID_DATA_TYPE

INVALID_DATA_LENGTH

public static final ModbusProtocolErrorCode INVALID_DATA_LENGTH

METHOD_NOT_SUPPORTED

public static final ModbusProtocolErrorCode METHOD_NOT_SUPPORTED

NOT_AVAILABLE

public static final ModbusProtocolErrorCode NOT_AVAILABLE

NOT_CONNECTED

public static final ModbusProtocolErrorCode NOT_CONNECTED

CONNECTION_FAILURE

public static final ModbusProtocolErrorCode CONNECTION_FAILURE

TRANSACTION_FAILURE

public static final ModbusProtocolErrorCode TRANSACTION_FAILURE

RESPONSE_TIMEOUT

public static final ModbusProtocolErrorCode RESPONSE_TIMEOUT
Method Detail

values

public static ModbusProtocolErrorCode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (ModbusProtocolErrorCode c : ModbusProtocolErrorCode.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static ModbusProtocolErrorCode valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null


Copyright © 2013. All Rights Reserved.