Package org.apache.rat.report.xml.writer

Examples of org.apache.rat.report.xml.writer.InvalidXmlException


    public IXmlWriter openElement(final CharSequence elementName) throws IOException {
        if (elementsWritten && elementNames.isEmpty()) {
            throw new OperationNotAllowedException("Root element already closed. Cannot open new element.");
        }
        if (!isValidName(elementName)) {
            throw new InvalidXmlException("'" + elementName + "' is not a valid element name");
        }
        elementsWritten = true;
        if (inElement) {
            writer.write('>');
        }
View Full Code Here


            } else {
                throw new OperationNotAllowedException("Close called before an element has been opened.");           
            }
        }
        if (!isValidName(name)) {
            throw new InvalidXmlException("'" + name + "' is not a valid attribute name.");
        }
        if (!inElement) {
            throw new InvalidXmlException("Attributes can only be written in elements");
        }
        if (currentAttributes.contains(name)) {
            throw new InvalidXmlException("Each attribute can only be written once");
        }
        writer.write(' ');
        rawWrite(name);
        writer.write('=');
        writer.write('\'');
View Full Code Here

    public IXmlWriter openElement(final CharSequence elementName) throws IOException {
        if (elementsWritten && elementNames.isEmpty()) {
            throw new OperationNotAllowedException("Root element already closed. Cannot open new element.");
        }
        if (!isValidName(elementName)) {
            throw new InvalidXmlException("'" + elementName + "' is not a valid element name");
        }
        elementsWritten = true;
        if (inElement) {
            writer.write('>');
        }
View Full Code Here

            } else {
                throw new OperationNotAllowedException("Close called before an element has been opened.");           
            }
        }
        if (!isValidName(name)) {
            throw new InvalidXmlException("'" + name + "' is not a valid attribute name.");
        }
        if (!inElement) {
            throw new InvalidXmlException("Attributes can only be written in elements");
        }
        if (currentAttributes.contains(name)) {
            throw new InvalidXmlException("Each attribute can only be written once");
        }
        writer.write(' ');
        rawWrite(name);
        writer.write('=');
        writer.write('\'');
View Full Code Here

TOP

Related Classes of org.apache.rat.report.xml.writer.InvalidXmlException

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.