public class PRSessionContext
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
PRSessionContext.LockAttribute |
static class |
PRSessionContext.SaveAttribute |
static class |
PRSessionContext.SaveInOwnTransactionAttribute |
static class |
PRSessionContext.TransactionAttribute |
static class |
PRSessionContext.TransactionType |
static class |
PRSessionContext.UniqueIDAttribute |
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
COPYRIGHT |
static java.lang.String |
VERSION |
Constructor and Description |
---|
PRSessionContext(javax.ejb.SessionContext aCtx) |
Modifier and Type | Method and Description |
---|---|
boolean |
canWeCommitOurConnections()
Tells you if you are allowed to call commit or rollback on a connection
JTA does not allow you to do this (whether container managed or bean managed)
The decision is based on a flag we keep that is maintained from
ThreadConnectionStore |
void |
endTransaction()
Clear the current transaction marker.
|
java.security.Principal |
getCallerPrincipal() |
java.lang.Exception |
getRollbackException() |
boolean |
getRollbackOnly() |
PRSessionContext.TransactionType |
getTransactionType()
Tells you what kind of transaction we are in (if any)
|
javax.transaction.UserTransaction |
getUserTransaction() |
boolean |
IsBeanManaged() |
boolean |
isContainerManagedButNoTransaction() |
boolean |
isContainerProvidingOurTransaction() |
boolean |
isGettingUniqueIDFromBean() |
boolean |
isLockingWithLockBean() |
boolean |
isSavingWithDatabaseBean() |
boolean |
isUsingSaveInOwnTransactionBean() |
void |
setAttributesForInvocation(PRSessionContext.TransactionAttribute transAttribute,
PRSessionContext.LockAttribute lockAttribute,
PRSessionContext.SaveInOwnTransactionAttribute saveInOwnTransactionAttributeAttribute,
PRSessionContext.UniqueIDAttribute uniqueIdAttribute,
PRSessionContext.SaveAttribute saveAttribute) |
void |
setRollbackException(java.lang.Exception ex) |
void |
setRollbackOnly() |
void |
setRollbackOnly(java.lang.Exception ex) |
void |
setTransactionType(PRSessionContext.TransactionType aType)
Sets the current transaction type.
|
void |
setTransactionTypeUsingTransactionAttribute()
Sets the current transaction type based on the transaction attribute.
|
public static final java.lang.String COPYRIGHT
public static final java.lang.String VERSION
public void setAttributesForInvocation(PRSessionContext.TransactionAttribute transAttribute, PRSessionContext.LockAttribute lockAttribute, PRSessionContext.SaveInOwnTransactionAttribute saveInOwnTransactionAttributeAttribute, PRSessionContext.UniqueIDAttribute uniqueIdAttribute, PRSessionContext.SaveAttribute saveAttribute)
public boolean isContainerProvidingOurTransaction()
public boolean isContainerManagedButNoTransaction()
public boolean IsBeanManaged()
public boolean isUsingSaveInOwnTransactionBean()
public boolean isLockingWithLockBean()
public boolean isGettingUniqueIDFromBean()
public boolean isSavingWithDatabaseBean()
public java.security.Principal getCallerPrincipal()
public javax.transaction.UserTransaction getUserTransaction()
public void setRollbackOnly()
public void setRollbackOnly(java.lang.Exception ex)
public boolean getRollbackOnly()
public void setRollbackException(java.lang.Exception ex)
public java.lang.Exception getRollbackException()
public void setTransactionType(PRSessionContext.TransactionType aType)
endTransaction
is used to clear it.aType
- public void setTransactionTypeUsingTransactionAttribute()
public void endTransaction()
public PRSessionContext.TransactionType getTransactionType()
public boolean canWeCommitOurConnections()
ThreadConnectionStore
Copyright © 2018 Pegasystems Inc. All Rights Reserved.