Portability | non-portable |
---|---|
Stability | experimental |
Maintainer | [email protected] |
Database.HaskellDB.DBLayout
Description
Exports every function needed by DBDirect generated files
- module Database.HaskellDB.BoundedString
- module Database.HaskellDB.DBSpec
- data CalendarTime
- data Expr a
- data Table r
- data Attr f a
- baseTable :: (ShowLabels r, ToPrimExprs r) => TableName -> Record r -> Table r
- data RecCons f a b
- data RecNil
- class FieldTag f where
- hdbMakeEntry :: FieldTag f => f -> Record (RecCons f (Expr a) RecNil)
- mkAttr :: FieldTag f => f -> Attr f a
- (#) :: Record (RecCons f a RecNil) -> (b -> c) -> b -> RecCons f a c
- emptyTable :: TableName -> Table (Record RecNil)
Documentation
module Database.HaskellDB.DBSpec
data CalendarTime
CalendarTime
is a user-readable and manipulable
representation of the internal ClockTime
type.
Type of normal expressions, contains the untyped PrimExpr.
Instances
ProjectExpr Expr | |
InsertExpr Expr | |
ExprC Expr | |
Read (Expr a) | |
Show (Expr a) | |
IsExpr (Expr a) | |
Args (Expr a) | |
ExprType a => ExprType (Expr a) | |
BStrToStr (Expr String) (Expr String) | |
BStrToStr (Expr (Maybe String)) (Expr (Maybe String)) | |
Size n => BStrToStr (Expr (Maybe (BoundedString n))) (Expr (Maybe String)) | |
Size n => BStrToStr (Expr (BoundedString n)) (Expr String) | |
IsExpr tail => IsExpr (Expr a -> tail) | |
Args (Expr a -> ExprAggr c) | |
(IsExpr tail, Args tail) => Args (Expr a -> tail) | |
HasField f r => Select (Attr f a) (Rel r) (Expr a) | Field selection operator. It is overloaded to work for both
relations in a query and the result of a query.
That is, it corresponds to both |
(RelToRec rest, FieldTag f) => RelToRec (RecCons f (Expr a) rest) | |
(ShowConstant a, ConstantRecord r cr) => ConstantRecord (RecCons f a r) (RecCons f (Expr a) cr) | |
(ProjectExpr e, ProjectRec r er) => ProjectRec (RecCons f (e a) r) (RecCons f (Expr a) er) | |
(InsertExpr e, InsertRec r er) => InsertRec (RecCons f (e a) r) (RecCons f (Expr a) er) | |
(GetValue a, GetRec er vr) => GetRec (RecCons f (Expr a) er) (RecCons f a vr) |
Basic tables, contains table name and an association from attributes to attribute names in the real table.
Typed attributes
Instances
HasField f r => Select (Attr f a) (Rel r) (Expr a) | Field selection operator. It is overloaded to work for both
relations in a query and the result of a query.
That is, it corresponds to both |
baseTable :: (ShowLabels r, ToPrimExprs r) => TableName -> Record r -> Table rSource
Constructor that adds a field to a record. f is the field tag, a is the field value and b is the rest of the record.
Instances
The empty record.
Class for field labels.
Constructs a table entry from a field tag