rethinkdb-2.2.0.5: A driver for RethinkDB 2.2

Safe HaskellNone
LanguageHaskell98

Database.RethinkDB.ReQL

Description

Building RQL queries in Haskell

Synopsis

Documentation

data ReQL Source

A ReQL Term

Constructors

ReQL 

Instances

Floating ReQL Source 
Fractional ReQL Source 
Num ReQL Source 
Show ReQL Source 
IsString ReQL Source 
Expr ReQL Source 
OptArgs ReQL Source 
((~) * a ReQL, (~) * b ReQL, (~) * c ReQL, (~) * d ReQL, (~) * e ReQL) => Expr (a -> b -> c -> d -> e -> ReQL) Source 
((~) * a ReQL, (~) * b ReQL, (~) * c ReQL, (~) * d ReQL) => Expr (a -> b -> c -> d -> ReQL) Source 
((~) * a ReQL, (~) * b ReQL, (~) * c ReQL) => Expr (a -> b -> c -> ReQL) Source 
((~) * a ReQL, (~) * b ReQL) => Expr (a -> b -> ReQL) Source 
(~) * a ReQL => Expr (a -> ReQL) Source 

op :: Arr a => TermType -> a -> ReQL Source

Build a term with no optargs

op' :: Arr a => TermType -> a -> [Attribute Static] -> ReQL Source

Build a term

data Term Source

Internal representation of a ReQL Term

Constructors

Term 
Datum 

Fields

termDatum :: Datum
 
Note 

Fields

termNote :: String
 
termTerm :: Term
 

class Expr e where Source

Convert other types into ReQL expressions

Minimal complete definition

Nothing

Methods

expr :: e -> ReQL Source

exprList :: [e] -> ReQL Source

Instances

Expr Bool Source 
Expr Char Source 
Expr Double Source 
Expr Float Source 
Expr Int Source 
Expr Int8 Source 
Expr Int16 Source 
Expr Int32 Source 
Expr Int64 Source 
Expr Integer Source 
Expr Word Source 
Expr Word8 Source 
Expr Word16 Source 
Expr Word32 Source 
Expr Word64 Source 
Expr () Source 
Expr ByteString Source 
Expr ByteString Source 
Expr Text Source 
Expr UTCTime Source 
Expr Value Source 
Expr Text Source 
Expr ZonedTime Source 
Expr LonLat Source 
Expr Datum Source 
Expr Table Source 
Expr Database Source 
Expr ReQL Source 
Expr Term Source 
Expr Unit Source 
Expr ConflictResolution Source 
Expr Durability Source 
Expr PaginationStrategy Source 
Expr HttpMethod Source 
Expr HttpResultFormat Source 
Expr a => Expr [a] Source 
Expr (Ratio Integer) Source 
Expr a => Expr (Maybe a) Source 
Expr a => Expr (Set a) Source 
Expr a => Expr (Vector a) Source 
Expr a => Expr (Bound a) Source 
Expr (Attribute a) Source 
((~) * a ReQL, (~) * b ReQL, (~) * c ReQL, (~) * d ReQL, (~) * e ReQL) => Expr (a -> b -> c -> d -> e -> ReQL) Source 
((~) * a ReQL, (~) * b ReQL, (~) * c ReQL, (~) * d ReQL) => Expr (a -> b -> c -> d -> ReQL) Source 
((~) * a ReQL, (~) * b ReQL, (~) * c ReQL) => Expr (a -> b -> c -> ReQL) Source 
((~) * a ReQL, (~) * b ReQL) => Expr (a -> b -> ReQL) Source 
(~) * a ReQL => Expr (a -> ReQL) Source 
(Expr a, Expr b) => Expr (Either a b) Source 
(Expr a, Expr b) => Expr (a, b) Source 
Expr a => Expr (HashMap [Char] a) Source 
(Expr k, Expr v) => Expr (HashMap k v) Source 
Expr a => Expr (HashMap Text a) Source 
Expr a => Expr (Map [Char] a) Source 
Expr a => Expr (Map Text a) Source 
(Expr a, Expr b, Expr c) => Expr (a, b, c) Source 
(Expr a, Expr b, Expr c, Expr d) => Expr (a, b, c, d) Source 
(Expr a, Expr b, Expr c, Expr d, Expr e) => Expr (a, b, c, d, e) Source 

str :: String -> ReQL Source

A shortcut for inserting strings into ReQL expressions Useful when OverloadedStrings makes the type ambiguous

num :: Double -> ReQL Source

A shortcut for inserting numbers into ReQL expressions

data Attribute a where Source

A key/value pair used for building objects

Constructors

(:=) :: Expr e => Text -> e -> Attribute a infix 0 
(::=) :: (Expr k, Expr v) => k -> v -> Attribute Dynamic 
NoAttribute :: Attribute a 

Instances

class OptArgs a where Source

An operation that accepts optional arguments

Methods

ex :: a -> [Attribute Static] -> a Source

Extend an operation with optional arguments

Instances

cons :: Expr e => e -> ArgList -> ArgList Source

data Bound a Source

An upper or lower bound for between and during

Constructors

Open

An inclusive bound

Fields

getBound :: a
 
Closed

An exclusive bound

Fields

getBound :: a
 
DefaultBound 

Fields

getBound :: a
 
MinVal 
MaxVal 

Instances

empty :: ReQL Source

An empty object

newtype WireQuery Source

Constructors

WireQuery 

Fields

queryJSON :: Datum
 

Instances

newtype WireBacktrace Source

Constructors

WireBacktrace 

Fields

backtraceJSON :: Datum
 

note :: String -> ReQL -> ReQL Source

Add a note a a ReQL Term

This note does not get sent to the server. It is used to annotate backtraces and help debugging.

(?:=) :: Expr e => Text -> Maybe e -> Attribute a Source

class Arr a where Source

Build arrays of exprs

Methods

arr :: a -> ArgList Source

Instances

Arr () Source 
Expr a => Arr [a] Source 
(Expr a, Expr b) => Arr (a, b) Source 
(Expr a, Expr b, Expr c) => Arr (a, b, c) Source 
(Expr a, Expr b, Expr c, Expr d) => Arr (a, b, c, d) Source