org.mule.util.queue
Interface Queue

All Superinterfaces:
NamedObject

public interface Queue
extends NamedObject

Queue TODO


Method Summary
 void clear()
          Discards all the elements in the queue
 void dispose()
          Disposes this queue by releasing it's storage and associated memory and storage.
 boolean offer(Serializable object, long timeout)
           
 Serializable peek()
           
 Serializable poll(long timeout)
           
 void put(Serializable object)
          Puts a new object in this queue and wait if necessary.
 int size()
          Returns the number of elements in this queue.
 Serializable take()
          Blocks and retrieves an object from this queue.
 void untake(Serializable item)
           
 
Methods inherited from interface org.mule.api.NamedObject
getName
 

Method Detail

size

int size()
Returns the number of elements in this queue.


put

void put(Serializable object)
         throws InterruptedException,
                ObjectStoreException
Puts a new object in this queue and wait if necessary.

Throws:
InterruptedException
ObjectStoreException

take

Serializable take()
                  throws InterruptedException
Blocks and retrieves an object from this queue.

Returns:
an object.
Throws:
InterruptedException

untake

void untake(Serializable item)
            throws InterruptedException,
                   ObjectStoreException
Throws:
InterruptedException
ObjectStoreException

peek

Serializable peek()
                  throws InterruptedException
Throws:
InterruptedException

poll

Serializable poll(long timeout)
                  throws InterruptedException
Throws:
InterruptedException

offer

boolean offer(Serializable object,
              long timeout)
              throws InterruptedException,
                     ObjectStoreException
Throws:
InterruptedException
ObjectStoreException

clear

void clear()
           throws InterruptedException
Discards all the elements in the queue

Throws:
InterruptedException

dispose

void dispose()
             throws MuleException,
                    InterruptedException
Disposes this queue by releasing it's storage and associated memory and storage. If after disposing the queue you try go get it back, you'll get a fresh new one which maintains none of the original one's data

Throws:
MuleException
InterruptedException


Copyright © 2003-2014 MuleSoft, Inc.. All Rights Reserved.