Detailed Description

RPCClient is used to do calls to other wCMF instances on the same mashine.

See also
RemotingServer
Author
ingo herwig ingo@.nosp@m.wemo.nosp@m.ve.co.nosp@m.m

Definition at line 24 of file RPCClient.php.

+ Inheritance diagram for RPCClient:

Public Member Functions

 __construct ($serverCli, $user)
 
 call (Request $request)
 

Public Attributes

const SIDS_SESSION_VARNAME = 'RPCClient.sids'
 

Protected Member Functions

 doRemoteCall (Request $request, $isLogin)
 
 doLogin ()
 
 setSessionId ($sessionId)
 
 getSessionId ()
 
 handleError ($response)
 

Constructor & Destructor Documentation

__construct (   $serverCli,
  $user 
)

Constructor.

Parameters
$serverCliThe command line interface of the other server instance.
$userThe remote user instance.

Definition at line 40 of file RPCClient.php.

Member Function Documentation

call ( Request  $request)

Do a call to the remote server.

Parameters
$requestA Request instance
Returns
A Response instance

Implements RemotingClient.

Definition at line 67 of file RPCClient.php.

doRemoteCall ( Request  $request,
  $isLogin 
)
protected

Do a remote call.

Parameters
$requestThe Request instance
$isLoginBoolean whether this request is a login request or not
Returns
The Response instance

Definition at line 78 of file RPCClient.php.

doLogin ( )
protected

Do the login request.

If the request is successful, the session id will be set.

Returns
True on success

Definition at line 140 of file RPCClient.php.

setSessionId (   $sessionId)
protected

Store the session id for our server in the local session.

Returns
The session id or null

Definition at line 164 of file RPCClient.php.

getSessionId ( )
protected

Get the session id for our server from the local session.

Returns
The session id or null

Definition at line 175 of file RPCClient.php.

handleError (   $response)
protected

Error handling method.

Parameters
$responseThe Response instance

Definition at line 189 of file RPCClient.php.

Member Data Documentation

const SIDS_SESSION_VARNAME = 'RPCClient.sids'

Definition at line 27 of file RPCClient.php.