標籤:
Atitit.資料擷取器 dataspider
/atiplat_cms/src/com/attilax/WebInfoX.java @dep
http://cl.cmcher.com/thread0806.php?fid=16&search=&page=2
/atiplat_cms/src/com/attilax/dataspider/TsaolyoNetDataSpider.java
爬蟲注意事項
設定useragent as ff
https的注意。。
主要是因為Java自己的HttpURLConnection對SSL支援的不好,而且控制起來不太方便,而且HttpClient還支援抓取非信任的網站,別的實現方式貌似需要在代碼中顯式匯入認證。
作者:: 綽號:老哇的爪子 ( 全名::Attilax Akbar Al Rapanui 阿提拉克斯 阿克巴 阿爾 拉帕努伊 ) 漢字名:艾龍, EMAIL:[email protected]
轉載請註明來源: http://www.cnblogs.com/attilax/
需要override打三個函數
public List<String> getpageUrls()
public List getArtListByPagehtml(String html) {
public List<String> getPics_byHtml
使用方法與參數
TsaolyoNetDataSpider x = new TsaolyoNetDataSpider();
// x.fileName=args[0];// "c:\\r2.csv";
x.picSaveDir = "c:\\0picSaveDir";
x.startPage = Integer.parseInt(System.getProperty("startPage", "1"));
x.endPage = Integer.parseInt(System.getProperty("endPage"));
;
x.exec();
Atitit.資料擷取器 dataspider