xerces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From knoa...@apache.org
Subject svn commit: r697134 [1/2] - in /xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs: SchemaSymbols.java traversers/XSAttributeChecker.java traversers/XSDComplexTypeTraverser.java traversers/XSDHandler.java traversers/XSDocumentInfo.java
Date Fri, 19 Sep 2008 15:36:02 GMT
Author: knoaman
Date: Fri Sep 19 08:36:02 2008
New Revision: 697134

URL: http://svn.apache.org/viewvc?rev=697134&view=rev
Log:
Add support for default attribute groups

Modified:
    xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/SchemaSymbols.java
    xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSAttributeChecker.java
    xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDComplexTypeTraverser.java
    xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDHandler.java
    xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDocumentInfo.java

Modified: xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/SchemaSymbols.java
URL: http://svn.apache.org/viewvc/xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/SchemaSymbols.java?rev=697134&r1=697133&r2=697134&view=diff
==============================================================================
--- xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/SchemaSymbols.java (original)
+++ xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/SchemaSymbols.java Fri Sep 19 08:36:02 2008
@@ -36,186 +36,188 @@
     // symbol table that comes with the parser
 
     // xsi attributes: in validator
-    public static final String URI_XSI                        = "http://www.w3.org/2001/XMLSchema-instance".intern();
+    public static final String URI_XSI                       = "http://www.w3.org/2001/XMLSchema-instance".intern();
     public static final String XSI_SCHEMALOCATION            = "schemaLocation".intern();
     public static final String XSI_NONAMESPACESCHEMALOCATION = "noNamespaceSchemaLocation".intern();
-    public static final String XSI_TYPE                       = "type".intern();
-    public static final String XSI_NIL                        = "nil".intern();
+    public static final String XSI_TYPE                      = "type".intern();
+    public static final String XSI_NIL                       = "nil".intern();
 
     // schema namespace
-    public static final String URI_SCHEMAFORSCHEMA            = "http://www.w3.org/2001/XMLSchema".intern();
+    public static final String URI_SCHEMAFORSCHEMA           = "http://www.w3.org/2001/XMLSchema".intern();
 
     // schema version namespace
     public static final String URI_SCHEMAVERSION = "http://www.w3.org/2007/XMLSchema-versioning".intern();
 
     // all possible schema element names
-    public static final String ELT_ALL                   = "all".intern();
-    public static final String ELT_ASSERT                = "assert".intern();
-    public static final String ELT_ALTERNATIVE           = "alternative".intern();
-    public static final String ELT_ANNOTATION            = "annotation".intern();
-    public static final String ELT_ANY                   = "any".intern();
-    public static final String ELT_ANYATTRIBUTE          = "anyAttribute".intern();
-    public static final String ELT_APPINFO               = "appinfo".intern();
-    public static final String ELT_ATTRIBUTE             = "attribute".intern();
-    public static final String ELT_ATTRIBUTEGROUP        = "attributeGroup".intern();
-    public static final String ELT_CHOICE                = "choice".intern();
-    public static final String ELT_COMPLEXCONTENT        = "complexContent".intern();
-    public static final String ELT_COMPLEXTYPE           = "complexType".intern();
-    public static final String ELT_DEFAULTOPENCONTENT    = "defaultOpenContent".intern();
-    public static final String ELT_DOCUMENTATION         = "documentation".intern();
-    public static final String ELT_ELEMENT               = "element".intern();
-    public static final String ELT_ENUMERATION           = "enumeration".intern();
-    public static final String ELT_EXTENSION             = "extension".intern();
-    public static final String ELT_FIELD                 = "field".intern();
-    public static final String ELT_FRACTIONDIGITS        = "fractionDigits".intern();
-    public static final String ELT_GROUP                 = "group".intern();
-    public static final String ELT_IMPORT                = "import".intern();
-    public static final String ELT_INCLUDE               = "include".intern();
-    public static final String ELT_KEY                   = "key".intern();
-    public static final String ELT_KEYREF                = "keyref".intern();
-    public static final String ELT_LENGTH                = "length".intern();
-    public static final String ELT_LIST                  = "list".intern();
-    public static final String ELT_MAXEXCLUSIVE          = "maxExclusive".intern();
-    public static final String ELT_MAXINCLUSIVE          = "maxInclusive".intern();
-    public static final String ELT_MAXLENGTH             = "maxLength".intern();
-    public static final String ELT_MINEXCLUSIVE          = "minExclusive".intern();
-    public static final String ELT_MININCLUSIVE          = "minInclusive".intern();
-    public static final String ELT_MINLENGTH             = "minLength".intern();
-    public static final String ELT_NOTATION              = "notation".intern();
-    public static final String ELT_OPENCONTENT           = "openContent".intern();
-    public static final String ELT_PATTERN               = "pattern".intern();
-    public static final String ELT_REDEFINE              = "redefine".intern();
-    public static final String ELT_RESTRICTION           = "restriction".intern();
-    public static final String ELT_SCHEMA                = "schema".intern();
-    public static final String ELT_SELECTOR              = "selector".intern();
-    public static final String ELT_SEQUENCE              = "sequence".intern();
-    public static final String ELT_SIMPLECONTENT         = "simpleContent".intern();
-    public static final String ELT_SIMPLETYPE            = "simpleType".intern();
-    public static final String ELT_TOTALDIGITS           = "totalDigits".intern();
-    public static final String ELT_UNION                 = "union".intern();
-    public static final String ELT_UNIQUE                = "unique".intern();
-    public static final String ELT_WHITESPACE            = "whiteSpace".intern();
+    public static final String ELT_ALL                    = "all".intern();
+    public static final String ELT_ASSERT                 = "assert".intern();
+    public static final String ELT_ALTERNATIVE            = "alternative".intern();
+    public static final String ELT_ANNOTATION             = "annotation".intern();
+    public static final String ELT_ANY                    = "any".intern();
+    public static final String ELT_ANYATTRIBUTE           = "anyAttribute".intern();
+    public static final String ELT_APPINFO                = "appinfo".intern();
+    public static final String ELT_ATTRIBUTE              = "attribute".intern();
+    public static final String ELT_ATTRIBUTEGROUP         = "attributeGroup".intern();
+    public static final String ELT_CHOICE                 = "choice".intern();
+    public static final String ELT_COMPLEXCONTENT         = "complexContent".intern();
+    public static final String ELT_COMPLEXTYPE            = "complexType".intern();
+    public static final String ELT_DEFAULTOPENCONTENT     = "defaultOpenContent".intern();
+    public static final String ELT_DOCUMENTATION          = "documentation".intern();
+    public static final String ELT_ELEMENT                = "element".intern();
+    public static final String ELT_ENUMERATION            = "enumeration".intern();
+    public static final String ELT_EXTENSION              = "extension".intern();
+    public static final String ELT_FIELD                  = "field".intern();
+    public static final String ELT_FRACTIONDIGITS         = "fractionDigits".intern();
+    public static final String ELT_GROUP                  = "group".intern();
+    public static final String ELT_IMPORT                 = "import".intern();
+    public static final String ELT_INCLUDE                = "include".intern();
+    public static final String ELT_KEY                    = "key".intern();
+    public static final String ELT_KEYREF                 = "keyref".intern();
+    public static final String ELT_LENGTH                 = "length".intern();
+    public static final String ELT_LIST                   = "list".intern();
+    public static final String ELT_MAXEXCLUSIVE           = "maxExclusive".intern();
+    public static final String ELT_MAXINCLUSIVE           = "maxInclusive".intern();
+    public static final String ELT_MAXLENGTH              = "maxLength".intern();
+    public static final String ELT_MINEXCLUSIVE           = "minExclusive".intern();
+    public static final String ELT_MININCLUSIVE           = "minInclusive".intern();
+    public static final String ELT_MINLENGTH              = "minLength".intern();
+    public static final String ELT_NOTATION               = "notation".intern();
+    public static final String ELT_OPENCONTENT            = "openContent".intern();
+    public static final String ELT_PATTERN                = "pattern".intern();
+    public static final String ELT_REDEFINE               = "redefine".intern();
+    public static final String ELT_RESTRICTION            = "restriction".intern();
+    public static final String ELT_SCHEMA                 = "schema".intern();
+    public static final String ELT_SELECTOR               = "selector".intern();
+    public static final String ELT_SEQUENCE               = "sequence".intern();
+    public static final String ELT_SIMPLECONTENT          = "simpleContent".intern();
+    public static final String ELT_SIMPLETYPE             = "simpleType".intern();
+    public static final String ELT_TOTALDIGITS            = "totalDigits".intern();
+    public static final String ELT_UNION                  = "union".intern();
+    public static final String ELT_UNIQUE                 = "unique".intern();
+    public static final String ELT_WHITESPACE             = "whiteSpace".intern();
  
     // all possible schema attribute names (and xml:lang defined on <schema> and <documentation>)
