org.zkoss.zkex.zul.impl
Class OperationQueue

java.lang.Object
  extended by org.zkoss.zkex.zul.impl.OperationQueue

public class OperationQueue
extends java.lang.Object

A queue for storing Operation and is thread-safe. This class is for model sharer developer only, you rarely need to use this class.

Available in ZK PE and ZK EE.

Since:
3.0.0
Author:
Dennis.Chen

Constructor Summary
OperationQueue()
           
 
Method Summary
 void addListener(OperationQueueListener listener)
          Add a listener to this queue
 Operation element()
          Get an operation from queue, doesn't remove it.
 boolean hasElement()
          Check is there any operation in queue.
 Operation next()
          Get an operation from queue, and then remove it.
 void put(Operation op)
          Put an operation to queue
 void remove()
          Remove the first operation in queue if exist.
 void removeListener(OperationQueueListener listener)
          Remove a listener to this queue.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OperationQueue

public OperationQueue()
Method Detail

addListener

public void addListener(OperationQueueListener listener)
Add a listener to this queue


removeListener

public void removeListener(OperationQueueListener listener)
Remove a listener to this queue.


put

public void put(Operation op)
Put an operation to queue

Parameters:
op - the operation.

element

public Operation element()
Get an operation from queue, doesn't remove it.

Returns:
the first operation in queue, null if not such operation.

hasElement

public boolean hasElement()
Check is there any operation in queue.

Returns:
true if there exist any operation in queue.

next

public Operation next()
Get an operation from queue, and then remove it.

Returns:
the first operation in queue, null if not such operation.

remove

public void remove()
Remove the first operation in queue if exist.



Copyright © 2005-2011 Potix Corporation. All Rights Reserved. SourceForge.net Logo