|
GigaSpaces XAP 9.7.2 API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.jini.core.transaction.server.ServerTransaction net.jini.core.transaction.server.NestableServerTransaction
public class NestableServerTransaction
Class implementing the NestableTransaction
interface, for use
with transaction participants that implement the default transaction
semantics.
NestableTransaction
,
NestableTransactionManager
,
TransactionFactory
,
Serialized FormNested Class Summary |
---|
Nested classes/interfaces inherited from interface net.jini.core.transaction.NestableTransaction |
---|
NestableTransaction.Created |
Field Summary | |
---|---|
NestableServerTransaction |
parent
The parent transaction, if any. |
Fields inherited from class net.jini.core.transaction.server.ServerTransaction |
---|
EMBEDDED_CRASH_COUNT, id, mgr |
Constructor Summary | |
---|---|
NestableServerTransaction()
Do not use. |
|
NestableServerTransaction(NestableTransactionManager mgr,
long id,
NestableServerTransaction parent,
long lease)
Simple constructor. |
Method Summary | |
---|---|
NestableTransaction.Created |
create(long leaseTime)
Create a new nested transaction, with the current transaction as parent, managed by the same transaction manager as the current transaction. |
NestableTransaction.Created |
create(NestableTransactionManager mgr,
long leaseTime)
Create a new nested transaction, with the current transaction as parent, managed by the given transaction manager. |
boolean |
enclosedBy(NestableTransaction enclosing)
Return true if the specified transaction is an ancestor of this transaction. |
boolean |
isNested()
Return true if the transaction has a parent, false if the transaction is top level. |
void |
promote(TransactionParticipant[] parts,
long[] crashCounts,
TransactionParticipant drop)
Promote the listed participants (from a subtransaction) into this (the parent) transaction. |
void |
readExternal(ObjectInput in)
|
String |
toString()
|
void |
writeExternal(ObjectOutput out)
|
Methods inherited from class net.jini.core.transaction.server.ServerTransaction |
---|
abort, abort, commit, commit, create, createCopy, createInstance, equals, getLease, getMetaData, getState, hashCode, initEmbedded, isEmbeddedMgrInProxy, isEmbeddedMgrProxySideInstance, isXid, join, join, join, joinIfNeededAndEmbedded, joinIfNeededAndEmbedded, needParticipantsJoin, readFromSwap, setEmbeddedMgrProxySideInstance, setLease, setMetaData, writeToSwap |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface net.jini.core.transaction.Transaction |
---|
abort, abort, commit, commit |
Field Detail |
---|
public NestableServerTransaction parent
Constructor Detail |
---|
public NestableServerTransaction()
public NestableServerTransaction(NestableTransactionManager mgr, long id, NestableServerTransaction parent, long lease)
TransactionFactory
and
NestableTransaction
methods.
mgr
- the manager for this transactionid
- the transaction idparent
- the parent transaction, if anyMethod Detail |
---|
public NestableTransaction.Created create(NestableTransactionManager mgr, long leaseTime) throws UnknownTransactionException, CannotJoinException, LeaseDeniedException, RemoteException
NestableTransaction
create
in interface NestableTransaction
mgr
- the transaction manager to use for this transactionleaseTime
- the requested lease time for the transaction
UnknownTransactionException
- if the parent transaction
is unknown to the parent transaction manager, either
because the transaction ID is incorrect or because the
transaction is no longer active and its state has been
discarded by the manager.
CannotJoinException
- if the parent transaction is known
to the manager but is no longer active.
LeaseDeniedException
- if this manager is unwilling to
grant the requested lease time
RemoteException
- if there is a communication errorpublic NestableTransaction.Created create(long leaseTime) throws UnknownTransactionException, CannotJoinException, LeaseDeniedException, RemoteException
NestableTransaction
create
in interface NestableTransaction
leaseTime
- the requested lease time for the transaction
UnknownTransactionException
- if the parent transaction
is unknown to the parent transaction manager, either
because the transaction ID is incorrect or because the
transaction is no longer active and its state has been
discarded by the manager.
CannotJoinException
- if the parent transaction is known
to the manager but is no longer active.
LeaseDeniedException
- if this manager is unwilling to
grant the requested lease time
RemoteException
- if there is a communication errorpublic void promote(TransactionParticipant[] parts, long[] crashCounts, TransactionParticipant drop) throws UnknownTransactionException, CannotJoinException, CrashCountException, RemoteException
crashCounts
array.
parts
- the participants being promoted to the parentcrashCounts
- the crash counts of the participantsdrop
- the manager to drop out, if any
CrashCountException
- if the crash count provided
for at least one participant differs from the crash
count in a previous invocation of the same pairing
of participant and transaction
UnknownTransactionException
- if a transaction
is unknown to the transaction manager, either
because the transaction ID is incorrect or because the
transaction is complete and its state has been
discarded by the manager.
CannotJoinException
- if a transaction is known
to the manager but is no longer active.
RemoteException
- if there is a communication errorNestableTransactionManager.promote(long, net.jini.core.transaction.server.TransactionParticipant[], long[], net.jini.core.transaction.server.TransactionParticipant)
public boolean enclosedBy(NestableTransaction enclosing)
enclosing
- transaction to test for being an ancestor
public boolean isNested()
ServerTransaction
isNested
in class ServerTransaction
public String toString()
toString
in class ServerTransaction
public void writeExternal(ObjectOutput out) throws IOException
writeExternal
in interface Externalizable
writeExternal
in class ServerTransaction
IOException
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal
in interface Externalizable
readExternal
in class ServerTransaction
IOException
ClassNotFoundException
|
GigaSpaces XAP 9.7.2 API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |