com.sun.jini.outrigger
Class OutriggerAvailabilityEvent
java.lang.Object
java.util.EventObject
net.jini.core.event.RemoteEvent
net.jini.space.AvailabilityEvent
com.sun.jini.outrigger.OutriggerAvailabilityEvent
- All Implemented Interfaces:
- Serializable
class OutriggerAvailabilityEvent
- extends AvailabilityEvent
Outrigger's implementation of AvailabilityEvent
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
rep
private final EntryRep rep
- The entry that triggered the event
OutriggerAvailabilityEvent
OutriggerAvailabilityEvent(JavaSpace source,
long eventID,
long seqNum,
MarshalledObject handback,
boolean visibilityTransition,
EntryRep rep)
- Constructs an OutriggerAvailabilityEvent object.
- Parameters:
source
- an Object
representing the event sourceeventID
- a long
containing the event identifierseqNum
- a long
containing the event sequence numberhandback
- a MarshalledObject
that was passed in
as part of the original event registration.visibilityTransition
- true
if this event
must also signal a transition from
invisible to visiblerep
- the entry that triggered the event
readObjectNoData
private void readObjectNoData()
throws InvalidObjectException
- Throws:
InvalidObjectException
- if called
getEntry
public Entry getEntry()
throws UnusableEntryException
- Description copied from class:
AvailabilityEvent
- Returns a copy of the
Entry
whose transition
triggered this event. The returned Entry
must
be unmarshalled in accordance with the Jini
Entry Specification.
- Specified by:
getEntry
in class AvailabilityEvent
- Returns:
- a copy of the
Entry
whose transition
triggered this event
- Throws:
UnusableEntryException
- if the Entry
can't be unmarshalled in the client. The next call
must re-attempt unmarshalling the
Entry
getSnapshot
public Entry getSnapshot()
- Description copied from class:
AvailabilityEvent
- Returns a snapshot of the
Entry
whose
transition triggered this event. Snapshots are defined in
section JS.2.6 of the
JavaSpaces Service Specification and are an
alternative representation of a given Entry
produced by a particular space for use with that same
space. Passing a snapshot to a space is generally more
efficient than passing the original Entry
.
Any snapshot returned by this method will meet the same
contract as the object returned by passing the result of
getEntry
to JavaSpace.snapshot
.
Generally there is a cost associated with calling the
JavaSpace.snapshot
method and thus creating a
snapshot using that method is usually only worthwhile if
the resulting snapshot is used more than once. The cost of
invoking this method should be low and should be worthwhile
even if the resulting snapshot is used only once.
- Specified by:
getSnapshot
in class AvailabilityEvent
- Returns:
- a snapshot of the
Entry
whose
transition triggered this event
Copyright 2007-2010, multiple authors.
Licensed under the Apache License, Version 2.0, see the NOTICE file for attributions.