9 #ifndef LARSIM_MARLEY_PARAMETERSET_WALKER_H
10 #define LARSIM_MARLEY_PARAMETERSET_WALKER_H
18 #include "fhiclcpp/ParameterSetWalker.h"
19 #include "fhiclcpp/detail/printing_helpers.h"
22 #include "marley/JSON.hh"
35 inline void enter_table(
const key_t& key,
const any_t& )
override {
38 = marley::JSON::make(marley::JSON::DataType::Object) );
46 = marley::JSON::make(marley::JSON::DataType::Array) );
49 inline void atom(
const key_t& key,
const any_t& any )
override {
55 marley::JSON json_atom;
57 if ( atom_val !=
"@nil" ) {
58 std::istringstream iss( atom_val );
60 json_atom = marley::parse_next( iss );
66 json[ key ] = json_atom;
70 inline void exit_table(
const key_t&,
const any_t& )
override {
83 std::vector< std::reference_wrapper<marley::JSON> >
92 #endif // LARSIM_MARLEY_PARAMETERSET_WALKER_H
const marley::JSON & get_json() const
void exit_sequence(const key_t &, const any_t &) override
void enter_sequence(const key_t &key, const any_t &) override
marley::JSON full_json_
Owned JSON object used to store the converted FHiCL parameters.
void enter_table(const key_t &key, const any_t &) override
void exit_table(const key_t &, const any_t &) override
std::vector< std::reference_wrapper< marley::JSON > > json_refs_
References to the owned JSON object or a sub-object thereof.
void atom(const key_t &key, const any_t &any) override
marley::JSON & get_json()