Squeleton code for the global routing matrix. Most functions are left unimplemented, but

the basic structure is here. Functions have been added to serialise both SHA1 and floats.
The router is not yet enabled since protocol is likely to change again.




git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@6886 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2013-11-02 14:35:33 +00:00
parent 261d9102d4
commit e0863194a3
18 changed files with 1241 additions and 4 deletions

View file

@ -789,7 +789,16 @@ bool Sha1CheckSum::operator==(const Sha1CheckSum& s) const
return false ;
return true ;
}
bool Sha1CheckSum::operator<(const Sha1CheckSum& s) const
{
for(int i=0;i<5;++i)
if(fourbytes[i] < s.fourbytes[i])
return true ;
else if(fourbytes[i] > s.fourbytes[i])
return false ;
return false ;
}
std::string Sha1CheckSum::toStdString() const
{
static const char outl[16] = { '0','1','2','3','4','5','6','7','8','9','a','b','c','d','e','f' } ;