Module: Util

Implements helper function for the whole codebase
License:
  • Apache-2.0
Source:

Members

(static) defaultProcedureRegEx

Regular expression to match the default procedure.
Source:

(static) Q4SVERSION

Q4S version string
Source:

Methods

(static) getPrivateIp() → {String}

Returns an string containing your local Ip. Obtained from the interface
Source:
Returns:
- The string representation of the Ip.
Type
String

(async, static) getPublicIp() → {Promise.<String>}

Returns an string containing your public Ip. Obtained using an external service.
Source:
Returns:
- The string representation of the Ip.
Type
Promise.<String>

(static) isRequest(msg) → {Boolean}

Helper function to distinguish between a request and a response. It may not be valid as the funtion is intended to be a lighwheight fast approeach to distinguish between them.
Parameters:
Name Type Description
msg String Line of the SDP containing the procedure.
Source:
Returns:
- True if a Request Q4S false if a Response Q4S.
Type
Boolean