Doors

State

Inside locks

Declaration

getInsideLocks()

Discussion

Inside lock states for the given doors

Example

val state:Doors.State
assertTrue(state.insideLocks[0].value?.location == Location.FRONT_LEFT)
assertTrue(state.insideLocks[0].value?.lockState == LockState.LOCKED)
// Front left door is locked inside

Locks

Declaration

getLocks()

Discussion

Lock states for the given doors

Example

val state:Doors.State
assertTrue(state.locks[0].value?.location == Location.FRONT_LEFT)
assertTrue(state.locks[0].value?.lockState == LockState.UNLOCKED)
// Front left door is unlocked

Positions

Declaration

getPositions()

Discussion

Door positions for the given doors

Example

val state:Doors.State
assertTrue(state.positions[0].value?.location == DoorPosition.Location.FRONT_LEFT)
assertTrue(state.positions[0].value?.position == Position.OPEN)
// Front left door is open

Inside locks state

Declaration

getInsideLocksState()

Discussion

Inside locks state for the whole vehicle (combines all specific lock states if available)

Example

val state:Doors.State
assertTrue(state.insideLocksState.value == LockState.LOCKED)
// Doors are locked inside

Locks state

Declaration

getLocksState()

Discussion

Locks state for the whole vehicle (combines all specific lock states if available)

Example

val state:Doors.State
assertTrue(state.locksState.value == LockState.UNLOCKED)
// Doors are unlocked

Setters

Lock unlock doors

Declaration

public LockUnlockDoors(LockState locksState)

Example

val lockUnlockDoors = Doors.LockUnlockDoors(LockState.UNLOCKED)    

Getters

Get Doors property availability information

Declaration

public GetStateAvailability()
public GetStateAvailability(byte... propertyIdentifiers)

Example

// get all property availabilities
val getAvailability = GetStateAvailability()
// get insideLock and lock property availabilities
val getAvailabilityProperties = GetStateAvailability(0x02, 0x03)

Get Doors properties

Declaration

public GetState()
public GetState(byte... propertyIdentifiers)            

Example

// get all properties
val getState = GetState()
// get insideLock and lock properties
val getStateProperties = GetState(0x02, 0x03)