|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.jzeno.aop.AbstractAspect
net.sf.jzeno.aop.TransactionAspect
public class TransactionAspect
This aspect implements the transaction behaviour.
Field Summary | |
---|---|
static java.lang.String |
TXN_MANDATORY
|
static java.lang.String |
TXN_NEVER
|
static java.lang.String |
TXN_NOTSUPPORTED
|
static java.lang.String |
TXN_REQUIRED
|
static java.lang.String |
TXN_REQUIRESNEW
|
static java.lang.String |
TXN_SUPPORTS
|
Fields inherited from class net.sf.jzeno.aop.AbstractAspect |
---|
afterException, beforeException, his, nextAspect, primaryException |
Constructor Summary | |
---|---|
TransactionAspect(Aspect nextAspect)
Creates an instance of the transaction aspect. |
Method Summary | |
---|---|
static org.hibernate.Transaction |
beginTransaction()
Begins a new transaction on the current session for this thread. |
static void |
commitTransaction(org.hibernate.Transaction transaction)
Commits the current transaction for the calling thread. |
static int |
getTransactionLevel()
Internal helper operation to read the transaction nesting level. |
void |
postProcess(java.lang.reflect.Method method,
java.lang.Object[] arguments)
|
void |
preProcess(java.lang.reflect.Method method,
java.lang.Object[] arguments)
|
static void |
rollbackTransaction(org.hibernate.Transaction transaction)
Rolls back the current transaction for the calling thread. |
Methods inherited from class net.sf.jzeno.aop.AbstractAspect |
---|
getNextAspect, invoke, process, setNextAspect |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String TXN_REQUIRED
public static final java.lang.String TXN_REQUIRESNEW
public static final java.lang.String TXN_MANDATORY
public static final java.lang.String TXN_SUPPORTS
public static final java.lang.String TXN_NOTSUPPORTED
public static final java.lang.String TXN_NEVER
Constructor Detail |
---|
public TransactionAspect(Aspect nextAspect)
Creates an instance of the transaction aspect. You can specify a successor for the aspect.
Method Detail |
---|
public void preProcess(java.lang.reflect.Method method, java.lang.Object[] arguments)
preProcess
in class AbstractAspect
public void postProcess(java.lang.reflect.Method method, java.lang.Object[] arguments)
postProcess
in class AbstractAspect
public static int getTransactionLevel()
Internal helper operation to read the transaction nesting level. The nesting level is equal to the transaction stack size.
public static org.hibernate.Transaction beginTransaction()
Begins a new transaction on the current session for this thread.
public static void commitTransaction(org.hibernate.Transaction transaction)
Commits the current transaction for the calling thread.
public static void rollbackTransaction(org.hibernate.Transaction transaction)
Rolls back the current transaction for the calling thread.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |