0
私はJavaプロジェクトで(universal) family of pairwise independent hash functionsを使用する簡単かつ簡単な方法をお探しです。Javaのペア独立ハッシュ関数
理想的には、整数をハッシュするメソッドhash()
でオブジェクトを返すオブジェクトUniversalFamily
(ファミリーを表す)があります。
使用例:
// use this object to generate pairwise independent hash functions
UniversalFamily family = new UniversalFamily();
// these objects represent the pairwise independent hash functions
HashF hashF1 = fam.getHashFunction();
HashF hashF2 = fam.getHashFunction();
// ...
/* here the hash functions are being used to hash the integers 1, 2 and
1337, the return values (not stored) are the results of the
corresponding hash functions. */
hashF1.hash(1);
hashF1.hash(2);
hashF2.hash(1337);
// ...
私の周りいじり始める前に、すでに利用可能なこのようなものがありますか?
'hashF2.hash;' '1337'この例では何ですか? –
@ JigarJoshi整数です。私は整数をハッシュすることに興味があります。 –
私はこれが広すぎて話題にならないかもしれないと恐れています、あなたはちょっとお勧めです。とにかく、私はヘルプセクションに適切な行を見つけることができず、個人的にあなたの質問の明瞭さ(あなたが編集していると思う仕事の量)が好きなので、私はそれを報告しません。がんばろう。 –