IoValueEvent
public class IoValueEvent : CommunicationEvent<IoValueEventData>
Undocumented
-
Create an IoValueEvent instance for the given IO source and IO value.
The IO value can be either JSON compatible or in binary format as a [Uint8] . The data format of the given IO value must conform to the
useRawIoValuesproperty of the given IO source. That means, if this property is set to true, the given value must be in binary format; if this property is set to false, the value must be a JSON encodable object. If this constraint is violated, an error is thrown.Throws
throws if the given value data format does not comply with theIoSource.useRawIoValuesoptionDeclaration
Swift
public static func with(ioSource: IoSource, value: [UInt8], options: [String : Any]) throws -> IoValueEventParameters
ioSourcethe IoSource for publishing
valuea
[UInt8]valueoptionsbinding-specific publication options
-
Create an IoValueEvent instance for the given IO source and IO value.
The IO value can be either JSON compatible or in binary format as a [Uint8] . The data format of the given IO value must conform to the
useRawIoValuesproperty of the given IO source. That means, if this property is set to true, the given value must be in binary format; if this property is set to false, the value must be a JSON encodable object. If this constraint is violated, an error is thrown.Throws
throws if the given value data format does not comply with theIoSource.useRawIoValuesoptionDeclaration
Swift
public static func with(ioSource: IoSource, value: AnyCodable, options: [String : Any]) throws -> IoValueEventParameters
ioSourcethe IoSource for publishing
valuean JSON compatible
AnyCodablevalueoptionsbinding-specific publication options
-
Undocumented
Declaration
Swift
public required init(from decoder: Decoder) throws -
Undocumented
Declaration
Swift
public override func encode(to encoder: Encoder) throws
View on GitHub
IoValueEvent Class Reference