public enum PositionState

  1. Object
  2. Enum<PositionState>
  3. PositionState

ImplementsComparable<PositionState>

Which way a window covering is moving, for Trait.COVERING_MOTION. Read-only on every backend.

Phrased in terms of opening and closing rather than of the position number going up or down, because the two backends disagree about which direction that number runs – see Trait.COVERING_POSITION. “Opening” here always means moving toward daylight.

Enum constants

STOPPEDNot moving.
OPENINGMoving toward fully open.
CLOSINGMoving toward fully closed.
UNKNOWNThe accessory could not say.

Methods

public static PositionState[] values()
public static PositionState valueOf(String name)
public static PositionState of(TraitValue value)Reads a motion state out of a trait value, total: a value that is not an enum, or whose ordinal is outside this set, answers UNKNOWN.

Inherited methods

Enum constant details

STOPPED

STOPPED
Not moving.

OPENING

OPENING
Moving toward fully open.

CLOSING

CLOSING
Moving toward fully closed.

UNKNOWN

UNKNOWN
The accessory could not say.

Method details

values

public static PositionState[] values()

valueOf

public static PositionState valueOf(String name)

of

public static PositionState of(TraitValue value)
Reads a motion state out of a trait value, total: a value that is not an enum, or whose ordinal is outside this set, answers UNKNOWN.

Parameters

value TraitValue
a value read from Trait.COVERING_MOTION, or null

Returns

the state, never null