sphinx-0.6.0.2: Haskell bindings to the Sphinx full-text searching daemon.

Safe HaskellSafe
LanguageHaskell98

Text.Search.Sphinx.Types

Synopsis

Documentation

data Query #

Data structure representing one query. It can be sent with runQueries or runQueries' to the server in batch mode.

Constructors

Query 

Fields

Instances

data VerCommand #

Current client-side command implementation versions

verCommand :: Num t => VerCommand -> t #

Important! 2.0 compatible

data Status #

Searchd status codes

Constructors

OK 
RETRY 
WARNING 
ERROR Int 

Instances

data QueryStatus #

status from an individual query

data Rank #

Ranking modes (ext2 only)

Instances

Enum Rank # 

Methods

succ :: Rank -> Rank #

pred :: Rank -> Rank #

toEnum :: Int -> Rank #

fromEnum :: Rank -> Int #

enumFrom :: Rank -> [Rank] #

enumFromThen :: Rank -> Rank -> [Rank] #

enumFromTo :: Rank -> Rank -> [Rank] #

enumFromThenTo :: Rank -> Rank -> Rank -> [Rank] #

Show Rank # 

Methods

showsPrec :: Int -> Rank -> ShowS #

show :: Rank -> String #

showList :: [Rank] -> ShowS #

data Sort #

Sort modes

Instances

Enum Sort # 

Methods

succ :: Sort -> Sort #

pred :: Sort -> Sort #

toEnum :: Int -> Sort #

fromEnum :: Sort -> Int #

enumFrom :: Sort -> [Sort] #

enumFromThen :: Sort -> Sort -> [Sort] #

enumFromTo :: Sort -> Sort -> [Sort] #

enumFromThenTo :: Sort -> Sort -> Sort -> [Sort] #

Show Sort # 

Methods

showsPrec :: Int -> Sort -> ShowS #

show :: Sort -> String #

showList :: [Sort] -> ShowS #

exclude :: Filter -> Filter #

shortcut for creating an exclusion filter

fromEnumFilter :: Num t => Filter -> t #

toAttrT :: (Num a, Eq a) => a -> AttrT #

attrT :: Num t => AttrT -> t #

data QueryResult #

The result of a query

Constructors

QueryResult 

Fields

  • matches :: [Match]

    The matches

  • total :: Int

    Total amount of matches retrieved on server by this query.

  • totalFound :: Int

    Total amount of matching documents in index.

  • words :: [(Text, Int, Int)]

    processed words with the number of docs and the number of hits.

  • attributeNames :: [ByteString]

    List of attribute names returned in the result. | The Match will contain just the attribute values in the same order.

data SingleResult #

a single query result, runQueries returns a list of these

data Result a #

a result returned from searchd

Constructors

Ok a 
Warning Text a 
Error Int Text 
Retry Text 

Instances

Show a => Show (Result a) # 

Methods

showsPrec :: Int -> Result a -> ShowS #

show :: Result a -> String #

showList :: [Result a] -> ShowS #

data Match #

Constructors

Match 

Instances

Eq Match # 

Methods

(==) :: Match -> Match -> Bool #

(/=) :: Match -> Match -> Bool #

Show Match # 

Methods

showsPrec :: Int -> Match -> ShowS #

show :: Match -> String #

showList :: [Match] -> ShowS #

data ByteString :: * #

A space-efficient representation of a Word8 vector, supporting many efficient operations.

A lazy ByteString contains 8-bit bytes, or by using the operations from Data.ByteString.Lazy.Char8 it can be interpreted as containing 8-bit characters.

Instances

Eq ByteString 
Data ByteString 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ByteString -> c ByteString #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ByteString #

toConstr :: ByteString -> Constr #

dataTypeOf :: ByteString -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c ByteString) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ByteString) #

gmapT :: (forall b. Data b => b -> b) -> ByteString -> ByteString #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ByteString -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ByteString -> r #

gmapQ :: (forall d. Data d => d -> u) -> ByteString -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> ByteString -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> ByteString -> m ByteString #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> ByteString -> m ByteString #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> ByteString -> m ByteString #

Ord ByteString 
Read ByteString 
Show ByteString 
IsString ByteString 
Semigroup ByteString 
Monoid ByteString 
NFData ByteString 

Methods

rnf :: ByteString -> () #