|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectlime.Location
lime.HostLocation
Defines the location of a tuple within the host-level tuple space
associated with a host. This tuple space is defined to be the union of all
the interface tuple spaces (ITS) of the agents residing on that
host. Objects of this class are used for specifying at most the current
location when invoking location-dependent operations (see the
Location
class). It is not possible to specify a destination
for a host. To do this semantically, one would create a stationary agent
"representing" the host, but this would be accessed as an
AgentLocation
.
One "wild card location" constant is provided by this class:
UNSPECIFIED
: it is used to leave unspecified the current
lcoation field in a location-dependent operation. Thus, for instance,
using the example provided in class Location
:
LimeTupleSpace ts = new LimeTupleSpace("myApplication"); ITuple t = ts.in(HostLocation.UNSPECIFIED, new AgentLocation(agent.getMgr().getID()), template);specifies a blocking
in
that searches the whole shared
tuple space for a tuple whose final location is the agent
's
ITS named myApplication
.
LimeTupleSpace
,
AgentID
,
AgentLocation
,
LocalizedReaction
,
Serialized FormField Summary | |
(package private) LimeServerID |
host
|
static HostLocation |
UNSPECIFIED
Define a wild card location that denotes an unspecified host location. |
Fields inherited from class lime.Location |
_ANY, _NORMAL, _UNKNOWN, _UNSPECIFIED, wildCard |
Constructor Summary | |
|
HostLocation(LimeServerID host)
Create a location corresponding to the host-level tuple space of a given host. |
(package private) |
HostLocation(short wildCard)
Create a wild card host location, specified by one of the constants associated with this class. |
Method Summary | |
boolean |
equals(java.lang.Object l)
Tests two host locations for equality. |
java.lang.String |
toString()
Returns a concise textual description for this object. |
Methods inherited from class lime.Location |
isWildCard |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
LimeServerID host
public static final HostLocation UNSPECIFIED
Constructor Detail |
public HostLocation(LimeServerID host)
host
- the host address:port combination.HostLocation(short wildCard)
wildCard
- the constant specifying the wild card host location.Method Detail |
public boolean equals(java.lang.Object l)
l
- a host location (it can be a wild card location).
true
is returned if both locations correspond to the same
host. If the locations are wild cards, then true
is returned
if they correspond to the same constant (e.g, the method returns
true
when comparing two UNSPECIFIED
locations). In all the remaining cases false
is returned.public java.lang.String toString()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |