Package org.apache.excalibur.xml.dom

Examples of org.apache.excalibur.xml.dom.DOMHandlerFactory


    public void testCreateDOMHandler()
    {
        try
        {
            final SAXParser parser = (SAXParser)manager.lookup( SAXParser.ROLE );
            final DOMHandlerFactory handlerFactory = (DOMHandlerFactory)manager.lookup( DOMHandlerFactory.ROLE );

            final DOMHandler handler = handlerFactory.createDOMHandler();
            parser.parse( new InputSource( IN ), handler );
            final Document document = handler.getDocument();

            final Element root = document.getDocumentElement();
            assertEquals( "Wrong root element", "test:root", root.getNodeName() );
View Full Code Here


    public void testCreateDOMHandler()
    {
        try
        {
            final SAXParser parser = (SAXParser)manager.lookup( SAXParser.ROLE );
            final DOMHandlerFactory handlerFactory = (DOMHandlerFactory)manager.lookup( DOMHandlerFactory.ROLE );       

            final DOMHandler handler = handlerFactory.createDOMHandler();
            parser.parse( new InputSource( IN ), handler );           
            final Document document = handler.getDocument();
           
            final Element root = document.getDocumentElement();
            assertEquals( "Wrong root element", "test:root", root.getNodeName() );
View Full Code Here

TOP

Related Classes of org.apache.excalibur.xml.dom.DOMHandlerFactory

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.