Package org.apache.xmlrpc.server
Class XmlRpcServer
- java.lang.Object
-
- org.apache.xmlrpc.common.XmlRpcController
-
- org.apache.xmlrpc.server.XmlRpcServer
-
- All Implemented Interfaces:
XmlRpcRequestProcessor
- Direct Known Subclasses:
XmlRpcStreamServer
public class XmlRpcServer extends XmlRpcController implements XmlRpcRequestProcessor
A multithreaded, reusable XML-RPC server object. The name may be misleading because this does not open any server sockets. Instead it is fed by passing instances ofXmlRpcRequestfrom a transport.
-
-
Field Summary
Fields Modifier and Type Field Description private XmlRpcServerConfigconfigprivate XmlRpcHandlerMappinghandlerMappingprivate TypeConverterFactorytypeConverterFactory
-
Constructor Summary
Constructors Constructor Description XmlRpcServer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Objectexecute(XmlRpcRequest pRequest)Performs the given request.XmlRpcConfiggetConfig()Returns the controllers default configuration.protected XmlRpcWorkerFactorygetDefaultXmlRpcWorkerFactory()Creates the controllers default worker factory.XmlRpcHandlerMappinggetHandlerMapping()Returns the servers handler mapping.TypeConverterFactorygetTypeConverterFactory()Returns the request processorsTypeConverterFactory.voidsetConfig(XmlRpcServerConfig pConfig)Sets the servers configuration.voidsetHandlerMapping(XmlRpcHandlerMapping pMapping)Sets the servers handler mapping.voidsetTypeConverterFactory(TypeConverterFactory pFactory)Sets the serversTypeConverterFactory.-
Methods inherited from class org.apache.xmlrpc.common.XmlRpcController
getMaxThreads, getTypeFactory, getWorkerFactory, setMaxThreads, setTypeFactory, setWorkerFactory
-
-
-
-
Field Detail
-
handlerMapping
private XmlRpcHandlerMapping handlerMapping
-
typeConverterFactory
private TypeConverterFactory typeConverterFactory
-
config
private XmlRpcServerConfig config
-
-
Method Detail
-
getDefaultXmlRpcWorkerFactory
protected XmlRpcWorkerFactory getDefaultXmlRpcWorkerFactory()
Description copied from class:XmlRpcControllerCreates the controllers default worker factory.- Specified by:
getDefaultXmlRpcWorkerFactoryin classXmlRpcController- Returns:
- The default factory for workers.
-
setTypeConverterFactory
public void setTypeConverterFactory(TypeConverterFactory pFactory)
Sets the serversTypeConverterFactory.
-
getTypeConverterFactory
public TypeConverterFactory getTypeConverterFactory()
Description copied from interface:XmlRpcRequestProcessorReturns the request processorsTypeConverterFactory.- Specified by:
getTypeConverterFactoryin interfaceXmlRpcRequestProcessor
-
setConfig
public void setConfig(XmlRpcServerConfig pConfig)
Sets the servers configuration.- Parameters:
pConfig- The new server configuration.
-
getConfig
public XmlRpcConfig getConfig()
Description copied from class:XmlRpcControllerReturns the controllers default configuration.- Specified by:
getConfigin classXmlRpcController- Returns:
- The default configuration.
-
setHandlerMapping
public void setHandlerMapping(XmlRpcHandlerMapping pMapping)
Sets the servers handler mapping.- Parameters:
pMapping- The servers handler mapping.
-
getHandlerMapping
public XmlRpcHandlerMapping getHandlerMapping()
Returns the servers handler mapping.- Returns:
- The servers handler mapping.
-
execute
public java.lang.Object execute(XmlRpcRequest pRequest) throws XmlRpcException
Performs the given request.- Specified by:
executein interfaceXmlRpcRequestProcessor- Parameters:
pRequest- The request being executed.- Returns:
- The result object.
- Throws:
XmlRpcException- The request failed.
-
-