Fixed formatting
This commit is contained in:
@@ -38,7 +38,8 @@ bool decorated_element::skip_relationship() const
|
||||
return false;
|
||||
}
|
||||
|
||||
std::pair<relationship_t, std::string> decorated_element::get_relationship() const
|
||||
std::pair<relationship_t, std::string>
|
||||
decorated_element::get_relationship() const
|
||||
{
|
||||
for (auto &d : decorators_)
|
||||
if (std::dynamic_pointer_cast<decorators::association>(d))
|
||||
|
||||
@@ -56,10 +56,7 @@ const std::vector<std::string> &element::using_namespaces() const
|
||||
return using_namespaces_;
|
||||
}
|
||||
|
||||
std::vector<relationship> &element::relationships()
|
||||
{
|
||||
return relationships_;
|
||||
}
|
||||
std::vector<relationship> &element::relationships() { return relationships_; }
|
||||
|
||||
const std::vector<relationship> &element::relationships() const
|
||||
{
|
||||
|
||||
@@ -17,7 +17,6 @@
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include "relationship.h"
|
||||
#include "decorated_element.h"
|
||||
#include "relationship.h"
|
||||
|
||||
|
||||
@@ -48,8 +48,8 @@ std::string to_string(relationship_t r)
|
||||
}
|
||||
}
|
||||
|
||||
relationship::relationship(relationship_t type,
|
||||
const std::string &destination, scope_t scope, const std::string &label,
|
||||
relationship::relationship(relationship_t type, const std::string &destination,
|
||||
scope_t scope, const std::string &label,
|
||||
const std::string &multiplicity_source,
|
||||
const std::string &multiplicity_destination)
|
||||
: type_{type}
|
||||
@@ -61,10 +61,7 @@ relationship::relationship(relationship_t type,
|
||||
{
|
||||
}
|
||||
|
||||
void relationship::set_type(relationship_t type) noexcept
|
||||
{
|
||||
type_ = type;
|
||||
}
|
||||
void relationship::set_type(relationship_t type) noexcept { type_ = type; }
|
||||
|
||||
relationship_t relationship::type() const noexcept { return type_; }
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ namespace clanguml::common::model {
|
||||
std::string to_string(relationship_t r);
|
||||
|
||||
class relationship : public common::model::decorated_element,
|
||||
public common::model::stylable_element {
|
||||
public common::model::stylable_element {
|
||||
public:
|
||||
relationship(relationship_t type, const std::string &destination,
|
||||
scope_t scope = scope_t::kNone, const std::string &label = "",
|
||||
@@ -55,8 +55,7 @@ public:
|
||||
void set_scope(scope_t scope) noexcept;
|
||||
scope_t scope() const noexcept;
|
||||
|
||||
friend bool operator==(
|
||||
const relationship &l, const relationship &r);
|
||||
friend bool operator==(const relationship &l, const relationship &r);
|
||||
|
||||
private:
|
||||
relationship_t type_{relationship_t::kAssociation};
|
||||
|
||||
Reference in New Issue
Block a user