org.apache.lucene.store.BufferedChecksum Java Examples
The following examples show how to use
org.apache.lucene.store.BufferedChecksum.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: RedisOutputStream.java From RedisDirectory with Apache License 2.0 | 5 votes |
private RedisOutputStream(String indexFileName, InputOutputStream inputOutputStream, boolean checksum) { super(indexFileName); this.currentBufferIndex = -1; this.currentBuffer = null; this.indexFileName = indexFileName; this.redisFile = new RedisFile(); this.inputOutputStream = inputOutputStream; if (checksum) { crc = new BufferedChecksum(new CRC32()); } else { crc = null; } }
Example #2
Source File: BufferedChecksumStreamInput.java From Elasticsearch with Apache License 2.0 | 5 votes |
public BufferedChecksumStreamInput(StreamInput in, BufferedChecksumStreamInput reuse) { this.in = in; if (reuse == null ) { this.digest = new BufferedChecksum(new CRC32()); } else { this.digest = reuse.digest; digest.reset(); this.skipBuffer = reuse.skipBuffer; } }
Example #3
Source File: RedisOutputStream.java From RedisDirectory with Apache License 2.0 | 5 votes |
private RedisOutputStream(String indexFileName, InputOutputStream inputOutputStream, boolean checksum) { super(indexFileName); this.currentBufferIndex = -1; this.currentBuffer = null; this.indexFileName = indexFileName; this.redisFile = new RedisFile(); this.inputOutputStream = inputOutputStream; if (checksum) { crc = new BufferedChecksum(new CRC32()); } else { crc = null; } }
Example #4
Source File: GridLuceneOutputStream.java From ignite with Apache License 2.0 | 5 votes |
/** * Constructor. * * @param f File. */ public GridLuceneOutputStream(GridLuceneFile f) { super("RAMOutputStream(name=\"noname\")", "noname"); file = f; mem = f.getDirectory().memory(); // make sure that we switch to the // first needed buffer lazily currBufIdx = -1; currBuf = 0; crc = new BufferedChecksum(new CRC32()); }
Example #5
Source File: BufferedChecksumStreamInput.java From crate with Apache License 2.0 | 5 votes |
public BufferedChecksumStreamInput(StreamInput in, String source, BufferedChecksumStreamInput reuse) { super(in); this.source = source; if (reuse == null) { this.digest = new BufferedChecksum(new CRC32()); } else { this.digest = reuse.digest; digest.reset(); this.skipBuffer = reuse.skipBuffer; } }
Example #6
Source File: BufferedChecksumStreamOutput.java From Elasticsearch with Apache License 2.0 | 4 votes |
public BufferedChecksumStreamOutput(StreamOutput out) { this.out = out; this.digest = new BufferedChecksum(new CRC32()); }
Example #7
Source File: BufferedChecksumStreamInput.java From Elasticsearch with Apache License 2.0 | 4 votes |
public BufferedChecksumStreamInput(StreamInput in) { this.in = in; this.digest = new BufferedChecksum(new CRC32()); }
Example #8
Source File: BufferedChecksumStreamOutput.java From crate with Apache License 2.0 | 4 votes |
public BufferedChecksumStreamOutput(StreamOutput out) { this.out = out; this.digest = new BufferedChecksum(new CRC32()); }
Example #9
Source File: Store.java From crate with Apache License 2.0 | 4 votes |
VerifyingIndexInput(IndexInput input) { this(input, new BufferedChecksum(new CRC32())); }