NetworkAddress.parseUri

Creates a new GSocketConnectable for connecting to the given uri. May fail and return NULL in case parsing uri fails.

Using this rather than NetworkAddress.new or NetworkAddress.parse allows gio.SocketClient to determine when to use application-specific proxy protocols.

class NetworkAddress
static
parseUri
(
string uri
,)

Parameters

uri string

the hostname and optionally a port

defaultPort ushort

The default port if none is found in the URI

Return Value

the new gio.NetworkAddress, or NULL on error

Throws

GException on failure.

Meta

Since

2.26