TrueUpdate Manager Specification 0.7.1

net.java.trueupdate.manager.spec.tx
Class Transactions

java.lang.Object
  extended by net.java.trueupdate.manager.spec.tx.Transactions

public class Transactions
extends Object

Provides functions for Transactions.

Author:
Christian Schlichtherle

Nested Class Summary
static class Transactions.LoggerConfig
           
static class Transactions.Method
           
 
Method Summary
static void execute(Transaction tx)
          Executes the given transaction.
static Transaction time(Transaction tx, String message, Transactions.LoggerConfig config)
          Wraps the given transaction in another transaction which logs the duration of each transaction method using the given configuration.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

execute

public static void execute(Transaction tx)
                    throws Exception
Executes the given transaction.

Throws:
IllegalStateException - if this method is called recursively.
Exception

time

public static Transaction time(Transaction tx,
                               String message,
                               Transactions.LoggerConfig config)
Wraps the given transaction in another transaction which logs the duration of each transaction method using the given configuration.

Returns:
the logging transaction.

TrueUpdate Manager Specification 0.7.1

Copyright © 2013 Schlichtherle IT Services. All rights reserved.