Package

streamadapter

Permalink

package streamadapter

a toolkit for adapting streams from one streaming library into another streaming library

Linear Supertypes
AnyRef, Any
Content Hierarchy
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. streamadapter
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. trait Chunkerator[+A] extends () ⇒ CloseableChunkIter[A]

    Permalink

    a closeable chunk iterator generator.

    a closeable chunk iterator generator. whenever the function is called, it produces an iterator for the same underlying resource. this is necessary for the enumerators to be reusable, ie, produce the same stream of elements when used with two iteratees, and not produce an empty stream when used a second time. note, however, that the iterators returned by this generating function do not have to produce the exact same results. allowance is made for the fact that the underlying resource may be a changeable resource. for instance, we could be iterating over the contents of a file, and some other process might modify the file in the meantime.

    at this point, Chunkerator serves as our common interchange format for publishers - we will try to get to and from conversions for this type, from each stream type we handle. we can then convert between any two publisher types using this one as a mediator.

  2. trait CloseableChunkIter[+A] extends CloseableIter[Seq[A]]

    Permalink

    a closeable iterator of chunks.

    a closeable iterator of chunks. has method close: Unit, along with the standard Iterator methods, so that enumerator can be closed early when the iteratee is complete.

  3. trait CloseableIter[+A] extends Iterator[A]

    Permalink

    a closeable iterator.

    a closeable iterator. has method close: Unit, along with the standard Iterator methods, so that enumerator can be closed early when the iteratee is complete.

  4. trait StreamAdapter[P1[_], P2[_]] extends AnyRef

    Permalink

    adapts streams from one streaming library into another streaming library

    adapts streams from one streaming library into another streaming library

    P1

    the type of stream to adapt from

    P2

    the type of stream to adapt into

Value Members

  1. object Chunkerator

    Permalink

    contains factory methods for producing chunkerators

  2. object CloseableChunkIter

    Permalink

    contains factory methods for producing closeable chunk iters

  3. def adapt[P1[_], P2[_], A](p1: P1[A])(implicit pa: StreamAdapter[P1, P2]): P2[A]

    Permalink

    adapts a stream of elements from one streaming library into a stream from another streaming library

    adapts a stream of elements from one streaming library into a stream from another streaming library

    P1

    the type of stream to adapt from

    P2

    the type of stream to adapt into

    A

    the type of the elements of the stream

    p1

    the stream to adapt

    returns

    the adapted stream

  4. implicit def chain[P1[_], P2[_]](implicit pa1: StreamAdapter[P1, Chunkerator], pa2: StreamAdapter[Chunkerator, P2]): StreamAdapter[P1, P2]

    Permalink

    chains two stream adapters together to create a new one.

    chains two stream adapters together to create a new one. the intermediary in the chain is hardcoded to Chunkerator.

    the idea being, every streaming library has adapters into and out of Chunkerator, and then we can adapt between two arbitrary streaming libraries.

  5. package iterateeio

    Permalink

    contains stream adapters for iteratee.io enumerators

Inherited from AnyRef

Inherited from Any

Ungrouped