| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Ouroboros.Consensus.Storage.FS.CRC
Description
Support for CRC
Synopsis
- newtype CRC = CRC {}
- initCRC :: CRC
- updateCRC :: forall a. CRC32 a => a -> CRC -> CRC
- computeCRC :: forall a. CRC32 a => a -> CRC
- hPutAllCRC :: forall m h. (HasCallStack, Monad m) => HasFS m h -> Handle h -> ByteString -> m (Word64, CRC)
- hGetExactlyAtCRC :: forall m h. (HasCallStack, MonadThrow m) => HasFS m h -> Handle h -> Word64 -> AbsOffset -> m (ByteString, CRC)
- hGetAllAtCRC :: forall m h. Monad m => HasFS m h -> Handle h -> AbsOffset -> m (ByteString, CRC)
Wrap digest functionality
computeCRC :: forall a. CRC32 a => a -> CRC Source #
File system functions with CRC functionality
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
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