Module
Droplet.Language.Internal.Function
- Package
- purescript-droplet
- Repository
- easafe/purescript-droplet
#TextColumn Source
#function' Source
function' :: forall output. String -> FunctionSignature' output
Represents a function that takes no arguments
#string_agg Source
string_agg :: forall f rest fields. ToStringAgg f rest fields => f -> rest -> Aggregate f rest fields (Maybe String)
#ToStringAgg Source
class ToStringAgg :: Type -> Type -> Row Type -> Constraint
class ToStringAgg (f :: Type) (rest :: Type) (fields :: Row Type) | f -> fields
Instances
(Cons name t e fields, TextColumn t) => ToStringAgg (Proxy name) String fields
(Cons name t e fields, TextColumn t) => ToStringAgg (Path alias name) String fields
#ToArrayAgg Source
class ToArrayAgg :: Type -> Row Type -> Type -> Constraint
class ToArrayAgg (f :: Type) (fields :: Row Type) (t :: Type) | f -> fields t
Instances
(Cons name t e fields, UnwrapDefinition t u) => ToArrayAgg (Proxy name) fields u
(AppendPath alias name fullPath, Cons fullPath t e fields, UnwrapDefinition t u) => ToArrayAgg (Path alias name) fields u
#ToCoalesce Source
class ToCoalesce :: Type -> Row Type -> Type -> Constraint
class ToCoalesce (a :: Type) (fields :: Row Type) (t :: Type) | a -> t
coalesce arguments must be of same type
Instances
(ToCoalesce inp fields t, ToCoalesce ut fields t) => ToCoalesce (Tuple inp ut) fields t
(MatchArgument i fields t) => ToCoalesce i fields t
#PgFunction Source
data PgFunction :: Type -> Type -> Row Type -> Type -> Type
data PgFunction (input :: Type) args (fields :: Row Type) (output :: Type)
Declares a functions
Constructors
PgFunction String args
Instances
(UnwrapNullable o t, TypeEquals fd fields) => MatchArgument (PgFunction i a fd o) fields t
#MatchArgument Source
class MatchArgument :: Type -> Row Type -> Type -> Constraint
class MatchArgument (a :: Type) (fields :: Row Type) (t :: Type) | a -> t
Instances
(Cons name t d fields, UnwrapDefinition t u, UnwrapNullable u v) => MatchArgument (Proxy name) fields v
(AppendPath alias name fullPath, Cons fullPath t d fields, UnwrapDefinition t u, UnwrapNullable u v) => MatchArgument (Path alias name) fields v
(UnwrapNullable o t, TypeEquals fd fields) => MatchArgument (PgFunction i a fd o) fields t
(ToValue a, UnwrapNullable a t) => MatchArgument a fields t
#function Source
function :: forall input output. String -> FunctionSignature input output
Represents a function that takes arguments
#MatchArgumentList Source
class MatchArgumentList :: Type -> Type -> Row Type -> Constraint
class MatchArgumentList (input :: Type) (args :: Type) (fields :: Row Type)
Function arguments must match input type
Instances
(MatchArgumentList inp ar fields, MatchArgumentList ut gs fields) => MatchArgumentList (Tuple inp ut) (Tuple ar gs) fields
(MatchArgument i fields t, MatchArgument a fields t) => MatchArgumentList i a fields
#FunctionSignature Source
type FunctionSignature input output = forall args fields. MatchArgumentList input args fields => args -> PgFunction input args fields output
#FunctionSignature' Source
type FunctionSignature' output = forall fields. PgFunction Void Unit fields output
#coalesce Source
coalesce :: forall input output fields. ToCoalesce input fields output => input -> PgFunction input input fields (Maybe output)
- Modules
- Droplet.
Driver - Droplet.
Driver. Internal. Migration - Droplet.
Driver. Internal. Pool - Droplet.
Driver. Internal. Query - Droplet.
Driver. Migration - Droplet.
Driver. Unsafe - Droplet.
Language - Droplet.
Language. Internal. Condition - Droplet.
Language. Internal. Definition - Droplet.
Language. Internal. Function - Droplet.
Language. Internal. Syntax - Droplet.
Language. Internal. Token - Droplet.
Language. Internal. Translate