Added package dependencies and dependants filter
This commit is contained in:
@@ -60,22 +60,6 @@ config load(const std::string &config_file)
|
||||
}
|
||||
}
|
||||
|
||||
std::string to_string(const diagram_type t)
|
||||
{
|
||||
switch (t) {
|
||||
case diagram_type::class_diagram:
|
||||
return "class";
|
||||
case diagram_type::sequence_diagram:
|
||||
return "sequence";
|
||||
case diagram_type::package_diagram:
|
||||
return "package";
|
||||
case diagram_type::include_diagram:
|
||||
return "include";
|
||||
default:
|
||||
assert(false);
|
||||
}
|
||||
}
|
||||
|
||||
std::string to_string(const hint_t t)
|
||||
{
|
||||
switch (t) {
|
||||
@@ -115,7 +99,10 @@ void inheritable_diagram_options::inherit(
|
||||
relative_to.override(parent.relative_to);
|
||||
}
|
||||
|
||||
diagram_type class_diagram::type() const { return diagram_type::class_diagram; }
|
||||
common::model::diagram_t class_diagram::type() const
|
||||
{
|
||||
return common::model::diagram_t::kClass;
|
||||
}
|
||||
|
||||
bool class_diagram::has_class(std::string clazz)
|
||||
{
|
||||
@@ -133,19 +120,19 @@ bool class_diagram::has_class(std::string clazz)
|
||||
return false;
|
||||
}
|
||||
|
||||
diagram_type sequence_diagram::type() const
|
||||
common::model::diagram_t sequence_diagram::type() const
|
||||
{
|
||||
return diagram_type::sequence_diagram;
|
||||
return common::model::diagram_t::kSequence;
|
||||
}
|
||||
|
||||
diagram_type package_diagram::type() const
|
||||
common::model::diagram_t package_diagram::type() const
|
||||
{
|
||||
return diagram_type::package_diagram;
|
||||
return common::model::diagram_t::kPackage;
|
||||
}
|
||||
|
||||
diagram_type include_diagram::type() const
|
||||
common::model::diagram_t include_diagram::type() const
|
||||
{
|
||||
return diagram_type::include_diagram;
|
||||
return common::model::diagram_t::kInclude;
|
||||
}
|
||||
|
||||
template <>
|
||||
|
||||
@@ -35,13 +35,6 @@
|
||||
namespace clanguml {
|
||||
namespace config {
|
||||
|
||||
enum class diagram_type {
|
||||
class_diagram,
|
||||
sequence_diagram,
|
||||
package_diagram,
|
||||
include_diagram
|
||||
};
|
||||
|
||||
enum class method_arguments { full, abbreviated, none };
|
||||
|
||||
struct plantuml {
|
||||
@@ -102,7 +95,6 @@ struct git_config {
|
||||
std::string toplevel;
|
||||
};
|
||||
|
||||
std::string to_string(const diagram_type t);
|
||||
std::string to_string(const hint_t t);
|
||||
|
||||
struct inheritable_diagram_options {
|
||||
@@ -127,7 +119,7 @@ struct inheritable_diagram_options {
|
||||
struct diagram : public inheritable_diagram_options {
|
||||
virtual ~diagram() = default;
|
||||
|
||||
virtual diagram_type type() const = 0;
|
||||
virtual common::model::diagram_t type() const = 0;
|
||||
|
||||
std::string name;
|
||||
};
|
||||
@@ -141,7 +133,7 @@ struct source_location {
|
||||
struct class_diagram : public diagram {
|
||||
virtual ~class_diagram() = default;
|
||||
|
||||
diagram_type type() const override;
|
||||
common::model::diagram_t type() const override;
|
||||
|
||||
option<std::vector<std::string>> classes{"classes"};
|
||||
option<layout_hints> layout{"layout"};
|
||||
@@ -152,7 +144,7 @@ struct class_diagram : public diagram {
|
||||
struct sequence_diagram : public diagram {
|
||||
virtual ~sequence_diagram() = default;
|
||||
|
||||
diagram_type type() const override;
|
||||
common::model::diagram_t type() const override;
|
||||
|
||||
option<std::vector<source_location>> start_from{"start_from"};
|
||||
};
|
||||
@@ -160,7 +152,7 @@ struct sequence_diagram : public diagram {
|
||||
struct package_diagram : public diagram {
|
||||
virtual ~package_diagram() = default;
|
||||
|
||||
diagram_type type() const override;
|
||||
common::model::diagram_t type() const override;
|
||||
|
||||
option<layout_hints> layout{"layout"};
|
||||
};
|
||||
@@ -168,7 +160,7 @@ struct package_diagram : public diagram {
|
||||
struct include_diagram : public diagram {
|
||||
virtual ~include_diagram() = default;
|
||||
|
||||
diagram_type type() const override;
|
||||
common::model::diagram_t type() const override;
|
||||
|
||||
option<layout_hints> layout{"layout"};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user