Package org.apache.cxf.workqueue
Class AutomaticWorkQueueImpl
java.lang.Object
org.apache.cxf.workqueue.AutomaticWorkQueueImpl
- All Implemented Interfaces:
- Executor,- AutomaticWorkQueue,- WorkQueue
- 
Field SummaryFields
- 
Constructor SummaryConstructorsConstructorDescriptionAutomaticWorkQueueImpl(int max) AutomaticWorkQueueImpl(int mqs, int initialThreads, int highWaterMark, int lowWaterMark, long dequeueTimeout) AutomaticWorkQueueImpl(int mqs, int initialThreads, int highWaterMark, int lowWaterMark, long dequeueTimeout, String name) AutomaticWorkQueueImpl(int max, String name) AutomaticWorkQueueImpl(String name) 
- 
Method SummaryModifier and TypeMethodDescriptionvoidaddChangeListener(PropertyChangeListener listener) voidvoidvoidSubmits a work item for execution at some time in the future, waiting for up to a specified amount of time for the item to be accepted.intprotected ThreadPoolExecutorintintintintlongGets the maximum size (capacity) of the backing queue.getName()Get's the name of the workqueueintintlonggetSize()Gets the current size of the backing queue.booleanisEmpty()booleanisFull()booleanisShared()booleanReturns true if this object has been shut down.voidvoidremoveChangeListener(PropertyChangeListener listener) voidvoidSchedules a work item for execution at some time in the future.voidsetDequeueTimeout(long l) voidsetHighWaterMark(int hwm) voidsetInitialSize(int initialSize) voidsetLowWaterMark(int lwm) voidvoidsetQueueSize(int size) voidsetShared(boolean shared) voidshutdown(boolean processRemainingWorkItems) Initiates an orderly shutdown.toString()voidupdate(Dictionary<String, String> config) 
- 
Field Details- 
PROPERTY_NAME- See Also:
 
 
- 
- 
Constructor Details- 
AutomaticWorkQueueImplpublic AutomaticWorkQueueImpl()
- 
AutomaticWorkQueueImpl
- 
AutomaticWorkQueueImplpublic AutomaticWorkQueueImpl(int max) 
- 
AutomaticWorkQueueImpl
- 
AutomaticWorkQueueImplpublic AutomaticWorkQueueImpl(int mqs, int initialThreads, int highWaterMark, int lowWaterMark, long dequeueTimeout) 
- 
AutomaticWorkQueueImplpublic AutomaticWorkQueueImpl(int mqs, int initialThreads, int highWaterMark, int lowWaterMark, long dequeueTimeout, String name) 
 
- 
- 
Method Details- 
addChangeListener
- 
removeChangeListener
- 
notifyChangeListeners
- 
getExecutor
- 
setName
- 
getNameDescription copied from interface:AutomaticWorkQueueGet's the name of the workqueue- Specified by:
- getNamein interface- AutomaticWorkQueue
- Returns:
- the name
 
- 
toString
- 
execute
- 
executeDescription copied from interface:WorkQueueSubmits a work item for execution at some time in the future, waiting for up to a specified amount of time for the item to be accepted.
- 
scheduleDescription copied from interface:WorkQueueSchedules a work item for execution at some time in the future.
- 
shutdownpublic void shutdown(boolean processRemainingWorkItems) Description copied from interface:AutomaticWorkQueueInitiates an orderly shutdown. IfprocessRemainingWorkItemsis true, waits for all active items to finish execution before returning, otherwise returns immediately after removing all non active items from the queue.- Specified by:
- shutdownin interface- AutomaticWorkQueue
 
- 
getMaxSizepublic long getMaxSize()Gets the maximum size (capacity) of the backing queue.- Returns:
- the maximum size (capacity) of the backing queue.
 
- 
getSizepublic long getSize()Gets the current size of the backing queue.- Returns:
- the current size of the backing queue.
 
- 
isEmptypublic boolean isEmpty()
- 
isFullpublic boolean isFull()
- 
getHighWaterMarkpublic int getHighWaterMark()
- 
getLowWaterMarkpublic int getLowWaterMark()
- 
getInitialSizepublic int getInitialSize()
- 
setHighWaterMarkpublic void setHighWaterMark(int hwm) 
- 
setLowWaterMarkpublic void setLowWaterMark(int lwm) 
- 
setInitialSizepublic void setInitialSize(int initialSize) 
- 
setQueueSizepublic void setQueueSize(int size) 
- 
setDequeueTimeoutpublic void setDequeueTimeout(long l) 
- 
isShutdownpublic boolean isShutdown()Description copied from interface:AutomaticWorkQueueReturns true if this object has been shut down.- Specified by:
- isShutdownin interface- AutomaticWorkQueue
- Returns:
- true if this object has been shut down.
 
- 
getLargestPoolSizepublic int getLargestPoolSize()
- 
getPoolSizepublic int getPoolSize()
- 
getActiveCountpublic int getActiveCount()
- 
update
- 
getProperties
 
-