Source Code Cross Referenced for NetConfiguration.java in  » Database-DBMS » db-derby-10.2 » org » apache » derby » client » net » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Database DBMS » db derby 10.2 » org.apache.derby.client.net 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:
003:           Derby - Class org.apache.derby.client.net.NetConfiguration
004:
005:           Licensed to the Apache Software Foundation (ASF) under one or more
006:           contributor license agreements.  See the NOTICE file distributed with
007:           this work for additional information regarding copyright ownership.
008:           The ASF licenses this file to You under the Apache License, Version 2.0
009:           (the "License"); you may not use this file except in compliance with
010:           the License.  You may obtain a copy of the License at
011:
012:              http://www.apache.org/licenses/LICENSE-2.0
013:
014:           Unless required by applicable law or agreed to in writing, software
015:           distributed under the License is distributed on an "AS IS" BASIS,
016:           WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
017:           See the License for the specific language governing permissions and
018:           limitations under the License.
019:
020:         */
021:        package org.apache.derby.client.net;
022:
023:        import org.apache.derby.iapi.reference.DRDAConstants;
024:        import org.apache.derby.client.am.Version;
025:
026:        public class NetConfiguration {
027:            // ---------------------------------------------------------------------------
028:
029:            static final int INITIAL_CAPACITY = 10; // initial size of the Vector for the input parameters
030:
031:            // Value to use when padding non-character data in ddm objects.
032:            public static final byte NON_CHAR_DDM_DATA_PAD_BYTE = 0x00;
033:
034:            static final int CURSOR_NOT_OPEN = 0;
035:            static final int CURSOR_OPEN = 1;
036:            static final int CURSOR_CLOSE_ONLY = 2;
037:
038:            // Number of bytes in the DDM header.
039:            static final int DDMHDR_LENGTH = 4;
040:
041:            // Number of bytes in the DSS header.
042:            static final int DSSHDR_LENGTH = 6;
043:
044:            // Maximum size of External Name.
045:            static final int EXTNAM_MAXSIZE = 255;
046:
047:            // Minimum agent level required by protocol.
048:            static final int MIN_AGENT_MGRLVL = 3;
049:
050:            // Minimum communications tcpip manager level required by protocol.
051:            static final int MIN_CMNTCPIP_MGRLVL = 5;
052:
053:            // Minimum LU6.2 Conversational Communications Manager
054:            static final int MIN_CMNAPPC_MGRLVL = 3;
055:
056:            // Minimum rdb manager level required by protocol.
057:            static final int MIN_RDB_MGRLVL = 3;
058:
059:            // Minimum secmgr manager level required by protocol.
060:            static final int MIN_SECMGR_MGRLVL = 5;
061:
062:            // Minimum sqlam manager level required by protocol.
063:            static final int MIN_SQLAM_MGRLVL = 4;
064:
065:            // Minimum xa manager level required by protocol.
066:            static final int MIN_XAMGR_MGRLVL = 7;
067:
068:            // Minimum secmgr manager level required by protocol.
069:            static final int MIN_SYNCPTMGR_MGRLVL = 5;
070:
071:            // Minimum sqlam manager level required by protocol.
072:            static final int MIN_RSYNCMGR_MGRLVL = 5;
073:
074:            // Maximun Password size.
075:            static final int PASSWORD_MAXSIZE = 255;
076:
077:            // Fixed PRDDTA application id fixed length.
078:            public static final int PRDDTA_APPL_ID_FIXED_LEN = 20;
079:
080:            // PRDDTA Accounting Suffix Length byte offset.
081:            static final int PRDDTA_ACCT_SUFFIX_LEN_BYTE = 55;
082:
083:            // PRDDTA Max Accounting Suffix Length.
084:            static final int PRDDTA_MAX_ACCT_SUFFIX_LEN = 199;
085:
086:            // PRDDTA Length byte offset.
087:            static final int PRDDTA_LEN_BYTE = 0;
088:
089:            // Maximum PRDDTA size.
090:            static final int PRDDTA_MAXSIZE = 255;
091:
092:            // PRDDTA platform id.
093:            public static final String PRDDTA_PLATFORM_ID = "JVM               ";
094:
095:            // Fixed PRDDTA user id fixed length.
096:            public static final int PRDDTA_USER_ID_FIXED_LEN = 8;
097:
098:            // Identifier Length for fixed length rdb name
099:            public static final int PKG_IDENTIFIER_FIXED_LEN = 18;
100:
101:            // Maximum RDB Identifier Length
102:            static final int PKG_IDENTIFIER_MAX_LEN = 255;
103:
104:            // Fixed pkgcnstkn length
105:            public static final int PKGCNSTKN_FIXED_LEN = 8;
106:
107:            // Maximum length of a security token.
108:            // Anything greater than 32763 bytes of SECTKN would require extended length DDMs.
109:            // This seems like an impossible upper bound limit right now so set
110:            // max to 32763 and cross bridge later.
111:            static final int SECTKN_MAXSIZE = 32763; // this was 255
112:
113:            // Server class name of the ClientDNC product.
114:            static final String SRVCLSNM_JVM = "QDERBY/JVM";
115:
116:            // Maximum size of SRVNAM Name.
117:            static final int SRVNAM_MAXSIZE = 255;
118:
119:            // Manager is NA or not usued.
120:            static final int MGRLVL_NA = 0;
121:
122:            // Manager Level 3 constant.
123:            static final int MGRLVL_3 = 0x03;
124:
125:            // Manager Level 4 constant.
126:            static final int MGRLVL_4 = 0x04;
127:
128:            // Manager Level 5 constant.
129:            static final int MGRLVL_5 = 0x05;
130:
131:            // Manager level 6 constant.
132:            static final int MGRLVL_6 = 0x06;
133:
134:            // Manager Level 7 constant.
135:            static final public int MGRLVL_7 = 0x07;
136:
137:            // Indicates the DCE security mechanism.
138:            static final int SECMEC_DCESEC = 0x01;
139:
140:            // Indicates encrypted userid, password,
141:            // new password security mechanism.
142:            static final int SECMEC_EUSRIDNWPWD = 0x0A;
143:
144:            // Indicates userid/encrypted password security mechanism.
145:            public static final int SECMEC_EUSRIDPWD = 0x09;
146:
147:            // Indicates userid only security mechanism.
148:            public static final int SECMEC_USRIDONL = 0x04;
149:
150:            // Indicates userid/encrypted password security mechanism.
151:            public static final int SECMEC_USRENCPWD = 0x07;
152:
153:            // Indicates userid/new password security mechanism.
154:            static final int SECMEC_USRIDNWPWD = 0x05;
155:
156:            // Indicates userid/password security mechanism.
157:            public static final int SECMEC_USRIDPWD = 0x03;
158:
159:            //Indicates Encrypted userid and Encrypted Security-sensitive Data security mechanism
160:            public static final int SECMEC_EUSRIDDTA = 0x0C;
161:
162:            //Indicates Encrypted userid,Encrypted password and Encrypted Security-sensitive Data security mechanism
163:            public static final int SECMEC_EUSRPWDDTA = 0x0D;
164:
165:            // Indicates userid with strong password substitute security mechanism.
166:            public static final int SECMEC_USRSSBPWD = 0x08;
167:
168:            // list of security mechanisms supported by this driver
169:            static final int[] SECMGR_SECMECS = {
170:                    NetConfiguration.SECMEC_EUSRIDPWD,
171:                    NetConfiguration.SECMEC_USRENCPWD,
172:                    NetConfiguration.SECMEC_USRIDPWD,
173:                    NetConfiguration.SECMEC_USRIDONL,
174:                    NetConfiguration.SECMEC_EUSRIDDTA,
175:                    NetConfiguration.SECMEC_EUSRPWDDTA,
176:                    NetConfiguration.SECMEC_USRSSBPWD };
177:
178:            // IEEE ASCII constant.
179:            public static final String SYSTEM_ASC = "QTDSQLASC";
180:
181:            // JVM constant.
182:            static final String SYSTEM_JVM = "QTDSQLJVM";
183:
184:            // Maximum size of User Name.
185:            static final int USRID_MAXSIZE = 255;
186:
187:            // Product id of the ClientDNC.
188:            public static String PRDID;
189:
190:            // The server release level of this product.
191:            // It will be prefixed with PRDID
192:            static String SRVRLSLV;
193:
194:            // Initialize PRDID and SRVRLSLV
195:            static {
196:                int majorVersion = Version.getMajorVersion();
197:                int minorVersion = Version.getMinorVersion();
198:                int protocolMaintVersion = Version.getProtocolMaintVersion();
199:
200:                // PRDID format as Network Server expects  it: DNCMMmx
201:                // MM = major version
202:                // mm = minor version
203:                // x = protocol MaintenanceVersion
204:
205:                String prdId = DRDAConstants.DERBY_DRDA_CLIENT_ID;
206:                if (majorVersion < 10) {
207:                    prdId += "0";
208:                }
209:                prdId += majorVersion;
210:
211:                if (minorVersion < 10) {
212:                    prdId += "0";
213:                }
214:
215:                prdId += minorVersion;
216:                prdId += protocolMaintVersion;
217:                PRDID = prdId;
218:                SRVRLSLV = prdId + "/" + Version.getDriverVersion();
219:            }
220:
221:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.