Tabnine Logo
IndexInput.readVLong
Code IndexAdd Tabnine to your IDE (free)

How to use
readVLong
method
in
org.apache.lucene.store.IndexInput

Best Java code snippets using org.apache.lucene.store.IndexInput.readVLong (Showing top 20 results out of 315)

origin: org.apache.lucene/lucene-core

/** Seeks the skip entry on the given level */
protected void seekChild(int level) throws IOException {
 skipStream[level].seek(lastChildPointer);
 numSkipped[level] = numSkipped[level + 1] - skipInterval[level + 1];
 skipDoc[level] = lastDoc;
 if (level > 0) {
  childPointer[level] = skipStream[level].readVLong() + skipPointer[level - 1];
 }
}
origin: org.apache.lucene/lucene-core

 throw new IOException("Invalid vLong detected (negative values disallowed)");
} else {
 return super.readVLong();
origin: org.apache.lucene/lucene-core

 @Override
 protected int readSkipData(int level, IndexInput skipStream) throws IOException {
  int delta = skipStream.readVInt();
  docPointer[level] += skipStream.readVLong();

  if (posPointer != null) {
   posPointer[level] += skipStream.readVLong();
   posBufferUpto[level] = skipStream.readVInt();

   if (payloadByteUpto != null) {
    payloadByteUpto[level] = skipStream.readVInt();
   }

   if (payPointer != null) {
    payPointer[level] += skipStream.readVLong();
   }
  }
  return delta;
 }
}
origin: org.apache.lucene/lucene-core

private boolean loadNextSkip(int level) throws IOException {
 // we have to skip, the target document is greater than the current
 // skip list entry        
 setLastSkipData(level);
  
 numSkipped[level] += skipInterval[level];
 // numSkipped may overflow a signed int, so compare as unsigned.
 if (Integer.compareUnsigned(numSkipped[level], docCount) > 0) {
  // this skip list is exhausted
  skipDoc[level] = Integer.MAX_VALUE;
  if (numberOfSkipLevels > level) numberOfSkipLevels = level; 
  return false;
 }
 // read next skip entry
 skipDoc[level] += readSkipData(level, skipStream[level]);
 
 if (level != 0) {
  // read the child pointer if we are not on the leaf level
  childPointer[level] = skipStream[level].readVLong() + skipPointer[level - 1];
 }
 
 return true;
}

origin: org.apache.lucene/lucene-core

