getCall()
wrtc.getCall() returns first matching call. Applications that handle only one call can use wrtc.getCall() without arguments to get the call object.
Arguments
wrtc.getCall(is)
- is - (optional) string containing call.is() argument to search for
Returns
If no argument is given any ongoing call is returned, or null if no call currently in progress.
If argument is supplied first call who's call.is() with that argument returns true is returned, or null if no matching call found.
Events
None.
Example
wrtc.getCall() returns first call found. In single call applications it can be used to get hold of the call object. If a call is in progress the call object is returned, if no current call null is returned. If multiple simultaneous calls only one of the call objects are returned.
wrtc.getCall("muted") returns first muted call found. If no calls are muted null is returned.
wrtc.getCall("To:foo") returns call to user foo. If no current call with user foo null is returned.