File tree Expand file tree Collapse file tree 1 file changed +0
-29
lines changed
fastfilter/src/main/java/org/fastfilter/xor Expand file tree Collapse file tree 1 file changed +0
-29
lines changed Original file line number Diff line number Diff line change 11package org .fastfilter .xor ;
22
3- import java .io .*;
43import java .nio .ByteBuffer ;
54
65import org .fastfilter .Filter ;
@@ -164,34 +163,6 @@ private int fingerprint(long hash) {
164163 return (int ) (hash & ((1 << BITS_PER_FINGERPRINT ) - 1 ));
165164 }
166165
167- public byte [] getData () {
168- try {
169- ByteArrayOutputStream out = new ByteArrayOutputStream ();
170- DataOutputStream d = new DataOutputStream (out );
171- d .writeInt (size );
172- d .writeLong (seed );
173- d .write (fingerprints );
174- return out .toByteArray ();
175- } catch (IOException e ) {
176- throw new RuntimeException (e );
177- }
178- }
179-
180- public Xor8 (InputStream in ) {
181- try {
182- DataInputStream din = new DataInputStream (in );
183- size = din .readInt ();
184- arrayLength = getArrayLength (size );
185- bitCount = arrayLength * BITS_PER_FINGERPRINT ;
186- blockLength = arrayLength / HASHES ;
187- seed = din .readLong ();
188- fingerprints = new byte [arrayLength ];
189- din .readFully (fingerprints );
190- } catch (IOException e ) {
191- throw new RuntimeException (e );
192- }
193- }
194-
195166 private Xor8 (int size , long seed , byte [] fingerprints ) {
196167 this .size = size ;
197168 this .arrayLength = getArrayLength (size );
You can’t perform that action at this time.
0 commit comments