myPeer

new myPeer(idopt, optionsopt)

Instance of the client-side peer with which to communicate with other peers.

Parameters:
NameTypeAttributesDescription
idstring<optional>

Other peers can connect to this peer using the provided ID. If no ID is given, one will be generated by the brokering server.

optionsObject<optional>

Options for setting up the peer connection; required

Listens to Events:

Events

on

Handles what happens when a new peer uses call().

Listeners of This Event:

on

Handles what happens when a new peer connects.