-    public static final String ATT_ABSTRACT              = "abstract".intern();
-    public static final String ATT_APPLIESTOEMPTY        = "appliesToEmpty".intern();
-    public static final String ATT_ATTRIBUTEFORMDEFAULT  = "attributeFormDefault".intern();
-    public static final String ATT_BASE                  = "base".intern();
-    public static final String ATT_BLOCK                 = "block".intern();
-    public static final String ATT_BLOCKDEFAULT          = "blockDefault".intern();
-    public static final String ATT_DEFAULT               = "default".intern();
-    public static final String ATT_ELEMENTFORMDEFAULT    = "elementFormDefault".intern();
-    public static final String ATT_FINAL                 = "final".intern();
-    public static final String ATT_FINALDEFAULT          = "finalDefault".intern();
-    public static final String ATT_FIXED                 = "fixed".intern();
-    public static final String ATT_FORM                  = "form".intern();
-    public static final String ATT_ID                    = "id".intern();
-    public static final String ATT_ITEMTYPE              = "itemType".intern();
-    public static final String ATT_MAXOCCURS             = "maxOccurs".intern();
-    public static final String ATT_MEMBERTYPES           = "memberTypes".intern();
-    public static final String ATT_MINOCCURS             = "minOccurs".intern();
-    public static final String ATT_MIXED                 = "mixed".intern();
-    public static final String ATT_MODE                  = "mode".intern();    
-    public static final String ATT_NAME                  = "name".intern();
-    public static final String ATT_NAMESPACE             = "namespace".intern();
-    public static final String ATT_NILLABLE              = "nillable".intern();
-    public static final String ATT_PROCESSCONTENTS       = "processContents".intern();
-    public static final String ATT_REF                   = "ref".intern();
-    public static final String ATT_REFER                 = "refer".intern();
-    public static final String ATT_SCHEMALOCATION        = "schemaLocation".intern();
-    public static final String ATT_SOURCE                = "source".intern();
-    public static final String ATT_SUBSTITUTIONGROUP     = "substitutionGroup".intern();
-    public static final String ATT_SYSTEM                = "system".intern();
-    public static final String ATT_PUBLIC                = "public".intern();
-    public static final String ATT_TARGETNAMESPACE       = "targetNamespace".intern();
-    public static final String ATT_TEST                  = "test".intern();
-    public static final String ATT_TYPE                  = "type".intern();
-    public static final String ATT_USE                   = "use".intern();
-    public static final String ATT_VALUE                 = "value".intern();
-    public static final String ATT_VERSION               = "version".intern();
-    public static final String ATT_XML_LANG              = "xml:lang".intern();
-    public static final String ATT_XPATH                 = "xpath".intern();
-    public static final String ATT_XPATH_DEFAULT_NS      = "xpathDefaultNamespace".intern();    
-    public static final String ATT_MINVERSION            = "minVersion".intern();
-    public static final String ATT_MAXVERSION            = "maxVersion".intern();
+    public static final String ATT_ABSTRACT               = "abstract".intern();
+    public static final String ATT_APPLIESTOEMPTY         = "appliesToEmpty".intern();
+    public static final String ATT_ATTRIBUTEFORMDEFAULT   = "attributeFormDefault".intern();
+    public static final String ATT_BASE                   = "base".intern();
+    public static final String ATT_BLOCK                  = "block".intern();
+    public static final String ATT_BLOCKDEFAULT           = "blockDefault".intern();
+    public static final String ATT_DEFAULT                = "default".intern();
+    public static final String ATT_DEFAULTATTRIBUTESAPPLY = "defaultAttributesApply".intern();
+    public static final String ATT_DEFAULTATTRIBUTES      = "defaultAttributes".intern();    
+    public static final String ATT_ELEMENTFORMDEFAULT     = "elementFormDefault".intern();
+    public static final String ATT_FINAL                  = "final".intern();
+    public static final String ATT_FINALDEFAULT           = "finalDefault".intern();
+    public static final String ATT_FIXED                  = "fixed".intern();
+    public static final String ATT_FORM                   = "form".intern();
+    public static final String ATT_ID                     = "id".intern();
+    public static final String ATT_ITEMTYPE               = "itemType".intern();
+    public static final String ATT_MAXOCCURS              = "maxOccurs".intern();
+    public static final String ATT_MEMBERTYPES            = "memberTypes".intern();
+    public static final String ATT_MINOCCURS              = "minOccurs".intern();
+    public static final String ATT_MIXED                  = "mixed".intern();
+    public static final String ATT_MODE                   = "mode".intern();    
+    public static final String ATT_NAME                   = "name".intern();
+    public static final String ATT_NAMESPACE              = "namespace".intern();
+    public static final String ATT_NILLABLE               = "nillable".intern();
+    public static final String ATT_PROCESSCONTENTS        = "processContents".intern();
+    public static final String ATT_REF                    = "ref".intern();
+    public static final String ATT_REFER                  = "refer".intern();
+    public static final String ATT_SCHEMALOCATION         = "schemaLocation".intern();
+    public static final String ATT_SOURCE                 = "source".intern();
+    public static final String ATT_SUBSTITUTIONGROUP      = "substitutionGroup".intern();
+    public static final String ATT_SYSTEM                 = "system".intern();
+    public static final String ATT_PUBLIC                 = "public".intern();
+    public static final String ATT_TARGETNAMESPACE        = "targetNamespace".intern();
+    public static final String ATT_TEST                   = "test".intern();
+    public static final String ATT_TYPE                   = "type".intern();
+    public static final String ATT_USE                    = "use".intern();
+    public static final String ATT_VALUE                  = "value".intern();
+    public static final String ATT_VERSION                = "version".intern();
+    public static final String ATT_XML_LANG               = "xml:lang".intern();
+    public static final String ATT_XPATH                  = "xpath".intern();
+    public static final String ATT_XPATH_DEFAULT_NS       = "xpathDefaultNamespace".intern();    
+    public static final String ATT_MINVERSION             = "minVersion".intern();
+    public static final String ATT_MAXVERSION             = "maxVersion".intern();
 
     // all possible schema attribute values
-    public static final String ATTVAL_TWOPOUNDANY        = "##any";
-    public static final String ATTVAL_TWOPOUNDDDEFAULTNS = "##defaultNamespace";    
-    public static final String ATTVAL_TWOPOUNDLOCAL      = "##local";
-    public static final String ATTVAL_TWOPOUNDOTHER      = "##other";
-    public static final String ATTVAL_TWOPOUNDTARGETNS   = "##targetNamespace";
-    public static final String ATTVAL_POUNDALL           = "#all";
-    public static final String ATTVAL_FALSE_0            = "0";
-    public static final String ATTVAL_TRUE_1             = "1";
-    public static final String ATTVAL_ANYSIMPLETYPE      = "anySimpleType";
-    public static final String ATTVAL_ANYTYPE            = "anyType";
-    public static final String ATTVAL_ANYURI             = "anyURI";
-    public static final String ATTVAL_BASE64BINARY       = "base64Binary";
-    public static final String ATTVAL_BOOLEAN            = "boolean";
-    public static final String ATTVAL_BYTE               = "byte";
-    public static final String ATTVAL_COLLAPSE           = "collapse";
-    public static final String ATTVAL_DATE               = "date";
-    public static final String ATTVAL_DATETIME           = "dateTime";
-    public static final String ATTVAL_DAY                = "gDay";
-    public static final String ATTVAL_DECIMAL            = "decimal";
-    public static final String ATTVAL_DOUBLE             = "double";
-    public static final String ATTVAL_DURATION           = "duration";
-    public static final String ATTVAL_ENTITY             = "ENTITY";
-    public static final String ATTVAL_ENTITIES           = "ENTITIES";
-    public static final String ATTVAL_EXTENSION          = "extension";
-    public static final String ATTVAL_FALSE              = "false";
-    public static final String ATTVAL_FLOAT              = "float";
-    public static final String ATTVAL_HEXBINARY          = "hexBinary";
-    public static final String ATTVAL_ID                 = "ID";
-    public static final String ATTVAL_IDREF              = "IDREF";
-    public static final String ATTVAL_IDREFS             = "IDREFS";
-    public static final String ATTVAL_INT                = "int";
-    public static final String ATTVAL_INTEGER            = "integer";
-    public static final String ATTVAL_INTERLEAVE         = "interleave";    
-    public static final String ATTVAL_LANGUAGE           = "language";
-    public static final String ATTVAL_LAX                = "lax";
-    public static final String ATTVAL_LIST               = "list";
-    public static final String ATTVAL_LONG               = "long";
-    public static final String ATTVAL_NAME               = "Name";
-    public static final String ATTVAL_NEGATIVEINTEGER    = "negativeInteger";
-    public static final String ATTVAL_MONTH              = "gMonth";
-    public static final String ATTVAL_MONTHDAY           = "gMonthDay";
-    public static final String ATTVAL_NCNAME             = "NCName";
-    public static final String ATTVAL_NMTOKEN            = "NMTOKEN";
-    public static final String ATTVAL_NMTOKENS           = "NMTOKENS";
-    public static final String ATTVAL_NONE               = "none";    
-    public static final String ATTVAL_NONNEGATIVEINTEGER = "nonNegativeInteger";
-    public static final String ATTVAL_NONPOSITIVEINTEGER = "nonPositiveInteger";
-    public static final String ATTVAL_NORMALIZEDSTRING   = "normalizedString";
-    public static final String ATTVAL_NOTATION           = "NOTATION";
-    public static final String ATTVAL_OPTIONAL           = "optional";
-    public static final String ATTVAL_POSITIVEINTEGER    = "positiveInteger";
-    public static final String ATTVAL_PRESERVE           = "preserve";
-    public static final String ATTVAL_PROHIBITED         = "prohibited";
-    public static final String ATTVAL_QNAME              = "QName";
-    public static final String ATTVAL_QUALIFIED          = "qualified";
-    public static final String ATTVAL_REPLACE            = "replace";
-    public static final String ATTVAL_REQUIRED           = "required";
-    public static final String ATTVAL_RESTRICTION        = "restriction";
-    public static final String ATTVAL_SHORT              = "short";
-    public static final String ATTVAL_SKIP               = "skip";
-    public static final String ATTVAL_STRICT             = "strict";
-    public static final String ATTVAL_STRING             = "string";    
-    public static final String ATTVAL_SUBSTITUTION       = "substitution";
-    public static final String ATTVAL_SUFFIX             = "suffix";
-    public static final String ATTVAL_TIME               = "time";
-    public static final String ATTVAL_TOKEN              = "token";
-    public static final String ATTVAL_TRUE               = "true";
-    public static final String ATTVAL_UNBOUNDED          = "unbounded";
-    public static final String ATTVAL_UNION              = "union";
-    public static final String ATTVAL_UNQUALIFIED        = "unqualified";
-    public static final String ATTVAL_UNSIGNEDBYTE       = "unsignedByte";
-    public static final String ATTVAL_UNSIGNEDINT        = "unsignedInt";
-    public static final String ATTVAL_UNSIGNEDLONG       = "unsignedLong";
-    public static final String ATTVAL_UNSIGNEDSHORT      = "unsignedShort";
-    public static final String ATTVAL_YEAR               = "gYear";
-    public static final String ATTVAL_YEARMONTH          = "gYearMonth";
+    public static final String ATTVAL_TWOPOUNDANY         = "##any";
+    public static final String ATTVAL_TWOPOUNDDEFAULTNS  = "##defaultNamespace";    
+    public static final String ATTVAL_TWOPOUNDLOCAL       = "##local";
+    public static final String ATTVAL_TWOPOUNDOTHER       = "##other";
+    public static final String ATTVAL_TWOPOUNDTARGETNS    = "##targetNamespace";
+    public static final String ATTVAL_POUNDALL            = "#all";
+    public static final String ATTVAL_FALSE_0             = "0";
+    public static final String ATTVAL_TRUE_1              = "1";
+    public static final String ATTVAL_ANYSIMPLETYPE       = "anySimpleType";
+    public static final String ATTVAL_ANYTYPE             = "anyType";
+    public static final String ATTVAL_ANYURI              = "anyURI";
+    public static final String ATTVAL_BASE64BINARY        = "base64Binary";
+    public static final String ATTVAL_BOOLEAN             = "boolean";
+    public static final String ATTVAL_BYTE                = "byte";
+    public static final String ATTVAL_COLLAPSE            = "collapse";
+    public static final String ATTVAL_DATE                = "date";
+    public static final String ATTVAL_DATETIME            = "dateTime";
+    public static final String ATTVAL_DAY                 = "gDay";
+    public static final String ATTVAL_DECIMAL             = "decimal";
+    public static final String ATTVAL_DOUBLE              = "double";
+    public static final String ATTVAL_DURATION            = "duration";
+    public static final String ATTVAL_ENTITY              = "ENTITY";
+    public static final String ATTVAL_ENTITIES            = "ENTITIES";
+    public static final String ATTVAL_EXTENSION           = "extension";
+    public static final String ATTVAL_FALSE               = "false";
+    public static final String ATTVAL_FLOAT               = "float";
+    public static final String ATTVAL_HEXBINARY           = "hexBinary";
+    public static final String ATTVAL_ID                  = "ID";
+    public static final String ATTVAL_IDREF               = "IDREF";
+    public static final String ATTVAL_IDREFS              = "IDREFS";
+    public static final String ATTVAL_INT                 = "int";
+    public static final String ATTVAL_INTEGER             = "integer";
+    public static final String ATTVAL_INTERLEAVE          = "interleave";    
+    public static final String ATTVAL_LANGUAGE            = "language";
+    public static final String ATTVAL_LAX                 = "lax";
+    public static final String ATTVAL_LIST                = "list";
+    public static final String ATTVAL_LONG                = "long";
+    public static final String ATTVAL_NAME                = "Name";
+    public static final String ATTVAL_NEGATIVEINTEGER     = "negativeInteger";
+    public static final String ATTVAL_MONTH               = "gMonth";
+    public static final String ATTVAL_MONTHDAY            = "gMonthDay";
+    public static final String ATTVAL_NCNAME              = "NCName";
+    public static final String ATTVAL_NMTOKEN             = "NMTOKEN";
+    public static final String ATTVAL_NMTOKENS            = "NMTOKENS";
+    public static final String ATTVAL_NONE                = "none";    
+    public static final String ATTVAL_NONNEGATIVEINTEGER  = "nonNegativeInteger";
+    public static final String ATTVAL_NONPOSITIVEINTEGER  = "nonPositiveInteger";
+    public static final String ATTVAL_NORMALIZEDSTRING    = "normalizedString";
+    public static final String ATTVAL_NOTATION            = "NOTATION";
+    public static final String ATTVAL_OPTIONAL            = "optional";
+    public static final String ATTVAL_POSITIVEINTEGER     = "positiveInteger";
+    public static final String ATTVAL_PRESERVE            = "preserve";
+    public static final String ATTVAL_PROHIBITED          = "prohibited";
+    public static final String ATTVAL_QNAME               = "QName";
+    public static final String ATTVAL_QUALIFIED           = "qualified";
+    public static final String ATTVAL_REPLACE             = "replace";
+    public static final String ATTVAL_REQUIRED            = "required";
+    public static final String ATTVAL_RESTRICTION         = "restriction";
+    public static final String ATTVAL_SHORT               = "short";
+    public static final String ATTVAL_SKIP                = "skip";
+    public static final String ATTVAL_STRICT              = "strict";
+    public static final String ATTVAL_STRING              = "string";    
+    public static final String ATTVAL_SUBSTITUTION        = "substitution";
+    public static final String ATTVAL_SUFFIX              = "suffix";
+    public static final String ATTVAL_TIME                = "time";
+    public static final String ATTVAL_TOKEN               = "token";
+    public static final String ATTVAL_TRUE                =  "true";
+    public static final String ATTVAL_UNBOUNDED           =  "unbounded";
+    public static final String ATTVAL_UNION               = "union";
+    public static final String ATTVAL_UNQUALIFIED         = "unqualified";
+    public static final String ATTVAL_UNSIGNEDBYTE        = "unsignedByte";
+    public static final String ATTVAL_UNSIGNEDINT         = "unsignedInt";
+    public static final String ATTVAL_UNSIGNEDLONG        = "unsignedLong";
+    public static final String ATTVAL_UNSIGNEDSHORT       = "unsignedShort";
+    public static final String ATTVAL_YEAR                = "gYear";
+    public static final String ATTVAL_YEARMONTH           = "gYearMonth";
 
     // form qualified/unqualified
     public static final short FORM_UNQUALIFIED = 0;

