ghc-7.8.2: The GHC API

Safe Haskell | Safe-Inferred
Language | Haskell98

Fingerprint

Synopsis

- data Fingerprint :: * = Fingerprint !Word64 !Word64
- fingerprint0 :: Fingerprint
- readHexFingerprint :: String -> Fingerprint
- fingerprintData :: Ptr Word8 -> Int -> IO Fingerprint
- fingerprintString :: String -> Fingerprint
- getFileHash :: FilePath -> IO Fingerprint

# Documentation

data Fingerprint :: * Source

Constructors

Fingerprint !Word64 !Word64 |

Instances

Eq Fingerprint |
Ord Fingerprint |
Show Fingerprint |
Storable Fingerprint |
Outputable Fingerprint |
Binary Fingerprint |

fingerprint0 :: Fingerprint Source

readHexFingerprint :: String -> Fingerprint

fingerprintData :: Ptr Word8 -> Int -> IO Fingerprint Source

fingerprintString :: String -> Fingerprint Source

getFileHash :: FilePath -> IO Fingerprint Source

Computes the hash of a given file. This function loops over the handle, running in constant memory.

Since: 4.7.0.0