svn commit: r1155198 - /xerces/java/branches/xml-schema-1.1-dev/samples/jaxp/SourceValidator.java

2011-08-08 Thread mukulg
Author: mukulg
Date: Tue Aug  9 03:41:04 2011
New Revision: 1155198

URL: http://svn.apache.org/viewvc?rev=1155198&view=rev
Log:
schema 1.1 change: a minor change for help text (to make it consistent with 
other help text strings) in jaxp.SourceValidator sample.

Modified:
xerces/java/branches/xml-schema-1.1-dev/samples/jaxp/SourceValidator.java

Modified: 
xerces/java/branches/xml-schema-1.1-dev/samples/jaxp/SourceValidator.java
URL: 
http://svn.apache.org/viewvc/xerces/java/branches/xml-schema-1.1-dev/samples/jaxp/SourceValidator.java?rev=1155198&r1=1155197&r2=1155198&view=diff
==
--- xerces/java/branches/xml-schema-1.1-dev/samples/jaxp/SourceValidator.java 
(original)
+++ xerces/java/branches/xml-schema-1.1-dev/samples/jaxp/SourceValidator.java 
Tue Aug  9 03:41:04 2011
@@ -602,7 +602,7 @@ public class SourceValidator 
 System.err.println("  -ga | -GA   Turn on/off generation of synthetic 
schema annotations.");
 System.err.println("  NOTE: Not supported by all schema 
factories and validators.");
 System.err.println("  -m  | -MTurn on/off memory usage report");
-System.err.println("  -xsd11  Turn on XSD 1.1 support.");
+System.err.println("  -xsd11  Turn on/off XSD 1.1 support.");
 System.err.println("  -h  This help screen.");
 
 System.err.println();



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



svn commit: r1155193 - /xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java

2011-08-08 Thread mrglavas
Author: mrglavas
Date: Tue Aug  9 02:29:14 2011
New Revision: 1155193

URL: http://svn.apache.org/viewvc?rev=1155193&view=rev
Log:
Fixing JIRA Issue #1520: http://issues.apache.org/jira/browse/XERCESJ-1520. 
Corrects several problems with rehash() and removeEntry(), in particular a case 
where we were double counting cleared SoftReferences which could lead to fCount 
becoming negative.

Modified:

xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java

Modified: 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java
URL: 
http://svn.apache.org/viewvc/xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java?rev=1155193&r1=1155192&r2=1155193&view=diff
==
--- 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java
 (original)
+++ 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java
 Tue Aug  9 02:29:14 2011
@@ -225,13 +225,16 @@ public class SoftReferenceSymbolTable ex
 if (newTable[index] != null) {
 newTable[index].prev = e;
 }
+e.bucket = index;
 e.next = newTable[index];
-e.prev = null;
 newTable[index] = e;
 }
 else {
-fCount--;
+e.bucket = -1;
+e.next = null;
+--fCount;
 }
+e.prev = null;
 }
 }
 }
@@ -298,16 +301,19 @@ public class SoftReferenceSymbolTable ex
 } // containsSymbol(char[],int,int):boolean
 
 private void removeEntry(SREntry entry) {
-if (entry.next != null) {
-entry.next.prev = entry.prev;
-}
-if (entry.prev != null) {
-entry.prev.next = entry.next;
-}
-else {
-fBuckets[entry.bucket] = entry.next;
+final int bucket = entry.bucket;
+if (bucket >= 0) {
+if (entry.next != null) {
+entry.next.prev = entry.prev;
+}
+if (entry.prev != null) {
+entry.prev.next = entry.next;
+}
+else {
+fBuckets[bucket] = entry.next;
+}
+--fCount;
 }
-fCount--;
 }
 
 /**
@@ -339,6 +345,7 @@ public class SoftReferenceSymbolTable ex
 /** The previous entry. */
 public SREntry prev;
 
+/** The bucket this entry is contained in; -1 if it has been removed 
from the table. */
 public int bucket;
 
 //



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



svn commit: r1155192 - /xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java

2011-08-08 Thread mrglavas
Author: mrglavas
Date: Tue Aug  9 02:28:48 2011
New Revision: 1155192

URL: http://svn.apache.org/viewvc?rev=1155192&view=rev
Log:
Fixing JIRA Issue #1520: http://issues.apache.org/jira/browse/XERCESJ-1520. 
Corrects several problems with rehash() and removeEntry(), in particular a case 
where we were double counting cleared SoftReferences which could lead to fCount 
becoming negative.

Modified:
xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java

Modified: 
xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java
URL: 
http://svn.apache.org/viewvc/xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java?rev=1155192&r1=1155191&r2=1155192&view=diff
==
--- xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java 
(original)
+++ xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java 
Tue Aug  9 02:28:48 2011
@@ -225,13 +225,16 @@ public class SoftReferenceSymbolTable ex
 if (newTable[index] != null) {
 newTable[index].prev = e;
 }
+e.bucket = index;
 e.next = newTable[index];
-e.prev = null;
 newTable[index] = e;
 }
 else {
-fCount--;
+e.bucket = -1;
+e.next = null;
+--fCount;
 }
