Basics

Guides

API Reference

Menu

Basics

Guides

API Reference

class: NetworkAddressMeta

[133:14] static extends: object

Generated metadata helpers for NetworkAddress class surfaces.

Methods

  • properties ()

    Returns property metadata for NetworkAddress.

    • @r A list.

class: NetworkAddress

[17:7] extends: object

GNetworkAddress provides an easy way to resolve a hostname and then attempt to connect to that host, handling the possibility of multiple IP addresses and multiple address families. The enumeration results of resolved addresses may be cached as long as this object is kept alive which may have unexpected results if alive for too long. See [iface@Gio.SocketConnectable] for an example of using the connectable interface.

Members

  • handleObj
  • lib
  • retainedCallbacks
  • signalHandlerNames
  • signalSetterHandlers

Methods

  • NetworkAddress (Handle = null)

    Creates a new NetworkAddress by wrapping a native handle or another wrapper.

    • @p Handle is the native handle or another wrapper whose handle to adopt.
  • toNativeHandle (Source)

    Normalizes a constructor argument into a raw pointer carrier. Accepts a raw NativeHandle, a raw NativeBuffer returned from fn.call(...), another generated wrapper exposing handle(), or null. Returns null when the argument carries no pointer.

    • @p Source is the raw handle, raw buffer, wrapper, or null.
    • @r A raw pointer carrier or null when no pointer is present.
  • getLib ()

    Returns the opened native library for this generated wrapper.

    • @r The opened native library.
  • handle ()

    Returns the wrapped NativeHandle.

    • @r The wrapped NativeHandle.
  • isNull ()

    Returns true when the wrapped handle is null.

    • @r A bool.
  • describe ()

    Returns a small string for debugging generated wrappers.

    • @r A string.
  • asObject ()

    Wraps this handle as Object.

    • @r A Object object.
  • asSocketConnectable ()

    Wraps this handle as SocketConnectable.

    • @r A SocketConnectable object.
  • get_hostname ()

    Gets @addr's hostname. This might be either UTF-8 or ASCII-encoded, depending on what @addr was created with.

  • get_scheme ()

    Gets @addr's scheme