@@ -82,14 +82,6 @@ public static XorPlus8 construct(long[] keys) {
8282 return new XorPlus8 (keys );
8383 }
8484
85- public XorPlus8 (int size , byte [] fingerprints ) {
86- this .size = size ;
87- this .arrayLength = getArrayLength (size );
88- this .bitCount = arrayLength * BITS_PER_FINGERPRINT ;
89- this .blockLength = arrayLength / HASHES ;
90- this .fingerprints = fingerprints ;
91- }
92-
9385 /**
9486 * Construct the filter. This is basically the BDZ algorithm. The algorithm
9587 * itself is basically the same as BDZ, except that xor is used to store the
@@ -110,7 +102,6 @@ public XorPlus8(int size, byte[] fingerprints) {
110102 public XorPlus8 (long [] keys ) {
111103 this .size = keys .length ;
112104 this .arrayLength = getArrayLength (size );
113- this .bitCount = arrayLength * BITS_PER_FINGERPRINT ;
114105 this .blockLength = arrayLength / HASHES ;
115106 int m = arrayLength ;
116107
@@ -366,10 +357,10 @@ public XorPlus8(InputStream in) {
366357 DataInputStream din = new DataInputStream (in );
367358 size = din .readInt ();
368359 arrayLength = getArrayLength (size );
369- bitCount = arrayLength * BITS_PER_FINGERPRINT ;
370360 blockLength = arrayLength / HASHES ;
371361 seed = din .readLong ();
372362 int fingerprintLength = din .readInt ();
363+ bitCount = fingerprintLength * BITS_PER_FINGERPRINT ;
373364 fingerprints = new byte [fingerprintLength ];
374365 din .readFully (fingerprints );
375366 rank = new Rank9 (din );
0 commit comments