New yaml validator discussion
I don't know if I got the new validator yaml correct from our conversation, but plugin would have file with tree "rules" and from it:
- one script would validate the user yamls
- second script would create a doxygen page
- third script would generate header file with structures that corresponds to the "rules" e.g:
User yaml:
file: "${example}.yml"
when: $i < 10
write: [data1, data2]
File with yaml "rules":
# plugin root
type: !map
keys:
file:
type: !expression
mandatory: true
when:
type: !expression
mandatory: false
write:
type: !list
elements:
type: !expression
mandatory: false
allow_other_keys: true
Generated c++ structures for plugin to include:
struct write_t {
std::vector<PDI::Expression> values;
};
struct when_t {
PDI::Expression value;
};
struct file_t {
PDI::Expression value;
};
struct root_t {
file_t file;
when_t when;
write_t write;
};
And then we would write some wrapper for paraconf that would fill these structures with values from yaml?