Logo Search packages:      
Sourcecode: djvulibre version File versions

unsigned int hash ( const GURL gurl  )  [friend]

Hashing function.

Returns:
hash suitable for usage in {GMap}

Definition at line 1961 of file GURL.cpp.

{
  unsigned int retval;
  const GUTF8String s(gurl.get_string());
  const int len=s.length();
  if(len && (s[len-1] == '/')) // Don't include the trailing slash as part of the hash.
  {
      retval=hash(s.substr(0,len-1));
  }else
  {
    retval=hash(s);
  }
  return retval;
}


Generated by  Doxygen 1.6.0   Back to index