1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * This library is free software; you can redistribute it and/or modify it under
5    * the terms of the GNU Lesser General Public License as published by the Free
6    * Software Foundation; either version 2.1 of the License, or (at your option)
7    * any later version.
8    *
9    * This library is distributed in the hope that it will be useful, but WITHOUT
10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11   * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
12   * details.
13   */
14  
15  package com.liferay.portal.kernel.annotation;
16  
17  import java.sql.Connection;
18  
19  /**
20   * <a href="TransactionDefinition.java.html"><b><i>View Source</i></b></a>
21   *
22   * @author Michael Young
23   */
24  public interface TransactionDefinition {
25  
26      public static final int ISOLATION_DEFAULT = -1;
27  
28      public static final int ISOLATION_PORTAL = -2;
29  
30      public static final int ISOLATION_READ_COMMITTED =
31          Connection.TRANSACTION_READ_COMMITTED;
32  
33      public static final int ISOLATION_READ_UNCOMMITTED =
34          Connection.TRANSACTION_READ_UNCOMMITTED;
35  
36      public static final int ISOLATION_REPEATABLE_READ =
37          Connection.TRANSACTION_REPEATABLE_READ;
38  
39      public static final int ISOLATION_SERIALIZABLE =
40          Connection.TRANSACTION_SERIALIZABLE;
41  
42      public static final int PROPAGATION_MANDATORY = 2;
43  
44      public static final int PROPAGATION_NESTED = 6;
45  
46      public static final int PROPAGATION_NEVER = 5;
47  
48      public static final int PROPAGATION_NOT_SUPPORTED = 4;
49  
50      public static final int PROPAGATION_REQUIRED = 0;
51  
52      public static final int PROPAGATION_REQUIRES_NEW = 3;
53  
54      public static final int PROPAGATION_SUPPORTS = 1;
55  
56      public static final int TIMEOUT_DEFAULT = -1;
57  
58  }