TOML key-value pair
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
character(kind=tfc, len=:), | public, | allocatable | :: | key |
Raw representation of the key to the TOML value |
||
integer, | public | :: | origin | = | 0 |
Original source of the value |
|
integer, | public | :: | origin_value | = | 0 |
Origin of value |
|
class(generic_value), | public, | allocatable | :: | val |
Actual TOML value |
Accept a visitor to transverse the data structure
Accept a visitor to transverse the data structure
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_value), | intent(inout) | :: | self |
Instance of the TOML value |
||
class(toml_visitor), | intent(inout) | :: | visitor |
Visitor for this value |
Release allocation hold by TOML key-value pair
Deconstructor to cleanup allocations (optional)
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(inout) | :: | self |
Instance of the TOML key-value pair |
Get the value stored in the key-value pair
Obtain real value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(in) | :: | self |
Instance of the TOML key-value pair |
||
real(kind=tfr), | intent(out), | pointer | :: | val |
Value to be assigned |
Obtain integer value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(in) | :: | self |
Instance of the TOML key-value pair |
||
integer(kind=tfi), | intent(out), | pointer | :: | val |
Value to be assigned |
Obtain boolean value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(in) | :: | self |
Instance of the TOML key-value pair |
||
logical, | intent(out), | pointer | :: | val |
Value to be assigned |
Obtain datetime value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(in) | :: | self |
Instance of the TOML key-value pair |
||
type(toml_datetime), | intent(out), | pointer | :: | val |
Value to be assigned |
Obtain datetime value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(in) | :: | self |
Instance of the TOML key-value pair |
||
character(kind=tfc, len=:), | intent(out), | pointer | :: | val |
Value to be assigned |
Obtain boolean value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(in) | :: | self |
Instance of the TOML key-value pair |
||
logical, | intent(out), | pointer | :: | val |
Value to be assigned |
Obtain datetime value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(in) | :: | self |
Instance of the TOML key-value pair |
||
type(toml_datetime), | intent(out), | pointer | :: | val |
Value to be assigned |
Obtain real value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(in) | :: | self |
Instance of the TOML key-value pair |
||
real(kind=tfr), | intent(out), | pointer | :: | val |
Value to be assigned |
Obtain integer value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(in) | :: | self |
Instance of the TOML key-value pair |
||
integer(kind=tfi), | intent(out), | pointer | :: | val |
Value to be assigned |
Get escaped key to TOML value
Get escaped key to TOML value
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_value), | intent(in) | :: | self |
TOML value instance. |
||
character(kind=tfc, len=:), | allocatable | :: | key |
Contains valid TOML key on exit |
Obtain datetime value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(in) | :: | self |
Instance of the TOML key-value pair |
||
character(kind=tfc, len=:), | intent(out), | pointer | :: | val |
Value to be assigned |
Get the type of the value stored in the key-value pair
Get the type of the value stored in the key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(in) | :: | self |
Instance of the TOML key-value pair |
Value type
Compare raw key of TOML value to input key
Compare raw key of TOML value to input key
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_value), | intent(in) | :: | self |
TOML value instance. |
||
character(kind=tfc, len=*), | intent(in) | :: | key |
TOML raw key to compare to |
Set the value for the key-value pair
Obtain real value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(inout) | :: | self |
Instance of the TOML key-value pair |
||
real(kind=tfr), | intent(in) | :: | val |
Value to be assigned |
Obtain integer value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(inout) | :: | self |
Instance of the TOML key-value pair |
||
integer(kind=tfi), | intent(in) | :: | val |
Value to be assigned |
Obtain boolean value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(inout) | :: | self |
Instance of the TOML key-value pair |
||
logical, | intent(in) | :: | val |
Value to be assigned |
Obtain datetime value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(inout) | :: | self |
Instance of the TOML key-value pair |
||
type(toml_datetime), | intent(in) | :: | val |
Value to be assigned |
Obtain datetime value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(inout) | :: | self |
Instance of the TOML key-value pair |
||
character(kind=tfc, len=*), | intent(in) | :: | val |
Value to be assigned |
Obtain boolean value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(inout) | :: | self |
Instance of the TOML key-value pair |
||
logical, | intent(in) | :: | val |
Value to be assigned |
Obtain datetime value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(inout) | :: | self |
Instance of the TOML key-value pair |
||
type(toml_datetime), | intent(in) | :: | val |
Value to be assigned |
Obtain real value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(inout) | :: | self |
Instance of the TOML key-value pair |
||
real(kind=tfr), | intent(in) | :: | val |
Value to be assigned |
Obtain integer value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(inout) | :: | self |
Instance of the TOML key-value pair |
||
integer(kind=tfi), | intent(in) | :: | val |
Value to be assigned |
Obtain datetime value from TOML key-value pair
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(toml_keyval), | intent(inout) | :: | self |
Instance of the TOML key-value pair |
||
character(kind=tfc, len=*), | intent(in) | :: | val |
Value to be assigned |
type, extends(toml_value) :: toml_keyval !> Actual TOML value class(generic_value), allocatable :: val !> Origin of value integer :: origin_value = 0 contains !> Get the value stored in the key-value pair generic :: get => get_float, get_integer, get_boolean, get_datetime, get_string procedure :: get_float procedure :: get_integer procedure :: get_boolean procedure :: get_datetime procedure :: get_string !> Set the value for the key-value pair generic :: set => set_float, set_integer, set_boolean, set_datetime, set_string procedure :: set_float procedure :: set_integer procedure :: set_boolean procedure :: set_datetime procedure :: set_string !> Get the type of the value stored in the key-value pair procedure :: get_type !> Release allocation hold by TOML key-value pair procedure :: destroy end type toml_keyval