Module buffered

Module buffered 

Source
Expand description

Acquires a Read instance and reads it in on-demand in a buffer. All of the bytes read are kept in memory.

Choose this implementation if:

  1. You have a Read source that might contain relatively large amounts of data.
  2. You want to run the JSONPath query on the input and then discard it.

§Performance characteristics

This is the best choice for a relatively large read-once input that is not a file (or when memory maps are not supported). It is faster than first reading all of the contents and then passing them to BorrowedBytes. It is, however, slow compared to other choices. If you know the approximate length of input, use the with_capacity function to avoid reallocating the internal buffers.

Structs§

BufferedInput
Input supporting a buffered read over a Read implementation.
BufferedInputBlock
Block returned from a BufferedInputBlockIterator.
BufferedInputBlockIterator
Iterator over a BufferedInput.