GetHostName

The GetHostName function returns the hostname portion of a supplied SIP URI.

string GetHostName(
  string uri
);

Parameters

  • uri
    A SIP URI whose hostname is returned, if available; for example, GetHostName("sip:someone@example.com") returns the string "example.com".

Return Values

Returns the hostname as a string. If no hostname is found, this function returns an empty string.