com.plumtree.uiinfrastructure.interpreter.filter.utils
Class ASQueue

java.lang.Object
  extended by com.plumtree.uiinfrastructure.interpreter.filter.utils.ASQueue

public class ASQueue
extends java.lang.Object

This class implements part of a multi-threaded queue. Currently it only maintains a counter of objects in the queue, but it will eventually be able to optimize identical requests out of the queue.

Author:
DonH

Constructor Summary
ASQueue(IApplication application)
           
 
Method Summary
 boolean Register()
          This method checks whether or not there is space available on the queue.
 boolean RemoveFromQueue()
          This method removes an item from the queue.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ASQueue

public ASQueue(IApplication application)
Method Detail

Register

public boolean Register()
This method checks whether or not there is space available on the queue. If there is, the registration succeeds and the queue length is incremented. If not, the registration fails and the length remains unchanged. There is no need to call RemoveFromQueue() if registration fails.

Returns:
boolean true implies success, false implies failure.

RemoveFromQueue

public boolean RemoveFromQueue()
This method removes an item from the queue. There is no need to call RemoveFromQueue() if Register() failed.

Returns:
boolean true implies success, false implies failure.



Copyright © 2002,2003,2004,2005 Plumtree Software, Inc., All Rights Reserved.