vibe.rpcchannel.client

Contains the RPC client API.

Note: This interface is decoupled from the underlying transport stream and therefore requires manually creating these streams. Higher level interfaces for common stream implementations are available in vibe.rpcchannel.tcp and vibe.rpcchannel.noise.

Synopsis:

abstract class API
{
    void callMethos();
    Event!() onEvent;
}

auto stream = connectTCP("127.0.0.1", 8080);
auto client = createClientSession!(API, TCPConnection)(stream, stream);

client.callMethod();
client.onEvent ~= () {};
client.disconnect();
stream.close();

Members

Classes

RPCClient
class RPCClient(API, ConnectionInfo)

This implements an RPC client for API.

Functions

createClientSession
RPCClient!(API, ConnectionInfo) createClientSession(Stream stream, ConnectionInfo info)

Create a new RPCClient implementing API.

Meta