public final class RemoteClientUserTransaction
extends java.lang.Object
implements javax.transaction.UserTransaction, java.io.Externalizable, javax.naming.Referenceable
Constructor and Description |
---|
RemoteClientUserTransaction()
No-argument constructor, as required by Externalizable interface.
|
RemoteClientUserTransaction(java.lang.String userTransactionServerLookupName,
ConfigProperties configProperties)
Preferred constructor.
|
RemoteClientUserTransaction(java.lang.String name,
java.lang.String initialContextFactory,
java.lang.String providerUrl) |
Modifier and Type | Method and Description |
---|---|
void |
begin() |
void |
commit() |
javax.naming.Reference |
getReference() |
int |
getStatus() |
void |
readExternal(java.io.ObjectInput in) |
void |
rollback() |
void |
setRollbackOnly() |
void |
setTransactionTimeout(int seconds) |
java.lang.String |
toString()
Overrides the default behaviour, to allow retrieving the corresponding
transaction at the server side.
|
void |
writeExternal(java.io.ObjectOutput out)
Needed to ship instances across the network among clients.
|
public RemoteClientUserTransaction()
public RemoteClientUserTransaction(java.lang.String userTransactionServerLookupName, ConfigProperties configProperties)
userTransactionServerLookupName
- configProperties
- public RemoteClientUserTransaction(java.lang.String name, java.lang.String initialContextFactory, java.lang.String providerUrl)
name
- The unique name of the UserTransactionServer.initialContextFactory
- The initial context factory of the server JNDI
context.providerUrl
- The provider URL of the server JNDI context.public void begin() throws javax.transaction.NotSupportedException, javax.transaction.SystemException
begin
in interface javax.transaction.UserTransaction
javax.transaction.NotSupportedException
javax.transaction.SystemException
UserTransaction
public void commit() throws javax.transaction.RollbackException, javax.transaction.HeuristicMixedException, javax.transaction.HeuristicRollbackException, javax.transaction.SystemException, java.lang.IllegalStateException, java.lang.SecurityException
commit
in interface javax.transaction.UserTransaction
javax.transaction.RollbackException
javax.transaction.HeuristicMixedException
javax.transaction.HeuristicRollbackException
javax.transaction.SystemException
java.lang.IllegalStateException
java.lang.SecurityException
UserTransaction
public void rollback() throws java.lang.IllegalStateException, javax.transaction.SystemException, java.lang.SecurityException
rollback
in interface javax.transaction.UserTransaction
java.lang.IllegalStateException
javax.transaction.SystemException
java.lang.SecurityException
UserTransaction
public void setRollbackOnly() throws java.lang.IllegalStateException, javax.transaction.SystemException
setRollbackOnly
in interface javax.transaction.UserTransaction
java.lang.IllegalStateException
javax.transaction.SystemException
UserTransaction
public int getStatus() throws javax.transaction.SystemException
getStatus
in interface javax.transaction.UserTransaction
javax.transaction.SystemException
UserTransaction
public void setTransactionTimeout(int seconds) throws javax.transaction.SystemException
setTransactionTimeout
in interface javax.transaction.UserTransaction
javax.transaction.SystemException
UserTransaction
public java.lang.String toString()
toString
in class java.lang.Object
public javax.naming.Reference getReference() throws javax.naming.NamingException
getReference
in interface javax.naming.Referenceable
javax.naming.NamingException
Referenceable
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
writeExternal
in interface java.io.Externalizable
java.io.IOException
Externalizable
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException
readExternal
in interface java.io.Externalizable
java.io.IOException
java.lang.ClassNotFoundException
Externalizable
Copyright © 2018. All Rights Reserved.