Hoogle Search

Within LTS Haskell 24.66 (ghc-9.10.3)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. class ToBaseId ent

    esqueleto Database.Esqueleto.Experimental

    Class that enables one to use toBaseId to convert an entity's key on a query into another (cf. toBaseId).

  2. connectionPoolConfigIdleTimeout :: ConnectionPoolConfig -> NominalDiffTime

    esqueleto Database.Esqueleto.Experimental

    How long connections can remain idle before being disposed of, in seconds. Default: 600

  3. emptyBackendSpecificOverrides :: BackendSpecificOverrides

    esqueleto Database.Esqueleto.Experimental

    Creates an empty BackendSpecificOverrides (i.e. use the default behavior; no overrides)

  4. entityIdFromJSON :: (PersistEntity record, FromJSON record) => Value -> Parser (Entity record)

    esqueleto Database.Esqueleto.Experimental

    Predefined parseJSON. The input JSON looks like {"id": 1, "name": ...}. The typical usage is:

    instance FromJSON (Entity User) where
    parseJSON = entityIdFromJSON
    

  5. entityIdToJSON :: (PersistEntity record, ToJSON record) => Entity record -> Value

    esqueleto Database.Esqueleto.Experimental

    Predefined toJSON. The resulting JSON looks like {"id": 1, "name": ...}. The typical usage is:

    instance ToJSON (Entity User) where
    toJSON = entityIdToJSON
    

  6. fieldIsImplicitIdColumn :: FieldDef -> !Bool

    esqueleto Database.Esqueleto.Experimental

    True if the field is an implicit ID column. False otherwise.

  7. fromBaseId :: ToBaseId ent => SqlExpr (Value (Key (BaseEnt ent))) -> SqlExpr (Value (Key ent))

    esqueleto Database.Esqueleto.Experimental

    The inverse of toBaseId. Note that this is somewhat less "safe" than toBaseId. Calling toBaseId will usually mean that a foreign key constraint is present that guarantees the presence of the base ID. fromBaseId has no such guarantee. Consider the code example given in toBaseId:

    Bar
    barNum Int
    Foo
    bar BarId
    fooNum Int
    Primary bar
    
    instance ToBaseId Foo where
    type BaseEnt Foo = Bar
    toBaseIdWitness barId = FooKey barId
    
    The type of toBaseId for Foo would be:
    toBaseId :: SqlExpr (Value FooId) -> SqlExpr (Value BarId)
    
    The foreign key constraint on Foo means that every FooId points to a BarId in the database. However, fromBaseId will not have this:
    fromBaseId :: SqlExpr (Value BarId) -> SqlExpr (Value FooId)
    

  8. fromBaseIdMaybe :: ToBaseId ent => SqlExpr (Value (Maybe (Key (BaseEnt ent)))) -> SqlExpr (Value (Maybe (Key ent)))

    esqueleto Database.Esqueleto.Experimental

    As fromBaseId, but works on Maybe keys.

  9. getEntityId :: EntityDef -> EntityIdDef

    esqueleto Database.Esqueleto.Experimental

    No documentation available.

  10. getEntityIdField :: EntityDef -> Maybe FieldDef

    esqueleto Database.Esqueleto.Experimental

    No documentation available.

Page 956 of many | Previous | Next