Source Code Cross Referenced for XMLSimpleType.java in  » XML » xerces-2_9_1 » org » apache » xerces » impl » dtd » 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 » XML » xerces 2_9_1 » org.apache.xerces.impl.dtd 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * Licensed to the Apache Software Foundation (ASF) under one or more
003:         * contributor license agreements.  See the NOTICE file distributed with
004:         * this work for additional information regarding copyright ownership.
005:         * The ASF licenses this file to You under the Apache License, Version 2.0
006:         * (the "License"); you may not use this file except in compliance with
007:         * the License.  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:        package org.apache.xerces.impl.dtd;
019:
020:        import org.apache.xerces.impl.dv.DatatypeValidator;
021:
022:        /**
023:         * @xerces.internal
024:         * 
025:         * @version $Id: XMLSimpleType.java 446755 2006-09-15 21:56:27Z mrglavas $
026:         */
027:        public class XMLSimpleType {
028:
029:            //
030:            // Constants
031:            //
032:
033:            /** TYPE_CDATA */
034:            public static final short TYPE_CDATA = 0;
035:
036:            /** TYPE_ENTITY */
037:            public static final short TYPE_ENTITY = 1;
038:
039:            /** TYPE_ENUMERATION */
040:            public static final short TYPE_ENUMERATION = 2;
041:
042:            /** TYPE_ID */
043:            public static final short TYPE_ID = 3;
044:
045:            /** TYPE_IDREF */
046:            public static final short TYPE_IDREF = 4;
047:
048:            /** TYPE_NMTOKEN */
049:            public static final short TYPE_NMTOKEN = 5;
050:
051:            /** TYPE_NOTATION */
052:            public static final short TYPE_NOTATION = 6;
053:
054:            /** TYPE_NAMED */
055:            public static final short TYPE_NAMED = 7;
056:
057:            /** DEFAULT_TYPE_DEFAULT */
058:            public static final short DEFAULT_TYPE_DEFAULT = 3;
059:
060:            /** DEFAULT_TYPE_FIXED */
061:            public static final short DEFAULT_TYPE_FIXED = 1;
062:
063:            /** DEFAULT_TYPE_IMPLIED */
064:            public static final short DEFAULT_TYPE_IMPLIED = 0;
065:
066:            /** DEFAULT_TYPE_REQUIRED */
067:            public static final short DEFAULT_TYPE_REQUIRED = 2;
068:
069:            //
070:            // Data
071:            //
072:
073:            /** type */
074:            public short type;
075:
076:            /** name */
077:            public String name;
078:
079:            /** enumeration */
080:            public String[] enumeration;
081:
082:            /** list */
083:            public boolean list;
084:
085:            /** defaultType */
086:            public short defaultType;
087:
088:            /** defaultValue */
089:            public String defaultValue;
090:
091:            /** non-normalized defaultValue */
092:            public String nonNormalizedDefaultValue;
093:
094:            /** datatypeValidator */
095:            public DatatypeValidator datatypeValidator;
096:
097:            //
098:            // Methods
099:            //
100:
101:            /**
102:             * setValues
103:             * 
104:             * @param type 
105:             * @param name 
106:             * @param enumeration 
107:             * @param list 
108:             * @param defaultType 
109:             * @param defaultValue 
110:             * @param nonNormalizedDefaultValue
111:             * @param datatypeValidator 
112:             */
113:            public void setValues(short type, String name,
114:                    String[] enumeration, boolean list, short defaultType,
115:                    String defaultValue, String nonNormalizedDefaultValue,
116:                    DatatypeValidator datatypeValidator) {
117:
118:                this .type = type;
119:                this .name = name;
120:                // REVISIT: Should this be a copy? -Ac
121:                if (enumeration != null && enumeration.length > 0) {
122:                    this .enumeration = new String[enumeration.length];
123:                    System.arraycopy(enumeration, 0, this .enumeration, 0,
124:                            this .enumeration.length);
125:                } else {
126:                    this .enumeration = null;
127:                }
128:                this .list = list;
129:                this .defaultType = defaultType;
130:                this .defaultValue = defaultValue;
131:                this .nonNormalizedDefaultValue = nonNormalizedDefaultValue;
132:                this .datatypeValidator = datatypeValidator;
133:
134:            } // setValues(short,String,String[],boolean,short,String,String,DatatypeValidator)
135:
136:            /** Set values. */
137:            public void setValues(XMLSimpleType simpleType) {
138:
139:                type = simpleType.type;
140:                name = simpleType.name;
141:                // REVISIT: Should this be a copy? -Ac
142:                if (simpleType.enumeration != null
143:                        && simpleType.enumeration.length > 0) {
144:                    enumeration = new String[simpleType.enumeration.length];
145:                    System.arraycopy(simpleType.enumeration, 0, enumeration, 0,
146:                            enumeration.length);
147:                } else {
148:                    enumeration = null;
149:                }
150:                list = simpleType.list;
151:                defaultType = simpleType.defaultType;
152:                defaultValue = simpleType.defaultValue;
153:                nonNormalizedDefaultValue = simpleType.nonNormalizedDefaultValue;
154:                datatypeValidator = simpleType.datatypeValidator;
155:
156:            } // setValues(XMLSimpleType)
157:
158:            /**
159:             * clear
160:             */
161:            public void clear() {
162:                this .type = -1;
163:                this .name = null;
164:                this .enumeration = null;
165:                this .list = false;
166:                this .defaultType = -1;
167:                this .defaultValue = null;
168:                this .nonNormalizedDefaultValue = null;
169:                this .datatypeValidator = null;
170:            } // clear
171:
172:        } // class XMLSimpleType
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.