int count = in.readVInt();
for(int i=0;i<count;i++) {
 long commitGen = in.readVLong();
 int refCount = in.readVInt();
 m.put(commitGen, refCount);
origin: org.apache.lucene/lucene-core

long length = skipStream[0].readVLong();
origin: org.apache.lucene/lucene-core

pointCount = in.readVLong();
docCount = in.readVInt();
 long lastFP = 0;
 for(int i=0;i<numLeaves;i++) {
  long delta = in.readVLong();
  leafBlockFPs[i] = lastFP + delta;
  lastFP += delta;
origin: org.apache.lucene/lucene-core

final long numTerms = termsIn.readVLong();
if (numTerms <= 0) {
 throw new CorruptIndexException("Illegal numTerms for field number: " + field, termsIn);
 throw new CorruptIndexException("invalid field number: " + field, termsIn);
final long sumTotalTermFreq = fieldInfo.getIndexOptions() == IndexOptions.DOCS ? -1 : termsIn.readVLong();
final long sumDocFreq = termsIn.readVLong();
final int docCount = termsIn.readVInt();
final int longsSize = termsIn.readVInt();
 throw new CorruptIndexException("invalid sumTotalTermFreq: " + sumTotalTermFreq + " sumDocFreq: " + sumDocFreq, termsIn);
final long indexStartFP = indexIn.readVLong();
FieldReader previous = fields.put(fieldInfo.name,       
                 new FieldReader(this, fieldInfo, numTerms, rootCode, sumTotalTermFreq, sumDocFreq, docCount,
origin: org.apache.lucene/lucene-core

startPointers[blockCount] = fieldsIndexIn.readVLong();
avgChunkSizes[blockCount] = fieldsIndexIn.readVLong();
final int bitsPerStartPointer = fieldsIndexIn.readVInt();
if (bitsPerStartPointer > 64) {
origin: org.apache.lucene/lucene-core

numChunks = fieldsStream.readVLong();
numDirtyChunks = fieldsStream.readVLong();
if (numDirtyChunks > numChunks) {
 throw new CorruptIndexException("invalid chunk counts: dirty=" + numDirtyChunks + ", total=" + numChunks, fieldsStream);
origin: org.apache.lucene/lucene-core

numChunks = vectorsStream.readVLong();
numDirtyChunks = vectorsStream.readVLong();
if (numDirtyChunks > numChunks) {
 throw new CorruptIndexException("invalid chunk counts: dirty=" + numDirtyChunks + ", total=" + numChunks, vectorsStream);
origin: altamiracorp/blur

@Override
public long readVLong() throws IOException {
 if (9 <= bufferLength-bufferPosition) {
  byte b = buffer[bufferPosition++];
  long i = b & 0x7F;
  for (int shift = 7; (b & 0x80) != 0; shift += 7) {
   b = buffer[bufferPosition++];
   i |= (b & 0x7FL) << shift;
  }
  return i;
 } else {
  return super.readVLong();
 }
}

origin: javasoze/clue

@Override
public long readVLong() throws IOException {
 if (9 <= bufferLength - bufferPosition) {
  byte b = buffer[bufferPosition++];
  long i = b & 0x7F;
  for (int shift = 7; (b & 0x80) != 0; shift += 7) {
   b = buffer[bufferPosition++];
   i |= (b & 0x7FL) << shift;
  }
  return i;
 } else {
  return super.readVLong();
 }
}

origin: org.infinispan/infinispan-embedded-query

/** Seeks the skip entry on the given level */
protected void seekChild(int level) throws IOException {
 skipStream[level].seek(lastChildPointer);
 numSkipped[level] = numSkipped[level + 1] - skipInterval[level + 1];
 skipDoc[level] = lastDoc;
 if (level > 0) {
  childPointer[level] = skipStream[level].readVLong() + skipPointer[level - 1];
 }
}
origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.lucene

/** Seeks the skip entry on the given level */
protected void seekChild(int level) throws IOException {
 skipStream[level].seek(lastChildPointer);
 numSkipped[level] = numSkipped[level + 1] - skipInterval[level + 1];
 skipDoc[level] = lastDoc;
 if (level > 0) {
  childPointer[level] = skipStream[level].readVLong() + skipPointer[level - 1];
 }
}
origin: org.apache.lucene/com.springsource.org.apache.lucene

/** Seeks the skip entry on the given level */
protected void seekChild(int level) throws IOException {
 skipStream[level].seek(lastChildPointer);
 numSkipped[level] = numSkipped[level + 1] - skipInterval[level + 1];
 skipDoc[level] = lastDoc;
 if (level > 0) {
   childPointer[level] = skipStream[level].readVLong() + skipPointer[level - 1];
 }
}

origin: org.apache.lucene/lucene-core-jfrog

/** Seeks the skip entry on the given level */
protected void seekChild(int level) throws IOException {
 skipStream[level].seek(lastChildPointer);
 numSkipped[level] = numSkipped[level + 1] - skipInterval[level + 1];
 skipDoc[level] = lastDoc;
 if (level > 0) {
   childPointer[level] = skipStream[level].readVLong() + skipPointer[level - 1];
 }
}

origin: harbby/presto-connectors

/** Seeks the skip entry on the given level */
protected void seekChild(int level) throws IOException {
 skipStream[level].seek(lastChildPointer);
 numSkipped[level] = numSkipped[level + 1] - skipInterval[level + 1];
 skipDoc[level] = lastDoc;
 if (level > 0) {
  childPointer[level] = skipStream[level].readVLong() + skipPointer[level - 1];
 }
}
origin: hibernate/hibernate-search

@Override
public long readVLong() throws IOException {
  return delegate.readVLong();
}
origin: org.apache.lucene/lucene-codecs

private FSTEntry readFSTEntry(IndexInput meta) throws IOException {
 FSTEntry entry = new FSTEntry();
 entry.offset = meta.readLong();
 entry.numOrds = meta.readVLong();
 return entry;
}

org.apache.lucene.storeIndexInputreadVLong

Javadoc

Reads a long stored in variable-length format. Reads between one and nine bytes. Smaller values take fewer bytes. Negative numbers are not supported.

Popular methods of IndexInput

  • close
    Closes the stream to futher operations.
  • readBytes
    Reads a specified number of bytes into an array at the specified offset with control over whether th
  • length
    The number of bytes in the file.
  • seek
    Sets current position in this file, where the next read will occur.
  • clone
    Warning: Lucene never closes cloned IndexInputs, it will only call #close() on the original object.
  • getFilePointer
    Returns the current position in this file, where the next read will occur.
  • readInt
    Reads four bytes and returns an int.
  • readLong
    Reads eight bytes and returns a long.
  • readByte
    Reads and returns a single byte.
  • readVInt
    Reads an int stored in variable-length format. Reads between one and five bytes. Smaller values take
  • readString
    Reads a string.
  • slice
    Creates a slice of this index input, with the given description, offset, and length. The slice is se
  • readString,
  • slice,
  • toString,
  • readShort,
  • randomAccessSlice,
  • readZLong,
  • readStringSet,
  • readStringStringMap,
  • skipBytes

Popular in Java

  • Reading from database using SQL prepared statement
  • notifyDataSetChanged (ArrayAdapter)
  • requestLocationUpdates (LocationManager)
  • compareTo (BigDecimal)
  • BufferedWriter (java.io)
    Wraps an existing Writer and buffers the output. Expensive interaction with the underlying reader is
  • URLConnection (java.net)
    A connection to a URL for reading or writing. For HTTP connections, see HttpURLConnection for docume
  • Charset (java.nio.charset)
    A charset is a named mapping between Unicode characters and byte sequences. Every Charset can decode
  • Collections (java.util)
    This class consists exclusively of static methods that operate on or return collections. It contains
  • Handler (java.util.logging)
    A Handler object accepts a logging request and exports the desired messages to a target, for example
  • ServletException (javax.servlet)
    Defines a general exception a servlet can throw when it encounters difficulty.
  • Top PhpStorm plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now