LiveEvent

public class LiveEvent : EventDelegate

A class that provides methods for a host and participants to stream and receive media during a live event.

Since

1.0.0
  • The role of the user in a live event.

    Since

    1.0.0

    Declaration

    Swift

    public var myRole: LiveEvent.Role { get }
  • Undocumented

    Declaration

    Swift

    public var isActiveHost: Bool { get }
  • The state of a live event. Valid values are created, ready, ongoing, and ended.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var state: LiveEvent.State { get }
  • The number of participants in a live event which is counted by the number of devices and browsers concurrently connected to Sendbird server.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var participantCount: Int { get }
  • The highest number of participantCount measured at a given time during a live event.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var peakParticipantCount: Int { get }
  • The sum of all participants that entered and exited a live event.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var cumulativeParticipantCount: Int { get }
  • The timestamp of when the live event was created, in miliseconds.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var createdAt: Int64 { get }
  • The timestamp of when the live event was created, in miliseconds.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var setReadyAt: Int64? { get }
  • The timestamp of when the live event was started, in miliseconds.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var startedAt: Int64? { get }
  • The timestamp of when the live event was ended, in miliseconds.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var endedAt: Int64? { get }
  • User ID of the user that created the live event.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var createdBy: String { get }
  • User ID of the user that set the live event ready.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var setReadyBy: String? { get }
  • User ID of the user that started the live event.

    • sicne: 1.0.0

    Declaration

    Swift

    public internal(set) var startedBy: String? { get }
  • User ID of the user that ended the live event.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var endedBy: String? { get }
  • Indicates whether the host is streaming media.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var isHostStreaming: Bool { get }
  • The period from the time when the live event was started to the time the live event was ended.

    Since

    1.0.0

    Declaration

    Swift

    public var duration: Int64 { get }
  • Unique identifier for the live event.

    Since

    1.0.0

    Declaration

    Swift

    public let liveEventId: String
  • An open channel that is used for the live event.

    Since

    1.0.0

    Declaration

    Swift

    public private(set) var openChannel: OpenChannel? { get }
  • Host of the live event.

    Since

    1.0.0

    Declaration

    Swift

    public internal(set) var host: Host? { get }
  • Undocumented

    Declaration

    Swift

    public internal(set) var userIdsForHost: [String] { get }
  • Undocumented

    Declaration

    Swift

    public internal(set) var customItems: [String : String] { get }
  • Undocumented

    Declaration

    Swift

    public internal(set) var title: String? { get }
  • Undocumented

    Declaration

    Swift

    public internal(set) var coverURL: String? { get }
  • Undocumented

    Declaration

    Swift

    public func addDelegate(_ delegate: LiveEventDelegate, forKey key: String)
  • Undocumented

    Declaration

    Swift

    public func removeDelegate(forKey key: String)
  • Undocumented

    Declaration

    Swift

    public func resetCamera()

Host only

Media Controls

Participant

  • Enters a live event.

    Since

    1.0.0

    Declaration

    Swift

    public func enter(completionHandler: ErrorHandler? = nil)
  • Exits a live event.

    Since

    1.0.0

    Declaration

    Swift

    public func exit(completionHandler: ErrorHandler? = nil)
  • A class that provides information for configuring a live event when it is created.

    Since

    1.0.0
    See more

    Declaration

    Swift

    public struct CreateParams
  • Undocumented

    See more

    Declaration

    Swift

    public struct UpdateParams
  • An enum that provides information about roles that users can take in a live event.

    Since

    1.0.0
    See more

    Declaration

    Swift

    public enum Role
  • An enum that provides information about the states of a live event.

    Since

    1.0.0
    See more

    Declaration

    Swift

    public enum State : String, Codable