Structure
ConnectionStatusEvent
public struct ConnectionStatusEvent: Codable, Equatable
Indicates the current connectivity of a Cloud Connector. This is sent when there is a change in the connectivity of a Cloud Connector.
See the Developer Website for more details.
Relationships
Nested Types
ConnectionStatusEvent.Connection
Indicates the current connectivity of a Cloud Connector.
ConnectionStatusEvent.Available
Indicates a connectivity that is available for a Cloud Connector.
Conforms To
PublishableEvent
Used by event types (such as
TouchEvent
) to indicate that they can be published to the device emulator.Codable
Equatable
Initializers
init(connection:available:timestamp:)
public init(connection: Connection, available: [Available], timestamp: Date)
Creates a new ConnectionStatusEvent
. Creating a new connection status event can be useful for testing purposes.
init(from:)
public init(from decoder: Decoder) throws
Properties
connection
public let connection: Connection
The current connection of the Cloud Connector. If both ethernet
and
cellular
is available, the Cloud Connector will prefer ethernet
.
available
public let available: [Available]
An array of the available Connection
s for the Cloud Connector.
timestamp
public let timestamp: Date
The timestamp of when the connection status event was received by a Cloud Connector.
eventType
public var eventType: EventType
Methods
encode(to:)
public func encode(to encoder: Encoder) throws