java.lang.Object | +--org.erights.e.elib.ref.Ref | +--org.erights.e.elib.ref.Proxy | +--org.erights.e.elib.ref.RemotePromise
A RemotePromise is a Proxy intended to represent a promise that will be resolved remotely (in another vat).
A RemotePromise is born handled (delegating to its ProxyHandler). While it is handled, it is EVENTUAL and has no identity. It is therefore also unsettled.
(package private) ProxyHandler
myOptHandler
Object
callAll(String verb,
Object[] args)
ProxyHandler
getOptProxyHandler(Class handlerClass)
(package private) Ref
resolutionRef()
Ref
sendAll(String verb,
Object[] args)
Throwable
sendAllOnly(String verb,
Object[] args)
broken, disconnected, getAllegedType, GetRefMaker, ignore, isBroken, isDeepFrozen, isDeepPassByCopy, isEventual, isFar, isNear, isPassByProxy, isPBC, isPersistent, isResolved, isSameEver, isSelfish, isSelfless, isSettled, makeBufferingPromise, makeSwitchablePromise, optBroken, optProblem, optSealedDispatch, optShorten, promise, resolution, resolution, respondsTo, sendMsg, state, toCallable, toRef, toString, whenBroken, whenBrokenOnly, whenResolved, whenResolvedOnly
ProxyHandler myOptHandler
Ref myOptTarget
RemotePromise(ProxyHandler handler)
public boolean isResolved()
Ref
isResolved in class Refvoid setTarget(Ref newTarget)
public SealedBox optSealedDispatch(Brand brand)
optSealedDispatch in interface AmplifiableoptSealedDispatch in class Refpublic ProxyHandler getOptProxyHandler(Class handlerClass)
All implementations of getOptProxyHandler/1 must be thread
safe, in order for
BootRefHandler.getOptBootRefHandler/1
to be thread safe: myOptHandler only makes one transition from non-null
to null. This implementation samples it once, and then proceeds with the
possibly slightly stale sample.
getOptProxyHandler in class Refpublic Throwable optProblem()
All implementations of optProblem/0 must be thread safe, in
order for Ref.state/0 to be thread safe.
optProblem in class RefRef.optProblem(Object)Ref resolutionRef()
All implementations of resolutionRef/0 must be thread safe, in
order for Ref.resolution/0 to be thread
safe: If resolutionRef/0 is called from another thread while this
proxy is in the middle of being shortened, then resolutionRef/0 must
return either this or what this proxy is being shortened to.
XXX Although the implementation doesn't synchronize, it is inductively thread safe given a simple memory model. Is it safe in Java's complex memory model? Do we care -- are any Java implementations not faithful to the simple memory model?
resolutionRef in class Refpublic String state()
All implementations of state/0 must be thread safe, in order
for Ref.isNear/1 to be thread safe.
Ref.state(Object)public Object callAll(String verb, Object[] args)
Ref
public Ref sendAll(String verb, Object[] args)
Ref
public Throwable sendAllOnly(String verb, Object[] args)
Ref
sendAllOnly in class Refvoid commit()