Packages

package io

Ordering
  1. Alphabetic
Visibility
  1. Public
  2. All

Type Members

  1. abstract class AbstractByteWriter extends ByteWriter

    An abstract implementation that implements the floating point methods in terms of integer methods.

  2. abstract class Buf extends AnyRef

    Buf represents a fixed, immutable byte buffer with efficient positional access.

    Buf represents a fixed, immutable byte buffer with efficient positional access. Buffers may be sliced and concatenated, and thus be used to implement bytestreams.

    See also

    com.twitter.io.Buf.Empty for an empty Buf.

    com.twitter.io.Buf.apply for creating a Buf from other Bufs

    com.twitter.io.Buf.ByteBuffer for an nio.ByteBuffer backed implementation.

    com.twitter.io.Buf.ByteArray for an Array[Byte] backed implementation.

  3. trait BufByteWriter extends ByteWriter

    A ByteWriter that results in an owned Buf

  4. class BufInputStream extends InputStream
  5. final class Bufs extends AnyRef

    A Java adaptation of the com.twitter.io.Buf companion object.

  6. trait ByteReader extends AutoCloseable

    A ByteReader provides a stateful API to extract bytes from an underlying buffer, which in most cases is a Buf.

    A ByteReader provides a stateful API to extract bytes from an underlying buffer, which in most cases is a Buf. This conveniently allows codec implementations to decode frames, specifically when they need to decode and interpret the bytes as a numeric value.

    Note

    Unless otherwise stated, ByteReader implementations are not thread safe.

  7. trait ByteWriter extends AnyRef

    ByteWriters allow efficient encoding to a buffer.

    ByteWriters allow efficient encoding to a buffer. Concatenating Bufs together is a common pattern for codecs (especially on the encode path), but using the concat method on Buf results in a suboptimal representation. In many cases, a ByteWriter not only allows for a more optimal representation (i.e., sequential accessible out regions), but also allows for writes to avoid allocations. What this means in practice is that builders are stateful. Assume that the builder implementations are ""not"" threadsafe unless otherwise noted.

  8. class InputStreamReader extends Reader with Closable with CloseAwaitably

    Provides the Reader API for an InputStream.

    Provides the Reader API for an InputStream.

    The given InputStream will be closed when Reader.read reaches the EOF or a call to discard() or close().

  9. trait Reader extends AnyRef

    A Reader represents a stream of bytes, read in discrete chunks.

    A Reader represents a stream of bytes, read in discrete chunks. Readers permit at most one outstanding read.

  10. final class Readers extends AnyRef

    Java APIs for Reader.

    Java APIs for Reader.

    See also

    com.twitter.io.Reader

  11. trait Writer extends AnyRef

    A Writer represents a sink for a stream of bytes, providing a convenient interface for the producer of such streams.

  12. final class Writers extends AnyRef

    Java APIs for Writer.

    Java APIs for Writer.

    See also

    com.twitter.io.Writer

Value Members

  1. object Buf

    Buf wrapper-types (like Buf.ByteArray and Buf.ByteBuffer) provide Shared and Owned APIs, each of which with construction & extraction utilities.

    Buf wrapper-types (like Buf.ByteArray and Buf.ByteBuffer) provide Shared and Owned APIs, each of which with construction & extraction utilities.

    The Owned APIs may provide direct access to a Buf's underlying implementation; and so mutating the data structure invalidates a Buf's immutability constraint. Users must take care to handle this data immutably.

    The Shared variants, on the other hand, ensure that the Buf shares no state with the caller (at the cost of additional allocation).

    Note: There are Java-friendly APIs for this object at com.twitter.io.Bufs.

  2. object BufByteWriter
  3. object BufReader
  4. object ByteReader
  5. object ByteWriter
  6. object Charsets

    A set of java.nio.charset.Charset utilities.

  7. object Files

    Utilities for working with java.io.Files

  8. object InputStreamReader
  9. object Reader
  10. object StreamIO
  11. object TempDirectory
  12. object TempFile
  13. object Writer

    See also

    Writers for Java friendly APIs.

Ungrouped