It derives from <GObject>.
<GSimpleProxyResolver> is a simple
<GProxyResolver> implementation that handles
a single default proxy, multiple URI-scheme-specific proxies, and a list
of hosts that proxies should not be used for.
<GSimpleProxyResolver> is never the
default proxy resolver, but it can be used as the base class for another
proxy resolver implementation, or it can be created and used manually,
such as with socket-client:set-proxy-resolver.
parent-instanceThe default proxy URI that will be used for any URI that doesn’t match
simple-proxy-resolver:ignore-hosts, and doesn’t match
any of the schemes set with simple-proxy-resolver:set-uri-proxy.
Note that as a special case, if this URI starts with "socks://",
<GSimpleProxyResolver> will treat it
as referring to all three of the socks5, socks4a, and socks4 proxy
types.
Its value is a string, or #f.
Set it with (set! (simple-proxy-resolver:default-proxy self)
value).
A list of hostnames and IP addresses that the resolver should allow direct connections to.
Entries can be in one of 4 formats:
Note that when dealing with Unicode hostnames, the matching is done against the ASCII form of the name.
Also note that hostname exclusions apply only to connections made to
hosts identified by name, and IP address exclusions apply only to
connections made to hosts identified by address. That is, if
example.com has an address of 192.168.1.1, and the :ignore-hosts list
contains only "192.168.1.1", then a connection to "example.com" (eg, via
a <GNetworkAddress>) will use the proxy,
and a connection to "192.168.1.1" (eg, via a
<GInetSocketAddress>) will not.
These rules match the "ignore-hosts"/"noproxy" rules most commonly used by other applications.
Its value is a vector, each a string (or, to set it, a list), or
#f.
Set it with (set! (simple-proxy-resolver:ignore-hosts self)
value).
Creates a new <GSimpleProxyResolver>.
See simple-proxy-resolver:default-proxy and
simple-proxy-resolver:ignore-hosts for more details on
how the arguments are interpreted.
Passed, or left out: a string, or #f.
the default proxy to use, eg "socks://192.168.1.1"
Passed, or left out: a list or vector, each a string, or #f.
an optional list of hosts/IP addresses to not use a proxy for.
Returned: a <GProxyResolver>.
a new <GSimpleProxyResolver>
Sets the default proxy on self, to be used for any URIs that don’t
match simple-proxy-resolver:ignore-hosts or a proxy set via
simple-proxy-resolver:set-uri-proxy.
If default-proxy starts with "socks://",
<GSimpleProxyResolver> will treat it
as referring to all three of the socks5, socks4a, and socks4 proxy
types.
Passed: a <GSimpleProxyResolver>.
Passed, or left out: a string, or #f.
the default proxy to use
Sets the list of ignored hosts.
See simple-proxy-resolver:ignore-hosts for more details on
how the ignore-hosts argument is interpreted.
Passed: a <GSimpleProxyResolver>.
Passed: a list or vector, each a string.
#f-terminated list of hosts/IP addresses to not use a proxy for
Adds a URI-scheme-specific proxy to self; URIs whose scheme
matches uri-scheme (and which don’t match
simple-proxy-resolver:ignore-hosts) will be proxied via
proxy.
As with simple-proxy-resolver:default-proxy, if proxy
starts with "socks://",
<GSimpleProxyResolver> will treat it
as referring to all three of the socks5, socks4a, and socks4 proxy
types.
Passed: a <GSimpleProxyResolver>.
Passed: a string.
the URI scheme to add a proxy for
Passed: a string.
the proxy to use for uri-scheme