Module
Droplet.Language.Internal.Definition
- Package
- purescript-droplet
- Repository
- easafe/purescript-droplet
Definition of SQL columns types as well conversions from and to columns
Do not import this module directly, it will break your code and make it not type safe. Use the sanitized Droplet.Language instead
#ForeignKey Source
data ForeignKey :: Symbol -> Type -> Typedata ForeignKey (field :: Symbol) (table :: Type)
#Joined Source
data Joined (t :: Type)A trick to mark left joined columns as nullable
Instances
(UnwrapDefinition t u) => UnwrapDefinition (Joined t) uIsNullable (Joined t)
#PrimaryKey Source
data PrimaryKey#Constraint Source
data Constraint :: forall n. n -> Type -> Typedata Constraint name t
#Column Source
data Column (t :: Type) (constraint :: Type)Constructors
Instances
UnwrapDefinition (Column t c) tIsNullable (Column (Maybe t) c)
#IsNullable Source
class IsNullable (t :: Type) Instances
IsNullable (Column (Maybe t) c)IsNullable (Maybe t)IsNullable (Joined t)
#UnwrapNullable Source
class UnwrapNullable (w :: Type) (t :: Type) | w -> tConvenience to remove nullable wrappers
Instances
UnwrapNullable (Maybe t) tUnwrapNullable t t
#ToParameters Source
class ToParameters :: Row Type -> RowList Type -> Constraintclass ToParameters record (list :: RowList Type) where
Members
Instances
ToParameters record Nil(IsSymbol name, Reflectable name String, ToValue t, Cons name t e record, ToParameters record rest) => ToParameters record (Cons name t rest)
#UnwrapDefinition Source
class UnwrapDefinition (w :: Type) (t :: Type) | w -> tConvenience to remove type wrappers
Instances
UnwrapDefinition (Column t c) t(UnwrapDefinition t u) => UnwrapDefinition (Joined t) uUnwrapDefinition t t
#AppendPath Source
class AppendPath :: Symbol -> Symbol -> Symbol -> Constraintclass AppendPath (alias :: Symbol) (name :: Symbol) (fullPath :: Symbol) | alias name -> fullPath
Simplify append qualifying column names
Instances
(Append alias Dot path, Append path name fullPath) => AppendPath alias name fullPath
- 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