Server.for_address


Description:

[ CCode ( has_construct_function = false ) ]
public Server.for_address (string swarm_name, string bus_address)

Creates a new instance of Server and tries to bind to bus_address.

The swarm_leader property will be set when the binding succeeds.

If there is already a Server instance bound to bus_address, the connection will be shared with the newly constructed instance.

Note:

This function is primarily meant for sharing of one connection (socket) between multiple DeeServers, so that you can create Server instances with varying swarm names, but the same bus address, which will cause them to share the connection (the sharing is possible only within the same process though).

Parameters:

swarm_name

Name of swarm to join.

bus_address

D-Bus address to use for the connection.

Returns:

A newly constructed Server.