class XmlRpcCallableClient extends java.lang.Object implements CallableClient
Modifier and Type | Field and Description |
---|---|
private static boolean |
isShutdown_ |
private java.lang.String |
privateKey_ |
private SampXmlRpcClient |
xClient_ |
Constructor and Description |
---|
XmlRpcCallableClient(SampXmlRpcClient xClient,
java.lang.String privateKey)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
private void |
exec(java.lang.String methodName,
java.lang.Object[] params)
Makes an XML-RPC call to the SAMP callable client represented
by this receiver.
|
private void |
rawExec(java.lang.String fqName,
java.util.List paramList)
Actually makes an XML-RPC call to the SAMP callable client
represented by this receiver.
|
void |
receiveCall(java.lang.String senderId,
java.lang.String msgId,
Message msg)
Receives a message for which a response is required.
|
void |
receiveNotification(java.lang.String senderId,
Message msg)
Receives a message for which no response is required.
|
void |
receiveResponse(java.lang.String responderId,
java.lang.String msgTag,
Response response)
Receives a response to a message previously sent by this client.
|
private final SampXmlRpcClient xClient_
private final java.lang.String privateKey_
private static volatile boolean isShutdown_
public XmlRpcCallableClient(SampXmlRpcClient xClient, java.lang.String privateKey)
xClient
- XML-RPC client implementationSAMP
- client's private keypublic void receiveCall(java.lang.String senderId, java.lang.String msgId, Message msg) throws SampException
CallableClient
reply
method at some future point.receiveCall
in interface CallableClient
senderId
- public ID of sending clientmsgId
- message identifier for later use with replymsg
- messageSampException
public void receiveNotification(java.lang.String senderId, Message msg) throws SampException
CallableClient
receiveNotification
in interface CallableClient
senderId
- public ID of sending clientmsg
- messageSampException
public void receiveResponse(java.lang.String responderId, java.lang.String msgTag, Response response) throws SampException
CallableClient
receiveResponse
in interface CallableClient
responderId
- public ID of responding clientmsgTag
- client-defined tag labelling previously-sent messageresponse
- returned response objectSampException
private void exec(java.lang.String methodName, java.lang.Object[] params) throws SampException
methodName
- unqualified SAMP callable client API method nameparams
- array of method parametersSampException
private void rawExec(java.lang.String fqName, java.util.List paramList) throws java.io.IOException
fqName
- fully qualified SAMP callable client API method nameparamList
- list of method parametersjava.io.IOException