Copyright | (c) 2013-2023 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Synopsis
- data Mapping = Mapping' {}
- newMapping :: Mapping
- mapping_children :: Lens' Mapping (Maybe [Mapping])
- mapping_dropped :: Lens' Mapping (Maybe Bool)
- mapping_fromPath :: Lens' Mapping (Maybe [Text])
- mapping_fromType :: Lens' Mapping (Maybe Text)
- mapping_toKey :: Lens' Mapping (Maybe Text)
- mapping_toType :: Lens' Mapping (Maybe Text)
Documentation
Specifies the mapping of data property keys.
See: newMapping
smart constructor.
Mapping' | |
|
Instances
newMapping :: Mapping Source #
Create a value of Mapping
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:children:Mapping'
, mapping_children
- Only applicable to nested data structures. If you want to change the
parent structure, but also one of its children, you can fill out this
data strucutre. It is also Mapping
, but its FromPath
will be the
parent's FromPath
plus the FromPath
from this structure.
For the children part, suppose you have the structure:
{ "FromPath": "OuterStructure", "ToKey": "OuterStructure", "ToType": "Struct", "Dropped": false, "Chidlren": [{ "FromPath": "inner", "ToKey": "inner", "ToType": "Double", "Dropped": false, }] }
You can specify a Mapping
that looks like:
{ "FromPath": "OuterStructure", "ToKey": "OuterStructure", "ToType": "Struct", "Dropped": false, "Chidlren": [{ "FromPath": "inner", "ToKey": "inner", "ToType": "Double", "Dropped": false, }] }
$sel:dropped:Mapping'
, mapping_dropped
- If true, then the column is removed.
$sel:fromPath:Mapping'
, mapping_fromPath
- The table or column to be modified.
$sel:fromType:Mapping'
, mapping_fromType
- The type of the data to be modified.
$sel:toKey:Mapping'
, mapping_toKey
- After the apply mapping, what the name of the column should be. Can be
the same as FromPath
.
$sel:toType:Mapping'
, mapping_toType
- The data type that the data is to be modified to.
mapping_children :: Lens' Mapping (Maybe [Mapping]) Source #
Only applicable to nested data structures. If you want to change the
parent structure, but also one of its children, you can fill out this
data strucutre. It is also Mapping
, but its FromPath
will be the
parent's FromPath
plus the FromPath
from this structure.
For the children part, suppose you have the structure:
{ "FromPath": "OuterStructure", "ToKey": "OuterStructure", "ToType": "Struct", "Dropped": false, "Chidlren": [{ "FromPath": "inner", "ToKey": "inner", "ToType": "Double", "Dropped": false, }] }
You can specify a Mapping
that looks like:
{ "FromPath": "OuterStructure", "ToKey": "OuterStructure", "ToType": "Struct", "Dropped": false, "Chidlren": [{ "FromPath": "inner", "ToKey": "inner", "ToType": "Double", "Dropped": false, }] }