KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > versant > core > jdbc > JdbcConfig


1
2 /*
3  * Copyright (c) 1998 - 2005 Versant Corporation
4  * All rights reserved. This program and the accompanying materials
5  * are made available under the terms of the Eclipse Public License v1.0
6  * which accompanies this distribution, and is available at
7  * http://www.eclipse.org/legal/epl-v10.html
8  *
9  * Contributors:
10  * Versant Corporation - initial API and implementation
11  */

12 package com.versant.core.jdbc;
13
14 import java.util.ArrayList JavaDoc;
15 import java.util.HashMap JavaDoc;
16 import java.util.Map JavaDoc;
17
18 /**
19  * Configuration for a JDBC store.
20  */

21 public class JdbcConfig {
22
23     public String JavaDoc name;
24     public String JavaDoc db;
25     public String JavaDoc poolname;
26     public String JavaDoc url;
27     public String JavaDoc driver;
28     public String JavaDoc user;
29     public String JavaDoc password;
30     public String JavaDoc properties;
31     public String JavaDoc conFactory; // JNDI lookup name1
32

33     // connection 2 stuff
34
public String JavaDoc driver2;
35     public String JavaDoc url2;
36     public String JavaDoc user2;
37     public String JavaDoc password2;
38     public String JavaDoc properties2;
39     public String JavaDoc conFactory2; // JNDI lookup name2
40

41     public int maxActive;
42     public int maxIdle;
43     public int minIdle;
44     public int reserved;
45
46     public int jdbcOptimisticLocking;
47     public boolean readOnly;
48     public int cacheStrategy;
49     public int inheritance;
50     public int defaultClassId;
51     public boolean jdbcDoNotCreateTable;
52     public boolean oidsInDefaultFetchGroup;
53     public boolean jdbcDisableStatementBatching;
54     public boolean jdbcDisablePsCache;
55     public boolean validateMappingOnStartup;
56     public boolean managedOneToMany;
57     public boolean managedManyToMany;
58
59     public int isolationLevel;
60     public String JavaDoc initSQL;
61     public String JavaDoc validateSQL;
62     public boolean waitForConOnStartup;
63     public boolean testOnAlloc;
64     public boolean testOnRelease;
65     public boolean testOnException = true;
66     public boolean testWhenIdle = true;
67     public int retryIntervalMs = 100;
68     public int retryCount;
69     public int psCacheMax;
70     public int conTimeout;
71     public int testInterval;
72     public boolean blockWhenFull;
73     public int maxConAge;
74
75     public String JavaDoc jdbcKeyGenerator;
76     public Map JavaDoc jdbcKeyGeneratorProps;
77
78     public String JavaDoc jdbcNameGenerator;
79     public Map JavaDoc jdbcNameGeneratorProps;
80     public Map JavaDoc jdbcMigrationControlProps;
81
82     public ArrayList JavaDoc typeMappings;
83     public ArrayList JavaDoc javaTypeMappings;
84
85     /**
86      * Use hash of the fully qualified name of the class as descriminator.
87      */

88     public static final int DEFAULT_CLASS_ID_HASH = 1;
89     /**
90      * Dot use a descriminator column in heirachies.
91      */

92     public static final int DEFAULT_CLASS_ID_NO = 2;
93     /**
94      * Use the name of the class without package as descriminator.
95      */

96     public static final int DEFAULT_CLASS_ID_NAME = 3;
97     /**
98      * Use the fully qualified name of the class as descriminator.
99      */

100     public static final int DEFAULT_CLASS_ID_FULLNAME = 4;
101 }
102
103
Popular Tags