Modified: xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSAttributeChecker.java
URL: http://svn.apache.org/viewvc/xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSAttributeChecker.java?rev=697134&r1=697133&r2=697134&view=diff
==============================================================================
--- xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSAttributeChecker.java (original)
+++ xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSAttributeChecker.java Fri Sep 19 08:36:02 2008
@@ -22,6 +22,7 @@
 import java.util.StringTokenizer;
 import java.util.Vector;
 
+import org.apache.xerces.impl.Constants;
 import org.apache.xerces.impl.dv.InvalidDatatypeValueException;
 import org.apache.xerces.impl.dv.XSSimpleType;
 import org.apache.xerces.impl.xs.SchemaGrammar;
@@ -78,53 +79,55 @@
     private static final String ATTRIBUTE_N = "attribute_n";
     private static final String ATTRIBUTE_R = "attribute_r";
 
-    private static       int ATTIDX_COUNT           = 0;
-    public static final int ATTIDX_ABSTRACT        = ATTIDX_COUNT++;
-    public static final int ATTIDX_AFORMDEFAULT    = ATTIDX_COUNT++;
-    public static final int ATTIDX_BASE            = ATTIDX_COUNT++;
-    public static final int ATTIDX_BLOCK           = ATTIDX_COUNT++;
-    public static final int ATTIDX_BLOCKDEFAULT    = ATTIDX_COUNT++;
-    public static final int ATTIDX_DEFAULT         = ATTIDX_COUNT++;
-    public static final int ATTIDX_EFORMDEFAULT    = ATTIDX_COUNT++;
-    public static final int ATTIDX_FINAL           = ATTIDX_COUNT++;
-    public static final int ATTIDX_FINALDEFAULT    = ATTIDX_COUNT++;
-    public static final int ATTIDX_FIXED           = ATTIDX_COUNT++;
-    public static final int ATTIDX_FORM            = ATTIDX_COUNT++;
-    public static final int ATTIDX_ID              = ATTIDX_COUNT++;
-    public static final int ATTIDX_ITEMTYPE        = ATTIDX_COUNT++;
-    public static final int ATTIDX_MAXOCCURS       = ATTIDX_COUNT++;
-    public static final int ATTIDX_MEMBERTYPES     = ATTIDX_COUNT++;
-    public static final int ATTIDX_MINOCCURS       = ATTIDX_COUNT++;
-    public static final int ATTIDX_MIXED           = ATTIDX_COUNT++;
-    public static final int ATTIDX_NAME            = ATTIDX_COUNT++;
-    public static final int ATTIDX_NAMESPACE       = ATTIDX_COUNT++;
-    public static final int ATTIDX_NAMESPACE_LIST  = ATTIDX_COUNT++;
-    public static final int ATTIDX_NILLABLE        = ATTIDX_COUNT++;
-    public static final int ATTIDX_NONSCHEMA       = ATTIDX_COUNT++;
-    public static final int ATTIDX_PROCESSCONTENTS = ATTIDX_COUNT++;
-    public static final int ATTIDX_PUBLIC          = ATTIDX_COUNT++;
-    public static final int ATTIDX_REF             = ATTIDX_COUNT++;
-    public static final int ATTIDX_REFER           = ATTIDX_COUNT++;
-    public static final int ATTIDX_SCHEMALOCATION  = ATTIDX_COUNT++;
-    public static final int ATTIDX_SOURCE          = ATTIDX_COUNT++;
-    public static final int ATTIDX_SUBSGROUP       = ATTIDX_COUNT++;
-    public static final int ATTIDX_SYSTEM          = ATTIDX_COUNT++;
-    public static final int ATTIDX_TARGETNAMESPACE = ATTIDX_COUNT++;
-    public static final int ATTIDX_TYPE            = ATTIDX_COUNT++;
-    public static final int ATTIDX_USE             = ATTIDX_COUNT++;
-    public static final int ATTIDX_VALUE           = ATTIDX_COUNT++;
-    public static final int ATTIDX_ENUMNSDECLS     = ATTIDX_COUNT++;
-    public static final int ATTIDX_VERSION         = ATTIDX_COUNT++;
-    public static final int ATTIDX_XML_LANG        = ATTIDX_COUNT++;
-    public static final int ATTIDX_XPATH           = ATTIDX_COUNT++;
-    public static final int ATTIDX_FROMDEFAULT     = ATTIDX_COUNT++;
-    //public static final int ATTIDX_OTHERVALUES     = ATTIDX_COUNT++;
-    public static final int ATTIDX_ISRETURNED      = ATTIDX_COUNT++;
+    private static      int ATTIDX_COUNT             = 0;
+    public static final int ATTIDX_ABSTRACT          = ATTIDX_COUNT++;
+    public static final int ATTIDX_AFORMDEFAULT      = ATTIDX_COUNT++;
+    public static final int ATTIDX_BASE              = ATTIDX_COUNT++;
+    public static final int ATTIDX_BLOCK             = ATTIDX_COUNT++;
+    public static final int ATTIDX_BLOCKDEFAULT      = ATTIDX_COUNT++;
+    public static final int ATTIDX_DEFAULT           = ATTIDX_COUNT++;
+    public static final int ATTIDX_EFORMDEFAULT      = ATTIDX_COUNT++;
+    public static final int ATTIDX_FINAL             = ATTIDX_COUNT++;
+    public static final int ATTIDX_FINALDEFAULT      = ATTIDX_COUNT++;
+    public static final int ATTIDX_FIXED             = ATTIDX_COUNT++;
+    public static final int ATTIDX_FORM              = ATTIDX_COUNT++;
+    public static final int ATTIDX_ID                = ATTIDX_COUNT++;
+    public static final int ATTIDX_ITEMTYPE          = ATTIDX_COUNT++;
+    public static final int ATTIDX_MAXOCCURS         = ATTIDX_COUNT++;
+    public static final int ATTIDX_MEMBERTYPES       = ATTIDX_COUNT++;
+    public static final int ATTIDX_MINOCCURS         = ATTIDX_COUNT++;
+    public static final int ATTIDX_MIXED             = ATTIDX_COUNT++;
+    public static final int ATTIDX_NAME              = ATTIDX_COUNT++;
+    public static final int ATTIDX_NAMESPACE         = ATTIDX_COUNT++;
+    public static final int ATTIDX_NAMESPACE_LIST    = ATTIDX_COUNT++;
+    public static final int ATTIDX_NILLABLE          = ATTIDX_COUNT++;
+    public static final int ATTIDX_NONSCHEMA         = ATTIDX_COUNT++;
+    public static final int ATTIDX_PROCESSCONTENTS   = ATTIDX_COUNT++;
+    public static final int ATTIDX_PUBLIC            = ATTIDX_COUNT++;
+    public static final int ATTIDX_REF               = ATTIDX_COUNT++;
+    public static final int ATTIDX_REFER             = ATTIDX_COUNT++;
+    public static final int ATTIDX_SCHEMALOCATION    = ATTIDX_COUNT++;
+    public static final int ATTIDX_SOURCE            = ATTIDX_COUNT++;
+    public static final int ATTIDX_SUBSGROUP         = ATTIDX_COUNT++;
+    public static final int ATTIDX_SYSTEM            = ATTIDX_COUNT++;
+    public static final int ATTIDX_TARGETNAMESPACE   = ATTIDX_COUNT++;
+    public static final int ATTIDX_TYPE              = ATTIDX_COUNT++;
+    public static final int ATTIDX_USE               = ATTIDX_COUNT++;
+    public static final int ATTIDX_VALUE             = ATTIDX_COUNT++;
+    public static final int ATTIDX_ENUMNSDECLS       = ATTIDX_COUNT++;
+    public static final int ATTIDX_VERSION           = ATTIDX_COUNT++;
+    public static final int ATTIDX_XML_LANG          = ATTIDX_COUNT++;
+    public static final int ATTIDX_XPATH             = ATTIDX_COUNT++;
+    public static final int ATTIDX_FROMDEFAULT       = ATTIDX_COUNT++;
+    //public static final int ATTIDX_OTHERVALUES       = ATTIDX_COUNT++;
+    public static final int ATTIDX_ISRETURNED        = ATTIDX_COUNT++;
     
     //  Schema 1.1
