org.jasen.net
Class StandardURLReader
java.lang.Object
org.jasen.net.StandardURLReader
- All Implemented Interfaces:
- URLReader
- public class StandardURLReader
- extends Object
- implements URLReader
Extracts the content from a remote web server for the purposes of analysis.
- Author:
- Jason Polites
StandardURLReader
public StandardURLReader()
readURL
public String readURL(URL url)
throws JasenException
- Description copied from interface:
URLReader
- Extracts the raw HTML from the given web url
- Specified by:
readURL
in interface URLReader
- Parameters:
url
-
- Returns:
- The [HTML] content located at the given URL
- Throws:
JasenException
getReadBufferSize
public int getReadBufferSize()
- Returns:
- Returns the size (in bytes) of the buffer used when reading url data.
setReadBufferSize
public void setReadBufferSize(int readBufferSize)
- Parameters:
readBufferSize
- The size (in bytes) of the buffer used when reading url data.
getReadTimeout
public long getReadTimeout()
- Returns:
- Returns the time (in milliseconds) to wait for data from the url stream until reading is abnormally aborted.
setReadTimeout
public void setReadTimeout(long readTimeout)
- Parameters:
readTimeout
- The time (in milliseconds) to wait for data from the url stream until reading is abnormally aborted.