< prev index next >

src/com/sun/org/apache/xerces/internal/impl/xs/XSConstraints.java

Print this page
rev 2127 : 8048021: Remove @version tag in jaxp repo
Reviewed-by: joehw


  28 import com.sun.org.apache.xerces.internal.impl.dv.InvalidDatatypeValueException;
  29 import com.sun.org.apache.xerces.internal.impl.dv.ValidatedInfo;
  30 import com.sun.org.apache.xerces.internal.impl.dv.ValidationContext;
  31 import com.sun.org.apache.xerces.internal.impl.dv.XSSimpleType;
  32 import com.sun.org.apache.xerces.internal.impl.xs.models.CMBuilder;
  33 import com.sun.org.apache.xerces.internal.impl.xs.models.XSCMValidator;
  34 import com.sun.org.apache.xerces.internal.impl.xs.util.SimpleLocator;
  35 import com.sun.org.apache.xerces.internal.impl.xs.util.XSObjectListImpl;
  36 import com.sun.org.apache.xerces.internal.util.SymbolHash;
  37 import com.sun.org.apache.xerces.internal.xs.XSConstants;
  38 import com.sun.org.apache.xerces.internal.xs.XSObjectList;
  39 import com.sun.org.apache.xerces.internal.xs.XSTypeDefinition;
  40 
  41 /**
  42  * Constaints shared by traversers and validator
  43  *
  44  * @xerces.internal
  45  *
  46  * @author Sandy Gao, IBM
  47  *
  48  * @version $Id: XSConstraints.java,v 1.7 2010-11-01 04:39:55 joehw Exp $
  49  */
  50 public class XSConstraints {
  51 
  52     // IHR: Visited on 2006-11-17
  53     // Added a boolean return value to particleValidRestriction (it was a void function)
  54     // to help the checkRecurseLax to know when expansion has happened and no order is required
  55     // (IHR@xbrl.org) (Ignacio@Hernandez-Ros.com)
  56 
  57     static final int OCCURRENCE_UNKNOWN = SchemaSymbols.OCCURRENCE_UNBOUNDED-1;
  58     static final XSSimpleType STRING_TYPE = (XSSimpleType)SchemaGrammar.SG_SchemaNS.getGlobalTypeDecl(SchemaSymbols.ATTVAL_STRING);
  59 
  60     private static XSParticleDecl fEmptyParticle = null;
  61     public static XSParticleDecl getEmptySequence() {
  62         if (fEmptyParticle == null) {
  63             XSModelGroupImpl group = new XSModelGroupImpl();
  64             group.fCompositor = XSModelGroupImpl.MODELGROUP_SEQUENCE;
  65             group.fParticleCount = 0;
  66             group.fParticles = null;
  67             group.fAnnotations = XSObjectListImpl.EMPTY_LIST;
  68             XSParticleDecl particle = new XSParticleDecl();




  28 import com.sun.org.apache.xerces.internal.impl.dv.InvalidDatatypeValueException;
  29 import com.sun.org.apache.xerces.internal.impl.dv.ValidatedInfo;
  30 import com.sun.org.apache.xerces.internal.impl.dv.ValidationContext;
  31 import com.sun.org.apache.xerces.internal.impl.dv.XSSimpleType;
  32 import com.sun.org.apache.xerces.internal.impl.xs.models.CMBuilder;
  33 import com.sun.org.apache.xerces.internal.impl.xs.models.XSCMValidator;
  34 import com.sun.org.apache.xerces.internal.impl.xs.util.SimpleLocator;
  35 import com.sun.org.apache.xerces.internal.impl.xs.util.XSObjectListImpl;
  36 import com.sun.org.apache.xerces.internal.util.SymbolHash;
  37 import com.sun.org.apache.xerces.internal.xs.XSConstants;
  38 import com.sun.org.apache.xerces.internal.xs.XSObjectList;
  39 import com.sun.org.apache.xerces.internal.xs.XSTypeDefinition;
  40 
  41 /**
  42  * Constaints shared by traversers and validator
  43  *
  44  * @xerces.internal
  45  *
  46  * @author Sandy Gao, IBM
  47  *

  48  */
  49 public class XSConstraints {
  50 
  51     // IHR: Visited on 2006-11-17
  52     // Added a boolean return value to particleValidRestriction (it was a void function)
  53     // to help the checkRecurseLax to know when expansion has happened and no order is required
  54     // (IHR@xbrl.org) (Ignacio@Hernandez-Ros.com)
  55 
  56     static final int OCCURRENCE_UNKNOWN = SchemaSymbols.OCCURRENCE_UNBOUNDED-1;
  57     static final XSSimpleType STRING_TYPE = (XSSimpleType)SchemaGrammar.SG_SchemaNS.getGlobalTypeDecl(SchemaSymbols.ATTVAL_STRING);
  58 
  59     private static XSParticleDecl fEmptyParticle = null;
  60     public static XSParticleDecl getEmptySequence() {
  61         if (fEmptyParticle == null) {
  62             XSModelGroupImpl group = new XSModelGroupImpl();
  63             group.fCompositor = XSModelGroupImpl.MODELGROUP_SEQUENCE;
  64             group.fParticleCount = 0;
  65             group.fParticles = null;
  66             group.fAnnotations = XSObjectListImpl.EMPTY_LIST;
  67             XSParticleDecl particle = new XSParticleDecl();


< prev index next >