Package org.apache.xerces.impl.xs.identity

Examples of org.apache.xerces.impl.xs.identity.UniqueOrKey


    {
      reportSchemaError("s4s-att-must-appear", new Object[] { SchemaSymbols.ELT_KEYREF, SchemaSymbols.ATT_REFER }, paramElement);
      this.fAttrChecker.returnAttrArray(arrayOfObject, paramXSDocumentInfo);
      return;
    }
    UniqueOrKey localUniqueOrKey = null;
    IdentityConstraint localIdentityConstraint = (IdentityConstraint)this.fSchemaHandler.getGlobalDecl(paramXSDocumentInfo, 5, localQName, paramElement);
    if (localIdentityConstraint != null)
      if ((localIdentityConstraint.getCategory() == 1) || (localIdentityConstraint.getCategory() == 3))
        localUniqueOrKey = (UniqueOrKey)localIdentityConstraint;
      else
        reportSchemaError("src-resolve", new Object[] { localQName.rawname, "identity constraint key/unique" }, paramElement);
    if (localUniqueOrKey == null)
    {
      this.fAttrChecker.returnAttrArray(arrayOfObject, paramXSDocumentInfo);
      return;
    }
    KeyRef localKeyRef = new KeyRef(paramXSDocumentInfo.fTargetNamespace, str, paramXSElementDecl.fName, localUniqueOrKey);
    traverseIdentityConstraint(localKeyRef, paramElement, paramXSDocumentInfo, arrayOfObject);
    if (localUniqueOrKey.getFieldCount() != localKeyRef.getFieldCount())
      reportSchemaError("c-props-correct.2", new Object[] { str, localUniqueOrKey.getIdentityConstraintName() }, paramElement);
    else
      paramSchemaGrammar.addIDConstraintDecl(paramXSElementDecl, localKeyRef);
    this.fAttrChecker.returnAttrArray(arrayOfObject, paramXSDocumentInfo);
  }
View Full Code Here


    {
      reportSchemaError("s4s-att-must-appear", new Object[] { DOMUtil.getLocalName(paramElement), SchemaSymbols.ATT_NAME }, paramElement);
      this.fAttrChecker.returnAttrArray(arrayOfObject, paramXSDocumentInfo);
      return;
    }
    UniqueOrKey localUniqueOrKey = null;
    if (DOMUtil.getLocalName(paramElement).equals(SchemaSymbols.ELT_UNIQUE))
      localUniqueOrKey = new UniqueOrKey(paramXSDocumentInfo.fTargetNamespace, str, paramXSElementDecl.fName, 3);
    else
      localUniqueOrKey = new UniqueOrKey(paramXSDocumentInfo.fTargetNamespace, str, paramXSElementDecl.fName, 1);
    traverseIdentityConstraint(localUniqueOrKey, paramElement, paramXSDocumentInfo, arrayOfObject);
    paramSchemaGrammar.addIDConstraintDecl(paramXSElementDecl, localUniqueOrKey);
    this.fAttrChecker.returnAttrArray(arrayOfObject, paramXSDocumentInfo);
  }
View Full Code Here

      {
        XMLSchemaValidator.LocalIDKey localLocalIDKey;
        switch (arrayOfIdentityConstraint[j].getCategory())
        {
        case 3:
          UniqueOrKey localUniqueOrKey1 = (UniqueOrKey)arrayOfIdentityConstraint[j];
          localLocalIDKey = new XMLSchemaValidator.LocalIDKey(XMLSchemaValidator.this, localUniqueOrKey1, XMLSchemaValidator.this.fElementDepth);
          XMLSchemaValidator.UniqueValueStore localUniqueValueStore = (XMLSchemaValidator.UniqueValueStore)this.fIdentityConstraint2ValueStoreMap.get(localLocalIDKey);
          if (localUniqueValueStore == null)
          {
            localUniqueValueStore = new XMLSchemaValidator.UniqueValueStore(XMLSchemaValidator.this, localUniqueOrKey1);
            this.fIdentityConstraint2ValueStoreMap.put(localLocalIDKey, localUniqueValueStore);
          }
          else
          {
            localUniqueValueStore.clear();
          }
          this.fValueStores.addElement(localUniqueValueStore);
          XMLSchemaValidator.this.activateSelectorFor(arrayOfIdentityConstraint[j]);
          break;
        case 1:
          UniqueOrKey localUniqueOrKey2 = (UniqueOrKey)arrayOfIdentityConstraint[j];
          localLocalIDKey = new XMLSchemaValidator.LocalIDKey(XMLSchemaValidator.this, localUniqueOrKey2, XMLSchemaValidator.this.fElementDepth);
          XMLSchemaValidator.KeyValueStore localKeyValueStore = (XMLSchemaValidator.KeyValueStore)this.fIdentityConstraint2ValueStoreMap.get(localLocalIDKey);
          if (localKeyValueStore == null)
          {
            localKeyValueStore = new XMLSchemaValidator.KeyValueStore(XMLSchemaValidator.this, localUniqueOrKey2);
View Full Code Here

TOP

Related Classes of org.apache.xerces.impl.xs.identity.UniqueOrKey

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.