Stability | experimental |
---|---|
Maintainer | Uwe Schmidt (uwe@fh-wedel.de) |
Safe Haskell | None |
A more space efficient substitute for Holumbus.Index.Documents
- data Documents a = Documents {}
- newtype CompressedDoc a = CDoc {
- unCDoc :: ByteString
- type DocMap a = DocIdMap (CompressedDoc a)
- type URIMap = PrefixTree DocId
- emptyDocuments :: Documents a
- singleton :: Binary a => Document a -> Documents a
- simplify :: (Binary a, Show a) => Documents a -> Documents String
- toDocument :: Binary a => CompressedDoc a -> Document a
- fromDocument :: Binary a => Document a -> CompressedDoc a
- fromDocMap :: Binary a => DocMap a -> DocIdMap (Document a)
- toDocMap :: Binary a => DocIdMap (Document a) -> DocMap a
Documents type
newtype CompressedDoc a Source
CDoc | |
|
Eq (CompressedDoc a) | |
Show (CompressedDoc a) | |
Binary a => Binary (CompressedDoc a) | |
NFData (CompressedDoc a) | |
(Binary a, XmlPickler a) => XmlPickler (CompressedDoc a) |
type DocMap a = DocIdMap (CompressedDoc a)Source
type URIMap = PrefixTree DocIdSource
The table which is used to map a document to an artificial id and vice versa.
Construction
emptyDocuments :: Documents aSource
Create an empty table.
singleton :: Binary a => Document a -> Documents aSource
Create a document table containing a single document.
Conversion
simplify :: (Binary a, Show a) => Documents a -> Documents StringSource
Simplify a document table by transforming the custom information into a string.
toDocument :: Binary a => CompressedDoc a -> Document aSource
fromDocument :: Binary a => Document a -> CompressedDoc aSource