trait FileHandle[F[_]] extends FileHandlePlatform[F]
Provides the ability to read/write/lock/inspect a file in the effect F.
- Source
- FileHandle.scala
- Alphabetic
- By Inheritance
- FileHandle
- FileHandlePlatform
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Abstract Value Members
- abstract def force(metaData: Boolean): F[Unit]
Force any updates for the underlying file to storage.
Force any updates for the underlying file to storage.
- metaData
If true, also attempts to force file metadata updates to storage.
- abstract def read(numBytes: Int, offset: Long): F[Option[Chunk[Byte]]]
Read the specified number of bytes at a particular offset.
Read the specified number of bytes at a particular offset.
- numBytes
the number of bytes to read.
- offset
the offset from the start of the file.
- returns
a number of bytes from the file (at most, numBytes in size).
- abstract def size: F[Long]
Report the current size of the file.
Report the current size of the file.
- returns
the size of the file.
- abstract def truncate(size: Long): F[Unit]
Truncate the underlying file to the specified size.
Truncate the underlying file to the specified size.
- size
the size of the file after truncation.
- abstract def write(bytes: Chunk[Byte], offset: Long): F[Int]
Write the specified bytes at a particular offset.
Write the specified bytes at a particular offset.
- bytes
the bytes to write to the
FileHandle.- offset
the offset at which to write the bytes.
- returns
the number of bytes written.
Concrete Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native() @IntrinsicCandidate()
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @IntrinsicCandidate()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @IntrinsicCandidate()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated