亚洲欧美日韩自偷自拍,国产大陆亚洲精品国产,亚洲欧美在线x视频http://m.tkk7.com/xmp123/自己的小屋的blogzh-cnMon, 12 May 2025 06:34:51 GMTMon, 12 May 2025 06:34:51 GMT60Nutch-Crawl: org.apache.nutch.protocol.ProtocolNotFound: protocol not found for url=httphttp://m.tkk7.com/xmp123/archive/2008/07/10/213905.html自己的小屋自己的小屋Thu, 10 Jul 2008 03:38:00 GMThttp://m.tkk7.com/xmp123/archive/2008/07/10/213905.htmlhttp://m.tkk7.com/xmp123/comments/213905.htmlhttp://m.tkk7.com/xmp123/archive/2008/07/10/213905.html#Feedback0http://m.tkk7.com/xmp123/comments/commentRss/213905.htmlhttp://m.tkk7.com/xmp123/services/trackbacks/213905.html
08/07/07 04:05:41 INFO conf.Configuration: found resource crawl-urlfilter.txt at file:/home/hut/installfiles/nutch-0.9/out/production/nutch-0.9/crawl-urlfilter.txt
08/07/07 04:05:41 INFO conf.Configuration: found resource parse-plugins.xml at file:/home/hut/installfiles/nutch-0.9/out/production/nutch-0.9/parse-plugins.xml
08/07/07 04:05:41 INFO fetcher.Fetcher: fetching http://www.yale.edu/
08/07/07 04:05:41 INFO fetcher.Fetcher: fetching http://www.harvard.edu/
08/07/07 04:05:41 INFO fetcher.Fetcher: fetch of http://www.harvard.edu/ failed with: org.apache.nutch.protocol.ProtocolNotFound: protocol not found for url=http
08/07/07 04:05:41 INFO fetcher.Fetcher: fetch of http://www.yale.edu/ failed with: org.apache.nutch.protocol.ProtocolNotFound: protocol not found for url=http

解決方法:nutch-site.xml
    <property>
        
<name>plugin.includes</name>
        
<value>
            nutch-extensionpoints|
protocol-http|urlfilter-regex|parse-(text|html|js)|index-basic|query-(basic|site|url)|summary-basic|scoring-opic|urlnormalizer-(pass|regex|basic)
        
</value>
        
<description>Regular expression naming plugin directory names to
            include. Any plugin not matching 
this expression is excluded.
            In any 
case you need at least include the nutch-extensionpoints plugin. By
            
default Nutch includes crawling just HTML and plain text via HTTP,
            and basic indexing and search plugins. In order to use HTTPS please enable
            protocol
-httpclient, but be aware of possible intermittent problems with the
            underlying commons
-httpclient library.
        
</description>
    
</property>

nutch-extensionpoints|被我錯誤的刪除了,還原以后一切工作正常. 默認情況下nutch0.9的目錄結構中并沒有plugin.includes這個properties, 它會載入nutch-default.xml里面的plugin.includes所以定義的所有的plugin. 在nutch-site.xml編輯/加入 plugin.includes properties的目的是為了加入我們自己的plugin而覆蓋nutch-default.xml定義的.


自己的小屋 2008-07-10 11:38 發表評論
]]>
Nutch-Crawl: ArrayIndexOutOfBoundsException http://m.tkk7.com/xmp123/archive/2008/07/10/213904.html自己的小屋自己的小屋Thu, 10 Jul 2008 03:32:00 GMThttp://m.tkk7.com/xmp123/archive/2008/07/10/213904.htmlhttp://m.tkk7.com/xmp123/comments/213904.htmlhttp://m.tkk7.com/xmp123/archive/2008/07/10/213904.html#Feedback0http://m.tkk7.com/xmp123/comments/commentRss/213904.htmlhttp://m.tkk7.com/xmp123/services/trackbacks/213904.html

java.lang.ArrayIndexOutOfBoundsException: -1

at org.apache.lucene.index.MultiReader.isDeleted(MultiReader.java:
113)

at org.apache.nutch.indexer.DeleteDuplicates$InputFormat$DDRecordReader.next(DeleteDuplicates.java:
176)

at org.apache.hadoop.mapred.MapTask$
1.next(MapTask.java:157)

at org.apache.hadoop.mapred.MapRunner.run(MapRunner.java:
46)

at org.apache.hadoop.mapred.MapTask.run(MapTask.java:
175)

at org.apache.hadoop.mapred.LocalJobRunner$Job.run(LocalJobRunner.java:
126)

Exception in thread 
"main" java.io.IOException: Job failed!

at org.apache.hadoop.mapred.JobClient.runJob(JobClient.java:
604)

at org.apache.nutch.indexer.DeleteDuplicates.dedup(DeleteDuplicates.java:
439)

at org.apache.nutch.crawl.Crawl.main(Crawl.java:
135)

問題的解決方法:

https://issues.apache.org/jira/browse/NUTCH-525?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12515955





自己的小屋 2008-07-10 11:32 發表評論
]]>
定位Java類中的每個方法在類文件中的位置(終結篇)http://m.tkk7.com/xmp123/archive/2007/08/15/136997.html自己的小屋自己的小屋Wed, 15 Aug 2007 09:56:00 GMThttp://m.tkk7.com/xmp123/archive/2007/08/15/136997.htmlhttp://m.tkk7.com/xmp123/comments/136997.htmlhttp://m.tkk7.com/xmp123/archive/2007/08/15/136997.html#Feedback0http://m.tkk7.com/xmp123/comments/commentRss/136997.htmlhttp://m.tkk7.com/xmp123/services/trackbacks/136997.html定位Java類中的每個方法在類文件中的位置>
引起了幾個大蝦的注意并且給我指點,當時看了以后也沒有怎么弄,也不知道怎么弄.

這是cape給我的建議:

最直接的辦法應該是分析class的bytecode,找到每個Method_info->Code Attribute->LineNumberTable Attribute

今天空閑得慌而是我拿這個method linenumber幾個keyword在網上狂搜了一把,
http://www.ibm.com/developerworks/cn/java/j-dyn0302/index.html

得到美文一篇,用Javassist來做. Javassist是一個專門操控java class的bytecode的類,可以動態的改變其狀態,我沒有深究它到底有多大的能耐,有興趣可以去它的官方網站看看,

http://www.csg.is.titech.ac.jp/~chiba/javassist/

但是它確實可以象cape指點的那樣,讓我實現對java類中的每個方法的定位(得到類中的某個方法的lineRange)

而是我就隨便翻了幾個例子以后根據在線文檔寫了不到100行代碼輕松搞定。:) 我高興啊。

干這個事情的兩個java的source code可以從這里得到:

http://m.tkk7.com/Files/xmp123/MethodParser.zip

代碼很簡單,我就不解釋代碼了。

這是示例結果:
------------------------------------------------------------------------------------------------------------------------------
Analyzing net.blogjava.xmp123.MyMethodInfo ...
net.blogjava.xmp123.MyMethodInfo.getLineList() locate between 56 and 56

net.blogjava.xmp123.MyMethodInfo.updateLineList() locate between 63 and 80

net.blogjava.xmp123.MyMethodInfo.addLineToLineList(int) locate between 87 and 89

net.blogjava.xmp123.MyMethodInfo.setLineList(java.util.List) locate between 95 and 97
...
------------------------------------------------------------------------------------------------------------------------------

希望這東西有用......


自己的小屋 2007-08-15 17:56 發表評論
]]>
定位Java類中的每個方法在類文件中的位置. http://m.tkk7.com/xmp123/archive/2007/03/12/103332.html自己的小屋自己的小屋Mon, 12 Mar 2007 07:40:00 GMThttp://m.tkk7.com/xmp123/archive/2007/03/12/103332.htmlhttp://m.tkk7.com/xmp123/comments/103332.htmlhttp://m.tkk7.com/xmp123/archive/2007/03/12/103332.html#Feedback9http://m.tkk7.com/xmp123/comments/commentRss/103332.htmlhttp://m.tkk7.com/xmp123/services/trackbacks/103332.html閱讀全文

自己的小屋 2007-03-12 15:40 發表評論
]]>
java io對文件的一些使用的操作http://m.tkk7.com/xmp123/archive/2006/10/24/76919.html自己的小屋自己的小屋Tue, 24 Oct 2006 03:02:00 GMThttp://m.tkk7.com/xmp123/archive/2006/10/24/76919.htmlhttp://m.tkk7.com/xmp123/comments/76919.htmlhttp://m.tkk7.com/xmp123/archive/2006/10/24/76919.html#Feedback0http://m.tkk7.com/xmp123/comments/commentRss/76919.htmlhttp://m.tkk7.com/xmp123/services/trackbacks/76919.html這東西比較有用:[轉載].出處:http://mike20049.spaces.live.com/mmm2006-09-13_01.00/
我收藏啦.:)
import java.io.*;

public class FileOperate {
? public FileOperate() {
? }

? /**
?? * 新建目錄
?? * @param folderPath String 如 c:/fqf
?? * @return boolean
?? */
? public void newFolder(String folderPath) {
??? try {
????? String filePath = folderPath;
????? filePath = filePath.toString();
????? java.io.File myFilePath = new java.io.File(filePath);
????? if (!myFilePath.exists()) {
??????? myFilePath.mkdir();
????? }
??? }
??? catch (Exception e) {
????? System.out.println("新建目錄操作出錯");
????? e.printStackTrace();
??? }
? }

? /**
?? * 新建文件
?? * @param filePathAndName String 文件路徑及名稱 如c:/fqf.txt
?? * @param fileContent String 文件內容
?? * @return boolean
?? */
? public void newFile(String filePathAndName, String fileContent) {

??? try {
????? String filePath = filePathAndName;
????? filePath = filePath.toString();
????? File myFilePath = new File(filePath);
????? if (!myFilePath.exists()) {
??????? myFilePath.createNewFile();
????? }
????? FileWriter resultFile = new FileWriter(myFilePath);
????? PrintWriter myFile = new PrintWriter(resultFile);
????? String strContent = fileContent;
????? myFile.println(strContent);
????? resultFile.close();

??? }
??? catch (Exception e) {
????? System.out.println("新建目錄操作出錯");
????? e.printStackTrace();

??? }

? }

? /**
?? * 刪除文件
?? * @param filePathAndName String 文件路徑及名稱 如c:/fqf.txt
?? * @param fileContent String
?? * @return boolean
?? */
? public void delFile(String filePathAndName) {
??? try {
????? String filePath = filePathAndName;
????? filePath = filePath.toString();
????? java.io.File myDelFile = new java.io.File(filePath);
????? myDelFile.delete();

??? }
??? catch (Exception e) {
????? System.out.println("刪除文件操作出錯");
????? e.printStackTrace();

??? }

? }

? /**
?? * 刪除文件夾
?? * @param filePathAndName String 文件夾路徑及名稱 如c:/fqf
?? * @param fileContent String
?? * @return boolean
?? */
? public void delFolder(String folderPath) {
??? try {
????? delAllFile(folderPath); //刪除完里面所有內容
????? String filePath = folderPath;
????? filePath = filePath.toString();
????? java.io.File myFilePath = new java.io.File(filePath);
????? myFilePath.delete(); //刪除空文件夾

??? }
??? catch (Exception e) {
????? System.out.println("刪除文件夾操作出錯");
????? e.printStackTrace();

??? }

? }

? /**
?? * 刪除文件夾里面的所有文件
?? * @param path String 文件夾路徑 如 c:/fqf
?? */
? public void delAllFile(String path) {
??? File file = new File(path);
??? if (!file.exists()) {
????? return;
??? }
??? if (!file.isDirectory()) {
????? return;
??? }
??? String[] tempList = file.list();
??? File temp = null;
??? for (int i = 0; i < tempList.length; i++) {
????? if (path.endsWith(File.separator)) {
??????? temp = new File(path + tempList[i]);
????? }
????? else {
??????? temp = new File(path + File.separator + tempList[i]);
????? }
????? if (temp.isFile()) {
??????? temp.delete();
????? }
????? if (temp.isDirectory()) {
??????? delAllFile(path+"/"+ tempList[i]);//先刪除文件夾里面的文件
??????? delFolder(path+"/"+ tempList[i]);//再刪除空文件夾
????? }
??? }
? }

? /**
?? * 復制單個文件
?? * @param oldPath String 原文件路徑 如:c:/fqf.txt
?? * @param newPath String 復制后路徑 如:f:/fqf.txt
?? * @return boolean
?? */
? public void copyFile(String oldPath, String newPath) {
??? try {
????? int bytesum = 0;
????? int byteread = 0;
????? File oldfile = new File(oldPath);
????? if (oldfile.exists()) { //文件存在時
??????? InputStream inStream = new FileInputStream(oldPath); //讀入原文件
??????? FileOutputStream fs = new FileOutputStream(newPath);
??????? byte[] buffer = new byte[1444];
??????? int length;
??????? while ( (byteread = inStream.read(buffer)) != -1) {
????????? bytesum += byteread; //字節數 文件大小
????????? System.out.println(bytesum);
????????? fs.write(buffer, 0, byteread);
??????? }
??????? inStream.close();
????? }
??? }
??? catch (Exception e) {
????? System.out.println("復制單個文件操作出錯");
????? e.printStackTrace();

??? }

? }

? /**
?? * 復制整個文件夾內容
?? * @param oldPath String 原文件路徑 如:c:/fqf
?? * @param newPath String 復制后路徑 如:f:/fqf/ff
?? * @return boolean
?? */
? public void copyFolder(String oldPath, String newPath) {

??? try {
????? (new File(newPath)).mkdirs(); //如果文件夾不存在 則建立新文件夾
????? File a=new File(oldPath);
????? String[] file=a.list();
????? File temp=null;
????? for (int i = 0; i < file.length; i++) {
??????? if(oldPath.endsWith(File.separator)){
????????? temp=new File(oldPath+file[i]);
??????? }
??????? else{
????????? temp=new File(oldPath+File.separator+file[i]);
??????? }

??????? if(temp.isFile()){
????????? FileInputStream input = new FileInputStream(temp);
????????? FileOutputStream output = new FileOutputStream(newPath + "/" +
????????????? (temp.getName()).toString());
????????? byte[] b = new byte[1024 * 5];
????????? int len;
????????? while ( (len = input.read(b)) != -1) {
??????????? output.write(b, 0, len);
????????? }
????????? output.flush();
????????? output.close();
????????? input.close();
??????? }
??????? if(temp.isDirectory()){//如果是子文件夾
????????? copyFolder(oldPath+"/"+file[i],newPath+"/"+file[i]);
??????? }
????? }
??? }
??? catch (Exception e) {
????? System.out.println("復制整個文件夾內容操作出錯");
????? e.printStackTrace();

??? }

? }

? /**
?? * 移動文件到指定目錄
?? * @param oldPath String 如:c:/fqf.txt
?? * @param newPath String 如:d:/fqf.txt
?? */
? public void moveFile(String oldPath, String newPath) {
??? copyFile(oldPath, newPath);
??? delFile(oldPath);

? }

? /**
?? * 移動文件到指定目錄
?? * @param oldPath String 如:c:/fqf.txt
?? * @param newPath String 如:d:/fqf.txt
?? */
? public void moveFolder(String oldPath, String newPath) {
??? copyFolder(oldPath, newPath);
??? delFolder(oldPath);

? }
}



自己的小屋 2006-10-24 11:02 發表評論
]]>
做了一個解析Java類的小東西.http://m.tkk7.com/xmp123/archive/2006/09/30/73077.html自己的小屋自己的小屋Sat, 30 Sep 2006 09:12:00 GMThttp://m.tkk7.com/xmp123/archive/2006/09/30/73077.htmlhttp://m.tkk7.com/xmp123/comments/73077.htmlhttp://m.tkk7.com/xmp123/archive/2006/09/30/73077.html#Feedback0http://m.tkk7.com/xmp123/comments/commentRss/73077.htmlhttp://m.tkk7.com/xmp123/services/trackbacks/73077.html
Mission: 檢測出java類中的所有的方法,以及這些方法在文件位于哪兩行之間.

碰到的問題:

1. 對付重載函數。
2. 如果一個方法占多行。

怎么解決:
1.利用反射得到他們所有的參數,但是某一行是不是含有所有的這樣的參數。
2.根據{來判斷,如果讀到的當前行包含方法的聲明,但是不包含{,那么此時就要保存好當前Readline讀取的內容,然后可以用StringBuffer append一下,在下一個Readline再做比較。

不支持:
比如
public static void main(String[] args)和? // 不支持。因為判斷的時候,前面是作為一個整體來判斷的。

public static? void main(String[] args),

當然這點我們完全可以實現。:)

敢興趣的朋友可以和我聯系:hut@hf.webex.com








自己的小屋 2006-09-30 17:12 發表評論
]]>
從今天開始,這個blog記錄這我的java學習經歷。希望能和大家一起探討。http://m.tkk7.com/xmp123/archive/2006/09/20/70746.html自己的小屋自己的小屋Wed, 20 Sep 2006 03:58:00 GMThttp://m.tkk7.com/xmp123/archive/2006/09/20/70746.htmlhttp://m.tkk7.com/xmp123/comments/70746.htmlhttp://m.tkk7.com/xmp123/archive/2006/09/20/70746.html#Feedback8http://m.tkk7.com/xmp123/comments/commentRss/70746.htmlhttp://m.tkk7.com/xmp123/services/trackbacks/70746.html

自己的小屋 2006-09-20 11:58 發表評論
]]>
主站蜘蛛池模板: 亚洲乱码中文字幕手机在线| 亚洲A∨无码无在线观看| 国产精品亚洲专区无码不卡| 亚洲av成人一区二区三区在线观看 | 狼色精品人妻在线视频免费| 亚洲情XO亚洲色XO无码| 13一14周岁毛片免费| 亚洲av无码一区二区三区在线播放| 亚洲一区二区三区乱码A| 污污网站免费观看| 亚洲爆乳无码专区www| 区久久AAA片69亚洲| 国产99视频精品免费观看7| 边摸边脱吃奶边高潮视频免费| 午夜亚洲AV日韩AV无码大全| 午夜免费不卡毛片完整版| 国产成人无码免费看片软件| 亚洲国产精品成人久久久| 亚洲一区日韩高清中文字幕亚洲| 久久精品免费一区二区| 黄色a级免费网站| 亚洲国产成人va在线观看网址| 亚洲?V无码乱码国产精品| 久草视频在线免费| 一级毛片免费不卡直观看| 亚洲天堂2017无码中文| 亚洲色无码专区在线观看| 日韩免费视频在线观看| 日韩精品无码一区二区三区免费| 免费无毒a网站在线观看| 亚洲人成网站在线观看播放青青| 国产亚洲日韩在线三区| 免费爱爱的视频太爽了| 亚洲网站免费观看| 三级黄色免费观看| 深夜福利在线免费观看| 亚洲av无码专区在线观看亚| 亚洲Av无码一区二区二三区| 久久亚洲国产伦理| 中文亚洲AV片在线观看不卡| 国产成人免费片在线观看 |