WriteCursor

final case class WriteCursor[F <: ([_$1] =>> Any)](file: FileHandle[F], offset: Long)
Associates a FileHandle with an offset in to the file.
This encapsulates the pattern of incrementally writing bytes in to a file,
a chunk at a time. Convenience methods are provided for working with pulls.
Companion
object
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any

Value members

Methods

def seek(position: Long): WriteCursor[F]
Returns a new cursor with the offset adjusted to the specified position.
def write(bytes: Chunk[Byte])(F: Monad[F]): F[WriteCursor[F]]
Writes a single chunk to the underlying file handle, returning a new cursor
with an offset incremented by the chunk size.
def writePull(bytes: Chunk[Byte]): Pull[F, Nothing, WriteCursor[F]]
Like write but returns a pull instead of an F[WriteCursor[F]].
def writeAll(s: Stream[F, Byte]): Pull[F, Nothing, WriteCursor[F]]
Writes all chunks from the supplied stream to the underlying file handle, returning a cursor
with offset incremented by the total number of bytes written.

Inherited methods

def productIterator: Iterator[Any]
Inhertied from
Product
def productElementNames: Iterator[String]
Inhertied from
Product