| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
System.FS.CRC
Description
Support for CRC
Synopsis
- newtype CRC = CRC {}
- computeCRC :: forall a. CRC32 a => a -> CRC
- initCRC :: CRC
- updateCRC :: forall a. CRC32 a => a -> CRC -> CRC
- hGetAllAtCRC :: forall m h. Monad m => HasFS m h -> Handle h -> AbsOffset -> m (ByteString, CRC)
- hGetExactlyAtCRC :: forall m h. (HasCallStack, MonadThrow m) => HasFS m h -> Handle h -> Word64 -> AbsOffset -> m (ByteString, CRC)
- hPutAllCRC :: forall m h. (HasCallStack, Monad m) => HasFS m h -> Handle h -> ByteString -> m (Word64, CRC)
Wrap digest functionality
computeCRC :: forall a. CRC32 a => a -> CRC Source #
File system functions with CRC functionality
Arguments
| :: forall m h. Monad m | |
| => HasFS m h | |
| -> Handle h | |
| -> AbsOffset | The offset at which to read. |
| -> m (ByteString, CRC) |
Variation on hGetAllAt that also computes a CRC
Arguments
| :: forall m h. (HasCallStack, MonadThrow m) | |
| => HasFS m h | |
| -> Handle h | |
| -> Word64 | The number of bytes to read. |
| -> AbsOffset | The offset at which to read. |
| -> m (ByteString, CRC) |
Variation on hGetExactlyAt that also computes a CRC
hPutAllCRC :: forall m h. (HasCallStack, Monad m) => HasFS m h -> Handle h -> ByteString -> m (Word64, CRC) Source #
Variation on hPutAll that also computes a CRC