Safe Haskell | None |
---|---|
Language | Haskell2010 |
- module Bio.Base
- module BasePrelude
- module System.IO
- module System.Posix.Files
- module System.Posix.IO
- module System.Posix.Types
- type Bytes = ByteString
- type LazyBytes = ByteString
- data HashMap k v :: * -> * -> *
- data HashSet a :: * -> *
- data IntMap a :: * -> *
- data IntSet :: *
- data Text :: *
- type LazyText = Text
- data Pair a b = !a :!: !b
- type (:!:) = Pair
- decodeBytes :: Bytes -> Text
- encodeBytes :: Text -> Bytes
- class Hashable a where
- class Unpack s where
- fdPut :: Fd -> Bytes -> IO ()
- fdPutLazy :: Fd -> LazyBytes -> IO ()
- withFd :: FilePath -> OpenMode -> Maybe FileMode -> OpenFileFlags -> (Fd -> IO a) -> IO a
Documentation
module Bio.Base
module BasePrelude
module System.IO
module System.Posix.Files
module System.Posix.IO
module System.Posix.Types
type Bytes = ByteString Source #
type LazyBytes = ByteString Source #
data HashMap k v :: * -> * -> * #
A map from keys to values. A map cannot contain duplicate keys; each key can map to at most one value.
Eq2 HashMap | |
Show2 HashMap | |
Hashable2 HashMap | |
Functor (HashMap k) | |
Foldable (HashMap k) | |
Traversable (HashMap k) | |
Eq k => Eq1 (HashMap k) | |
(Eq k, Hashable k, Read k) => Read1 (HashMap k) | |
Show k => Show1 (HashMap k) | |
Hashable k => Hashable1 (HashMap k) | |
(Eq k, Hashable k) => IsList (HashMap k v) | |
(Eq k, Eq v) => Eq (HashMap k v) | |
(Data k, Data v, Eq k, Hashable k) => Data (HashMap k v) | |
(Eq k, Hashable k, Read k, Read e) => Read (HashMap k e) | |
(Show k, Show v) => Show (HashMap k v) | |
(Eq k, Hashable k) => Semigroup (HashMap k v) | |
(Eq k, Hashable k) => Monoid (HashMap k v) | |
(NFData k, NFData v) => NFData (HashMap k v) | |
(Hashable k, Hashable v) => Hashable (HashMap k v) | |
type Item (HashMap k v) | |
A set of values. A set cannot contain duplicate values.
Foldable HashSet | |
Eq1 HashSet | |
Show1 HashSet | |
Hashable1 HashSet | |
(Eq a, Hashable a) => IsList (HashSet a) | |
Eq a => Eq (HashSet a) | |
(Data a, Eq a, Hashable a) => Data (HashSet a) | |
(Eq a, Hashable a, Read a) => Read (HashSet a) | |
Show a => Show (HashSet a) | |
(Hashable a, Eq a) => Semigroup (HashSet a) | |
(Hashable a, Eq a) => Monoid (HashSet a) | |
NFData a => NFData (HashSet a) | |
Hashable a => Hashable (HashSet a) | |
type Item (HashSet a) | |
A map of integers to values a
.
A set of integers.
A space efficient, packed, unboxed Unicode text type.
A strict pair.
!a :!: !b infixl 2 |
decodeBytes :: Bytes -> Text Source #
The class of types that can be converted to a hash value.
Minimal implementation: hashWithSalt
.
hashWithSalt :: Int -> a -> Int infixl 0 #
Return a hash value for the argument, using the given salt.
The general contract of hashWithSalt
is:
- If two values are equal according to the
==
method, then applying thehashWithSalt
method on each of the two values must produce the same integer result if the same salt is used in each case. - It is not required that if two values are unequal
according to the
==
method, then applying thehashWithSalt
method on each of the two values must produce distinct integer results. However, the programmer should be aware that producing distinct integer results for unequal values may improve the performance of hashing-based data structures. - This method can be used to compute different hash values for
the same input by providing a different salt in each
application of the method. This implies that any instance
that defines
hashWithSalt
must make use of the salt in its implementation.
Like hashWithSalt
, but no salt is used. The default
implementation uses hashWithSalt
with some default salt.
Instances might want to implement this method to provide a more
efficient implementation than the default implementation.