- Integrated the turtle search and download to the gui. Now the search handles both friend and turtle searching.

- added a console in config->server->F2F routing to be able to visualize turtle routing statistics

WARNING: this is not complete yet. The fllowing still needs to be done:
- detect duplicates in search results between turtle and friends search
- RegExpr search does ot work with turtle (still to code).
- search does not search own files. Is this really needed after all ?



git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@1540 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2009-08-16 20:10:53 +00:00
parent 44efa071f4
commit a293a39d1b
17 changed files with 384 additions and 160 deletions

View file

@ -29,6 +29,7 @@
#include <inttypes.h>
#include <string>
#include <list>
#include <vector>
class RsTurtle;
extern RsTurtle *rsTurtle ;
@ -56,11 +57,11 @@ struct TurtleFileInfo
class RsTurtle
{
public:
enum FileSharingStrategy { SHARE_ENTIRE_NETWORK, SHARE_FRIENDS_ONLY } ;
RsTurtle() { _sharing_strategy = SHARE_ENTIRE_NETWORK ;}
virtual ~RsTurtle() {}
enum FileSharingStrategy { SHARE_ENTIRE_NETWORK, SHARE_FRIENDS_ONLY } ;
// Lauches a search request through the pipes, and immediately returns
// the request id, which will be further used by the gui to store results
// as they come back.
@ -85,6 +86,10 @@ class RsTurtle
void setFileSharingStrategy(FileSharingStrategy f) { _sharing_strategy = f ; }
// Get info from the turtle router. I use std strings to hide the internal structs.
virtual void getInfo(std::vector<std::vector<std::string> >&,std::vector<std::vector<std::string> >&,
std::vector<std::vector<std::string> >&,std::vector<std::vector<std::string> >&) const = 0;
protected:
FileSharingStrategy _sharing_strategy ;
};