bass.crawler
Class PageGetter
java.lang.Object
bass.crawler.PageGetter
public class PageGetter
- extends java.lang.Object
This class represents the functionality to read content from the web
- Version:
- 0.2
- Author:
- Thomas Klein, Fabian Winkhardt
|
Method Summary |
static java.lang.String |
getFirstFriendsPage(int id)
|
static java.lang.String |
getFirstFriendsPage(int id,
java.lang.String proxyIP,
java.lang.String proxyPort)
|
static java.lang.String |
getFriendsPage(int page,
int id,
java.lang.String viewstate)
|
static java.lang.String |
getFriendsPage(int page,
int id,
java.lang.String viewstate,
java.lang.String proxyIP,
java.lang.String proxyPort)
|
protected static java.lang.String |
getPage(java.lang.String url)
|
protected static java.lang.String |
getPage(java.lang.String url,
java.lang.String proxyIP,
java.lang.String proxyPort)
same as getPage, but using proxyserver |
static java.lang.String |
getProfilePage(int id)
|
static java.lang.String |
getProfilePage(int id,
java.lang.String proxyIP,
java.lang.String proxyPort)
|
protected static java.lang.String |
getSearchPage(int page,
java.lang.String countryCode)
|
protected static java.lang.String |
getSearchPage(int page,
java.lang.String countryCode,
java.lang.String proxyIP,
java.lang.String proxyPort)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PageGetter
public PageGetter()
getPage
protected static java.lang.String getPage(java.lang.String url,
java.lang.String proxyIP,
java.lang.String proxyPort)
throws java.net.MalformedURLException,
java.io.IOException
- same as getPage, but using proxyserver
- Parameters:
url - String represantion of the URL to getproxyIP - ip of the proxy hostproxyPort - port of the proxy server
- Returns:
- String represantion of the site's HTML code
- Throws:
java.net.MalformedURLException
{@link - IOException}
java.io.IOException
getPage
protected static java.lang.String getPage(java.lang.String url)
throws java.net.MalformedURLException,
java.io.IOException
- Parameters:
url - String represantion of the URL to get
- Returns:
- String represantion of the site's HTML code
- Throws:
java.net.MalformedURLException
{@link - IOException}
java.io.IOException
getSearchPage
protected static java.lang.String getSearchPage(int page,
java.lang.String countryCode)
throws java.net.MalformedURLException,
java.io.IOException
- Parameters:
page - Pagenumber of the search-site to get
- Returns:
- String represantion of the site's HTML code
- Throws:
java.net.MalformedURLException
java.io.IOException
getSearchPage
protected static java.lang.String getSearchPage(int page,
java.lang.String countryCode,
java.lang.String proxyIP,
java.lang.String proxyPort)
throws java.net.MalformedURLException,
java.io.IOException
- Parameters:
page - Pagenumber of the search-site to getproxyIP - ip of the proxy hostproxyPort - port of the proxy server
- Returns:
- String represantion of the site's HTML code
- Throws:
java.net.MalformedURLException
java.io.IOException
getFriendsPage
public static java.lang.String getFriendsPage(int page,
int id,
java.lang.String viewstate)
throws java.net.MalformedURLException,
java.io.IOException
- Parameters:
page - Pagenumber of the friends-site to getid - the band's mySpace IDviewstate - myspace session or whatever this is ...
- Returns:
- String represantion of the site's HTML code
- Throws:
java.net.MalformedURLException
java.io.IOException
getFriendsPage
public static java.lang.String getFriendsPage(int page,
int id,
java.lang.String viewstate,
java.lang.String proxyIP,
java.lang.String proxyPort)
throws java.net.MalformedURLException,
java.io.IOException
- Parameters:
page - Pagenumber of the friends-site to getid - the band's mySpace IDviewstate - myspace session or whatever this is ...proxyIP - ip of the proxy hostproxyPort - port of the proxy server
- Returns:
- String represantion of the site's HTML code
- Throws:
java.net.MalformedURLException
java.io.IOException
getFirstFriendsPage
public static java.lang.String getFirstFriendsPage(int id)
throws java.net.MalformedURLException,
java.io.IOException
- Parameters:
id - the band's mySpace ID
- Returns:
- String represantion of the site's HTML code
- Throws:
java.net.MalformedURLException
java.io.IOException
getFirstFriendsPage
public static java.lang.String getFirstFriendsPage(int id,
java.lang.String proxyIP,
java.lang.String proxyPort)
throws java.net.MalformedURLException,
java.io.IOException
- Parameters:
id - the band's mySpace IDproxyIP - ip of the proxy hostproxyPort - port of the proxy server
- Returns:
- String represantion of the site's HTML code
- Throws:
java.net.MalformedURLException
java.io.IOException
getProfilePage
public static java.lang.String getProfilePage(int id)
throws java.net.MalformedURLException,
java.io.IOException
- Parameters:
id - id the band's mySpace ID
- Returns:
- String represantion of the site's HTML code
- Throws:
java.net.MalformedURLException
java.io.IOException
getProfilePage
public static java.lang.String getProfilePage(int id,
java.lang.String proxyIP,
java.lang.String proxyPort)
throws java.net.MalformedURLException,
java.io.IOException
- Parameters:
id - id the band's mySpace IDproxyIP - ip of the proxy hostproxyPort - port of the proxy server
- Returns:
- String represantion of the site's HTML code
- Throws:
java.net.MalformedURLException
java.io.IOException