Package org.htmlparser.tags

Examples of org.htmlparser.tags.Div.toPlainTextString()


        parser.addScanner(new DivScanner());
        parseAndAssertNodeCount(1);
        assertType("node should be table", TableTag.class, node[0]);
        TableTag tableTag = (TableTag) node[0];
        Div div = (Div) tableTag.searchFor(Div.class).toNodeArray()[0];
        assertEquals("div contents", "some text", div.toPlainTextString());
    }

    /**
     * Test case for bug #735193 Explicit tag type recognition for CompositTags not working.
     */
 
View Full Code Here


        createParser("<table><div align=\"left\">some text</div></table>");
        parseAndAssertNodeCount(1);
        assertType("node should be table",TableTag.class,node[0]);
        TableTag tableTag = (TableTag)node[0];
        Div div = (Div)tableTag.searchFor(Div.class, true).toNodeArray()[0];
        assertEquals("div contents","some text",div.toPlainTextString());
    }

    /**
     * Test case for bug #735193 Explicit tag type recognition for CompositTags not working.
     */
 
View Full Code Here

    parser.addScanner(new DivScanner());
    parseAndAssertNodeCount(1);
    assertType("node should be table", TableTag.class, node[0]);
    TableTag tableTag = (TableTag) node[0];
    Div div = (Div) tableTag.searchFor(Div.class).toNodeArray()[0];
    assertEquals("div contents", "some text", div.toPlainTextString());
  }

  /**
   * Test case for bug #735193 Explicit tag type recognition for CompositTags
   * not working.
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.