Table of Contents

Class SocketConnection

Namespace
Gio.Internal
Assembly
Gio-2.0.dll
public class SocketConnection
Inheritance
SocketConnection
Inherited Members

Methods

Connect(IntPtr, IntPtr, IntPtr, out ErrorOwnedHandle)

Calls native method g_socket_connection_connect. Version: 2.32

[Version("2.32")]
public static extern bool Connect(IntPtr connection, IntPtr address, IntPtr cancellable, out ErrorOwnedHandle error)

Parameters

connection IntPtr

Transfer ownership: None Nullable: False

address IntPtr

Transfer ownership: None Nullable: False

cancellable IntPtr

Transfer ownership: None Nullable: True

error ErrorOwnedHandle

Returns

bool

Transfer ownership: None Nullable: False

ConnectAsync(IntPtr, IntPtr, IntPtr, AsyncReadyCallback, IntPtr)

Calls native method g_socket_connection_connect_async. Version: 2.32

[Version("2.32")]
public static extern void ConnectAsync(IntPtr connection, IntPtr address, IntPtr cancellable, AsyncReadyCallback callback, IntPtr userData)

Parameters

connection IntPtr

Transfer ownership: None Nullable: False

address IntPtr

Transfer ownership: None Nullable: False

cancellable IntPtr

Transfer ownership: None Nullable: True

callback AsyncReadyCallback

Transfer ownership: None Nullable: True

userData IntPtr

Transfer ownership: None Nullable: True

ConnectFinish(IntPtr, IntPtr, out ErrorOwnedHandle)

Calls native method g_socket_connection_connect_finish. Version: 2.32

[Version("2.32")]
public static extern bool ConnectFinish(IntPtr connection, IntPtr result, out ErrorOwnedHandle error)

Parameters

connection IntPtr

Transfer ownership: None Nullable: False

result IntPtr

Transfer ownership: None Nullable: False

error ErrorOwnedHandle

Returns

bool

Transfer ownership: None Nullable: False

FactoryLookupType(SocketFamily, SocketType, int)

Calls native function g_socket_connection_factory_lookup_type. Version: 2.22

[Version("2.22")]
public static extern nuint FactoryLookupType(SocketFamily family, SocketType type, int protocolId)

Parameters

family SocketFamily

Transfer ownership: None Nullable: False

type SocketType

Transfer ownership: None Nullable: False

protocolId int

Transfer ownership: None Nullable: False

Returns

nuint

Transfer ownership: None Nullable: False

FactoryRegisterType(Type, SocketFamily, SocketType, int)

Calls native function g_socket_connection_factory_register_type. Version: 2.22

[Version("2.22")]
public static extern void FactoryRegisterType(Type gType, SocketFamily family, SocketType type, int protocol)

Parameters

gType Type

Transfer ownership: None Nullable: False

family SocketFamily

Transfer ownership: None Nullable: False

type SocketType

Transfer ownership: None Nullable: False

protocol int

Transfer ownership: None Nullable: False

GetGType()

Calls native function g_socket_connection_get_type.

public static extern nuint GetGType()

Returns

nuint

Transfer ownership: None Nullable: False

GetLocalAddress(IntPtr, out ErrorOwnedHandle)

Calls native method g_socket_connection_get_local_address. Version: 2.22

[Version("2.22")]
public static extern IntPtr GetLocalAddress(IntPtr connection, out ErrorOwnedHandle error)

Parameters

connection IntPtr

Transfer ownership: None Nullable: False

error ErrorOwnedHandle

Returns

IntPtr

Transfer ownership: Full Nullable: False

GetRemoteAddress(IntPtr, out ErrorOwnedHandle)

Calls native method g_socket_connection_get_remote_address. Version: 2.22

[Version("2.22")]
public static extern IntPtr GetRemoteAddress(IntPtr connection, out ErrorOwnedHandle error)

Parameters

connection IntPtr

Transfer ownership: None Nullable: False

error ErrorOwnedHandle

Returns

IntPtr

Transfer ownership: Full Nullable: False

GetSocket(IntPtr)

Calls native method g_socket_connection_get_socket. Version: 2.22

[Version("2.22")]
public static extern IntPtr GetSocket(IntPtr connection)

Parameters

connection IntPtr

Transfer ownership: None Nullable: False

Returns

IntPtr

Transfer ownership: None Nullable: False

IsConnected(IntPtr)

Calls native method g_socket_connection_is_connected. Version: 2.32

[Version("2.32")]
public static extern bool IsConnected(IntPtr connection)

Parameters

connection IntPtr

Transfer ownership: None Nullable: False

Returns

bool

Transfer ownership: None Nullable: False