-    public static final int ATTIDX_XPATHDEFAULTNS  = ATTIDX_COUNT++;
-    public static final int ATTIDX_APPLIESTOEMPTY  = ATTIDX_COUNT++;
-    public static final int ATTIDX_MODE            = ATTIDX_COUNT++;    
+    public static final int ATTIDX_APPLIESTOEMPTY    = ATTIDX_COUNT++;
+    public static final int ATTIDX_DEFAULTATTRAPPLY  = ATTIDX_COUNT++;
+    public static final int ATTIDX_DEFAULTATTRIBUTES = ATTIDX_COUNT++;    
+    public static final int ATTIDX_MODE              = ATTIDX_COUNT++;
+    public static final int ATTIDX_XPATHDEFAULTNS    = ATTIDX_COUNT++;    
 
     private static final XIntPool fXIntPool = new XIntPool();
     // constants to return
@@ -154,6 +157,14 @@
     // for 39 local elements
     private static final Hashtable fEleAttrsMapL = new Hashtable(79);
 
+    // XML Schema 1.1
+    //
+    // used to store the map from element name to attribute list
+    // for 15 global elements
+    private static final Hashtable fEleAttrs11MapG = new Hashtable(31);
+    // for 47 local elememnts
+    private static final Hashtable fEleAttrs11MapL = new Hashtable(97);
+
     // used to initialize fEleAttrsMap
     // step 1: all possible data types
     // DT_??? >= 0 : validate using a validator, which is initialized staticly
