|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SemiSpaceInterface
Operations possible to perform on space, inspired by the JavaSpace interface.
Method Summary | ||
---|---|---|
SemiEventRegistration |
notify(Object template,
SemiEventListener listener,
long duration)
Register a listener for a particular template search. |
|
|
read(T template,
long duration)
Read an object from the space, which has matching fields (or getters) with the template |
|
|
readIfExists(T template)
Same as read, with duration 0 |
|
|
take(T template,
long duration)
Same as read, except that the object is removed from the space. |
|
|
takeIfExists(T template)
Same as take, with a duration of 0 |
|
SemiLease |
write(Object obj,
long duration)
Write object into tuple space, with a life time given in ms. |
Method Detail |
---|
SemiLease write(Object obj, long duration)
obj
- Object to be written into the spaceduration
- Life time in milliseconds of the written object
<T> T read(T template, long duration)
template
- Object of exactly the same type as what
is wanted as return value, with zero or more none-null fields or getters.duration
- How long you are willing to wait for an answer / match.
<T> T readIfExists(T template)
read(Object, long)
<T> T take(T template, long duration)
read(Object, long)
<T> T takeIfExists(T template)
take(Object, long)
,
read(Object, long)
SemiEventRegistration notify(Object template, SemiEventListener listener, long duration)
template
- Template to be matched.listener
- Listener to be notified when object with a matching template is foundduration
- How long this particular listener is valid.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |