Package org.apache.xerces.xni

Examples of org.apache.xerces.xni.XMLString


     *
     * @returns Returns the next character on the stream.
     */
    protected int scanContent() throws IOException, XNIException {

        XMLString content = fTempString;
        int c = fEntityScanner.scanContent(content);
        if (c == '\r') {
            // happens when there is the character reference 
            fEntityScanner.scanChar();
            fStringBuffer.clear();
View Full Code Here


      super.endElement(element, augs);
    }

    private XMLString createXMLString(String string) {
      char[] cs = string.toCharArray();
      return new XMLString(cs, 0, cs.length);
    }
View Full Code Here

                    return name.equals(elementEvent.element.rawname); // succeed if exact end element found and all is balanced
                }
            } else if (event.type == XMLEvent.CDATA) {
                xmlFragments.add(new XMLText(event.toString()));
            } else if (event.type == XMLEvent.CHARACTERS) {
                XMLString xmlString = ((CharactersEvent) event).text;
                xmlFragments.add(new XMLText(xmlString.toString()));
            } else {
                // ignore other types, as of XMPP spec
            }
        }
    }
View Full Code Here

                    return;
                }
                reportFatalError("QuoteRequiredInSystemID", null);
            }
            fEntityScanner.scanChar();
            XMLString ident = fString;
            if (fEntityScanner.scanLiteral(quote, ident) != quote) {
                fStringBuffer.clear();
                do {
                    fStringBuffer.append(ident);
                    int c = fEntityScanner.peekChar();
                    if (XMLChar.isMarkup(c) || c == ']') {
                        fStringBuffer.append((char)fEntityScanner.scanChar());
                    }
                } while (fEntityScanner.scanLiteral(quote, ident) != quote);
                fStringBuffer.append(ident);
                ident = fStringBuffer;
            }
            systemId = ident.toString();
            if (!fEntityScanner.skipChar(quote)) {
                reportFatalError("SystemIDUnterminated", null);
            }
        }
View Full Code Here

            reportFatalError("OpenQuoteMissingInDecl", null);
        }
        // store at which depth of entities we start
        int entityDepth = fEntityDepth;

        XMLString literal = fString;
        if (fEntityScanner.scanLiteral(quote, fString) != quote) {
            fStringBuffer2.clear();
            do {
                fStringBuffer2.append(fString);
                if (fEntityScanner.skipChar('&')) {
View Full Code Here

     *
     * @returns Returns the next character on the stream.
     */
    protected int scanContent() throws IOException, SAXException {

        XMLString content = fString;
        int c = fEntityScanner.scanContent(content);
        if (c == '\r') {
            // happens when there is the character reference 
            fEntityScanner.scanChar();
            fStringBuffer.clear();
View Full Code Here

    private void sendElementEvent(
        String elementName,
        Vector attributes,
        String elementValue) {
        XMLString text =
            elementValue == null
                ? null
                : new XMLString(
                    elementValue.toCharArray(),
                    0,
                    elementValue.length());
        this.sendElementEvent(elementName, attributes, text);
    }
View Full Code Here

            fIndentChars = new char[fIndentChars.length * 2];
            for (int i = 0; i < fIndentChars.length; i++) {
                fIndentChars[i] = '\t';
            }
        }
        XMLString text = new XMLString(fIndentChars, 0, fIndent);
        fDocumentHandler.characters(text, null);
    }
View Full Code Here

     *
     * @return Returns the next character on the stream.
     */
    protected int scanContent() throws IOException, XNIException {

        XMLString content = fString;
        int c = fEntityScanner.scanContent(content);
        if (c == '\r' || c == 0x85 || c == 0x2028) {
            // happens when there is the character reference &#13;
            // but scanContent doesn't do entity expansions...
            // is this *really* necessary???  - NG
View Full Code Here

            reportFatalError("OpenQuoteMissingInDecl", null);
        }
        // store at which depth of entities we start
        int entityDepth = fEntityDepth;

        XMLString literal = fString;
        XMLString literal2 = fString;
        if (fEntityScanner.scanLiteral(quote, fString) != quote) {
            fStringBuffer.clear();
            fStringBuffer2.clear();
            do {
                fStringBuffer.append(fString);
View Full Code Here

TOP

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

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.