KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > oracle > toplink > essentials > platform > server > sunas > SunAS9ServerPlatform


1 /*
2  * The contents of this file are subject to the terms
3  * of the Common Development and Distribution License
4  * (the "License"). You may not use this file except
5  * in compliance with the License.
6  *
7  * You can obtain a copy of the license at
8  * glassfish/bootstrap/legal/CDDLv1.0.txt or
9  * https://glassfish.dev.java.net/public/CDDLv1.0.html.
10  * See the License for the specific language governing
11  * permissions and limitations under the License.
12  *
13  * When distributing Covered Code, include this CDDL
14  * HEADER in each file and include the License file at
15  * glassfish/bootstrap/legal/CDDLv1.0.txt. If applicable,
16  * add the following below this CDDL HEADER, with the
17  * fields enclosed by brackets "[]" replaced with your
18  * own identifying information: Portions Copyright [yyyy]
19  * [name of copyright owner]
20  */

21 // Copyright (c) 1998, 2006, Oracle. All rights reserved.
22
package oracle.toplink.essentials.platform.server.sunas;
23
24 import oracle.toplink.essentials.internal.sessions.DatabaseSessionImpl;
25 import oracle.toplink.essentials.transaction.sunas.SunAS9TransactionController;
26 import oracle.toplink.essentials.platform.server.ServerPlatformBase;
27 import oracle.toplink.essentials.logging.SessionLog;
28 import oracle.toplink.essentials.logging.JavaLog;
29
30 /**
31  * PUBLIC:
32  *
33  * This is the concrete subclass responsible for representing SunAS9-specific server behaviour.
34  *
35  * This platform overrides:
36  *
37  * getExternalTransactionControllerClass(): to use an SunAS9-specific controller class
38  *
39  */

40 public class SunAS9ServerPlatform extends ServerPlatformBase {
41
42     /**
43      * INTERNAL:
44      * Default Constructor: All behaviour for the default constructor is inherited
45      */

46     public SunAS9ServerPlatform(DatabaseSessionImpl newDatabaseSession) {
47         super(newDatabaseSession);
48     }
49
50     /**
51      * INTERNAL: getExternalTransactionControllerClass(): Answer the class of external transaction controller to use
52      * for Oc4j. This is read-only.
53      *
54      * @return Class externalTransactionControllerClass
55      *
56      * @see oracle.toplink.essentials.transaction.JTATransactionController
57      * @see ServerPlatformBase.isJTAEnabled()
58      * @see ServerPlatformBase.disableJTA()
59      * @see ServerPlatformBase.initializeExternalTransactionController()
60      */

61     public Class JavaDoc getExternalTransactionControllerClass() {
62         if (externalTransactionControllerClass == null){
63             externalTransactionControllerClass = SunAS9TransactionController.class;
64         }
65         return externalTransactionControllerClass;
66     }
67
68     public SessionLog getServerLog() {
69         return new JavaLog();
70     }
71 }
72
Popular Tags