001: package org.apache.ojb.broker.metadata;
002:
003: /* Copyright 2002-2005 The Apache Software Foundation
004: *
005: * Licensed under the Apache License, Version 2.0 (the "License");
006: * you may not use this file except in compliance with the License.
007: * You may obtain a copy of the License at
008: *
009: * http://www.apache.org/licenses/LICENSE-2.0
010: *
011: * Unless required by applicable law or agreed to in writing, software
012: * distributed under the License is distributed on an "AS IS" BASIS,
013: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014: * See the License for the specific language governing permissions and
015: * limitations under the License.
016: */
017:
018: /**
019: * This interface contains integer constants representing the
020: * elements of a DescriptorRepository.
021: * This constants are used in marshalling and unmarshalling a
022: * DescriptorRepository to identify all its constituent elements.
023: * @author Thomas Mahler
024: * @version $Id: RepositoryElements.java,v 1.36.2.1 2005/04/26 03:41:36 mkalen Exp $
025: */
026: public interface RepositoryElements {
027:
028: public static final int MAPPING_REPOSITORY = 0;
029: public static final int JDBC_CONNECTION_DESCRIPTOR = 1;
030: public static final int DBMS_NAME = 2;
031: public static final int SORT = 3;
032: public static final int SCHEMA_NAME = 5;
033: public static final int JCD_ALIAS = 82;
034: public static final int DEFAULT_CONNECTION = 80;
035: public static final int DRIVER_NAME = 6;
036: public static final int URL_PROTOCOL = 7;
037: public static final int URL_SUBPROTOCOL = 8;
038: public static final int URL_DBALIAS = 9;
039: public static final int USER_NAME = 10;
040: public static final int USER_PASSWD = 11;
041: public static final int EAGER_RELEASE = 74;
042: public static final int BATCH_MODE = 83;
043: public static final int USE_AUTOCOMMIT = 90;
044: public static final int IGNORE_AUTOCOMMIT_EXCEPTION = 91;
045: public static final int CLASS_DESCRIPTOR = 12;
046: public static final int CLASS_NAME = 13;
047: public static final int CLASS_PROXY = 35;
048: public static final int CLASS_EXTENT = 33;
049: public static final int EXTENDS = 76;
050: public static final int TABLE_NAME = 14;
051: public static final int ORDERBY = 36;
052: public static final int FIELD_CONVERSION = 30;
053: public static final int ROW_READER = 32;
054: public static final int FIELD_DESCRIPTOR = 15;
055: public static final int FIELD_NAME = 16;
056: public static final int COLUMN_NAME = 17;
057: public static final int JDBC_TYPE = 18;
058: public static final int PRIMARY_KEY = 19;
059: public static final int AUTO_INCREMENT = 31;
060: public static final int SEQUENCE_NAME = 77;
061: public static final int REFERENCE_DESCRIPTOR = 20;
062: public static final int REFERENCED_CLASS = 22;
063: public static final int AUTO_RETRIEVE = 24;
064: public static final int AUTO_UPDATE = 25;
065: public static final int AUTO_DELETE = 26;
066: public static final int OTM_DEPENDENT = 102;
067: public static final int COLLECTION_DESCRIPTOR = 27;
068: public static final int ITEMS_CLASS = 29;
069: public static final int INVERSE_FK = 38;
070: public static final int COLLECTION_CLASS = 37;
071: public static final int INDIRECTION_TABLE = 39;
072: public static final int FK_POINTING_TO_ITEMS_CLASS = 40;
073: public static final int FK_POINTING_TO_THIS_CLASS = 41;
074: public static final int DATASOURCE_NAME = 44;
075: public static final int JDBC_LEVEL = 45;
076: public static final int LOCKING = 46;
077: public static final int UPDATE_LOCK = 98;
078: public static final int REFRESH = 47;
079: public static final int PROXY_REFERENCE = 48;
080: public static final int ISOLATION_LEVEL = 34;
081: public static final int FOREIGN_KEY = 49;
082: public static final int NULLABLE = 50;
083: public static final int INDEXED = 51;
084: public static final int LENGTH = 52;
085: public static final int PRECISION = 53;
086: public static final int SCALE = 54;
087: public static final int ACCESS = 99;
088:
089: public static final int CON_MAX_ACTIVE = 55;
090: public static final int CON_MAX_IDLE = 56;
091: public static final int CON_MAX_WAIT = 57;
092: public static final int CON_MIN_EVICTABLE_IDLE_TIME_MILLIS = 58;
093: public static final int CON_NUM_TESTS_PER_EVICTION_RUN = 59;
094: public static final int CON_TEST_ON_BORROW = 60;
095: public static final int CON_TEST_ON_RETURN = 61;
096: public static final int CON_TEST_WHILE_IDLE = 62;
097: public static final int CON_TIME_BETWEEN_EVICTION_RUNS_MILLIS = 63;
098: public static final int CON_WHEN_EXHAUSTED_ACTION = 64;
099: public static final int CON_LOG_ABANDONED = 87;
100: public static final int CON_REMOVE_ABANDONED = 85;
101: public static final int CON_REMOVE_ABANDONED_TIMEOUT = 86;
102:
103: public static final int CONNECTION_POOL = 65;
104: public static final int CONNECTION_FACTORY = 66;
105: public static final int VALIDATION_QUERY = 79;
106: public static final int SEQUENCE_MANAGER = 88;
107: public static final int SEQUENCE_MANAGER_CLASS = 89;
108:
109: public static final int REPOSITORY_VERSION = 67;
110: public static final int CLASS_REF = 68;
111: public static final int ID = 69;
112: public static final int FIELD_ID_REF = 70;
113: public static final int FIELD_REF = 84;
114: public static final int ATTRIBUTE = 71;
115: public static final int ATTRIBUTE_NAME = 72;
116: public static final int ATTRIBUTE_VALUE = 73;
117: public static final int DOCUMENTATION = 75;
118: public static final int ACCEPT_LOCKS = 78;
119: public static final int QUERY_CUSTOMIZER = 92;
120: public static final int INITIALIZATION_METHOD = 93;
121: public static final int FACTORY_CLASS = 100;
122: public static final int FACTORY_METHOD = 101;
123:
124: public static final int INDEX_DESCRIPTOR = 94;
125: public static final int INDEX_COLUMN = 95;
126: public static final int UNIQUE = 96;
127: public static final int NAME = 97;
128:
129: public static final int INSERT_PROCEDURE = 103;
130: public static final int UPDATE_PROCEDURE = 104;
131: public static final int DELETE_PROCEDURE = 105;
132: public static final int CONSTANT_ARGUMENT = 106;
133: public static final int RUNTIME_ARGUMENT = 107;
134: public static final int RETURN_FIELD_REF = 108;
135: public static final int INCLUDE_ALL_FIELDS = 109;
136: public static final int INCLUDE_PK_FIELDS_ONLY = 110;
137: public static final int RETURN = 111;
138: public static final int VALUE = 112;
139:
140: public static final int OBJECT_CACHE = 113;
141:
142: public static final int PROXY_PREFETCHING_LIMIT = 114;
143:
144: // maintain a next id to keep track where we are
145: static final int _NEXT = 115;
146:
147: // String constants
148: public static final String TAG_ACCESS = "access";
149:
150: public static final String TAG_ACCESS_ANONYMOUS = "anonymous";
151: public static final String TAG_ACCESS_READONLY = "readonly";
152: public static final String TAG_ACCESS_READWRITE = "readwrite";
153:
154: public static final String TAG_SUPER = "super";
155:
156: public static final String CASCADE_NONE_STR = "none";
157: public static final String CASCADE_LINK_STR = "link";
158: public static final String CASCADE_OBJECT_STR = "object";
159:
160: }
|