Query: rpcpeer
OS: debian
Section: 3i
Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar
RpcPeer(3I) InterViews Reference Manual RpcPeer(3I)NAMERpcPeer - support bi-directional RPC between two servicesSYNOPSIS#include <Dispatch/rpcpeer.h>DESCRIPTIONAn RpcPeer (actually, an instance of a derived class) tries to open a connection to another RpcPeer. If the other RpcPeer is not yet run- ning, the RpcPeer will create its own port and wait for the other RpcPeer to open a connection. When either RpcPeer opens a connection, each RpcPeer will create both a reader and a writer so each RpcPeer can send RPC requests to its opposite over the same connection.CONSTRUCTORRpcPeer(const char* lPath, int lPort = 0) Store the arguments for later use since a base constructor can't call a derived class's virtual function. The derived class's con- structor should call ``init'', described below. void init(const char* rPath) Find the host name and port number registered by the other RpcPeer and try to open a connection to it. If it's not running, create our own port and wait for the other RpcPeer to open a connection.PUBLIC OPERATIONSvoid run() void quitRunning() Read RPC requests continuously until ``quitRunning()'' terminates the loop. If you're using InterViews, you don't have to call ``run()'' since the InterViews event-reading code will also read RPC requests.PROTECTED OPERATIONSvirtual boolean createReaderAndWriter(const char* rHost, int rPort) = 0 virtual void createReaderAndWriter(int fd) = 0 You must define both functions in a derived class in order to start reading and writing RPC requests over the connection. Typically both functions would create a writer using the given parameters and then attach a reader to the writer's rpcstream.SEE ALSODispatcher(3I), RpcReader(3I), RpcRegistry(3I), RpcWriter(3I) InterViews 27 March 1991 RpcPeer(3I)
Related Man Pages |
---|
iohandler(3i) - debian |
rpchdr(3i) - debian |
statevarview(3u) - debian |
statevarview(3u) - minix |
statevarview(3u) - osx |
Similar Topics in the Unix Linux Community |
---|
Attach process with port 2222 |