Package org.htmlparser.tags

Examples of org.htmlparser.tags.Html.toHtml()


        assertTrue(node[0] instanceof Html);
        Html htmlTag = (Html)node[0];
        assertTrue(htmlTag.getChild(0) instanceof HeadTag);
        HeadTag headTag = (HeadTag)htmlTag.getChild(0);
        assertEquals("toHtml()","<HEAD></HEAD>",headTag.toHtml());
        assertEquals("toHtml()","<HTML><HEAD></HEAD></HTML>",htmlTag.toHtml());
    }

    public void testSimpleHeadWithBody() throws ParserException {
        createParser("<HTML><HEAD><BODY></HTML>");
        parseAndAssertNodeCount(1);
View Full Code Here


        Html htmlTag = (Html)node[0];
        assertTrue(htmlTag.getChild(0) instanceof HeadTag);
        //assertTrue(htmlTag.getChild(1) instanceof BodyTag);
        HeadTag headTag = (HeadTag)htmlTag.getChild(0);
        assertEquals("toHtml()","<HEAD></HEAD>",headTag.toHtml());
        assertEquals("toHtml()","<HTML><HEAD></HEAD><BODY></BODY></HTML>",htmlTag.toHtml());
    }
}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.