com.caucho.jms.file
Class FileQueueStore

java.lang.Object
  extended by com.caucho.jms.file.FileQueueStore

public class FileQueueStore
extends java.lang.Object

Implements a file queue.


Constructor Summary
FileQueueStore(Path path, java.lang.String serverId)
           
FileQueueStore(Path path, java.lang.String serverId, java.lang.ClassLoader loader)
           
 
Method Summary
 void close()
           
static FileQueueStore create()
           
 int getMessageCount()
           
 java.io.Serializable readMessage(long id)
          Retrieves a message from the persistent store.
 java.io.Serializable receive(byte[] queueHash)
          Retrieves a message from the persistent store.
 long send(byte[] queueHash, java.lang.String msgId, java.io.Serializable payload, int priority, long expireTime)
          Adds a new message to the persistent store.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FileQueueStore

public FileQueueStore(Path path,
                      java.lang.String serverId,
                      java.lang.ClassLoader loader)

FileQueueStore

public FileQueueStore(Path path,
                      java.lang.String serverId)
Method Detail

create

public static FileQueueStore create()

send

public long send(byte[] queueHash,
                 java.lang.String msgId,
                 java.io.Serializable payload,
                 int priority,
                 long expireTime)
Adds a new message to the persistent store.


readMessage

public java.io.Serializable readMessage(long id)
Retrieves a message from the persistent store.


receive

public java.io.Serializable receive(byte[] queueHash)
Retrieves a message from the persistent store.


getMessageCount

public int getMessageCount()

close

public void close()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object