Disruptive Documentation

Enumeration Device.​Device​Type

public enum DeviceType: Decodable, Equatable  

Represents the type of a Device.

For more details about the various sensors, see the DT product page.

%303 Device.DeviceType Device.DeviceType Decodable Decodable Device.DeviceType->Decodable Equatable Equatable Device.DeviceType->Equatable

Member Of

Device

Represents a Sensor or Cloud Connector from Disruptive Technologies.

Conforms To

Decodable
Equatable

Initializers

init(from:​)

public init(from decoder: Decoder) throws  

Enumeration Cases

temperature

case temperature

touch

case touch

proximity

case proximity

humidity

case humidity

touch​Counter

case touchCounter

proximity​Counter

case proximityCounter

water​Detector

case waterDetector

cloud​Connector

case cloudConnector

unknown

case unknown(value: String) 

The type received for the device was unknown. Added for backwards compatibility in case a new device type is added on the backend, and not yet added to this client library.

Methods

display​Name()

public func displayName() -> String  

Returns a String representation of the device type that is suited for presenting to a user on screen.