public abstract class OpMethod extends OpImpl
OpRemote.Helper| Constructor and Description |
|---|
OpMethod()
Create a new instance of an operation that's to be serviced
via a method.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
canAppearInInni()
Can this operation be serviced by an inni?
Only an
OpInni can. |
abstract void |
codeBlock(Invocation inv)
Override this method
with the actual code for the operation.
|
void |
deliverPendingMessages()
If operation's queue of pending invocations was locked due
to equivalence class locking stuff (e.g., merging),
then deliver pending messages.
|
edu.ucdavis.rj.OpInniIterator |
elements()
Get an iterator to iterate over
pending invocations of this operation.
|
long |
getFirstTime()
Get the timestamp of the first (oldest)
pending invocation of this operation.
|
edu.ucdavis.rj.InLock |
getLock()
Get the equivalence class lock for this operation.
|
boolean |
isRemote(java.lang.String site)
Is this operation on a remote VM or on the current VM?
(Not allowed on an
OpMethod.) |
int |
length()
Returns the number of Invocations pending for this operation.
|
Invocation |
P()
A semaphore P (aka down) operation.
|
Invocation |
receive()
Get the first (oldest) pending invocation of this
OpInni. |
call, call, equals, getId, hashCode, isNoop, send, send, Vpublic OpMethod()
throws java.rmi.RemoteException
java.rmi.RemoteException - if RMI fails.public abstract void codeBlock(Invocation inv)
inv - The invocation to service.public Invocation receive()
OpOpInni.
Wait if no invocation is pending.
(Not allowed on an OpMethod.)public long getFirstTime()
Oppublic boolean canAppearInInni()
throws java.rmi.RemoteException
OpOpInni can.true if and only if this operation is an OpInni.java.rmi.RemoteException - if RMI fails.public edu.ucdavis.rj.InLock getLock()
throws java.rmi.RemoteException
OpOpMethod.)java.rmi.RemoteException - if RMI fails.public boolean isRemote(java.lang.String site)
throws java.rmi.RemoteException
OpOpMethod.)site - machine name.true if and only if this operation is remote.java.rmi.RemoteException - if RMI fails.public void deliverPendingMessages()
throws java.rmi.RemoteException
Opjava.rmi.RemoteException - if this Op is an OpMethod.public edu.ucdavis.rj.OpInniIterator elements()
throws java.rmi.RemoteException
Opjava.rmi.RemoteException - if this Op is an OpMethod.public Invocation P()
OpOpInni's semaphore operations.
(Not allowed on an OpMethod.)