Package net.sbbi.upnp.services
Class StateVariable
java.lang.Object
net.sbbi.upnp.services.StateVariable
- All Implemented Interfaces:
StateVariableTypes
Class to contain a service state variable definition
-
Field Summary
FieldsModifier and TypeFieldDescriptionA set of allowed values (String objects) for the variablefinal String
The variable UPNP data typefinal String
The default value of the state variablefinal String
The maximum value as a stringfinal String
The minimum value as a stringfinal String
State variable namefinal Service
The parentService
Objectfinal boolean
Boolean to indicate if the variable is sending events when value of the var is changing.final String
The value step range as a stringFields inherited from interface net.sbbi.upnp.services.StateVariableTypes
BIN_BASE64, BIN_BASE64_INT, BIN_HEX, BIN_HEX_INT, BOOLEAN, BOOLEAN_INT, CHAR, CHAR_INT, DATE, DATE_INT, DATETIME, DATETIME_INT, DATETIME_TZ, DATETIME_TZ_INT, FIXED_14_4, FIXED_14_4_INT, FLOAT, FLOAT_INT, I1, I1_INT, I2, I2_INT, I4, I4_INT, INT, INT_INT, NUMBER, NUMBER_INT, R4, R4_INT, R8, R8_INT, STRING, STRING_INT, TIME, TIME_INT, TIME_TZ, TIME_TZ_INT, UI1, UI1_INT, UI2, UI2_INT, UI4, UI4_INT, URI, URI_INT, UUID, UUID_INT
-
Method Summary
-
Field Details
-
name
State variable name -
sendEvents
public final boolean sendEventsBoolean to indicate if the variable is sending events when value of the var is changing. -
dataType
The variable UPNP data type -
defaultValue
The default value of the state variable -
minimumRangeValue
The minimum value as a string -
maximumRangeValue
The maximum value as a string -
stepRangeValue
The value step range as a string -
allowedvalues
A set of allowed values (String objects) for the variable -
parent
The parentService
Object
-
-
Method Details
-
getValue
Call to the UPNP device to retrieve the state variable actual value- Returns:
- the state variable actual value on the device, should be never null, an empty string could be returned by the device
- Throws:
UPNPResponseException
- if the device throws an exception during queryIOException
- if some IO error with device occurs during query
-
getDataTypeAsClass
The variable JAVA data type (using an UPNP->Java mapping)- Returns:
- the class mapped
-
toString
-