Mapper::MapperRuntimeKeyInfo Struct Reference

Describes a runtime mapper field key. More...

## Public Attributes

*hash< string, bool > | conflicting_keys
| Hash of conflicting keys, if any.
string | desc
| A description of the key.
code | handler
| The code to handle the key at runtime. More...
bool | requires_field_type = False
| If the type of the value for the key must be the same as the field type.
*softlist< string > | requires_roles
| If the key can only be used if one or more other keys supplying the given roles are also present.
*string | returns_type
| If the key provides a value that returns a specific type.
*softlist< string > | unique_roles
| If the key provides some unique functionality. More...
string | value_type = "string"
| The type of value that must be assigned to this key.

## Detailed Description

Describes a runtime mapper field key.

## Member Data Documentation

## handler

code Mapper::MapperRuntimeKeyInfo::handler

The code to handle the key at runtime.

the signature of this closure or call reference depends on requires_input:

- requires_roles contains value: `auto sub (auto arg, auto val) {}`
  - parameters:
    - `arg:` the argument to the runtime key in the mapping
    - `val:` the current value of the mapping, if any
- requires_roles does not contain value: `auto sub (auto arg) {}`
  - parameters:
    - `arg:` the argument to the runtime key in the mapping

In both cases the return value is the value to use for the field

## unique_roles

*softlist<string> Mapper::MapperRuntimeKeyInfo::unique_roles

If the key provides some unique functionality.

only one key providing the given functionality can be included in an output field; this is a list so that keys can provide more than one unique function