This module acts as a proxy to the toml-f
public Fortran API and allows
to selectively expose components from the library to fpm
.
The interaction with toml-f
data types outside of this module should be
limited to tables, arrays and key-lists, most of the necessary interactions
are implemented in the building interface with the get_value
and set_value
procedures.
This module allows to implement features necessary for fpm
, which are
not yet available in upstream toml-f
.
For more details on the library used see the TOML-Fortran developer pages.
Check if table contains only keys that are part of the list. If a key is found that is not part of the list, an error is allocated.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(toml_table), | intent(inout) | :: | table |
Instance of the TOML data structure |
||
character(len=*), | intent(in) | :: | valid_keys(:) |
List of keys to check. |
||
type(error_t), | intent(out), | allocatable | :: | error |
Error handling |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(toml_table), | intent(inout) | :: | table |
Instance of the TOML data structure |
||
character(len=*), | intent(in) | :: | key |
Key to read from |
||
type(string_t), | intent(out), | allocatable | :: | list(:) |
List of strings to read |
|
type(error_t), | intent(out), | allocatable | :: | error |
Error handling |
Process the configuration file to a TOML data structure
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(toml_table), | intent(out), | allocatable | :: | table |
TOML data structure |
|
character(len=*), | intent(in) | :: | manifest |
Name of the package configuration file |
||
type(error_t), | intent(out), | allocatable | :: | error |
Error status of the operation |