public class SpaceProxy2 extends Object implements JavaSpace05, Administrable, net.jini.id.ReferentUuid, Serializable, net.jini.export.ProxyAccessor
OutriggerServerImpl
implements the
OutriggerSpace
interface, and each
SpaceProxy2
object holds a reference to the remote
OutriggerSpace server it represents to the client. The client makes
calls from the JavaSpace
interface, which the
SpaceProxy2
translates into appropriate
OutriggerSpace
calls to the
OutriggerServerImpl
server.Constructor and Description |
---|
SpaceProxy2(OutriggerServer space,
net.jini.id.Uuid spaceUuid,
long serverMaxServerQueryTimeout)
Create a new
SpaceProxy2 for the given space. |
Modifier and Type | Method and Description |
---|---|
protected net.jini.core.lease.Lease |
constructLease(net.jini.id.Uuid uuid,
long expiration)
Create a new lease with the specified id and initial expiration
|
MatchSet |
contents(Collection tmpls,
net.jini.core.transaction.Transaction txn,
long leaseDuration,
long maxEntries) |
boolean |
equals(Object other) |
Object |
getAdmin() |
Object |
getProxy() |
net.jini.id.Uuid |
getReferentUuid() |
int |
hashCode() |
protected net.jini.core.lease.Lease |
newLease(net.jini.id.Uuid uuid,
long duration)
Create a new lease with the specified id and initial duration
|
net.jini.core.event.EventRegistration |
notify(net.jini.core.entry.Entry tmpl,
net.jini.core.transaction.Transaction txn,
net.jini.core.event.RemoteEventListener listener,
long lease,
MarshalledObject handback) |
net.jini.core.entry.Entry |
read(net.jini.core.entry.Entry tmpl,
net.jini.core.transaction.Transaction txn,
long timeout) |
net.jini.core.entry.Entry |
readIfExists(net.jini.core.entry.Entry tmpl,
net.jini.core.transaction.Transaction txn,
long timeout) |
net.jini.core.event.EventRegistration |
registerForAvailabilityEvent(Collection tmpls,
net.jini.core.transaction.Transaction txn,
boolean visibilityOnly,
net.jini.core.event.RemoteEventListener listener,
long leaseDuration,
MarshalledObject handback) |
net.jini.core.entry.Entry |
snapshot(net.jini.core.entry.Entry entry) |
Collection |
take(Collection tmpls,
net.jini.core.transaction.Transaction txn,
long timeout,
long maxEntries) |
net.jini.core.entry.Entry |
take(net.jini.core.entry.Entry tmpl,
net.jini.core.transaction.Transaction txn,
long timeout) |
net.jini.core.entry.Entry |
takeIfExists(net.jini.core.entry.Entry tmpl,
net.jini.core.transaction.Transaction txn,
long timeout) |
String |
toString() |
net.jini.core.lease.Lease |
write(net.jini.core.entry.Entry entry,
net.jini.core.transaction.Transaction txn,
long lease) |
List |
write(List entries,
net.jini.core.transaction.Transaction txn,
List leaseDurations) |
public SpaceProxy2(OutriggerServer space, net.jini.id.Uuid spaceUuid, long serverMaxServerQueryTimeout)
SpaceProxy2
for the given space.space
- The OutriggerServer
for the
space.spaceUuid
- The universally unique ID for the
spaceserverMaxServerQueryTimeout
- The value this proxy
should use for the maxServerQueryTimeout
if no local value is provided.NullPointerException
- if space
or
spaceUuid
is null
.IllegalArgumentException
- if
serverMaxServerQueryTimeout
is not
larger than zero.public net.jini.id.Uuid getReferentUuid()
getReferentUuid
in interface net.jini.id.ReferentUuid
public Object getProxy()
getProxy
in interface net.jini.export.ProxyAccessor
public net.jini.core.lease.Lease write(net.jini.core.entry.Entry entry, net.jini.core.transaction.Transaction txn, long lease) throws net.jini.core.transaction.TransactionException, RemoteException
write
in interface JavaSpace
net.jini.core.transaction.TransactionException
RemoteException
public net.jini.core.entry.Entry read(net.jini.core.entry.Entry tmpl, net.jini.core.transaction.Transaction txn, long timeout) throws net.jini.core.entry.UnusableEntryException, net.jini.core.transaction.TransactionException, InterruptedException, RemoteException
read
in interface JavaSpace
net.jini.core.entry.UnusableEntryException
net.jini.core.transaction.TransactionException
InterruptedException
RemoteException
public net.jini.core.entry.Entry readIfExists(net.jini.core.entry.Entry tmpl, net.jini.core.transaction.Transaction txn, long timeout) throws net.jini.core.entry.UnusableEntryException, net.jini.core.transaction.TransactionException, InterruptedException, RemoteException
readIfExists
in interface JavaSpace
net.jini.core.entry.UnusableEntryException
net.jini.core.transaction.TransactionException
InterruptedException
RemoteException
public net.jini.core.entry.Entry take(net.jini.core.entry.Entry tmpl, net.jini.core.transaction.Transaction txn, long timeout) throws net.jini.core.entry.UnusableEntryException, net.jini.core.transaction.TransactionException, InterruptedException, RemoteException
take
in interface JavaSpace
net.jini.core.entry.UnusableEntryException
net.jini.core.transaction.TransactionException
InterruptedException
RemoteException
public net.jini.core.entry.Entry takeIfExists(net.jini.core.entry.Entry tmpl, net.jini.core.transaction.Transaction txn, long timeout) throws net.jini.core.entry.UnusableEntryException, net.jini.core.transaction.TransactionException, InterruptedException, RemoteException
takeIfExists
in interface JavaSpace
net.jini.core.entry.UnusableEntryException
net.jini.core.transaction.TransactionException
InterruptedException
RemoteException
public net.jini.core.entry.Entry snapshot(net.jini.core.entry.Entry entry) throws MarshalException
snapshot
in interface JavaSpace
MarshalException
public net.jini.core.event.EventRegistration notify(net.jini.core.entry.Entry tmpl, net.jini.core.transaction.Transaction txn, net.jini.core.event.RemoteEventListener listener, long lease, MarshalledObject handback) throws net.jini.core.transaction.TransactionException, RemoteException
notify
in interface JavaSpace
net.jini.core.transaction.TransactionException
RemoteException
public List write(List entries, net.jini.core.transaction.Transaction txn, List leaseDurations) throws RemoteException, net.jini.core.transaction.TransactionException
write
in interface JavaSpace05
RemoteException
net.jini.core.transaction.TransactionException
public Collection take(Collection tmpls, net.jini.core.transaction.Transaction txn, long timeout, long maxEntries) throws UnusableEntriesException, net.jini.core.transaction.TransactionException, RemoteException
take
in interface JavaSpace05
UnusableEntriesException
net.jini.core.transaction.TransactionException
RemoteException
public net.jini.core.event.EventRegistration registerForAvailabilityEvent(Collection tmpls, net.jini.core.transaction.Transaction txn, boolean visibilityOnly, net.jini.core.event.RemoteEventListener listener, long leaseDuration, MarshalledObject handback) throws net.jini.core.transaction.TransactionException, RemoteException
registerForAvailabilityEvent
in interface JavaSpace05
net.jini.core.transaction.TransactionException
RemoteException
public MatchSet contents(Collection tmpls, net.jini.core.transaction.Transaction txn, long leaseDuration, long maxEntries) throws RemoteException, net.jini.core.transaction.TransactionException
contents
in interface JavaSpace05
RemoteException
net.jini.core.transaction.TransactionException
protected final net.jini.core.lease.Lease newLease(net.jini.id.Uuid uuid, long duration)
uuid
- lease idduration
- lease duration in milliseconds, note actual lease duration
granted may be less.protected net.jini.core.lease.Lease constructLease(net.jini.id.Uuid uuid, long expiration)
uuid
- lease id.expiration
- time lease expires, in milliseconds since epoch.public Object getAdmin() throws RemoteException
getAdmin
in interface Administrable
RemoteException
Copyright © 2016–2018. All rights reserved.