|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.encog.bot.browse.LoadWebPage
public class LoadWebPage
Called to actually load a web page. This will read the HTML on a web page and generate the DocumentRange classes.
Constructor Summary | |
---|---|
LoadWebPage(URL theBase)
Construct a web page loader with the specified base URL. |
Method Summary | |
---|---|
int |
findEndTag(int index,
Tag tag)
Find the end tag that lines up to the beginning tag. |
WebPage |
load(InputStream is)
Load a web page from the specified stream. |
WebPage |
load(String str)
Load the web page from a string that contains HTML. |
protected void |
loadContents()
Using the data units, which should have already been loaded by this time, load the contents of the web page. |
protected void |
loadDataUnits(InputStream is)
Load the data units. |
protected void |
loadForm(int index,
Tag tag)
Called by loadContents to load a form on the page. |
protected void |
loadInput(int index,
Tag tag)
Called by loadContents to load an input tag on the form. |
protected void |
loadLink(int index,
Tag tag)
Called by loadContents to load a link on the page. |
protected void |
loadTitle(int index,
Tag tag)
Called by loadContents to load the title of the page. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LoadWebPage(URL theBase)
theBase
- The base URL to use when loading.Method Detail |
---|
public final int findEndTag(int index, Tag tag)
index
- The index to start the search on. This specifies the starting
data unit.tag
- The beginning tag that we are seeking the end tag for.
public final WebPage load(InputStream is)
is
- The input stream to load from.
public final WebPage load(String str)
str
- A string containing HTML.
protected final void loadContents()
protected final void loadDataUnits(InputStream is)
is
- The input stream that the data units are loaded from.protected final void loadForm(int index, Tag tag)
index
- The index to begin loading at.tag
- The beginning tag.protected final void loadInput(int index, Tag tag)
index
- The index to begin loading at.tag
- The beginning tag.protected final void loadLink(int index, Tag tag)
index
- The index to begin loading at.tag
- The beginning tag.protected final void loadTitle(int index, Tag tag)
index
- The index to begin loading at.tag
- The beginning tag.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |