• State
  • State Class

    Holds the parameters of a State of a Device. More...

    Header: #include <State>

    Public Functions

    State(const StateTypeId & stateTypeId, const DeviceId & deviceId)
    DeviceId deviceId() const
    StateId id() const
    void setValue(const QVariant & value)
    StateTypeId stateTypeId() const
    QVariant value() const

    Detailed Description

    Holds the parameters of a State of a Device.

    States hold the state values for devices. A State is associated to a Device by the State::deviceId() and represents the value of a state described in a StateType

    See also StateType and StateDescriptor.

    Member Function Documentation

    State::State(const StateTypeId & stateTypeId, const DeviceId & deviceId)

    Constructs a State reflecting the StateType given by stateTypeId and associated with the Device given by deviceId

    DeviceId State::deviceId() const

    Returns the id of the StateType describing this State.

    StateId State::id() const

    Returns the id of this State.

    void State::setValue(const QVariant & value)

    Set the state's value to value.

    See also value().

    StateTypeId State::stateTypeId() const

    Returns the id of the StateType describing this State.

    QVariant State::value() const

    Returns the state's value.

    See also setValue().