KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > xquark > mapper > metadata > RepositoryConstants


1 /*
2  * This file belongs to the XQuark distribution.
3  * Copyright (C) 2003 Universite de Versailles Saint-Quentin.
4  *
5  * This program is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Lesser General Public
7  * License as published by the Free Software Foundation; either
8  * version 2.1 of the License, or (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  * Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public
16  * License along with this program; if not, write to the Free Software
17  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307.
18  * You can also get it at http://www.gnu.org/licenses/lgpl.html
19  *
20  * For more information on this software, see http://www.xquark.org.
21  */

22
23 package org.xquark.mapper.metadata;
24
25 /** General constants for XMLCollection.
26  *
27  */

28 public interface RepositoryConstants
29 {
30     //
31
// XMLCollection Current Version
32
//
33

34     ////////////////////
35
// NODE TYPES (= extension of XPath types see org.xquark.xml.xpath)
36
////////////////////
37
public byte XSI_NIL = 0x09;
38     public byte XSI_TYPE = 0x0A;
39     public byte XSI_SCHEMA_LOCATION = 0x0B;
40     public byte XSI_NO_NAMESPACE_SCHEMA_LOCATION = 0x0C;
41     public byte START_CDATA_SECTION = 0x0D;
42     public byte END_CDATA_SECTION = 0x0E;
43     
44     public String JavaDoc ATTRIBUTE_TYPES[] = {"ID", "IDREF", "IDREFS", "ENTITY", "ENTITIES", "NMTOKEN", "NMTOKENS", "CDATA"};
45
46     public short ROOT_PATH_ID = 0;
47     
48     public int SEQUENCE_FIRST_VALUE = 1;
49     
50     // OID limits
51
public byte UOID_SIZE = 63;
52     public byte CID_SIZE_DEFAULT_VALUE = 8;
53     public byte CID_SIZE_MIN_VALUE = 8;
54     public byte CID_SIZE_MAX_VALUE = 16;
55     public byte DID_SIZE_DEFAULT_VALUE = 24;
56     public byte DID_SIZE_MIN_VALUE = 8;
57     public byte DID_SIZE_MAX_VALUE = 48;
58     
59     //
60
// TABLE NAMES
61
//
62
public String JavaDoc TABLE_PREFIX = "XQUARK$";
63     
64     public String JavaDoc LEGACY_REPOSITORY_CHECKER = TABLE_PREFIX + "CONF%";
65     
66     /* Column index in table specifications loaded by TableSpecLoader */
67     // Default XML data table
68
public int V_UOID_INDEX = 0;
69     public int V_PATHID_INDEX = 1;
70     public int V_CHAR_VALUE_INDEX = 2;
71     public int V_NUM_VALUE_INDEX = 3;
72     public int V_DATE_VALUE_INDEX = 4;
73     
74     // XMLCollection tables features
75
public int DEFAULT_METADATA_CACHE_SIZE = 10;
76     
77     public byte DEFAULT_CID_SIZE = 8;
78     public int ID_LENGTH = 255;
79     public int DEFAULT_DATA_LENGTH = 255; // minimum value due to Sybase
80

81     //
82
// CONFIGURATION
83
//
84
public String JavaDoc VERSION_FILE = "Repository.ver";
85     public String JavaDoc CONF_FILE = "Repository.properties";
86     public String JavaDoc DEFAULT_CONF_FILE = "DefaultRepository.properties";
87     public String JavaDoc CONF_PACKAGE = "/com/xquark/";
88     public String JavaDoc RESOURCES_FOLDER = "resources/";
89     public String JavaDoc MAPPING_PACKAGE = "mapping/";
90     public String JavaDoc MAPPING_SCHEMA_FILE = "mapping.xsd";
91     
92     // MAPPER
93
public String JavaDoc CONF_USER_BATCHSIZE = "org.xquark.mapper.batchSize";
94      
95     // REPOSITORY SPECIFIC
96
public String JavaDoc CONF_USER_FETCHSIZE = "org.xquark.repository.dbms.user.fetchSize";
97     public String JavaDoc CONF_TREE_FETCHSIZE = "org.xquark.repository.dbms.tree.fetchSize";
98     public String JavaDoc CONF_DATA_FETCHSIZE = "org.xquark.repository.dbms.data.fetchSize";
99     public String JavaDoc CONF_DATA_BATCHSIZE = "org.xquark.repository.data.batchSize";
100     public String JavaDoc CONF_TREE_BATCHSIZE = "org.xquark.repository.dbms.tree.batchSize";
101     public String JavaDoc CONF_DOCID_BATCHSIZE = "org.xquark.repository.dbms.docID.batchSize";
102     public String JavaDoc CONF_PATH_BATCHSIZE = "org.xquark.repository.dbms.path.batchSize";
103     public String JavaDoc CONF_REMOVE_BATCHSIZE = "org.xquark.repository.dbms.remove.batchSize";
104     public String JavaDoc CONF_RENAME_BATCHSIZE = "org.xquark.repository.dbms.rename.batchSize";
105     public String JavaDoc CONF_COLLECTION_METADATA_CACHE = "org.xquark.repository.memory.collectionCache";
106     public String JavaDoc CONF_TRIM_WS = "org.xquark.repository.trimWhiteSpaces";
107    
108     // OTHER
109
public String JavaDoc REPOSITORY_SOURCE_NAME = "Repository";
110     public String JavaDoc NO_NAMESPACE_SCHEMA_ID = "xquark:noNamespace";
111 }
112
Popular Tags