@@ -219,276 +230,289 @@
     static {
         // step 2: all possible attributes for all elements
         int attCount = 0;
-        int ATT_ABSTRACT_D          = attCount++;
-        int ATT_ATTRIBUTE_FD_D      = attCount++;
-        int ATT_BASE_R              = attCount++;
-        int ATT_BASE_N              = attCount++;
-        int ATT_BLOCK_N             = attCount++;
-        int ATT_BLOCK1_N            = attCount++;
-        int ATT_BLOCK_D_D           = attCount++;
-        int ATT_DEFAULT_N           = attCount++;
-        int ATT_ELEMENT_FD_D        = attCount++;
-        int ATT_FINAL_N             = attCount++;
-        int ATT_FINAL1_N            = attCount++;
-        int ATT_FINAL_D_D           = attCount++;
-        int ATT_FIXED_N             = attCount++;
-        int ATT_FIXED_D             = attCount++;
-        int ATT_FORM_N              = attCount++;
-        int ATT_ID_N                = attCount++;
-        int ATT_ITEMTYPE_N          = attCount++;
-        int ATT_MAXOCCURS_D         = attCount++;
-        int ATT_MAXOCCURS1_D        = attCount++;
-        int ATT_MEMBER_T_N          = attCount++;
-        int ATT_MINOCCURS_D         = attCount++;
-        int ATT_MINOCCURS1_D        = attCount++;
-        int ATT_MIXED_D             = attCount++;
-        int ATT_MIXED_N             = attCount++;
-        int ATT_NAME_R              = attCount++;
-        int ATT_NAMESPACE_D         = attCount++;
-        int ATT_NAMESPACE_N         = attCount++;
-        int ATT_NILLABLE_D          = attCount++;
-        int ATT_PROCESS_C_D         = attCount++;
-        int ATT_PUBLIC_R            = attCount++;
-        int ATT_REF_R               = attCount++;
-        int ATT_REFER_R             = attCount++;
-        int ATT_SCHEMA_L_R          = attCount++;
-        int ATT_SCHEMA_L_N          = attCount++;
-        int ATT_SOURCE_N            = attCount++;
-        int ATT_SUBSTITUTION_G_N    = attCount++;
-        int ATT_SYSTEM_N            = attCount++;
-        int ATT_TARGET_N_N          = attCount++;
-        int ATT_TYPE_N              = attCount++;
-        int ATT_USE_D               = attCount++;
-        int ATT_VALUE_NNI_N         = attCount++;
-        int ATT_VALUE_PI_N          = attCount++;
-        int ATT_VALUE_STR_N         = attCount++;
-        int ATT_VALUE_WS_N          = attCount++;
-        int ATT_VERSION_N           = attCount++;
-        int ATT_XML_LANG            = attCount++;
-        int ATT_XPATH_R             = attCount++;
-        int ATT_XPATH1_R            = attCount++;
+        int ATT_ABSTRACT_D           = attCount++;
+        int ATT_ATTRIBUTE_FD_D       = attCount++;
+        int ATT_BASE_R               = attCount++;
+        int ATT_BASE_N               = attCount++;
+        int ATT_BLOCK_N              = attCount++;
+        int ATT_BLOCK1_N             = attCount++;
+        int ATT_BLOCK_D_D            = attCount++;
+        int ATT_DEFAULT_N            = attCount++;
+        int ATT_ELEMENT_FD_D         = attCount++;
+        int ATT_FINAL_N              = attCount++;
+        int ATT_FINAL1_N             = attCount++;
+        int ATT_FINAL_D_D            = attCount++;
+        int ATT_FIXED_N              = attCount++;
+        int ATT_FIXED_D              = attCount++;
+        int ATT_FORM_N               = attCount++;
+        int ATT_ID_N                 = attCount++;
+        int ATT_ITEMTYPE_N           = attCount++;
+        int ATT_MAXOCCURS_D          = attCount++;
+        int ATT_MAXOCCURS1_D         = attCount++;
+        int ATT_MEMBER_T_N           = attCount++;
+        int ATT_MINOCCURS_D          = attCount++;
+        int ATT_MINOCCURS1_D         = attCount++;
+        int ATT_MIXED_D              = attCount++;
+        int ATT_MIXED_N              = attCount++;
+        int ATT_NAME_R               = attCount++;
+        int ATT_NAMESPACE_D          = attCount++;
+        int ATT_NAMESPACE_N          = attCount++;
+        int ATT_NILLABLE_D           = attCount++;
+        int ATT_PROCESS_C_D          = attCount++;
+        int ATT_PUBLIC_R             = attCount++;
+        int ATT_REF_R                = attCount++;
+        int ATT_REFER_R              = attCount++;
+        int ATT_SCHEMA_L_R           = attCount++;
+        int ATT_SCHEMA_L_N           = attCount++;
+        int ATT_SOURCE_N             = attCount++;
+        int ATT_SUBSTITUTION_G_N     = attCount++;
+        int ATT_SYSTEM_N             = attCount++;
+        int ATT_TARGET_N_N           = attCount++;
+        int ATT_TYPE_N               = attCount++;
+        int ATT_USE_D                = attCount++;
+        int ATT_VALUE_NNI_N          = attCount++;
+        int ATT_VALUE_PI_N           = attCount++;
+        int ATT_VALUE_STR_N          = attCount++;
+        int ATT_VALUE_WS_N           = attCount++;
+        int ATT_VERSION_N            = attCount++;
+        int ATT_XML_LANG             = attCount++;
+        int ATT_XPATH_R              = attCount++;
+        int ATT_XPATH1_R             = attCount++;
+
         // XML Schema 1.1 attributes
-        int ATT_TEST_XPATH_R        = attCount++;
-        int ATT_DEFAULT_XPATH_NS_N  = attCount++;
-        int ATT_APPLIESTO_EMPTY_D   = attCount++;
-        int ATT_MODE_D              = attCount++;
-        int ATT_MODE1_D             = attCount++;        
+        int ATT_APPLIESTO_EMPTY_D    = attCount++;
+        int ATT_DEFAULT_ATTRIBUTES_N = attCount++;
+        int ATT_DEFAULT_ATTR_APPLY_D = attCount++;        
+        int ATT_DEFAULT_XPATH_NS_N   = attCount++;
+        int ATT_MODE_D               = attCount++;
+        int ATT_MODE1_D              = attCount++;
+        int ATT_TEST_XPATH_R         = attCount++;
 
         // step 3: store all these attributes in an array
         OneAttr[] allAttrs = new OneAttr[attCount];
-        allAttrs[ATT_ABSTRACT_D]         =   new OneAttr(SchemaSymbols.ATT_ABSTRACT,
+        allAttrs[ATT_ABSTRACT_D]           = new OneAttr(SchemaSymbols.ATT_ABSTRACT,
                                                         DT_BOOLEAN,
                                                         ATTIDX_ABSTRACT,
                                                         Boolean.FALSE);
-        allAttrs[ATT_APPLIESTO_EMPTY_D]  =   new OneAttr(SchemaSymbols.ATT_APPLIESTOEMPTY,
-                                                        DT_BOOLEAN,
-                                                        ATTIDX_APPLIESTOEMPTY,
-                                                        Boolean.FALSE);
-        allAttrs[ATT_ATTRIBUTE_FD_D]     =   new OneAttr(SchemaSymbols.ATT_ATTRIBUTEFORMDEFAULT,
+        allAttrs[ATT_ATTRIBUTE_FD_D]       = new OneAttr(SchemaSymbols.ATT_ATTRIBUTEFORMDEFAULT,
                                                         DT_FORM,
                                                         ATTIDX_AFORMDEFAULT,
                                                         INT_UNQUALIFIED);
-        allAttrs[ATT_BASE_R]             =   new OneAttr(SchemaSymbols.ATT_BASE,
+        allAttrs[ATT_BASE_R]               = new OneAttr(SchemaSymbols.ATT_BASE,
                                                         DT_QNAME,
                                                         ATTIDX_BASE,
                                                         null);
-        allAttrs[ATT_BASE_N]             =   new OneAttr(SchemaSymbols.ATT_BASE,
+        allAttrs[ATT_BASE_N]               = new OneAttr(SchemaSymbols.ATT_BASE,
                                                         DT_QNAME,
                                                         ATTIDX_BASE,
                                                         null);
-        allAttrs[ATT_BLOCK_N]            =   new OneAttr(SchemaSymbols.ATT_BLOCK,
+        allAttrs[ATT_BLOCK_N]              = new OneAttr(SchemaSymbols.ATT_BLOCK,
                                                         DT_BLOCK,
                                                         ATTIDX_BLOCK,
                                                         null);
-        allAttrs[ATT_BLOCK1_N]           =   new OneAttr(SchemaSymbols.ATT_BLOCK,
+        allAttrs[ATT_BLOCK1_N]             = new OneAttr(SchemaSymbols.ATT_BLOCK,
                                                         DT_BLOCK1,
                                                         ATTIDX_BLOCK,
                                                         null);
-        allAttrs[ATT_BLOCK_D_D]          =   new OneAttr(SchemaSymbols.ATT_BLOCKDEFAULT,
+        allAttrs[ATT_BLOCK_D_D]            = new OneAttr(SchemaSymbols.ATT_BLOCKDEFAULT,
                                                         DT_BLOCK,
                                                         ATTIDX_BLOCKDEFAULT,
                                                         INT_EMPTY_SET);
-        allAttrs[ATT_DEFAULT_N]          =   new OneAttr(SchemaSymbols.ATT_DEFAULT,
+        allAttrs[ATT_DEFAULT_N]            = new OneAttr(SchemaSymbols.ATT_DEFAULT,
                                                         DT_STRING,
                                                         ATTIDX_DEFAULT,
                                                         null);
-        allAttrs[ATT_DEFAULT_XPATH_NS_N] =   new OneAttr(SchemaSymbols.ATT_XPATH_DEFAULT_NS,
-                                                        DT_XPATH_DEFAULT_NS,
-                                                        ATTIDX_XPATHDEFAULTNS,
-                                                        null);
-        allAttrs[ATT_ELEMENT_FD_D]       =   new OneAttr(SchemaSymbols.ATT_ELEMENTFORMDEFAULT,
+        allAttrs[ATT_ELEMENT_FD_D]         = new OneAttr(SchemaSymbols.ATT_ELEMENTFORMDEFAULT,
                                                         DT_FORM,
                                                         ATTIDX_EFORMDEFAULT,
                                                         INT_UNQUALIFIED);
-        allAttrs[ATT_FINAL_N]            =   new OneAttr(SchemaSymbols.ATT_FINAL,
+        allAttrs[ATT_FINAL_N]              = new OneAttr(SchemaSymbols.ATT_FINAL,
                                                         DT_FINAL,
                                                         ATTIDX_FINAL,
                                                         null);
-        allAttrs[ATT_FINAL1_N]           =   new OneAttr(SchemaSymbols.ATT_FINAL,
+        allAttrs[ATT_FINAL1_N]             = new OneAttr(SchemaSymbols.ATT_FINAL,
                                                         DT_FINAL1,
                                                         ATTIDX_FINAL,
                                                         null);
-        allAttrs[ATT_FINAL_D_D]          =   new OneAttr(SchemaSymbols.ATT_FINALDEFAULT,
+        allAttrs[ATT_FINAL_D_D]            = new OneAttr(SchemaSymbols.ATT_FINALDEFAULT,
                                                         DT_FINAL2,
                                                         ATTIDX_FINALDEFAULT,
                                                         INT_EMPTY_SET);
-        allAttrs[ATT_FIXED_N]            =   new OneAttr(SchemaSymbols.ATT_FIXED,
+        allAttrs[ATT_FIXED_N]              = new OneAttr(SchemaSymbols.ATT_FIXED,
                                                         DT_STRING,
                                                         ATTIDX_FIXED,
                                                         null);
-        allAttrs[ATT_FIXED_D]            =   new OneAttr(SchemaSymbols.ATT_FIXED,
+        allAttrs[ATT_FIXED_D]              = new OneAttr(SchemaSymbols.ATT_FIXED,
                                                         DT_BOOLEAN,
                                                         ATTIDX_FIXED,
                                                         Boolean.FALSE);
-        allAttrs[ATT_FORM_N]             =   new OneAttr(SchemaSymbols.ATT_FORM,
+        allAttrs[ATT_FORM_N]               = new OneAttr(SchemaSymbols.ATT_FORM,
                                                         DT_FORM,
                                                         ATTIDX_FORM,
                                                         null);
-        allAttrs[ATT_ID_N]               =   new OneAttr(SchemaSymbols.ATT_ID,
+        allAttrs[ATT_ID_N]                 = new OneAttr(SchemaSymbols.ATT_ID,
                                                         DT_ID,
                                                         ATTIDX_ID,
                                                         null);
-        allAttrs[ATT_ITEMTYPE_N]         =   new OneAttr(SchemaSymbols.ATT_ITEMTYPE,
+        allAttrs[ATT_ITEMTYPE_N]           = new OneAttr(SchemaSymbols.ATT_ITEMTYPE,
                                                         DT_QNAME,
                                                         ATTIDX_ITEMTYPE,
                                                         null);
-        allAttrs[ATT_MAXOCCURS_D]        =   new OneAttr(SchemaSymbols.ATT_MAXOCCURS,
+        allAttrs[ATT_MAXOCCURS_D]          = new OneAttr(SchemaSymbols.ATT_MAXOCCURS,
                                                         DT_MAXOCCURS,
                                                         ATTIDX_MAXOCCURS,
                                                         fXIntPool.getXInt(1));
-        allAttrs[ATT_MAXOCCURS1_D]       =   new OneAttr(SchemaSymbols.ATT_MAXOCCURS,
+        allAttrs[ATT_MAXOCCURS1_D]         = new OneAttr(SchemaSymbols.ATT_MAXOCCURS,
                                                         DT_MAXOCCURS1,
                                                         ATTIDX_MAXOCCURS,
                                                         fXIntPool.getXInt(1));
-        allAttrs[ATT_MEMBER_T_N]         =   new OneAttr(SchemaSymbols.ATT_MEMBERTYPES,
+        allAttrs[ATT_MEMBER_T_N]           = new OneAttr(SchemaSymbols.ATT_MEMBERTYPES,
                                                         DT_MEMBERTYPES,
                                                         ATTIDX_MEMBERTYPES,
                                                         null);
-        allAttrs[ATT_MINOCCURS_D]        =   new OneAttr(SchemaSymbols.ATT_MINOCCURS,
+        allAttrs[ATT_MINOCCURS_D]          = new OneAttr(SchemaSymbols.ATT_MINOCCURS,
                                                         DT_NONNEGINT,
                                                         ATTIDX_MINOCCURS,
                                                         fXIntPool.getXInt(1));
-        allAttrs[ATT_MINOCCURS1_D]       =   new OneAttr(SchemaSymbols.ATT_MINOCCURS,
+        allAttrs[ATT_MINOCCURS1_D]         = new OneAttr(SchemaSymbols.ATT_MINOCCURS,
                                                         DT_MINOCCURS1,
                                                         ATTIDX_MINOCCURS,
                                                         fXIntPool.getXInt(1));
-        allAttrs[ATT_MIXED_D]            =   new OneAttr(SchemaSymbols.ATT_MIXED,
+        allAttrs[ATT_MIXED_D]              = new OneAttr(SchemaSymbols.ATT_MIXED,
                                                         DT_BOOLEAN,
                                                         ATTIDX_MIXED,
                                                         Boolean.FALSE);
-        allAttrs[ATT_MIXED_N]            =   new OneAttr(SchemaSymbols.ATT_MIXED,
+        allAttrs[ATT_MIXED_N]              = new OneAttr(SchemaSymbols.ATT_MIXED,
                                                         DT_BOOLEAN,
                                                         ATTIDX_MIXED,
                                                         null);
-        allAttrs[ATT_MODE_D]             =   new OneAttr(SchemaSymbols.ATT_MODE,
-                                                        DT_MODE,
-                                                        ATTIDX_MODE,
-                                                        INT_MODE_INTERLEAVE);
-        allAttrs[ATT_MODE1_D]            =   new OneAttr(SchemaSymbols.ATT_MODE,
-                                                        DT_MODE1,
-                                                        ATTIDX_MODE,
-                                                        INT_MODE_INTERLEAVE);
-        allAttrs[ATT_NAME_R]             =   new OneAttr(SchemaSymbols.ATT_NAME,
+        allAttrs[ATT_NAME_R]               = new OneAttr(SchemaSymbols.ATT_NAME,
                                                         DT_NCNAME,
                                                         ATTIDX_NAME,
                                                         null);
-        allAttrs[ATT_NAMESPACE_D]        =   new OneAttr(SchemaSymbols.ATT_NAMESPACE,
+        allAttrs[ATT_NAMESPACE_D]          = new OneAttr(SchemaSymbols.ATT_NAMESPACE,
                                                         DT_NAMESPACE,
                                                         ATTIDX_NAMESPACE,
                                                         INT_ANY_ANY);
-        allAttrs[ATT_NAMESPACE_N]        =   new OneAttr(SchemaSymbols.ATT_NAMESPACE,
+        allAttrs[ATT_NAMESPACE_N]          = new OneAttr(SchemaSymbols.ATT_NAMESPACE,
                                                         DT_ANYURI,
                                                         ATTIDX_NAMESPACE,
                                                         null);
-        allAttrs[ATT_NILLABLE_D]         =   new OneAttr(SchemaSymbols.ATT_NILLABLE,
+        allAttrs[ATT_NILLABLE_D]           = new OneAttr(SchemaSymbols.ATT_NILLABLE,
                                                         DT_BOOLEAN,
                                                         ATTIDX_NILLABLE,
                                                         Boolean.FALSE);
-        allAttrs[ATT_PROCESS_C_D]        =   new OneAttr(SchemaSymbols.ATT_PROCESSCONTENTS,
+        allAttrs[ATT_PROCESS_C_D]          = new OneAttr(SchemaSymbols.ATT_PROCESSCONTENTS,
                                                         DT_PROCESSCONTENTS,
                                                         ATTIDX_PROCESSCONTENTS,
                                                         INT_ANY_STRICT);
-        allAttrs[ATT_PUBLIC_R]           =   new OneAttr(SchemaSymbols.ATT_PUBLIC,
+        allAttrs[ATT_PUBLIC_R]             = new OneAttr(SchemaSymbols.ATT_PUBLIC,
                                                         DT_TOKEN,
                                                         ATTIDX_PUBLIC,
                                                         null);
-        allAttrs[ATT_REF_R]              =   new OneAttr(SchemaSymbols.ATT_REF,
+        allAttrs[ATT_REF_R]                = new OneAttr(SchemaSymbols.ATT_REF,
                                                         DT_QNAME,
                                                         ATTIDX_REF,
                                                         null);
-        allAttrs[ATT_REFER_R]            =   new OneAttr(SchemaSymbols.ATT_REFER,
+        allAttrs[ATT_REFER_R]              = new OneAttr(SchemaSymbols.ATT_REFER,
                                                         DT_QNAME,
                                                         ATTIDX_REFER,
                                                         null);
-        allAttrs[ATT_SCHEMA_L_R]         =   new OneAttr(SchemaSymbols.ATT_SCHEMALOCATION,
+        allAttrs[ATT_SCHEMA_L_R]           = new OneAttr(SchemaSymbols.ATT_SCHEMALOCATION,
                                                         DT_ANYURI,
                                                         ATTIDX_SCHEMALOCATION,
                                                         null);
-        allAttrs[ATT_SCHEMA_L_N]         =   new OneAttr(SchemaSymbols.ATT_SCHEMALOCATION,
+        allAttrs[ATT_SCHEMA_L_N]           = new OneAttr(SchemaSymbols.ATT_SCHEMALOCATION,
                                                         DT_ANYURI,
                                                         ATTIDX_SCHEMALOCATION,
                                                         null);
-        allAttrs[ATT_SOURCE_N]           =   new OneAttr(SchemaSymbols.ATT_SOURCE,
+        allAttrs[ATT_SOURCE_N]             = new OneAttr(SchemaSymbols.ATT_SOURCE,
                                                         DT_ANYURI,
                                                         ATTIDX_SOURCE,
                                                         null);
-        allAttrs[ATT_SUBSTITUTION_G_N]   =   new OneAttr(SchemaSymbols.ATT_SUBSTITUTIONGROUP,
+        allAttrs[ATT_SUBSTITUTION_G_N]     = new OneAttr(SchemaSymbols.ATT_SUBSTITUTIONGROUP,
                                                         DT_QNAME,
                                                         ATTIDX_SUBSGROUP,
                                                         null);
-        allAttrs[ATT_SYSTEM_N]           =   new OneAttr(SchemaSymbols.ATT_SYSTEM,
+        allAttrs[ATT_SYSTEM_N]             = new OneAttr(SchemaSymbols.ATT_SYSTEM,
                                                         DT_ANYURI,
                                                         ATTIDX_SYSTEM,
                                                         null);
-        allAttrs[ATT_TARGET_N_N]         =   new OneAttr(SchemaSymbols.ATT_TARGETNAMESPACE,
+        allAttrs[ATT_TARGET_N_N]           = new OneAttr(SchemaSymbols.ATT_TARGETNAMESPACE,
                                                         DT_ANYURI,
                                                         ATTIDX_TARGETNAMESPACE,
                                                         null);
-        allAttrs[ATT_TYPE_N]             =   new OneAttr(SchemaSymbols.ATT_TYPE,
+        allAttrs[ATT_TYPE_N]               = new OneAttr(SchemaSymbols.ATT_TYPE,
                                                         DT_QNAME,
                                                         ATTIDX_TYPE,
                                                         null);
-        allAttrs[ATT_USE_D]              =   new OneAttr(SchemaSymbols.ATT_USE,
+        allAttrs[ATT_USE_D]                = new OneAttr(SchemaSymbols.ATT_USE,
                                                         DT_USE,
                                                         ATTIDX_USE,
                                                         INT_USE_OPTIONAL);
-        allAttrs[ATT_VALUE_NNI_N]        =   new OneAttr(SchemaSymbols.ATT_VALUE,
+        allAttrs[ATT_VALUE_NNI_N]          = new OneAttr(SchemaSymbols.ATT_VALUE,
                                                         DT_NONNEGINT,
                                                         ATTIDX_VALUE,
                                                         null);
-        allAttrs[ATT_VALUE_PI_N]         =   new OneAttr(SchemaSymbols.ATT_VALUE,
+        allAttrs[ATT_VALUE_PI_N]           = new OneAttr(SchemaSymbols.ATT_VALUE,
                                                         DT_POSINT,
                                                         ATTIDX_VALUE,
                                                         null);
-        allAttrs[ATT_VALUE_STR_N]        =   new OneAttr(SchemaSymbols.ATT_VALUE,
+        allAttrs[ATT_VALUE_STR_N]          = new OneAttr(SchemaSymbols.ATT_VALUE,
                                                         DT_STRING,
                                                         ATTIDX_VALUE,
                                                         null);
-        allAttrs[ATT_VALUE_WS_N]         =   new OneAttr(SchemaSymbols.ATT_VALUE,
+        allAttrs[ATT_VALUE_WS_N]           = new OneAttr(SchemaSymbols.ATT_VALUE,
                                                         DT_WHITESPACE,
                                                         ATTIDX_VALUE,
                                                         null);
-        allAttrs[ATT_VERSION_N]          =   new OneAttr(SchemaSymbols.ATT_VERSION,
+        allAttrs[ATT_VERSION_N]            = new OneAttr(SchemaSymbols.ATT_VERSION,
                                                         DT_TOKEN,
                                                         ATTIDX_VERSION,
                                                         null);
-        allAttrs[ATT_XML_LANG]           =   new OneAttr(SchemaSymbols.ATT_XML_LANG,
+        allAttrs[ATT_XML_LANG]             = new OneAttr(SchemaSymbols.ATT_XML_LANG,
                                                         DT_LANGUAGE,
                                                         ATTIDX_XML_LANG,
                                                         null);
-        allAttrs[ATT_XPATH_R]            =   new OneAttr(SchemaSymbols.ATT_XPATH,
+        allAttrs[ATT_XPATH_R]              = new OneAttr(SchemaSymbols.ATT_XPATH,
                                                         DT_XPATH,
                                                         ATTIDX_XPATH,
                                                         null);
-        allAttrs[ATT_XPATH1_R]           =   new OneAttr(SchemaSymbols.ATT_XPATH,
+        allAttrs[ATT_XPATH1_R]             = new OneAttr(SchemaSymbols.ATT_XPATH,
                                                         DT_XPATH1,
                                                         ATTIDX_XPATH,
                                                         null);
-        allAttrs[ATT_TEST_XPATH_R]       =   new OneAttr(SchemaSymbols.ATT_TEST,
+
+        // XML Schema 1.1
+        allAttrs[ATT_APPLIESTO_EMPTY_D]    = new OneAttr(SchemaSymbols.ATT_APPLIESTOEMPTY,
+                                                        DT_BOOLEAN,
+                                                        ATTIDX_APPLIESTOEMPTY,
+                                                        Boolean.FALSE);
+        allAttrs[ATT_DEFAULT_ATTRIBUTES_N] = new OneAttr(SchemaSymbols.ATT_DEFAULTATTRIBUTES,
+                                                        DT_QNAME,
+                                                        ATTIDX_DEFAULTATTRIBUTES,
+                                                        null);
+        allAttrs[ATT_DEFAULT_ATTR_APPLY_D] = new OneAttr(SchemaSymbols.ATT_DEFAULTATTRIBUTESAPPLY,
+                                                        DT_BOOLEAN,
+                                                        ATTIDX_DEFAULTATTRAPPLY,
+                                                        Boolean.TRUE);
+        allAttrs[ATT_DEFAULT_XPATH_NS_N]   = new OneAttr(SchemaSymbols.ATT_XPATH_DEFAULT_NS,
+                                                        DT_XPATH_DEFAULT_NS,
+                                                        ATTIDX_XPATHDEFAULTNS,
+                                                        null);
+        allAttrs[ATT_MODE_D]               = new OneAttr(SchemaSymbols.ATT_MODE,
+                                                        DT_MODE,
+                                                        ATTIDX_MODE,
+                                                        INT_MODE_INTERLEAVE);
+        allAttrs[ATT_MODE1_D]              = new OneAttr(SchemaSymbols.ATT_MODE,
+                                                        DT_MODE1,
+                                                        ATTIDX_MODE,
+                                                        INT_MODE_INTERLEAVE);
+        allAttrs[ATT_TEST_XPATH_R]         = new OneAttr(SchemaSymbols.ATT_TEST,
                                                         DT_XPATH1,
                                                         ATTIDX_XPATH,
                                                         null);
-        
+
 
         // step 4: for each element, make a list of possible attributes
         Container attrList;
@@ -506,6 +530,8 @@
         // type = QName
         attrList.put(SchemaSymbols.ATT_TYPE, allAttrs[ATT_TYPE_N]);
         fEleAttrsMapG.put(SchemaSymbols.ELT_ATTRIBUTE, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_ATTRIBUTE, attrList);
 
         // for element "attribute" - local name
         attrList = Container.getContainer(7);
@@ -538,6 +564,8 @@
         // use = (optional | prohibited | required) : optional
         attrList.put(SchemaSymbols.ATT_USE, allAttrs[ATT_USE_D]);
         fEleAttrsMapL.put(ATTRIBUTE_R, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(ATTRIBUTE_R, attrList);
 
         // for element "element" - global
         attrList = Container.getContainer(10);
@@ -598,6 +626,8 @@
         // ref = QName
         attrList.put(SchemaSymbols.ATT_REF, allAttrs[ATT_REF_R]);
         fEleAttrsMapL.put(ELEMENT_R, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(ELEMENT_R, attrList);
 
         // for element "complexType" - global
         attrList = Container.getContainer(6);
@@ -626,7 +656,8 @@
         // system = anyURI
         attrList.put(SchemaSymbols.ATT_SYSTEM, allAttrs[ATT_SYSTEM_N]);
         fEleAttrsMapG.put(SchemaSymbols.ELT_NOTATION, attrList);
-
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_NOTATION, attrList);
 
         // for element "complexType" - local
         attrList = Container.getContainer(2);
@@ -641,6 +672,8 @@
         // id = ID
         attrList.put(SchemaSymbols.ATT_ID, allAttrs[ATT_ID_N]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_SIMPLECONTENT, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_SIMPLECONTENT, attrList);
 
         // for element "restriction" - local
         attrList = Container.getContainer(2);
@@ -649,6 +682,8 @@
         // id = ID
         attrList.put(SchemaSymbols.ATT_ID, allAttrs[ATT_ID_N]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_RESTRICTION, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_RESTRICTION, attrList);
 
         // for element "extension" - local
         attrList = Container.getContainer(2);
@@ -657,6 +692,8 @@
         // id = ID
         attrList.put(SchemaSymbols.ATT_ID, allAttrs[ATT_ID_N]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_EXTENSION, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_EXTENSION, attrList);
 
         // for element "attributeGroup" - local ref
         attrList = Container.getContainer(2);
@@ -665,6 +702,8 @@
         // ref = QName
         attrList.put(SchemaSymbols.ATT_REF, allAttrs[ATT_REF_R]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_ATTRIBUTEGROUP, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_ATTRIBUTEGROUP, attrList);
 
         // for element "anyAttribute" - local
         attrList = Container.getContainer(3);
@@ -683,6 +722,8 @@
         // mixed = boolean
         attrList.put(SchemaSymbols.ATT_MIXED, allAttrs[ATT_MIXED_N]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_COMPLEXCONTENT, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_COMPLEXCONTENT, attrList);
 
         // for element "attributeGroup" - global
         attrList = Container.getContainer(2);
@@ -691,6 +732,8 @@
         // name = NCName
         attrList.put(SchemaSymbols.ATT_NAME, allAttrs[ATT_NAME_R]);
         fEleAttrsMapG.put(SchemaSymbols.ELT_ATTRIBUTEGROUP, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_ATTRIBUTEGROUP, attrList);
 
         // for element "group" - global
         attrList = Container.getContainer(2);
@@ -699,6 +742,8 @@
         // name = NCName
         attrList.put(SchemaSymbols.ATT_NAME, allAttrs[ATT_NAME_R]);
         fEleAttrsMapG.put(SchemaSymbols.ELT_GROUP, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_GROUP, attrList);
 
         // for element "group" - local ref
         attrList = Container.getContainer(4);
@@ -711,6 +756,8 @@
         // ref = QName
         attrList.put(SchemaSymbols.ATT_REF, allAttrs[ATT_REF_R]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_GROUP, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_GROUP, attrList);
 
         // for element "all" - local
         attrList = Container.getContainer(3);
@@ -721,6 +768,8 @@
         // minOccurs = (0 | 1) : 1
         attrList.put(SchemaSymbols.ATT_MINOCCURS, allAttrs[ATT_MINOCCURS1_D]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_ALL, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_ALL, attrList);
 
         // for element "choice" - local
         attrList = Container.getContainer(3);
@@ -733,6 +782,11 @@
         fEleAttrsMapL.put(SchemaSymbols.ELT_CHOICE, attrList);
         // for element "sequence" - local
         fEleAttrsMapL.put(SchemaSymbols.ELT_SEQUENCE, attrList);
+        // XML Schema 1.1 - same list
+        // for element "choice" - local
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_CHOICE, attrList);
+        // for element "sequence" - local
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_SEQUENCE, attrList);
 
         // for element "any" - local
         attrList = Container.getContainer(5);
@@ -791,6 +845,9 @@
         fEleAttrsMapG.put(SchemaSymbols.ELT_ANNOTATION, attrList);
         // for element "annotation" - local
         fEleAttrsMapL.put(SchemaSymbols.ELT_ANNOTATION, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_ANNOTATION, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_ANNOTATION, attrList);
 
         // for element "appinfo" - local
         attrList = Container.getContainer(1);
@@ -798,6 +855,9 @@
         attrList.put(SchemaSymbols.ATT_SOURCE, allAttrs[ATT_SOURCE_N]);
         fEleAttrsMapG.put(SchemaSymbols.ELT_APPINFO, attrList);
         fEleAttrsMapL.put(SchemaSymbols.ELT_APPINFO, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_APPINFO, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_APPINFO, attrList);
 
         // for element "documentation" - local
         attrList = Container.getContainer(2);
@@ -807,6 +867,9 @@
         attrList.put(SchemaSymbols.ATT_XML_LANG, allAttrs[ATT_XML_LANG]);
         fEleAttrsMapG.put(SchemaSymbols.ELT_DOCUMENTATION, attrList);
         fEleAttrsMapL.put(SchemaSymbols.ELT_DOCUMENTATION, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_DOCUMENTATION, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_DOCUMENTATION, attrList);
 
         // for element "simpleType" - global
         attrList = Container.getContainer(3);
@@ -817,6 +880,8 @@
         // name = NCName
         attrList.put(SchemaSymbols.ATT_NAME, allAttrs[ATT_NAME_R]);
         fEleAttrsMapG.put(SchemaSymbols.ELT_SIMPLETYPE, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_SIMPLETYPE, attrList);
 
         // for element "simpleType" - local
         attrList = Container.getContainer(2);
@@ -825,6 +890,8 @@
         // id = ID
         attrList.put(SchemaSymbols.ATT_ID, allAttrs[ATT_ID_N]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_SIMPLETYPE, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_SIMPLETYPE, attrList);
 
         // for element "restriction" - local
         // already registered for complexType
@@ -836,6 +903,8 @@
         // itemType = QName
         attrList.put(SchemaSymbols.ATT_ITEMTYPE, allAttrs[ATT_ITEMTYPE_N]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_LIST, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_LIST, attrList);
 
         // for element "union" - local
         attrList = Container.getContainer(2);
@@ -844,6 +913,8 @@
         // memberTypes = List of QName
         attrList.put(SchemaSymbols.ATT_MEMBERTYPES, allAttrs[ATT_MEMBER_T_N]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_UNION, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_UNION, attrList);
 
         // for element "schema" - global
         attrList = Container.getContainer(8);
@@ -874,6 +945,9 @@
         fEleAttrsMapG.put(SchemaSymbols.ELT_INCLUDE, attrList);
         // for element "redefine" - global
         fEleAttrsMapG.put(SchemaSymbols.ELT_REDEFINE, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_INCLUDE, attrList);
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_REDEFINE, attrList);
 
         // for element "import" - global
         attrList = Container.getContainer(3);
@@ -884,6 +958,8 @@
         // schemaLocation = anyURI
         attrList.put(SchemaSymbols.ATT_SCHEMALOCATION, allAttrs[ATT_SCHEMA_L_N]);
         fEleAttrsMapG.put(SchemaSymbols.ELT_IMPORT, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_IMPORT, attrList);
 
         // for element "length" - local
         attrList = Container.getContainer(3);
@@ -900,6 +976,11 @@
         fEleAttrsMapL.put(SchemaSymbols.ELT_MAXLENGTH, attrList);
         // for element "fractionDigits" - local
         fEleAttrsMapL.put(SchemaSymbols.ELT_FRACTIONDIGITS, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_LENGTH, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_MINLENGTH, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_MAXLENGTH, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_FRACTIONDIGITS, attrList);
 
         // for element "totalDigits" - local
         attrList = Container.getContainer(3);
@@ -910,6 +991,8 @@
         // fixed = boolean : false
         attrList.put(SchemaSymbols.ATT_FIXED, allAttrs[ATT_FIXED_D]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_TOTALDIGITS, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_TOTALDIGITS, attrList);
 
         // for element "pattern" - local
         attrList = Container.getContainer(2);
@@ -918,6 +1001,8 @@
         // value = string
         attrList.put(SchemaSymbols.ATT_VALUE, allAttrs[ATT_VALUE_STR_N]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_PATTERN, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_PATTERN, attrList);
 
         // for element "enumeration" - local
         attrList = Container.getContainer(2);
@@ -926,6 +1011,8 @@
         // value = anySimpleType
         attrList.put(SchemaSymbols.ATT_VALUE, allAttrs[ATT_VALUE_STR_N]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_ENUMERATION, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_ENUMERATION, attrList);
 
         // for element "whiteSpace" - local
         attrList = Container.getContainer(3);
@@ -936,6 +1023,8 @@
         // fixed = boolean : false
         attrList.put(SchemaSymbols.ATT_FIXED, allAttrs[ATT_FIXED_D]);
         fEleAttrsMapL.put(SchemaSymbols.ELT_WHITESPACE, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_WHITESPACE, attrList);
 
         // for element "maxInclusive" - local
         attrList = Container.getContainer(3);
@@ -952,8 +1041,90 @@
         fEleAttrsMapL.put(SchemaSymbols.ELT_MININCLUSIVE, attrList);
         // for element "minExclusive" - local
         fEleAttrsMapL.put(SchemaSymbols.ELT_MINEXCLUSIVE, attrList);
+        // XML Schema 1.1 - same list
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_MAXINCLUSIVE, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_MAXEXCLUSIVE, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_MININCLUSIVE, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_MINEXCLUSIVE, attrList);
+
 
         // XML Schema 1.1
+        // same components - modified representation
+
+        // for element "schema" - global
+        attrList = Container.getContainer(10);
+        // attributeFormDefault = (qualified | unqualified) : unqualified
+        attrList.put(SchemaSymbols.ATT_ATTRIBUTEFORMDEFAULT, allAttrs[ATT_ATTRIBUTE_FD_D]);
+        // defaultAttributes = xs:QName
+        attrList.put(SchemaSymbols.ATT_DEFAULTATTRIBUTES, allAttrs[ATT_DEFAULT_ATTRIBUTES_N]);
+        // blockDefault = (#all | List of (extension | restriction | substitution))  : ''
+        attrList.put(SchemaSymbols.ATT_BLOCKDEFAULT, allAttrs[ATT_BLOCK_D_D]);
+        // xpathDefaultNamespace = (anyURI | (##defaultNamespace | ##targetNamespace | ##local))  : ##local
+        attrList.put(SchemaSymbols.ATT_XPATH_DEFAULT_NS, allAttrs[ATT_DEFAULT_XPATH_NS_N]);
+        // elementFormDefault = (qualified | unqualified) : unqualified
+        attrList.put(SchemaSymbols.ATT_ELEMENTFORMDEFAULT, allAttrs[ATT_ELEMENT_FD_D]);
+        // finalDefault = (#all | List of (extension | restriction | list | union))  : ''
+        attrList.put(SchemaSymbols.ATT_FINALDEFAULT, allAttrs[ATT_FINAL_D_D]);
+        // id = ID
+        attrList.put(SchemaSymbols.ATT_ID, allAttrs[ATT_ID_N]);
+        // targetNamespace = anyURI
+        attrList.put(SchemaSymbols.ATT_TARGETNAMESPACE, allAttrs[ATT_TARGET_N_N]);
+        // version = token
+        attrList.put(SchemaSymbols.ATT_VERSION, allAttrs[ATT_VERSION_N]);
+        // xml:lang = language
+        attrList.put(SchemaSymbols.ATT_XML_LANG, allAttrs[ATT_XML_LANG]);
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_SCHEMA, attrList);
+
+        // for element "complexType" - global
+        attrList = Container.getContainer(7);
+        // abstract = boolean : false
+        attrList.put(SchemaSymbols.ATT_ABSTRACT, allAttrs[ATT_ABSTRACT_D]);
+        // block = (#all | List of (extension | restriction))
+        attrList.put(SchemaSymbols.ATT_BLOCK, allAttrs[ATT_BLOCK1_N]);
+        // final = (#all | List of (extension | restriction))
+        attrList.put(SchemaSymbols.ATT_FINAL, allAttrs[ATT_FINAL_N]);
+        // id = ID
+        attrList.put(SchemaSymbols.ATT_ID, allAttrs[ATT_ID_N]);
+        // mixed = boolean : false
+        attrList.put(SchemaSymbols.ATT_MIXED, allAttrs[ATT_MIXED_D]);
+        // name = NCName
+        attrList.put(SchemaSymbols.ATT_NAME, allAttrs[ATT_NAME_R]);
+        // defaultAttributesApply = boolean : true
+        attrList.put(SchemaSymbols.ATT_DEFAULTATTRIBUTESAPPLY, allAttrs[ATT_DEFAULT_ATTR_APPLY_D]);        
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_COMPLEXTYPE, attrList);
+        
+        // for element "complexType" - local
+        attrList = Container.getContainer(3);
+        // id = ID
+        attrList.put(SchemaSymbols.ATT_ID, allAttrs[ATT_ID_N]);
+        // mixed = boolean : false
+        attrList.put(SchemaSymbols.ATT_MIXED, allAttrs[ATT_MIXED_D]);
+        // defaultAttributesApply = boolean : true
+        attrList.put(SchemaSymbols.ATT_DEFAULTATTRIBUTESAPPLY, allAttrs[ATT_DEFAULT_ATTR_APPLY_D]);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_COMPLEXTYPE, attrList);
+
+        // for element "selector" - local
+        attrList = Container.getContainer(3);
+        // id = ID
+        attrList.put(SchemaSymbols.ATT_ID, allAttrs[ATT_ID_N]);
+        // xpath = a subset of XPath expression
+        attrList.put(SchemaSymbols.ATT_XPATH, allAttrs[ATT_XPATH_R]);
+        // xpathDefaultNamespace = (anyURI | (##defaultNamespace | ##targetNamespace | ##local))
+        attrList.put(SchemaSymbols.ATT_XPATH_DEFAULT_NS, allAttrs[ATT_DEFAULT_XPATH_NS_N]);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_SELECTOR, attrList);
+
+        // for element "field" - local
+        attrList = Container.getContainer(3);
+        // id = ID
+        attrList.put(SchemaSymbols.ATT_ID, allAttrs[ATT_ID_N]);
+        // xpath = a subset of XPath expression
+        attrList.put(SchemaSymbols.ATT_XPATH, allAttrs[ATT_XPATH1_R]);
+        // xpathDefaultNamespace = (anyURI | (##defaultNamespace | ##targetNamespace | ##local))
+        attrList.put(SchemaSymbols.ATT_XPATH_DEFAULT_NS, allAttrs[ATT_DEFAULT_XPATH_NS_N]);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_FIELD, attrList);
+
+
+        // new components
 
         // for element "alternative" - local
         attrList = Container.getContainer(4);
@@ -965,8 +1136,7 @@
         attrList.put(SchemaSymbols.ATT_TYPE, allAttrs[ATT_TYPE_N]);
         // xpathDefaultNamespace = (anyURI | (##defaultNamespace | ##targetNamespace | ##local))
         attrList.put(SchemaSymbols.ATT_XPATH_DEFAULT_NS, allAttrs[ATT_DEFAULT_XPATH_NS_N]);
-        // TODO: use 1.1 map
-        fEleAttrsMapL.put(SchemaSymbols.ELT_ALTERNATIVE, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_ALTERNATIVE, attrList);
         
         // for element "assert" - local // mukul
         attrList = Container.getContainer(3);
@@ -976,7 +1146,7 @@
         attrList.put(SchemaSymbols.ATT_TEST, allAttrs[ATT_TEST_XPATH_R]);
         // xpathDefaultNamespace = (anyURI | (##defaultNamespace | ##targetNamespace | ##local))
         attrList.put(SchemaSymbols.ATT_XPATH_DEFAULT_NS, allAttrs[ATT_DEFAULT_XPATH_NS_N]);
-        fEleAttrsMapL.put(SchemaSymbols.ELT_ASSERT, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_ASSERT, attrList);
 
         // for element "defaultOpenContent" - global
         attrList = Container.getContainer(3);
@@ -986,7 +1156,7 @@
         attrList.put(SchemaSymbols.ATT_ID, allAttrs[ATT_ID_N]);
         // mode = (interleave | suffix) : interleave
         attrList.put(SchemaSymbols.ATT_MODE, allAttrs[ATT_MODE_D]);
-        /*fEleAttrs11MapG*/fEleAttrsMapG.put(SchemaSymbols.ELT_DEFAULTOPENCONTENT, attrList);
+        fEleAttrs11MapG.put(SchemaSymbols.ELT_DEFAULTOPENCONTENT, attrList);
 
         // for element "openContent" - local
         attrList = Container.getContainer(2);
@@ -994,7 +1164,7 @@
         attrList.put(SchemaSymbols.ATT_ID, allAttrs[ATT_ID_N]);
         // mode = (none | interleave | suffix) : interleave
         attrList.put(SchemaSymbols.ATT_MODE, allAttrs[ATT_MODE1_D]);
-        /*fEleAttrs11MapL*/fEleAttrsMapL.put(SchemaSymbols.ELT_OPENCONTENT, attrList);
+        fEleAttrs11MapL.put(SchemaSymbols.ELT_OPENCONTENT, attrList);
     }
 
     // used to resolver namespace prefixes
@@ -1070,7 +1240,8 @@
             reportSchemaError("s4s-elt-schema-ns", new Object[] {elName}, element);
         }
 
-        Hashtable eleAttrsMap = fEleAttrsMapG;
+        Hashtable eleAttrsMap = (fSchemaHandler.fSchemaVersion < Constants.SCHEMA_VERSION_1_1)
+               ? fEleAttrsMapG : fEleAttrs11MapG;
         String lookupName = elName;
 
         // REVISIT: only local element and attribute are different from others.
@@ -1078,7 +1249,8 @@
         //          are only allowed to have one of name or ref, or neither of them.
         //          we'd better move such checking to the traverser.
         if (!isGlobal) {
-            eleAttrsMap = fEleAttrsMapL;
+            eleAttrsMap = (fSchemaHandler.fSchemaVersion < Constants.SCHEMA_VERSION_1_1)
+                ? fEleAttrsMapL : fEleAttrs11MapL;
             if (elName.equals(SchemaSymbols.ELT_ELEMENT)) {
                 if (DOMUtil.getAttr(element, SchemaSymbols.ATT_REF) != null)
                     lookupName = ELEMENT_R;
@@ -1621,7 +1793,7 @@
             retValue = null;
             if (value.equals(SchemaSymbols.ATTVAL_TWOPOUNDTARGETNS)) {
                 retValue = schemaDoc.fTargetNamespace;
-            } else if (value.equals(SchemaSymbols.ATTVAL_TWOPOUNDDDEFAULTNS)) {
+            } else if (value.equals(SchemaSymbols.ATTVAL_TWOPOUNDDEFAULTNS)) {
                 retValue = schemaDoc.fValidationContext.getURI(XMLSymbols.EMPTY_STRING);
                 if (retValue != null) {
                     retValue = fSymbolTable.addSymbol((String)retValue);

Modified: xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDComplexTypeTraverser.java
URL: http://svn.apache.org/viewvc/xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDComplexTypeTraverser.java?rev=697134&r1=697133&r2=697134&view=diff
==============================================================================
--- xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDComplexTypeTraverser.java (original)
+++ xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDComplexTypeTraverser.java Fri Sep 19 08:36:02 2008
@@ -274,6 +274,21 @@
         Element child = null;
         
         try {
+            // XML Schema 1.1 - {attribute uses}
+            //
+            // If the defaultAttributesApply [attribute] of the <complexType> element is not present
+            // or has actual value 'true', and the <schema> ancestor has an defaultAttributes attribute,
+            // then properties {attribute uses} and {attribute wildcard} are computed as if there were
+            // an <attributeGroup> [child] with empty content and a ref [attribute] whose actual value is
+            // the same as that of the defaultAttributes [attribute].
+            if (fSchemaHandler.fSchemaVersion == Constants.SCHEMA_VERSION_1_1) {
+                /* NOTE: default value is true; i.e. if attribute is missing its value defaults to true */
+                Boolean defaultAttributeAppliesAttr = (Boolean) attrValues[XSAttributeChecker.ATTIDX_DEFAULTATTRAPPLY];
+                if (defaultAttributeAppliesAttr.booleanValue() == true && schemaDoc.fDefaultAGroup != null) {
+                    mergeAttributes(schemaDoc.fDefaultAGroup, fAttrGrp, fName, true, complexTypeDecl);
+                }
+            }
+
             // ---------------------------------------------------------------
             // First, handle any ANNOTATION declaration and get next child
             // ---------------------------------------------------------------

Modified: xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDHandler.java
URL: http://svn.apache.org/viewvc/xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDHandler.java?rev=697134&r1=697133&r2=697134&view=diff
==============================================================================
--- xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDHandler.java (original)
+++ xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDHandler.java Fri Sep 19 08:36:02 2008
@@ -39,6 +39,7 @@
 import org.apache.xerces.impl.xs.SchemaSymbols;
 import org.apache.xerces.impl.xs.XMLSchemaException;
 import org.apache.xerces.impl.xs.XMLSchemaLoader;
+import org.apache.xerces.impl.xs.XSAttributeGroupDecl;
 import org.apache.xerces.impl.xs.XSComplexTypeDecl;
 import org.apache.xerces.impl.xs.XSDDescription;
 import org.apache.xerces.impl.xs.XSDeclarationPool;
@@ -1292,6 +1293,16 @@
             }
             Element currRoot = currDoc;
             boolean sawAnnotation = false;
+
+            // if XML Schema 1.1, set default attribute group 
+            if (fSchemaVersion == Constants.SCHEMA_VERSION_1_1) {
+                // Check that we have a 'defaultAttributes' and that we have not already processed it
+                if (currSchemaDoc.fDefaultAttributes != null && currSchemaDoc.fDefaultAGroup != null) {
+                    currSchemaDoc.fDefaultAGroup = (XSAttributeGroupDecl) getGlobalDecl(
+                            currSchemaDoc, XSDHandler.ATTRIBUTEGROUP_TYPE, currSchemaDoc.fDefaultAttributes, currRoot);
+                }
+            }
+
             // traverse this schema's global decls
             for (Element globalComp =
                 DOMUtil.getFirstVisibleChildElement(currRoot, fHiddenNodes);



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@xerces.apache.org
For additional commands, e-mail: commits-help@xerces.apache.org


Mime
View raw message