Package

fs2.io

file

Permalink

package file

Provides support for working with files.

Source
file.scala
Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. file
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. trait FileHandle[F[_]] extends AnyRef

    Permalink

    Provides the ability to read/write/lock/inspect a file in the effect F.

    Provides the ability to read/write/lock/inspect a file in the effect F.

    To construct a FileHandle, use the methods in the fs2.io.file.pulls object.

Value Members

  1. object pulls

    Permalink

    Provides various Pulls for working with files.

  2. def readAll[F[_]](path: Path, blockingExecutionContext: ExecutionContext, chunkSize: Int)()(implicit arg0: Sync[F], arg1: ContextShift[F]): Stream[F, Byte]

    Permalink

    Reads all data synchronously from the file at the specified java.nio.file.Path.

  3. def readRange[F[_]](path: Path, blockingExecutionContext: ExecutionContext, chunkSize: Int, start: Long, end: Long)()(implicit arg0: Sync[F], arg1: ContextShift[F]): Stream[F, Byte]

    Permalink

    Reads a range of data synchronously from the file at the specified java.nio.file.Path.

    Reads a range of data synchronously from the file at the specified java.nio.file.Path. start is inclusive, end is exclusive, so when start is 0 and end is 2, two bytes are read.

  4. def watch[F[_]](path: Path, types: Seq[EventType] = Nil, modifiers: Seq[Modifier] = Nil, pollTimeout: FiniteDuration = 1.second)(implicit F: Concurrent[F]): Stream[F, Event]

    Permalink

    Watches a single path.

    Watches a single path.

    Alias for creating a watcher and watching the supplied path, releasing the watcher when the resulting stream is finalized.

  5. def watcher[F[_]](implicit F: Concurrent[F]): Resource[F, Watcher[F]]

    Permalink

    Creates a Watcher for the default file system.

    Creates a Watcher for the default file system.

    A singleton bracketed stream is returned consisting of the single watcher. To use the watcher, flatMap the returned stream, watch or register 1 or more paths, and then return watcher.events().

    returns

    singleton bracketed stream returning a watcher

  6. def writeAll[F[_]](path: Path, blockingExecutionContext: ExecutionContext, flags: Seq[StandardOpenOption] = List(StandardOpenOption.CREATE))(implicit arg0: Sync[F], arg1: ContextShift[F]): Sink[F, Byte]

    Permalink

    Writes all data synchronously to the file at the specified java.nio.file.Path.

    Writes all data synchronously to the file at the specified java.nio.file.Path.

    Adds the WRITE flag to any other OpenOption flags specified. By default, also adds the CREATE flag.

Inherited from AnyRef

Inherited from Any

Ungrouped