|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.xmlrpc.common.XmlRpcWorkerFactory
public abstract class XmlRpcWorkerFactory
A factory for XmlRpcWorker
instances.
Field Summary | |
---|---|
private XmlRpcController |
controller
|
private int |
numThreads
|
private java.util.List |
pool
|
private XmlRpcWorker |
singleton
|
Constructor Summary | |
---|---|
XmlRpcWorkerFactory(XmlRpcController pController)
Creates a new instance. |
Method Summary | |
---|---|
XmlRpcController |
getController()
Returns the factory controller. |
int |
getCurrentRequests()
Returns the number of currently running requests. |
XmlRpcWorker |
getWorker()
Returns a worker for synchronous processing. |
protected abstract XmlRpcWorker |
newWorker()
Creates a new worker instance. |
void |
releaseWorker(XmlRpcWorker pWorker)
Called, when the worker did its job. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private final XmlRpcWorker singleton
private final XmlRpcController controller
private final java.util.List pool
private int numThreads
Constructor Detail |
---|
public XmlRpcWorkerFactory(XmlRpcController pController)
pController
- The client controlling the factory.Method Detail |
---|
protected abstract XmlRpcWorker newWorker()
XmlRpcWorker
.public XmlRpcController getController()
org.apache.xmlrpc.client.XmlRpcClient
, or
org.apache.xmlrpc.server.XmlRpcServer
.public XmlRpcWorker getWorker() throws XmlRpcLoadException
XmlRpcWorker
, which is ready
for use.
XmlRpcLoadException
- The clients maximum number of concurrent
threads is exceeded.public void releaseWorker(XmlRpcWorker pWorker)
pWorker
- The worker being released.public int getCurrentRequests()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |