| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 1981 人关注过本帖
标题:The search technique what I thought
只看楼主 加入收藏
kai
Rank: 16Rank: 16Rank: 16Rank: 16
等 级:版主
威 望:52
帖 子:3450
专家分:59
注 册:2004-4-25
收藏
得分:0 
myajax95,

ich kann wirklich sehr schnell in Deutsch schreiben. Mein Deutschkenntnis is viel besser als Englisch.

I can really very quickly write in german. My german is much better than english.

自由,民主,平等,博爱,进步.
中华民国,我的祖国,中华民国万岁!中华民国加油!
本人自愿加入中国国民党,为人的自由性,独立性和平等性而奋斗!
2006-07-25 01:02
ysol
Rank: 1
等 级:新手上路
帖 子:107
专家分:0
注 册:2006-6-11
收藏
得分:0 

kai!
nice to meet you too!

佩服LZ懂至少4种语言哈哈!羡慕ing.

2006-07-25 01:23
kai
Rank: 16Rank: 16Rank: 16Rank: 16
等 级:版主
威 望:52
帖 子:3450
专家分:59
注 册:2004-4-25
收藏
得分:0 
ysol,
not 4, but just 3 arts Language.

自由,民主,平等,博爱,进步.
中华民国,我的祖国,中华民国万岁!中华民国加油!
本人自愿加入中国国民党,为人的自由性,独立性和平等性而奋斗!
2006-07-25 02:23
myajax95
Rank: 16Rank: 16Rank: 16Rank: 16
等 级:版主
威 望:30
帖 子:2978
专家分:0
注 册:2006-3-5
收藏
得分:0 
以下是引用kai在2006-7-25 0:59:45的发言:
myajax95,

a listener is just an extern object, and every file object just add the listener. code like this.

For example you have tree structure for your file system. I name it fileTree

MySearchListener msl = new MySearchListener();
fileTree.add(msl);

// code for search

fileTree.doSearch( your search content );

So What is the content of a file? Is it representing one object or a collection of objects. If it is for one object, there might be too many files. If not, the collection of files just conduct the same function as table. you still needs to build relationships with all files.

[此贴子已经被作者于2006-7-25 2:45:45编辑过]


http://myajax95./
2006-07-25 02:44
kai
Rank: 16Rank: 16Rank: 16Rank: 16
等 级:版主
威 望:52
帖 子:3450
专家分:59
注 册:2004-4-25
收藏
得分:0 
myajax95,

think about the date structure from Tree, a tree has a root, the root can be null, or can also be an object. root stands in level 0, then in level1 are the childreen of roots, any child can also has his child, they stand in his next level. Only the object that has no child more, is leaf. In a file system, the leaf is the object, that consists of a file, the others are the objects, that consist of more objects(his children), it could be so that, there were leafs in his children or nonleaf fileobject in his children.

summerization:
A file system consists of file object, a file object could be a leaf or nonleaf. A leaf in file system is a file object, that has a file. My Idea is, every file object will have a listener, that mean a listener will be added in a file object. Searching in a file system, will like something, water go through all pipes. In level one a listener will some response, that mean, he will ask himself, if he is leaf, when yes, then search the file, when no, then search his children, and the his children make the same thing. Pay attention here, when a file object is not a leaf, he will make all his children active, because every file object is a thread, active a file object then this file object will do search. So in a very quickly time, All file object in this file system will be actived and start their searching work, so that many searching works will be done in the same time, that is concurrent.

I will implement it recently in java.

自由,民主,平等,博爱,进步.
中华民国,我的祖国,中华民国万岁!中华民国加油!
本人自愿加入中国国民党,为人的自由性,独立性和平等性而奋斗!
2006-07-25 09:39
myajax95
Rank: 16Rank: 16Rank: 16Rank: 16
等 级:版主
威 望:30
帖 子:2978
专家分:0
注 册:2006-3-5
收藏
得分:0 
Kai:

I think I'm kind of understand your idea. And the second paragraph looks familiar to me. I forgot where I read that.

Althrough every file has a listener, are you going to active all of them or only files on root level get actived, and the root file will active its children based on the search condition?

I'm not doubting about the feasibility of your approach. But I guess you need to prove that searching through a file system is really different than seaching through traditional Database table, and its performance it really better. That might be your challange.

[此贴子已经被作者于2006-7-25 11:17:29编辑过]


http://myajax95./
2006-07-25 10:04
baidu
Rank: 3Rank: 3
等 级:新手上路
威 望:8
帖 子:3811
专家分:0
注 册:2005-11-4
收藏
得分:0 
请myajax95将此移到
http://www.

偶放弃所有文章版权,偶在BCCN论坛任何贴子,可转贴,可散发,可抄袭,可复制,可被冒名顶替,可被任何人引用到任何文章中且不写出引文出处,偶分文不取。
2006-07-25 10:07
nick_annie
Rank: 1
等 级:新手上路
帖 子:105
专家分:0
注 册:2005-11-19
收藏
得分:0 
以下是引用kai在2006-7-25 1:02:02的发言:
myajax95,

ich kann wirklich sehr schnell in Deutsch schreiben. Mein Deutschkenntnis is viel besser als Englisch.

I can really very quickly write in german. My german is much better than english.

Mandarin,English,even German!
Well,in the future,if have chances,could i have a talk to you in Shanghai dialect?


2006-07-25 10:59
kai
Rank: 16Rank: 16Rank: 16Rank: 16
等 级:版主
威 望:52
帖 子:3450
专家分:59
注 册:2004-4-25
收藏
得分:0 
ku yi a. me wen ti.

自由,民主,平等,博爱,进步.
中华民国,我的祖国,中华民国万岁!中华民国加油!
本人自愿加入中国国民党,为人的自由性,独立性和平等性而奋斗!
2006-07-25 11:03
nick_annie
Rank: 1
等 级:新手上路
帖 子:105
专家分:0
注 册:2005-11-19
收藏
得分:0 
哈哈..个的比参啊拉饿"关税"区了.....

2006-07-25 11:13
快速回复:The search technique what I thought
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.033952 second(s), 7 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved