org.encog.bot.browse
Class Browser
- java.lang.Object
-
- org.encog.bot.browse.Browser
-
public class Browser extends java.lang.ObjectThe main class for web browsing. This class allows you to navigate to a specific URL. Once you navigate to one URL, you can naviage to any URL contained on the page.
-
-
Constructor Summary
Constructors Constructor and Description Browser()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description WebPagegetCurrentPage()voidnavigate(Form form)Navigate to the specified form by performing a submit of that form.voidnavigate(Form form, Input submit)Navigate based on a form.voidnavigate(Link link)Navigate to a new page based on a link.voidnavigate(java.lang.String url)Navigate based on a string URL.voidnavigate(java.net.URL url)Navigate to a page based on a URL object.voidnavigate(java.net.URL url, java.io.InputStream is)Navigate to a page and post the specified data.voidsetCurrentPage(WebPage theCurrentPage)Set the current page.java.lang.StringtoString()
-
-
-
Method Detail
-
getCurrentPage
public final WebPage getCurrentPage()
- Returns:
- The page currently being browsed.
-
navigate
public final void navigate(Form form)
Navigate to the specified form by performing a submit of that form.- Parameters:
form- The form to be submitted.
-
navigate
public final void navigate(Form form, Input submit)
Navigate based on a form. Complete and post the form.- Parameters:
form- The form to be posted.submit- The submit button on the form to simulate clicking.
-
navigate
public final void navigate(Link link)
Navigate to a new page based on a link.- Parameters:
link- The link to navigate to.
-
navigate
public final void navigate(java.lang.String url)
Navigate based on a string URL.- Parameters:
url- The URL to navigate to.
-
navigate
public final void navigate(java.net.URL url)
Navigate to a page based on a URL object. This will be an HTTP GET operation.- Parameters:
url- The URL to navigate to.
-
navigate
public final void navigate(java.net.URL url, java.io.InputStream is)Navigate to a page and post the specified data.- Parameters:
url- The URL to post the data to.is- The data to post to the page.
-
setCurrentPage
public final void setCurrentPage(WebPage theCurrentPage)
Set the current page.- Parameters:
theCurrentPage- The current page.
-
toString
public final java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-
DMelt 3.0 © DataMelt by jWork.ORG