KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > sleepycat > collections > test > NullTransactionRunner


1 /*-
2  * See the file LICENSE for redistribution information.
3  *
4  * Copyright (c) 2002,2006 Oracle. All rights reserved.
5  *
6  * $Id: NullTransactionRunner.java,v 1.16 2006/10/30 21:14:39 bostic Exp $
7  */

8
9 package com.sleepycat.collections.test;
10
11 import com.sleepycat.collections.TransactionRunner;
12 import com.sleepycat.collections.TransactionWorker;
13 import com.sleepycat.je.Environment;
14 import com.sleepycat.util.ExceptionUnwrapper;
15
16 class NullTransactionRunner extends TransactionRunner {
17
18     NullTransactionRunner(Environment env) {
19
20         super(env);
21     }
22
23     public void run(TransactionWorker worker)
24         throws Exception JavaDoc {
25
26         try {
27             worker.doWork();
28         } catch (Exception JavaDoc e) {
29             throw ExceptionUnwrapper.unwrap(e);
30         }
31     }
32 }
33
Popular Tags