org.zkoss.zk.ui.sys
Interface RequestQueue

All Known Implementing Classes:
RequestQueueImpl

public interface RequestQueue

A queue of AuRequest. There is one queue for each desktop.

Implementation Note: Unlike only of desktop members, this class must be thread-safe.

Author:
tomyeh

Method Summary
 void addPerfRequestId(java.lang.String requestId)
          Adds a request ID that uniquely identifies a request for performance measurement PerformanceMeter.
 void addRequests(java.util.Collection<AuRequest> requests)
          Adds a list of requests to the queue.
 java.util.Collection<java.lang.String> clearPerfRequestIds()
          Clears all request IDs that were added by addPerfRequestId(java.lang.String) for performance measurement.
 boolean isEmpty()
          Returns if no more request available in the queue.
 AuRequest nextRequest()
          Returns the next request, or null if no more request.
 

Method Detail

isEmpty

boolean isEmpty()
Returns if no more request available in the queue.

Returns:
whether no more request is available in the queue.
Since:
3.0.5

nextRequest

AuRequest nextRequest()
Returns the next request, or null if no more request. Once returned, the request is removed from the queue.


addRequests

void addRequests(java.util.Collection<AuRequest> requests)
Adds a list of requests to the queue. Notice that when the request is added, it will be activated first, i.e., AuRequest.activate() will be called before adding to queue. If the component is not found or does not belong to the current execution, it will be ignored.


addPerfRequestId

void addPerfRequestId(java.lang.String requestId)
Adds a request ID that uniquely identifies a request for performance measurement PerformanceMeter.

Parameters:
requestId - the request ID (never null)
Since:
3.0.5

clearPerfRequestIds

java.util.Collection<java.lang.String> clearPerfRequestIds()
Clears all request IDs that were added by addPerfRequestId(java.lang.String) for performance measurement. It is usually called after all requests are processed (isEmpty() is true).

Returns:
a list of request IDs that were added by addPerfRequestId(java.lang.String), or null if no request ID was added.
Since:
3.0.5


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