Added element_types diagram filter (#131)
This commit is contained in:
@@ -61,6 +61,12 @@ struct filter {
|
||||
|
||||
std::vector<std::string> elements;
|
||||
|
||||
// E.g.:
|
||||
// - class
|
||||
// - enum
|
||||
// - concept
|
||||
std::vector<std::string> element_types;
|
||||
|
||||
// E.g.:
|
||||
// - inheritance/extension
|
||||
// - dependency
|
||||
|
||||
@@ -301,6 +301,10 @@ template <> struct convert<filter> {
|
||||
if (node["elements"])
|
||||
rhs.elements = node["elements"].as<decltype(rhs.elements)>();
|
||||
|
||||
if (node["element_types"])
|
||||
rhs.element_types =
|
||||
node["element_types"].as<decltype(rhs.element_types)>();
|
||||
|
||||
if (node["access"])
|
||||
rhs.access = node["access"].as<decltype(rhs.access)>();
|
||||
|
||||
|
||||
@@ -60,6 +60,8 @@ YAML::Emitter &operator<<(YAML::Emitter &out, const filter &f)
|
||||
out << YAML::Key << "dependencies" << YAML::Value << f.dependencies;
|
||||
if (!f.elements.empty())
|
||||
out << YAML::Key << "elements" << YAML::Value << f.elements;
|
||||
if (!f.element_types.empty())
|
||||
out << YAML::Key << "element_types" << YAML::Value << f.element_types;
|
||||
if (!f.paths.empty())
|
||||
out << YAML::Key << "paths" << YAML::Value << f.paths;
|
||||
if (!f.relationships.empty())
|
||||
|
||||
Reference in New Issue
Block a user