Package org.apache.ws.jaxme.xs.parser.impl

Examples of org.apache.ws.jaxme.xs.parser.impl.LocSAXException


  }

  public void validate() throws SAXException {
    super.validate();
    if (schemaLocation == null) {
      throw new LocSAXException("Missing attribute: 'schemaLocation'", getLocator());
    }
  }
View Full Code Here


  }

  public void validate() throws SAXException {
    super.validate();
    if (value == null) {
      throw new LocSAXException("Missing 'value' attribute", getLocator());
    }
  }
View Full Code Here

    if (isReference()) {
      qName = getXsTAttributeGroup().getRef();
    } else {
      XsNCName myName = pBaseGroup.getName();
      if (myName == null) {
        throw new LocSAXException("Invalid attribute group: Neither of its 'name' or 'ref' attributes are set.",
                                     pBaseGroup.getLocator());
      } else {
        XsESchema schema = pBaseGroup.getXsESchema();
        qName = new XsQName(schema.getTargetNamespace(), myName.toString(), schema.getTargetNamespacePrefix());
      }
View Full Code Here

    }

    if (isReference()) {
      XSAttributeGroup referencedGroup = getXSSchema().getAttributeGroup(getName());
      if (referencedGroup == null) {
        throw new LocSAXException("Invalid attribute group: Unknown attribute group " + name + " referenced",
                                   getLocator());
      }
      referencedGroup.validate();
      attributes = referencedGroup.getAttributes();
    } else {
View Full Code Here

        attributes.add(attribute);
      } else if (o instanceof XsTAttributeGroupRef) {
        XsTAttributeGroupRef agRef = (XsTAttributeGroupRef) o;
        XsQName ref = agRef.getRef();
        if (ref == null) {
          throw new LocSAXException("Invalid attribute group: Missing 'ref' attribute", pObject.getLocator());
        }
        XSAttributeGroup attributeGroup = pObject.getXSSchema().getAttributeGroup(ref);
        if (attributeGroup == null) {
          throw new LocSAXException("Unknown attribute group name: " + ref, pObject.getLocator());
        }
        attributeGroup.validate();
        XSAttributable[] agAttributes = attributeGroup.getAttributes();
        for (int j = 0;  j < agAttributes.length;  j++) {
          attributes.add(agAttributes[j]);
View Full Code Here

    super(pParent);
  }

  public XsERestriction createRestriction() throws SAXException {
    if (restriction != null  ||  list != null  ||  union != null) {
      throw new LocSAXException("Only one 'restriction', 'list', or 'union' child element is allowed.", getLocator());
    }
    return restriction = getObjectFactory().newXsERestriction(this);
  }
View Full Code Here

    return restriction;
  }

  public XsEList createList() throws SAXException {
    if (restriction != null  ||  list != null  ||  union != null) {
      throw new LocSAXException("Only one 'restriction', 'list', or 'union' child element is allowed.", getLocator());
    }
    return list = getObjectFactory().newXsEList(this);
  }
View Full Code Here

    return list;
  }

  public XsEUnion createUnion() throws SAXException {
    if (restriction != null  ||  list != null  ||  union != null) {
      throw new LocSAXException("Only one 'restriction', 'list', or 'union' child element is allowed.", getLocator());
    }
    return union = getObjectFactory().newXsEUnion(this);
  }
View Full Code Here

  }

  public void validate() throws SAXException {
    super.validate();
    if (restriction == null  &&  list == null  &&  union == null) {
      throw new LocSAXException("Expected either of 'restriction', 'list' or 'union' child element.", getLocator());
    }
  }
View Full Code Here

      this.name = pBaseAttribute.getRef();
      isGlobal = pBaseAttribute.isGlobal();
    } else {
      XsNCName myName = pBaseAttribute.getName();
      if (myName == null) {
        throw new LocSAXException("Invalid attribute: Neither of its 'name' or 'ref' attributes are set.",
                                     pBaseAttribute.getLocator());
      }
      XsESchema schema = pBaseAttribute.getXsESchema();
      XsAnyURI namespace;
      String namespacePrefix;
View Full Code Here

TOP

Related Classes of org.apache.ws.jaxme.xs.parser.impl.LocSAXException

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.