| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
Data.GI.Base.Internal.PathFieldAccess
Description
Support for creating lenses from overloaded labels of the type
#fieldName, or #"fieldName.subfield".
Synopsis
- type family Components (s :: Symbol) :: [Symbol] where ...
- class PathFieldAccess (path :: [Symbol]) (model :: Type) (val :: Type) | path model -> val where
- pathFieldAccess :: Proxy path -> Proxy model -> (Lens' model val, [Text])
Documentation
type family Components (s :: Symbol) :: [Symbol] where ... Source #
Equations
| Components s = SplitByChar '.' s |
class PathFieldAccess (path :: [Symbol]) (model :: Type) (val :: Type) | path model -> val where Source #
Create a lens for the given path, and return it together with the path split into components.
Instances
| (GFieldImpl fieldName model model val val, NonEmpty fieldName ('Text "Field names cannot be empty"), KnownSymbol fieldName) => PathFieldAccess '[fieldName] model val Source # | |
Defined in Data.GI.Base.Internal.PathFieldAccess | |
| (GFieldImpl fieldName model model val val, KnownSymbol fieldName, PathFieldAccess rest val inner) => PathFieldAccess (fieldName ': rest) model inner Source # | |
Defined in Data.GI.Base.Internal.PathFieldAccess | |