Tabnine Logo
EndOfFileException
Code IndexAdd Tabnine to your IDE (free)

How to use
EndOfFileException
in
kg.apc.jmeter

Best Java code snippets using kg.apc.jmeter.EndOfFileException (Showing top 4 results out of 315)

origin: undera/jmeter-plugins

private byte getOneByte() throws IOException {
  oneByte.rewind();
  if (file.read(oneByte) < 1) {
    throw new EndOfFileException(getFileName());
  }
  return oneByte.get(0);
}
origin: kg.apc/jmeter-plugins-extras

private byte getOneByte() throws IOException {
  oneByte.rewind();
  if (file.read(oneByte) < 1) {
    throw new EndOfFileException(getFileName());
  }
  return oneByte.get(0);
}
origin: undera/jmeter-plugins

private synchronized String readNextChunk(int capacity)
    throws IOException {
  if (capacity == 0) {
    throw new EndOfFileException("Zero chunk size, possibly end of file reached.");
  }
  ByteBuffer buf = ByteBuffer.allocateDirect(capacity);
  byte[] dst = new byte[capacity];
  int cnt = file.read(buf);
  //log.debug("Read " + cnt);
  if (cnt != capacity) {
    throw new IOException("Expected chunk size (" + capacity + ") differs from read bytes count (" + cnt + ")");
  }
  buf.flip();
  buf.get(dst);
  if (log.isDebugEnabled()) {
    log.debug("Chunk : " + new String(dst));
  }
  if (isHexEncode()) {
    return JOrphanUtils.baToHexString(dst);
  } else {
    return new String(dst, binaryCharset);
  }
}
origin: kg.apc/jmeter-plugins-extras

private synchronized String readNextChunk(int capacity)
    throws IOException {
  if (capacity == 0) {
    throw new EndOfFileException("Zero chunk size, possibly end of file reached.");
  }
  ByteBuffer buf = ByteBuffer.allocateDirect(capacity);
  byte[] dst = new byte[capacity];
  int cnt = file.read(buf);
  //log.debug("Read " + cnt);
  if (cnt != capacity) {
    throw new IOException("Expected chunk size (" + capacity + ") differs from read bytes count (" + cnt + ")");
  }
  buf.flip();
  buf.get(dst);
  if (log.isDebugEnabled()) {
    log.debug("Chunk : " + new String(dst));
  }
  if (isHexEncode()) {
    return JOrphanUtils.baToHexString(dst);
  } else {
    return new String(dst, binaryCharset);
  }
}
kg.apc.jmeterEndOfFileException

Most used methods

  • <init>

Popular in Java

  • Finding current android device location
  • getSharedPreferences (Context)
  • findViewById (Activity)
  • getContentResolver (Context)
  • Pointer (com.sun.jna)
    An abstraction for a native pointer data type. A Pointer instance represents, on the Java side, a na
  • PriorityQueue (java.util)
    A PriorityQueue holds elements on a priority heap, which orders the elements according to their natu
  • Stack (java.util)
    Stack is a Last-In/First-Out(LIFO) data structure which represents a stack of objects. It enables u
  • TreeSet (java.util)
    TreeSet is an implementation of SortedSet. All optional operations (adding and removing) are support
  • Reference (javax.naming)
  • Table (org.hibernate.mapping)
    A relational table
  • 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