Package ch.bailu.gtk.gio
Class InetSocketAddress
java.lang.Object
ch.bailu.gtk.type.Type
ch.bailu.gtk.type.Pointer
ch.bailu.gtk.gobject.Object
ch.bailu.gtk.gio.SocketAddress
ch.bailu.gtk.gio.InetSocketAddress
- All Implemented Interfaces:
PointerInterface
- Direct Known Subclasses:
ProxyAddress
An IPv4 or IPv6 socket address; that is, the combination of a
#GInetAddress and a port number.
#GInetAddress and a port number.
-
Nested Class Summary
Nested classes/interfaces inherited from class ch.bailu.gtk.gobject.Object
Object.OnBindingTransformFunc, Object.OnDestroyNotify, Object.OnDuplicateFunc, Object.OnNotify, Object.OnToggleNotify, Object.OnWeakNotify
-
Field Summary
Fields inherited from class ch.bailu.gtk.gobject.Object
SIGNAL_ON_NOTIFY
-
Constructor Summary
ConstructorDescriptionInetSocketAddress
(InetAddress address, int port) Creates a new #GInetSocketAddress for @address and @port.InetSocketAddress
(PointerContainer pointer) -
Method Summary
Modifier and TypeMethodDescriptionImplements interfaceSocketConnectable
.Gets @address's #GInetAddress.static ClassHandler
int
Gets the `sin6_flowinfo` field from @address,
which must be an IPv6 address.static int
static long
static TypeSystem.TypeSize
int
getPort()
Gets @address's port.int
Gets the `sin6_scope_id` field from @address,
which must be an IPv6 address.static long
static TypeSystem.TypeSize
static InetSocketAddress
newFromStringInetSocketAddress
(Str address, int port) Creates a new #GInetSocketAddress for @address and @port.static InetSocketAddress
newFromStringInetSocketAddress
(String address, int port) Creates a new #GInetSocketAddress for @address and @port.Methods inherited from class ch.bailu.gtk.gio.SocketAddress
getFamily, getNativeSize, newFromNativeSocketAddress, toNative
Methods inherited from class ch.bailu.gtk.gobject.Object
addToggleRef, bindProperty, bindProperty, bindPropertyFull, bindPropertyFull, bindPropertyWithClosures, bindPropertyWithClosures, compatControl, connect, connect, disconnect, disconnect, dupData, dupData, dupQdata, forceFloating, freezeNotify, get, get, getData, getData, getProperty, getProperty, getQdata, interfaceFindProperty, interfaceInstallProperty, isFloating, notify, notify, notifyByPspec, onNotify, ref, refSink, removeToggleRef, replaceData, replaceData, replaceQdata, runDispose, set, set, setData, setData, setDataFull, setDataFull, setProperty, setProperty, setQdata, setQdataFull, stealData, stealData, stealQdata, takeRef, thawNotify, unref, watchClosure, weakRef, weakUnref
Methods inherited from class ch.bailu.gtk.type.Pointer
asCPointer, cast, connectSignal, disconnectSignals, disconnectSignals, equals, hashCode, throwIfNull, throwNullPointerException, toString, unregisterCallbacks, unregisterCallbacks
Methods inherited from class ch.bailu.gtk.type.Type
asCPointer, asCPointer, asCPointerNotNull, asJnaPointer, asJnaPointer, asPointer, asPointer, cast, cast, throwIfNull
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface ch.bailu.gtk.type.PointerInterface
asCPointerNotNull, asJnaPointer, asPointer, isNotNull, isNull
-
Constructor Details
-
InetSocketAddress
-
InetSocketAddress
Creates a new #GInetSocketAddress for @address and @port.- Parameters:
address
- a #GInetAddressport
- a port number
-
-
Method Details
-
getClassHandler
-
newFromStringInetSocketAddress
Creates a new #GInetSocketAddress for @address and @port.
If @address is an IPv6 address, it can also contain a scope ID
(separated from the address by a `%`).- Parameters:
address
- the string form of an IP addressport
- a port number- Returns:
- a new #GInetSocketAddress, or %NULL if @address cannot be parsed.
-
newFromStringInetSocketAddress
Creates a new #GInetSocketAddress for @address and @port.
If @address is an IPv6 address, it can also contain a scope ID
(separated from the address by a `%`).- Parameters:
address
- the string form of an IP addressport
- a port number- Returns:
- a new #GInetSocketAddress, or %NULL if @address cannot be parsed.
-
getAddress
Gets @address's #GInetAddress.- Returns:
- the #GInetAddress for @address, which must be g_object_ref()'d if it will be stored
-
getFlowinfo
public int getFlowinfo()Gets the `sin6_flowinfo` field from @address,
which must be an IPv6 address.- Returns:
- the flowinfo field
-
getPort
public int getPort()Gets @address's port.- Returns:
- the port for @address
-
getScopeId
public int getScopeId()Gets the `sin6_scope_id` field from @address,
which must be an IPv6 address.- Returns:
- the scope id field
-
asSocketConnectable
Implements interfaceSocketConnectable
. Call this to get access to interface functions.- Overrides:
asSocketConnectable
in classSocketAddress
- Returns:
SocketConnectable
-
getTypeID
public static long getTypeID() -
getParentTypeID
public static long getParentTypeID() -
getTypeSize
-
getParentTypeSize
-
getInstanceSize
public static int getInstanceSize()
-