com.pega.pegarules.pub.context
Interface PRQueueIterator


public interface PRQueueIterator

A simple iterator with support for next() method to browse a particular class of items in the queue.


Field Summary
static java.lang.String VERSION
           
 
Method Summary
 ClipboardPage first()
          Get oldest (first) queue item based on criteria and class specified when this QueueIterator was constructed via PRQueueManager.iterator(String)
 ClipboardPage first(boolean aAcquireLock)
          Get oldest (first) queue item based on criteria and class specified when this QueueIterator was constructed via PRQueueManager.iterator(String)
 java.lang.Object next()
          Get next queue item based on criteria and class specified when this QueueIterator was constructed.
 ClipboardPage next(boolean aAcquireLock)
          Get next queue item based on criteria and class specified when this QueueIterator was constructed via PRQueueManager.iterator(String)
 

Field Detail

VERSION

static final java.lang.String VERSION
Method Detail

next

ClipboardPage next(boolean aAcquireLock)
Get next queue item based on criteria and class specified when this QueueIterator was constructed via PRQueueManager.iterator(String)

If previous locked item exists in the owning QueueManager, will throw Exception.

This method will return the item that is the next oldest after the previous item retrieved by this iterator.

Parameters:
aAcquireLock - Should queue item be reserved for exclusive processing. If lock is acquired, this marks the start of the transaction that can be completed via rollback or commit. Note: If aAcquireLock is false, item will NOT be locked for exclusive processing, and could potentially be processed by another requestor.
Returns:
ClipboardPage The queue item, or null if no items are available that match criteria.

next

java.lang.Object next()
Get next queue item based on criteria and class specified when this QueueIterator was constructed.

If previous locked item exists in the owning QueueManager, will throw Exception.

This version of next always acquires a lock on the item which can be released via commit() or rollback().

This method will return the item that is the next oldest after the previous item retrieved by this iterator.

Returns:
Object The queue item (ClipboardPage), or null if no items are available that match criteria.

first

ClipboardPage first(boolean aAcquireLock)
Get oldest (first) queue item based on criteria and class specified when this QueueIterator was constructed via PRQueueManager.iterator(String)

If previous locked item exists in the owning QueueManager, will throw Exception.

This method ignores any previous items retrieved by this iterator, so it may return the same item repeatedly.

Parameters:
aAcquireLock - Should queue item be reserved for exclusive processing. If lock is acquired, this marks the start of the transaction that can be completed via rollback or commit. Note: If aAcquireLock is false, item will NOT be locked for exclusive processing, and could potentially be processed by another requestor.
Returns:
ClipboardPage The queue item, or null if no items are available that match criteria.

first

ClipboardPage first()
Get oldest (first) queue item based on criteria and class specified when this QueueIterator was constructed via PRQueueManager.iterator(String)

If previous locked item exists in the owning QueueManager, will throw Exception.

This method ignores any previous items retrieved by this iterator, so it may return the same item repeatedly.

This version of first always acquires a lock on the item which can be released via commit() or rollback().

Returns:
ClipboardPage The queue item, or null if no items are available that match criteria.


Copyright © 2012 Pegasystems Inc. All Rights Reserved.