Package org.jpos.q2.qbean
Class SpaceLet
- java.lang.Object
-
- org.jpos.q2.QBeanSupport
-
- org.jpos.q2.qbean.SpaceLet
-
- All Implemented Interfaces:
Configurable
,QBean
,QBeanSupportMBean
,QPersist
,Space
public class SpaceLet extends QBeanSupport implements Space
-
-
Field Summary
-
Fields inherited from class org.jpos.q2.QBeanSupport
cfg, log, scheduledThreadPoolExecutor
-
-
Constructor Summary
Constructors Constructor Description SpaceLet()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
existAny(java.lang.Object[] keys)
boolean
existAny(java.lang.Object[] keys, long timeout)
java.lang.Object
in(java.lang.Object key)
Take an entry from the space, waiting forever until one exists.java.lang.Object
in(java.lang.Object key, long timeout)
Take an entry from the space, waiting a limited amount of time until one exists.void
initService()
java.lang.Object
inp(java.lang.Object key)
In probe takes an entry from the space if one exists, return null otherwise.void
nrd(java.lang.Object key)
Nrd (not read) waits forever until Key is not present in space Resolution for expiring entries is implementation dependant, but a minimum one-second is suggested.java.lang.Object
nrd(java.lang.Object key, long timeout)
Nrd (not read) waits up to timeout until Key is not present in space Resolution for expiring entries is implementation dependant, but a minimum one-second is suggested.void
out(java.lang.Object key, java.lang.Object value)
Write a new entry into the Spacevoid
out(java.lang.Object key, java.lang.Object value, long timeout)
Write a new entry into the Space, with an timeout valuevoid
push(java.lang.Object key, java.lang.Object value)
Write a new entry at the head of a queue.void
push(java.lang.Object key, java.lang.Object value, long timeout)
Write a new entry at the head of the queue with a timeout valuevoid
put(java.lang.Object key, java.lang.Object value)
Write a single entry at the head of the queue discarding the other entriesvoid
put(java.lang.Object key, java.lang.Object value, long timeout)
Write a single entry at the head of the queue discarding the other entries, with timeout.java.lang.Object
rd(java.lang.Object key)
Read an entry from the space, waiting forever until one exists.java.lang.Object
rd(java.lang.Object key, long timeout)
Read an entry from the space, waiting a limited amount of time until one exists.java.lang.Object
rdp(java.lang.Object key)
Read probe reads an entry from the space if one exists, return null otherwise.void
startService()
void
stopService()
-
Methods inherited from class org.jpos.q2.QBeanSupport
addAttr, close, createElement, destroy, destroyService, getAttrs, getAttrs, getConfiguration, getDump, getFactory, getLoader, getLoaderURLS, getLog, getLogger, getName, getPersist, getProperties, getProperty, getRealm, getScheduledThreadPoolExecutor, getServer, getState, getStateAsString, init, isModified, running, setAttr, setConfiguration, setLogger, setModified, setName, setPersist, setProperty, setRealm, setServer, setState, start, stop
-
-
-
-
Constructor Detail
-
SpaceLet
public SpaceLet()
-
-
Method Detail
-
initService
public void initService() throws ConfigurationException
- Overrides:
initService
in classQBeanSupport
- Throws:
ConfigurationException
-
startService
public void startService()
- Overrides:
startService
in classQBeanSupport
-
stopService
public void stopService()
- Overrides:
stopService
in classQBeanSupport
-
out
public void out(java.lang.Object key, java.lang.Object value)
Description copied from interface:Space
Write a new entry into the Space
-
out
public void out(java.lang.Object key, java.lang.Object value, long timeout)
Description copied from interface:Space
Write a new entry into the Space, with an timeout value
-
push
public void push(java.lang.Object key, java.lang.Object value)
Description copied from interface:Space
Write a new entry at the head of a queue.
-
push
public void push(java.lang.Object key, java.lang.Object value, long timeout)
Description copied from interface:Space
Write a new entry at the head of the queue with a timeout value
-
put
public void put(java.lang.Object key, java.lang.Object value)
Description copied from interface:Space
Write a single entry at the head of the queue discarding the other entries
-
put
public void put(java.lang.Object key, java.lang.Object value, long timeout)
Description copied from interface:Space
Write a single entry at the head of the queue discarding the other entries, with timeout.
-
in
public java.lang.Object in(java.lang.Object key)
Description copied from interface:Space
Take an entry from the space, waiting forever until one exists.
-
rd
public java.lang.Object rd(java.lang.Object key)
Description copied from interface:Space
Read an entry from the space, waiting forever until one exists.
-
in
public java.lang.Object in(java.lang.Object key, long timeout)
Description copied from interface:Space
Take an entry from the space, waiting a limited amount of time until one exists.
-
rd
public java.lang.Object rd(java.lang.Object key, long timeout)
Description copied from interface:Space
Read an entry from the space, waiting a limited amount of time until one exists.
-
inp
public java.lang.Object inp(java.lang.Object key)
Description copied from interface:Space
In probe takes an entry from the space if one exists, return null otherwise.
-
rdp
public java.lang.Object rdp(java.lang.Object key)
Description copied from interface:Space
Read probe reads an entry from the space if one exists, return null otherwise.
-
existAny
public boolean existAny(java.lang.Object[] keys)
-
existAny
public boolean existAny(java.lang.Object[] keys, long timeout)
-
nrd
public void nrd(java.lang.Object key)
Description copied from interface:Space
Nrd (not read) waits forever until Key is not present in space Resolution for expiring entries is implementation dependant, but a minimum one-second is suggested.
-
-