com.pushtotest.tool.parser.html
Class HTMLParser

java.lang.Object
  extended by com.pushtotest.tool.parser.html.HTMLParser

public class HTMLParser
extends java.lang.Object


Constructor Summary
HTMLParser(java.lang.String html)
          Creates a new instance of HTMLParser with the value to parse as a string.
HTMLParser(java.lang.String html, java.lang.String base_uri)
           
HTMLParser(java.net.URI uri)
          Create a new HTMLParser from the contents of a given URI.
 
Method Summary
 HTMLForm[] parse()
          Parse the page for forms.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HTMLParser

public HTMLParser(java.lang.String html)
Creates a new instance of HTMLParser with the value to parse as a string.

Parameters:
html - The HTML to parse.

HTMLParser

public HTMLParser(java.lang.String html,
                  java.lang.String base_uri)
           throws java.net.URISyntaxException
Throws:
java.net.URISyntaxException

HTMLParser

public HTMLParser(java.net.URI uri)
           throws java.net.MalformedURLException,
                  java.io.IOException
Create a new HTMLParser from the contents of a given URI.

Parameters:
uri - The {#link java.net.URI URI) to connect to
Throws:
java.net.MalformedURLException - If the URI is not formed properly.
java.io.IOException - If there is a problem with the connection.
Method Detail

parse

public HTMLForm[] parse()
Parse the page for forms.

Returns:
The forms that were in the page.