PusherEvent
@objcMembers
open class PusherEvent : NSObject, NSCopying
Undocumented
-
According to Channels protocol, there is always an event https://pusher.com/docs/channels/library_auth_reference/pusher-websockets-protocol#events The name of the event.
Declaration
Swift
public let eventName: String
-
The name of the channel that the event was triggered on. Not present in events without an associated channel, e.g. “pusher:error” events relating to the connection.
Declaration
Swift
public let channelName: String?
-
The data that was passed when the event was triggered.
Declaration
Swift
public let data: String?
-
The ID of the user who triggered the event. Only present in client event on presence channels.
Declaration
Swift
public let userId: String?
-
A helper function for accessing raw properties from the websocket event. Data returned by this function should not be considered stable and it is recommended that you use the properties of the
PusherEvent
instance instead e.g.eventName
,channelName
etc.Declaration
Swift
public func property(withKey key: String) -> Any?
Parameters
key
The key of the property to be returned
Return Value
The property, if present
-
Undocumented
Declaration
Swift
public func copy(with zone: NSZone? = nil) -> Any