Portability | I'm too young to die |
---|---|

Stability | Ultra-Violence |

Safe Haskell | None |

Higher-level file patterns. Don't support read/write operations at offsets and handling stat changes as for now.

- simpleFile :: forall a b m rr wr. (Monad m, EmbedIO m, ReadRef rr m a, Convertible a ByteString, WriteRef wr m b, Convertible ByteString b) => String -> rr -> wr -> NineFile m
- simpleFileBy :: forall a b m. (Monad m, EmbedIO m) => String -> (m a, b -> m ()) -> (a -> ByteString, ByteString -> b) -> NineFile m
- rwFile :: forall m. EmbedIO m => String -> Maybe (m ByteString) -> Maybe (ByteString -> m ()) -> NineFile m

# Documentation

simpleFile :: forall a b m rr wr. (Monad m, EmbedIO m, ReadRef rr m a, Convertible a ByteString, WriteRef wr m b, Convertible ByteString b) => String -> rr -> wr -> NineFile mSource

simpleFileBy :: forall a b m. (Monad m, EmbedIO m) => String -> (m a, b -> m ()) -> (a -> ByteString, ByteString -> b) -> NineFile mSource

Typeclass-free version of `simpleFile`

.

:: forall m . EmbedIO m | |

=> String | File name |

-> Maybe (m ByteString) | Read handler |

-> Maybe (ByteString -> m ()) | Write handler |

-> NineFile m |

A file that reads and writes using simple user-specified callbacks.