+e.prev = null;
 }
 }
 }
@@ -298,16 +301,19 @@ public class SoftReferenceSymbolTable ex
 } // containsSymbol(char[],int,int):boolean
 
 private void removeEntry(SREntry entry) {
-if (entry.next != null) {
-entry.next.prev = entry.prev;
-}
-if (entry.prev != null) {
-entry.prev.next = entry.next;
-}
-else {
-fBuckets[entry.bucket] = entry.next;
+final int bucket = entry.bucket;
+if (bucket >= 0) {
+if (entry.next != null) {
+entry.next.prev = entry.prev;
+}
+if (entry.prev != null) {
+entry.prev.next = entry.next;
+}
+else {
+fBuckets[bucket] = entry.next;
+}
+--fCount;
 }
-fCount--;
 }
 
 /**
@@ -339,6 +345,7 @@ public class SoftReferenceSymbolTable ex
 /** The previous entry. */
 public SREntry prev;
 
+/** The bucket this entry is contained in; -1 if it has been removed 
from the table. */
 public int bucket;
 
 //



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



[Xerces Wiki] Update of "xmlschema11SaxonicaTests" by Mukul Gandhi

2011-08-08 Thread Apache Wiki
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Xerces Wiki" for change 
notification.

The "xmlschema11SaxonicaTests" page has been changed by Mukul Gandhi:
http://wiki.apache.org/xerces/xmlschema11SaxonicaTests?action=diff&rev1=11&rev2=12

  || || ||<:>id008|| || || || ||
  ||<:>29.|| || ||<:>id008.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>30.|| || || ||<:>id008.v01.xml||<: #CCFF99>valid||<: #CCFF99>valid||
- ||<:>31.|| || || ||<:>id008.v02.xml||<: #FFCC99>valid||<: #FFCC99>invalid||
- ||<:>32.|| || || ||<:>id008.v03.xml||<: #FFCC99>valid||<: #FFCC99>invalid||
+ ||<:>31.|| || || ||<:>id008.v02.xml||<: #CCFF99>invalid||<: #CCFF99>invalid||
+ ||<:>32.|| || || ||<:>id008.v03.xml||<: #CCFF99>invalid||<: #CCFF99>invalid||
  || || ||<:>id009|| || || || ||
  ||<:>33.|| || ||<:>id009.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>34.|| || || ||<:>id009.v01.xml||<: #CCFF99>valid||<: #CCFF99>valid||
@@ -1606, +1606 @@

  ||<:>193.|| || || ||<:>wild060.n2.xml||<: #CCFF99>invalid||<: 
#CCFF99>invalid||
  || || ||<:>wild061|| || || || ||
  ||<:>194.|| || ||<:>wild061.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
- ||<:>195.|| || || ||<:>wild061.n1.xml||<: #FFCC99>invalid||<: #FFCC99>valid||
+ ||<:>195.|| || || ||<:>wild061.n1.xml||<: #CCFF99>invalid||<: 
#CCFF99>invalid||
  || || ||<:>wild062|| || || || ||
  ||<:>196.|| || ||<:>wild062.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>197.|| || || ||<:>wild062.v1.xml||<: #CCFF99>valid||<: #CCFF99>valid||
- ||<:>198.|| || || ||<:>wild062.n1.xml||<: #FFCC99>invalid||<: #FFCC99>valid||
+ ||<:>198.|| || || ||<:>wild062.n1.xml||<: #CCFF99>invalid||<: 
#CCFF99>invalid||
- ||<:>199.|| || || ||<:>wild062.n2.xml||<: #FFCC99>invalid||<: #FFCC99>valid||
+ ||<:>199.|| || || ||<:>wild062.n2.xml||<: #CCFF99>invalid||<: 
#CCFF99>invalid||
- ||<:>200.|| || || ||<:>wild062.n3.xml||<: #FFCC99>invalid||<: #FFCC99>valid||
+ ||<:>200.|| || || ||<:>wild062.n3.xml||<: #CCFF99>invalid||<: 
#CCFF99>invalid||
  || || ||<:>wild063|| || || || ||
  ||<:>201.|| || ||<:>wild063.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>202.|| || || ||<:>wild063.v1.xml||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>203.|| || || ||<:>wild063.v2.xml||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>204.|| || || ||<:>wild063.n1.xml||<: #CCFF99>invalid||<: 
#CCFF99>invalid||
- ||<:>205.|| || || ||<:>wild063.n2.xml||<: #FFCC99>invalid||<: #FFCC99>valid||
+ ||<:>205.|| || || ||<:>wild063.n2.xml||<: #CCFF99>invalid||<: 
#CCFF99>invalid||
  || || ||<:>wild064|| || || || ||
  ||<:>206.|| || ||<:>wild064.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>207.|| || || ||<:>wild064.v1.xml||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>208.|| || || ||<:>wild064.v2.xml||<: #CCFF99>valid||<: #CCFF99>valid||
- ||<:>209.|| || || ||<:>wild064.n1.xml||<: #FFCC99>invalid||<: #FFCC99>valid||
+ ||<:>209.|| || || ||<:>wild064.n1.xml||<: #CCFF99>invalid||<: 
#CCFF99>invalid||
  || || ||<:>wild065|| || || || ||
  ||<:>210.|| || ||<:>wild065.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>211.|| || || ||<:>wild065.v1.xml||<: #CCFF99>valid||<: #CCFF99>valid||
@@ -1633, +1633 @@

  ||<:>214.|| || || ||<:>wild066.v1.xml||<: #CCFF99>valid||<: #CCFF99>valid||
  || || ||<:>wild067|| || || || ||
  ||<:>215.|| || ||<:>wild067.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
- ||<:>216.|| || || ||<:>wild067.n1.xml||<: #FFCC99>invalid||<: #FFCC99>valid||
+ ||<:>216.|| || || ||<:>wild067.n1.xml||<: #CCFF99>invalid||<: 
#CCFF99>invalid||
  || || ||<:>wild068|| || || || ||
  ||<:>217.|| || ||<:>wild068.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>218.|| || || ||<:>wild068.n1.xml||<: #FFCC99>invalid||<: #FFCC99>valid||
@@ -1667, +1667 @@

  || || ||<:>wild075|| || || || ||
  ||<:>240.|| || ||<:>wild075.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>241.|| || || ||<:>wild075.v1.xml||<: #CCFF99>valid||<: #CCFF99>valid||
- ||<:>242.|| || || ||<:>wild075.n1.xml||<: #FFCC99>invalid||<: #FFCC99>valid||
+ ||<:>242.|| || || ||<:>wild075.n1.xml||<: #CCFF99>invalid||<: 
#CCFF99>invalid||
  || || ||<:>wild076|| || || || ||
  ||<:>243.|| || ||<:>wild076.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>244.|| || || ||<:>wild076.v1.xml||<: #CCFF99>valid||<: #CCFF99>valid||
- ||<:>245.|| || || ||<:>wild076.n1.xml||<: #FFCC99>invalid||<: #FFCC99>valid||
+ ||<:>245.|| || || ||<:>wild076.n1.xml||<: #CCFF99>invalid||<: 
#CCFF99>invalid||
  || || ||<:>wild077|| || || || ||
  ||<:>246.|| || ||<:>wild077.xsd|| ||<: #CCFF99>valid||<: #CCFF99>valid||
  ||<:>247.|| || || ||<:>wild077.v1.xml||<: #CCFF99>valid||<: #CCFF99>valid||

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



[Xerces Wiki] Update of "xmlschema11TestSuiteReports" by Mukul Gandhi

2011-08-08 Thread Apache Wiki
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Xerces Wiki" for change 
notification.

The "xmlschema11TestSuiteReports" page has been changed by Mukul Gandhi:
http://wiki.apache.org/xerces/xmlschema11TestSuiteReports?action=diff&rev1=14&rev2=15

Comment:
updating test suite results after latest implementation changes

  '''__XERCES XML Schema 1.1 test-suite results__'''
  
- Xerces SVN Revision: 1152244
+ Xerces SVN Revision: 1155074
  
  (1) __Xerces running IBM XML Schema 1.1 Tests__
  
  ''Summary'':
  ||Total Tests ||Tests passed ||Success % ||
- ||969 ||955 
||98.56 ||
+ ||969 ||954 
||98.45 ||
  
  
  
@@ -19, +19 @@

  
  ''Summary'':
  ||Total Tests ||Tests passed ||Success % ||
- ||1329 ||1251 
||94.13 ||
+ ||1329 ||1260 
||94.81 ||
  
  
  
@@ -28, +28 @@

  
  '''Overall Test Suite run status:'''
  ||Total Tests ||Tests passed ||Success % ||
- ||2298 ||2206 
||96.00 ||
+ ||2298 ||2214 
||96.34 ||
  
  
  

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



svn commit: r1155074 - /xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties

2011-08-08 Thread knoaman
Author: knoaman
Date: Mon Aug  8 20:03:23 2011
New Revision: 1155074

URL: http://svn.apache.org/viewvc?rev=1155074&view=rev
Log:
Element Delcaration Consistent
When matching a wildcard, the type of the matched global declaration must be 
same or validly derived from the type of any local element delcaration with the 
same name

Modified:

xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties

Modified: 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties
URL: 
http://svn.apache.org/viewvc/xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties?rev=1155074&r1=1155073&r2=1155074&view=diff
==
--- 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties
 (original)
+++ 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/msg/XMLSchemaMessages.properties
 Mon Aug  8 20:03:23 2011
@@ -206,7 +206,8 @@
 cos-ct-extends.1.4.3.2.2.3.4 = cos-ct-extends.1.4.3.2.2.3.4: The 
namespace constraint of the wildcard on the open content of the base type must 
be a subset of the namespace constraint of the wildcard on the open content of 
the derived type. This is not the case for type ''{0}''.
 cos-content-act-restrict.5.3 = cos-content-act-restrict.5.3: Error for 
type ''{0}''. The attribute use ''{1}'' in this type has value of 
''inheritable'', which is inconsistent with the value in the base type.
 cos-element-consistent = cos-element-consistent: Error for type 
''{0}''. Multiple elements with name ''{1}'', with different types, appear in 
the model group.
-cos-element-consistent.4 = cos-element-consistent.4: Error for type 
''{0}''. Multiple elements with name ''{1}'', with non equivalent type tables, 
appear in the model group.
+cos-element-consistent.4.a = cos-element-consistent.4: A wildcard 
matched a global element ''{0}'' whose type ''{1}'' is not validly derived from 
the type definition, ''{2}'', of a local element with the same name.
+cos-element-consistent.4.b = cos-element-consistent.4: Error for type 
''{0}''. Multiple elements with name ''{1}'', with non equivalent type tables, 
appear in the model group.
 cos-list-of-atomic = cos-list-of-atomic: In the definition of list 
type ''{0}'', type ''{1}'' is an invalid list element type because it is not 
atomic (''{1}'' is either a list type, or a union type which contains a list).
 cos-nonambig = cos-nonambig: {0} and {1} (or elements from their 
substitution group) violate \"Unique Particle Attribution\". During validation 
against this schema, ambiguity would be created for those two particles.
 cos-particle-extends.3.1 = cos-particle-extends.3.1: When both a 
derived type and its base have particles with  as their {term}s, the 
minOccurs of the derived particle needs to be equal to that of its base.



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



svn commit: r1155073 - in /xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs: ./ models/ traversers/

2011-08-08 Thread knoaman
Author: knoaman
Date: Mon Aug  8 20:02:50 2011
New Revision: 1155073

URL: http://svn.apache.org/viewvc?rev=1155073&view=rev
Log:
Element Delcaration Consistent
When matching a wildcard, the type of the matched global declaration must be 
same or validly derived from the type of any local element delcaration with the 
same name

Modified:

xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java

xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/XSConstraints.java

xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/models/XS11AllCM.java

xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/models/XSAllCM.java

xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/models/XSCMValidator.java

xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/models/XSDFACM.java

xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/models/XSEmptyCM.java

xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/traversers/XSDHandler.java

Modified: 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java
URL: 
http://svn.apache.org/viewvc/xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java?rev=1155073&r1=1155072&r2=1155073&view=diff
==
--- 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java
 (original)
+++ 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java
 Mon Aug  8 20:02:50 2011
@@ -410,7 +410,9 @@ public class XMLSchemaValidator
  * While parsing a document, keep the location of the document.
  */
 private XMLLocator fLocator;
-
+
+private ArrayList fXSITypeErrors = new ArrayList(4);
+
 private IDContext fIDContext = null;
 
 /**
@@ -2230,6 +2232,8 @@ public class XMLSchemaValidator
 }
 
 // if no decl/type found for the current element
+final boolean isSchema11 = (fSchemaVersion == 
Constants.SCHEMA_VERSION_1_1);
+boolean needToPushErrorContext = false;
 if (fCurrentType == null && xsiType == null) {
 // if this is the validation root, report an error, because
 // we can't find eith decl or type for this element
@@ -2289,17 +2293,35 @@ public class XMLSchemaValidator
 // push error reporter context: record the current position
 // This has to happen after we process skip contents,
 // otherwise push and pop won't be correctly paired.
-fXSIErrorReporter.pushContext();
+if (isSchema11) {
+needToPushErrorContext = true;
+}
+else {
+fXSIErrorReporter.pushContext();
+}
 } else {
 // push error reporter context: record the current position
 // This has to happen after we process skip contents,
 // otherwise push and pop won't be correctly paired.
-fXSIErrorReporter.pushContext();
+if (isSchema11) {
+needToPushErrorContext = true;
+}
+else {
+fXSIErrorReporter.pushContext();
+}
 
 // get xsi:type
 if (xsiType != null) {
 XSTypeDefinition oldType = fCurrentType;
-fCurrentType = getAndCheckXsiType(element, xsiType, 
attributes);
+if (isSchema11) {
+if (fXSITypeErrors.size() > 0) {
+fXSITypeErrors.clear();
+}
+fCurrentType = getAndCheckXsiType(element, xsiType, 
attributes, fXSITypeErrors);
+}
+else {
+fCurrentType = getAndCheckXsiType(element, xsiType, 
attributes);
+}
 // If it fails, use the old type. Use anyType if ther is no 
old type.
 if (fCurrentType == null) {
 if (oldType == null)
@@ -2325,6 +2347,39 @@ public class XMLSchemaValidator
 }
 }
 
+// EDC rule
+if (isSchema11) {
+if (wildcard != null && fCurrentCM != null) {
+XSElementDecl elemDecl = 
fCurrentCM.findMatchingElemDecl(element, fSubGroupHandler);
+if (elemDecl != null) {
+final XSTypeDefinition elemType = 
elemDecl.getTypeDefinition();
+// types need to be equivalent
+if (fCurrentType != elemType) {
+short block = elemDecl.fBlock;
+if (elemType.getTypeCategory() == 
XSTypeDefinition.COMPLEX_TYPE) {
+block |= ((XSComplexTypeDecl) elemType).fBlock;
+}
+i

svn commit: r1155067 - /xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java

2011-08-08 Thread mrglavas
Author: mrglavas
Date: Mon Aug  8 19:28:47 2011
New Revision: 1155067

URL: http://svn.apache.org/viewvc?rev=1155067&view=rev
Log:
Memory usage improvement. The fBuckets field in the base class isn't used so 
make the array as small as possible.

Modified:

xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java

Modified: 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java
URL: 
http://svn.apache.org/viewvc/xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java?rev=1155067&r1=1155066&r2=1155067&view=diff
==
--- 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java
 (original)
+++ 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/util/SoftReferenceSymbolTable.java
 Mon Aug  8 19:28:47 2011
@@ -65,9 +65,12 @@ public class SoftReferenceSymbolTable ex
  */
 public SoftReferenceSymbolTable(int initialCapacity, float loadFactor) {
 /*
- * Not calling super() because we don't want to initialize the Entry 
buckets
- * used by the base class.
+ * The Entry buckets in the base class are not used by this class.
+ * We call super() with 1 as the initial capacity to minimize the
+ * memory used by the field in the base class.
  */
+super(1, loadFactor);
+
 if (initialCapacity < 0) {
 throw new IllegalArgumentException("Illegal Capacity: " + 
initialCapacity);
 }



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



svn commit: r1155066 - /xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java

2011-08-08 Thread mrglavas
Author: mrglavas
Date: Mon Aug  8 19:28:28 2011
New Revision: 1155066

URL: http://svn.apache.org/viewvc?rev=1155066&view=rev
Log:
Memory usage improvement. The fBuckets field in the base class isn't used so 
make the array as small as possible.

Modified:
xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java

Modified: 
xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java
URL: 
http://svn.apache.org/viewvc/xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java?rev=1155066&r1=1155065&r2=1155066&view=diff
==
--- xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java 
(original)
+++ xerces/java/trunk/src/org/apache/xerces/util/SoftReferenceSymbolTable.java 
Mon Aug  8 19:28:28 2011
@@ -65,9 +65,12 @@ public class SoftReferenceSymbolTable ex
  */
 public SoftReferenceSymbolTable(int initialCapacity, float loadFactor) {
 /*
- * Not calling super() because we don't want to initialize the Entry 
buckets
- * used by the base class.
+ * The Entry buckets in the base class are not used by this class.
+ * We call super() with 1 as the initial capacity to minimize the
+ * memory used by the field in the base class.
  */
+super(1, loadFactor);
+
 if (initialCapacity < 0) {
 throw new IllegalArgumentException("Illegal Capacity: " + 
initialCapacity);
 }



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