PeerData

PeerData

Class that represents PeerData methods

Constructor

(private) new PeerData()

Source:

Methods

(private, static) getCurrentSessionInfo(room) → {peerInfo}

Parameters:
Name Type Description
room SkylinkRoom
Source:

(private, static) getPeerInfo(peerId, room) → {peerInfo}

Function that returns the User / Peer current session information.

Parameters:
Name Type Description
peerId String
room SkylinkRoom
Source:

(static) getPeersCustomSettings(roomState) → {Object}

Function that gets the list of current custom Peer settings sent and set.

Parameters:
Name Type Description
roomState SkylinkState
Source:

(private, static) getPeersDataChannels(roomState) → {Object}

Function that gets the current list of connected Peers Datachannel connections in the Room.

Parameters:
Name Type Description
roomState SkylinkState
Source:

(private, static) getPeersStreams(roomState, includeSelfopt) → {Object}

Function that gets the list of connected Peers Streams in the Room.

Parameters:
Name Type Attributes Default Description
roomState SkylinkState
includeSelf boolean <optional>
true

The flag if self streams are included.

Source:

(private, static) getUserData(roomState, peerId) → {roomState.userData}

Function that returns the User / Peer current custom data.

Parameters:
Name Type Description
roomState Skylink
peerId String
Source:

(private, static) getUserInfo(room) → {Object}

Function that returns the User session information to be sent to Peers.

Parameters:
Name Type Description
room SkylinkRoom
Source:

(static) setGreatestPeerPriorityWeight(roomState) → {*|void}

Iterates through all connected peers to find the greatest peerPriorityWeight and sets the current users peerPriorityWeight to max.

Parameters:
Name Type Description
roomState SkylinkState
Source:

(private, static) setUserData(room, userData)

Function that overwrites the User current custom data.

Parameters:
Name Type Description
room SkylinkRoom
userData String | Object
Source: