Options
All
  • Public
  • Public/Protected
  • All
Menu

The SharingController class is a managing class to control the sharing-related functions and states in an active meeting, such as starts or stops the sharing.

Hierarchy

  • SharingEventEmitter
    • SharingController

Index

Constructors

Events

Methods

  • isLocalSharing(): boolean
  • Indicates whether the current sharing is started by the local user.

    Returns boolean

    True means the local user or otherwise

  • isRemoteSharing(): boolean
  • Indicates whether the current sharing is started by the remote user.

    Returns boolean

    True means the remote user or otherwise

  • isSharingLocked(): boolean
  • Indicates whether the sharing is being locked.

    Returns boolean

    True means locked, False means not

  • Locks sharing function.

    description

    If it is locked and a participant is sharing, then the present sharing will stop right away and participants unable to start the sharing again. The host or moderator is still able to start the sharing.

    description

    Only the meeting host or moderator has permission to invoke this method.

    Returns Promise<ErrorCodeType>

    0 means the action succeeds or fails otherwise

  • Removes the specified listener from the listener array for the event named eventName.

    Parameters

    Returns void

  • Adds a one-time listener function for the event named eventName. The next time eventName is triggered, this listener is removed and then invoked.

    Parameters

    Returns void

  • startSharing(spec?: DisplayMediaStreamConstraints, options?: IMediaStreamOptions): Promise<MediaStream>
  • Starts sharing the device screen in an active meeting.

    Parameters

    • Optional spec: DisplayMediaStreamConstraints
    • options: IMediaStreamOptions = {}

    Returns Promise<MediaStream>

    MediaStream means the action succeeds or fails otherwise

  • Stops the current sharing session of the remote user.

    description

    Only the meeting host or moderator has permission to invoke this method.

    Parameters

    • uid: string

      The unique id of the specific meeting user

    Returns Promise<ErrorCodeType>

    0 means success or fails otherwise

  • Stops sharing.

    Returns Promise<ErrorCodeType>

    0 means success or fails otherwise

  • Unlocks the current meeting sharing.

    description

    If it is unlocked, everyone in the meeting can share again.

    description

    Only the meeting host or moderator has permission to invoke this method.

    Returns Promise<ErrorCodeType>

    0 means the action succeeds or fails otherwise