|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.turbine.services.xmlrpc.TurbineXmlRpc
This is a static accesor class for XmlRpcService
.
Constructor Summary | |
TurbineXmlRpc()
|
Method Summary | |
static void |
acceptClient(java.lang.String address)
Add an IP address to the list of accepted clients. |
static void |
denyClient(java.lang.String address)
Add an IP address to the list of denied clients. |
static java.lang.Object |
executeAuthenticatedRpc(java.net.URL url,
java.lang.String username,
java.lang.String password,
java.lang.String methodName,
java.util.Vector params)
Execute a remote procedure call taht requires authentication |
static java.lang.Object |
executeRpc(java.net.URL url,
java.lang.String methodName,
java.util.Vector params)
Execute a remote procedure call. |
static void |
get(java.lang.String serverURL,
java.lang.String sourceLocationProperty,
java.lang.String sourceFileName,
java.lang.String destinationLocationProperty,
java.lang.String destinationFileName)
Method to allow a client to get a file from a server. |
static void |
get(java.lang.String serverURL,
java.lang.String username,
java.lang.String password,
java.lang.String sourceLocationProperty,
java.lang.String sourceFileName,
java.lang.String destinationLocationProperty,
java.lang.String destinationFileName)
Method to allow a client to get a file to a server that requires authentication |
static XmlRpcService |
getService()
Returns system's configured implementation of XmlRpcService . |
static byte[] |
handleRequest(java.io.InputStream is)
Handle an XML-RPC request using the encapsulated server. |
static byte[] |
handleRequest(java.io.InputStream is,
java.lang.String user,
java.lang.String password)
Handle an XML-RPC request using the encapsulated server with user authentication. |
static void |
registerHandler(java.lang.Object handler)
Register an object as a the default handler for the XmlRpc Server part. |
static void |
registerHandler(java.lang.String handlerName,
java.lang.Object handler)
Register an object as a handler for the XmlRpc Server part. |
static void |
remove(java.lang.String serverURL,
java.lang.String sourceLocationProperty,
java.lang.String sourceFileName)
Method to allow a client to remove a file from the server |
static void |
remove(java.lang.String serverURL,
java.lang.String username,
java.lang.String password,
java.lang.String sourceLocationProperty,
java.lang.String sourceFileName)
Method to allow a client to remove a file from a server that requires authentication |
static void |
send(java.lang.String serverURL,
java.lang.String sourceLocationProperty,
java.lang.String sourceFileName,
java.lang.String destinationLocationProperty,
java.lang.String destinationFileName)
Method to allow a client to send a file to a server. |
static void |
send(java.lang.String serverURL,
java.lang.String username,
java.lang.String password,
java.lang.String sourceLocationProperty,
java.lang.String sourceFileName,
java.lang.String destinationLocationProperty,
java.lang.String destinationFileName)
Method to allow a client to send a file to a server that requires authentication |
static void |
setParanoid(boolean state)
Switch client filtering on/off. |
static void |
unregisterHandler(java.lang.String handlerName)
Unregister a handler. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public TurbineXmlRpc()
Method Detail |
public static XmlRpcService getService()
XmlRpcService
.XmlRpcService
public static java.lang.Object executeRpc(java.net.URL url, java.lang.String methodName, java.util.Vector params) throws TurbineException
url
- A URL.methodName
- A String with the method name.params
- A Vector with the parameters.XmlRpcException.
- IOException.
- public static java.lang.Object executeAuthenticatedRpc(java.net.URL url, java.lang.String username, java.lang.String password, java.lang.String methodName, java.util.Vector params) throws TurbineException
url
- A URL.username
- The username to try and authenticate withpassword
- The password to try and authenticate withmethodName
- A String with the method name.params
- A Vector with the parameters.XmlRpcException.
- IOException.
- public static void registerHandler(java.lang.String handlerName, java.lang.Object handler) throws org.apache.xmlrpc.XmlRpcException, java.io.IOException
handlerName
- The name under which we want
to register the servicehandler
- The handler objectXmlRpcException.
- IOException.
- public static void registerHandler(java.lang.Object handler) throws org.apache.xmlrpc.XmlRpcException, java.io.IOException
handler
- The handler objectXmlRpcException.
- IOException.
- public static void unregisterHandler(java.lang.String handlerName)
handlerName
- The name of the handler to unregister.public static byte[] handleRequest(java.io.InputStream is)
is
- the stream to read request data from.public static byte[] handleRequest(java.io.InputStream is, java.lang.String user, java.lang.String password)
Note that the handlers need to implement AuthenticatedXmlRpcHandler interface to access the authentication infomration.
is
- the stream to read request data from.user
- the user that is making the request.password
- the password given by user.public static void send(java.lang.String serverURL, java.lang.String sourceLocationProperty, java.lang.String sourceFileName, java.lang.String destinationLocationProperty, java.lang.String destinationFileName) throws java.lang.Exception
serverURL
- sourceLocationProperty
- sourceFileName
- destinationLocationProperty
- destinationFileName
- public static void send(java.lang.String serverURL, java.lang.String username, java.lang.String password, java.lang.String sourceLocationProperty, java.lang.String sourceFileName, java.lang.String destinationLocationProperty, java.lang.String destinationFileName) throws java.lang.Exception
serverURL
- username
- password
- sourceLocationProperty
- sourceFileName
- destinationLocationProperty
- destinationFileName
- public static void get(java.lang.String serverURL, java.lang.String sourceLocationProperty, java.lang.String sourceFileName, java.lang.String destinationLocationProperty, java.lang.String destinationFileName) throws java.lang.Exception
serverURL
- sourceLocationProperty
- sourceFileName
- destinationLocationProperty
- destinationFileName
- public static void get(java.lang.String serverURL, java.lang.String username, java.lang.String password, java.lang.String sourceLocationProperty, java.lang.String sourceFileName, java.lang.String destinationLocationProperty, java.lang.String destinationFileName) throws java.lang.Exception
serverURL
- username
- password
- sourceLocationProperty
- sourceFileName
- destinationLocationProperty
- destinationFileName
- public static void remove(java.lang.String serverURL, java.lang.String sourceLocationProperty, java.lang.String sourceFileName) throws java.lang.Exception
serverURL
- sourceLocationProperty
- sourceFileName
- public static void remove(java.lang.String serverURL, java.lang.String username, java.lang.String password, java.lang.String sourceLocationProperty, java.lang.String sourceFileName) throws java.lang.Exception
serverURL
- username
- password
- sourceLocationProperty
- sourceFileName
- public static void setParanoid(boolean state)
acceptClient(java.lang.String)
,
denyClient(java.lang.String)
public static void acceptClient(java.lang.String address)
denyClient(java.lang.String)
,
setParanoid(boolean)
public static void denyClient(java.lang.String address)
acceptClient(java.lang.String)
,
setParanoid(boolean)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |