Package org.apache.xerces.xni

Examples of org.apache.xerces.xni.QName


        if (fMarkupDepth < fEntityStack[fEntityDepth - 1]) {
            reportFatalError("ElementEntityMismatch",
                             new Object[]{fCurrentElement.rawname});
        }
        // make sure the elements match
        QName startElement = fQName;
        fElementStack.popElement(startElement);
        if (element.rawname != startElement.rawname) {
            reportFatalError("ETagRequired",
                             new Object[]{startElement.rawname});
        }
View Full Code Here


        /** Default constructor. */
        public ElementStack() {
            fElements = new QName[10];
            for (int i = 0; i < fElements.length; i++) {
                fElements[i] = new QName();
            }
        } // <init>()
View Full Code Here

            if (fSize == fElements.length) {
                QName[] array = new QName[fElements.length * 2];
                System.arraycopy(fElements, 0, array, 0, fSize);
                fElements = array;
                for (int i = fSize; i < fElements.length; i++) {
                    fElements[i] = new QName();
                }
            }
            fElements[fSize].setValues(element);
            return fElements[fSize++];
        } // pushElement(QName):QName
View Full Code Here

        super.endCDATA(augs);

        break;

      case Node.ELEMENT_NODE:
        QName name = new QName(prefix, node.getNodeName(), node.getNodeName(), uri);
        XMLAttributes attrs = new XMLAttributesImpl();
       
        NamedNodeMap attributes = node.getAttributes();
        if (attributes != null) {
          int l = attributes.getLength();
 
          for (int i = 0; i < l; i++) {
            Node attributeNode = attributes.item(i);
            attrs.addAttribute(new QName(prefix, attributeNode.getNodeName(),
                attributeNode.getNodeName(), uri), "CDATA",
                attributeNode.getNodeValue());
          }
         
        }
View Full Code Here

      }
      return false;
    }

    void insertStartElement(String name) {
      QName element = new QName(null, name, name, null);
      XMLAttributes attrs = new XMLAttributesImpl();
      Augmentations augs = new HTMLAugmentations();
      super.startElement(element, attrs, augs);
    }
View Full Code Here

      Augmentations augs = new HTMLAugmentations();
      super.startElement(element, attrs, augs);
    }

    void insertEndElement(String name) {
      QName element = new QName(null, name, name, null);
      // XMLAttributes attrs = new XMLAttributesImpl();
      Augmentations augs = new HTMLAugmentations();
      super.endElement(element, augs);
    }
View Full Code Here

    private void insertResources() {
      headParsed = true;
      if (null != _styles) {
        for (Iterator iter = _styles.iterator(); iter.hasNext();) {
          String style = (String) iter.next();
          QName element = new QName(null, "link", "link", null);
          XMLAttributes attrs = new XMLAttributesImpl();
          attrs.addAttribute(new QName(null, "href", "href", null),
              "CDATA", style);
          attrs.addAttribute(new QName(null, "type", "type", null),
              "CDATA", "text/css");
          attrs.addAttribute(new QName(null, "rel", "rel", null),
              "CDATA", "stylesheet");
          Augmentations augs = new HTMLAugmentations();
          super.emptyElement(element, attrs, augs);
        }
      }
      if (null != _scripts) {
        for (Iterator iter = _scripts.iterator(); iter.hasNext();) {
          String script = (String) iter.next();
          QName element = new QName(null, "script", "script", null);
          XMLAttributes attrs = new XMLAttributesImpl();
          attrs.addAttribute(new QName(null, "src", "src", null),
              "CDATA", script);
          attrs.addAttribute(new QName(null, "type", "type", null),
              "CDATA", "text/javascript");
          Augmentations augs = new HTMLAugmentations();
          super.startElement(element, attrs, augs);
          super.endElement(element, augs);
        }
View Full Code Here

      }
      return false;
    }

    void insertStartElement(String name) {
      QName element = new QName(null, name, name, null);
      XMLAttributes attrs = new XMLAttributesImpl();
      Augmentations augs = new HTMLAugmentations();
      super.startElement(element, attrs, augs);
    }
View Full Code Here

      Augmentations augs = new HTMLAugmentations();
      super.startElement(element, attrs, augs);
    }

    void insertEndElement(String name) {
      QName element = new QName(null, name, name, null);
      // XMLAttributes attrs = new XMLAttributesImpl();
      Augmentations augs = new HTMLAugmentations();
      super.endElement(element, augs);
    }
View Full Code Here

        default:
            return null;
        }
        if (nameToFind == null) return null;
        int commaPos = nameToFind.indexOf(",");
        QName qNameToFind = new QName(XMLSymbols.EMPTY_STRING, nameToFind.substring(commaPos+1),
            nameToFind.substring(commaPos), (commaPos == 0)? null : nameToFind.substring(0, commaPos));
        Object retObj = getGlobalDecl(currSchema, type, qNameToFind, elmNode);
        if(retObj == null) {
            switch (type) {
            case ATTRIBUTEGROUP_TYPE:
View Full Code Here

TOP

Related Classes of org.apache.xerces.xni.QName

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.