Buggy code:
@ XStreamAlias ( "thermostatSetpointCommandClass" ) public class ZWaveThermostatSetpointCommandClass extends ZWaveCommandClass implements ZWaveBasicCommands , ZWaveCommandClassDynamicState , ZWaveCommandClassInitialization { @ XStreamOmitField private static final Logger logger = LoggerFactory . getLogger ( ZWaveThermostatSetpointCommandClass . class ) ; private static final byte THERMOSTAT_SETPOINT_SET = 1 ; private static final byte THERMOSTAT_SETPOINT_GET = 2 ; private static final byte THERMOSTAT_SETPOINT_REPORT = 3 ; private static final byte THERMOSTAT_SETPOINT_SUPPORTED_GET = 4 ; private static final byte THERMOSTAT_SETPOINT_SUPPORTED_REPORT = 5 ; private static final int MAX_DYNAMIC_TRIES = 5 ; private final Map < ZWaveThermostatSetpointCommandClass . SetpointType , ZWaveThermostatSetpointCommandClass . Setpoint > setpoints = new HashMap < ZWaveThermostatSetpointCommandClass . SetpointType , ZWaveThermostatSetpointCommandClass . Setpoint > ( ) ; @ XStreamOmitField private boolean initialiseDone = false ; @ XStreamOmitField private boolean dynamicDone = false ; private boolean isGetSupported = true ; public ZWaveThermostatSetpointCommandClass ( ZWaveNode node , ZWaveController controller , ZWaveEndpoint endpoint ) { } @ Override public CommandClass getCommandClass ( ) { } @ Override public int getMaxVersion ( ) { } @ Override public void handleApplicationCommandRequest ( SerialMessage serialMessage , int offset , int endpoint ) { } protected void processThermostatSetpointReport ( SerialMessage serialMessage , int offset , int endpoint ) { } @ Override public Collection < SerialMessage > initialize ( boolean refresh ) { } @ Override public Collection < SerialMessage > getDynamicValues ( boolean refresh ) { } @ Override public SerialMessage getValueMessage ( ) { } @ Override public void setGetSupported ( Boolean supported ) { } public SerialMessage getMessage ( ZWaveThermostatSetpointCommandClass . SetpointType setpointType ) { if ( setpointType == null ) { return null ; } ZWaveThermostatSetpointCommandClass . logger . debug ( "NODE<seq2seq4repair_space>{}:<seq2seq4repair_space>Creating<seq2seq4repair_space>new<seq2seq4repair_space>message<seq2seq4repair_space>for<seq2seq4repair_space>application<seq2seq4repair_space>command<seq2seq4repair_space>THERMOSTAT_SETPOINT_GET<seq2seq4repair_space>({})" , this . getNode ( ) . getNodeId ( ) , setpointType . getLabel ( ) ) ; <START_BUG> SerialMessage result = new SerialMessage ( this . getNode ( ) . getNodeId ( ) , SerialMessageClass . SendData , SerialMessageType . Request , SerialMessageClass . SendData , SerialMessagePriority . Get ) ; <END_BUG> byte [ ] payload = new byte [ ] { ( ( byte ) ( this . getNode ( ) . getNodeId ( ) ) ) , 3 , ( ( byte ) ( getCommandClass ( ) . getKey ( ) ) ) , ZWaveThermostatSetpointCommandClass . THERMOSTAT_SETPOINT_GET , ( ( byte ) ( setpointType . getKey ( ) ) ) } ; result . setMessagePayload ( payload ) ; return result ; } public SerialMessage getSupportedMessage ( ) { } @ Override public SerialMessage setValueMessage ( int value ) { } public SerialMessage setMessage ( int scale , BigDecimal setpoint ) { } public SerialMessage setMessage ( int scale , ZWaveThermostatSetpointCommandClass . SetpointType setpointType , BigDecimal setpoint ) { } @ XStreamAlias ( "setpointType" ) public enum SetpointType { HEATING ( 1 , "Heating" ) , COOLING ( 2 , "Cooling" ) , FURNACE ( 7 , "Furnace" ) , DRY_AIR ( 8 , "Dry<seq2seq4repair_space>Air" ) , MOIST_AIR ( 9 , "Moist<seq2seq4repair_space>Air" ) , AUTO_CHANGEOVER ( 10 , "Auto<seq2seq4repair_space>Changeover" ) , HEATING_ECON ( 11 , "Heating<seq2seq4repair_space>Economical" ) , COOLING_ECON ( 12 , "Cooling<seq2seq4repair_space>Economical" ) , AWAY_HEATING ( 13 , "Away<seq2seq4repair_space>Heating" ) ; private static Map < Integer , ZWaveThermostatSetpointCommandClass . SetpointType > codeToSetpointTypeMapping ; private int key ; private String label ; private SetpointType ( int key , String label ) { } private static void initMapping ( ) { } public static ZWaveThermostatSetpointCommandClass . SetpointType getSetpointType ( int i ) { } public int getKey ( ) { } public String getLabel ( ) { } } private class Setpoint { ZWaveThermostatSetpointCommandClass . SetpointType setpointType ; boolean initialised = false ; int initCount = 0 ; public Setpoint ( ZWaveThermostatSetpointCommandClass . SetpointType type ) { } public ZWaveThermostatSetpointCommandClass . SetpointType getSetpointType ( ) { } public void setInitialised ( ) { } public boolean getInitialised ( ) { } public void incrementInitCount ( ) { } } public class ZWaveThermostatSetpointValueEvent extends ZWaveCommandClassValueEvent { private ZWaveThermostatSetpointCommandClass . SetpointType setpointType ; private int scale ; private ZWaveThermostatSetpointValueEvent ( int nodeId , int endpoint , ZWaveThermostatSetpointCommandClass . SetpointType setpointType , int scale , Object value ) { } public ZWaveThermostatSetpointCommandClass . SetpointType getSetpointType ( ) { } public int getScale ( ) { } } }

Fix:
SerialMessage result = new SerialMessage ( this . getNode ( ) . getNodeId ( ) , SerialMessageClass . SendData , SerialMessageType . Request , SerialMessageClass . ApplicationCommandHandler , SerialMessagePriority . Get ) ;