| Safe Haskell | None |
|---|---|
| Language | GHC2021 |
Effectful.FileSystem.HandleRW.Static
Synopsis
- data HandleRW (a :: Type -> Type) b
- openBinaryFile :: forall (es :: [Effect]). (HandleRW :> es, HasCallStack) => OsPath -> Eff es (Handle 'HandleModeReadWrite)
- withBinaryFile :: forall (es :: [Effect]) a. (HandleRW :> es, HasCallStack) => OsPath -> (Handle 'HandleModeReadWrite -> Eff es a) -> Eff es a
- runHandleRW :: forall (es :: [Effect]) a. (HasCallStack, IOE :> es) => Eff (HandleRW ': es) a -> Eff es a
- data ByteString
- data Handle (p :: HandleMode)
- data HandleMode = HandleModeReadWrite
- type OsPath = OsString
Effect
data HandleRW (a :: Type -> Type) b Source #
Static effect for reading a handle.
Since: 0.1
Instances
| type DispatchOf HandleRW Source # | |
Defined in Effectful.FileSystem.HandleRW.Static | |
| data StaticRep HandleRW Source # | |
Defined in Effectful.FileSystem.HandleRW.Static | |
openBinaryFile :: forall (es :: [Effect]). (HandleRW :> es, HasCallStack) => OsPath -> Eff es (Handle 'HandleModeReadWrite) Source #
Opens a file in ReadWrite mode.
Since: 0.1
withBinaryFile :: forall (es :: [Effect]) a. (HandleRW :> es, HasCallStack) => OsPath -> (Handle 'HandleModeReadWrite -> Eff es a) -> Eff es a Source #
Opens a file in ReadWrite mode.
Since: 0.1
Handlers
runHandleRW :: forall (es :: [Effect]) a. (HasCallStack, IOE :> es) => Eff (HandleRW ': es) a -> Eff es a Source #
Reexports
data ByteString #
A space-efficient representation of a Word8 vector, supporting many
efficient operations.
A ByteString contains 8-bit bytes, or by using the operations from
Data.ByteString.Char8 it can be interpreted as containing 8-bit
characters.
Instances
data Handle (p :: HandleMode) Source #
Wrapper for file handles that includes an index for the mode.
Since: 0.1
Instances
| HasField "unHandle" (Handle p :: Type) Handle Source # | Since: 0.1 |
Defined in Effectful.FileSystem.Handle.Internal | |
| HasField "unLockedHandle" (LockedHandle p :: Type) (Handle p :: Type) Source # | Since: 0.1 |
Defined in Effectful.FileSystem.Handle.Internal Methods getField :: LockedHandle p -> Handle p # | |
| (k ~ A_Getter, a ~ Handle, b ~ Handle) => LabelOptic "unHandle" k (Handle p) (Handle p) a b Source # | Since: 0.1 |
Defined in Effectful.FileSystem.Handle.Internal | |