425 lines
9.5 KiB
Markdown
425 lines
9.5 KiB
Markdown
# t00053 - Test case for `together` layout hint in class diagram
|
|
## Config
|
|
```yaml
|
|
diagrams:
|
|
t00053_class:
|
|
type: class
|
|
glob:
|
|
- t00053.cc
|
|
include:
|
|
namespaces:
|
|
- clanguml::t00053
|
|
using_namespace: clanguml::t00053
|
|
layout:
|
|
a:
|
|
- together: [c,e,f]
|
|
A:
|
|
- together: [C,E,F]
|
|
h:
|
|
- together: [j]
|
|
|
|
```
|
|
## Source code
|
|
File `tests/t00053/t00053.cc`
|
|
```cpp
|
|
namespace clanguml {
|
|
namespace t00053 {
|
|
struct a { };
|
|
struct b { };
|
|
struct c { };
|
|
struct d { };
|
|
struct e { };
|
|
struct f { };
|
|
struct g { };
|
|
|
|
struct A { };
|
|
struct B { };
|
|
struct C { };
|
|
struct D { };
|
|
struct E { };
|
|
struct F { };
|
|
struct G { };
|
|
|
|
enum class h { hhh };
|
|
enum class i { iii };
|
|
enum class j { jjj };
|
|
|
|
}
|
|
}
|
|
```
|
|
## Generated PlantUML diagrams
|
|

|
|
## Generated Mermaid diagrams
|
|

|
|
## Generated JSON models
|
|
```json
|
|
{
|
|
"diagram_type": "class",
|
|
"elements": [
|
|
{
|
|
"bases": [],
|
|
"display_name": "a",
|
|
"id": "2781038698340153159",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "a",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 3,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "b",
|
|
"id": "11010757161954084380",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "b",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 4,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "c",
|
|
"id": "4035710408756550430",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "c",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 5,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "d",
|
|
"id": "10115641318897792718",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "d",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 6,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "e",
|
|
"id": "7263375710215516879",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "e",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 7,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "f",
|
|
"id": "11370313029314192677",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "f",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 8,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "g",
|
|
"id": "1601817013670096009",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "g",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 9,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "A",
|
|
"id": "2581142729043675406",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "A",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 11,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "B",
|
|
"id": "7012991760569303265",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "B",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 12,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "C",
|
|
"id": "9987791926272995751",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "C",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 13,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "D",
|
|
"id": "3761824362382283158",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "D",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 14,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "E",
|
|
"id": "8307078113770890060",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "E",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 15,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "F",
|
|
"id": "4242029990488317339",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "F",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 16,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"bases": [],
|
|
"display_name": "G",
|
|
"id": "8252914587750588627",
|
|
"is_abstract": false,
|
|
"is_nested": false,
|
|
"is_struct": true,
|
|
"is_template": false,
|
|
"is_union": false,
|
|
"members": [],
|
|
"methods": [],
|
|
"name": "G",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 8,
|
|
"file": "t00053.cc",
|
|
"line": 17,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"template_parameters": [],
|
|
"type": "class"
|
|
},
|
|
{
|
|
"constants": [
|
|
"hhh"
|
|
],
|
|
"display_name": "h",
|
|
"id": "1527826936592257484",
|
|
"is_nested": false,
|
|
"name": "h",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 12,
|
|
"file": "t00053.cc",
|
|
"line": 19,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"type": "enum"
|
|
},
|
|
{
|
|
"constants": [
|
|
"iii"
|
|
],
|
|
"display_name": "i",
|
|
"id": "11785716967071887447",
|
|
"is_nested": false,
|
|
"name": "i",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 12,
|
|
"file": "t00053.cc",
|
|
"line": 20,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"type": "enum"
|
|
},
|
|
{
|
|
"constants": [
|
|
"jjj"
|
|
],
|
|
"display_name": "j",
|
|
"id": "7720668843789291480",
|
|
"is_nested": false,
|
|
"name": "j",
|
|
"namespace": "clanguml::t00053",
|
|
"source_location": {
|
|
"column": 12,
|
|
"file": "t00053.cc",
|
|
"line": 21,
|
|
"translation_unit": "t00053.cc"
|
|
},
|
|
"type": "enum"
|
|
}
|
|
],
|
|
"name": "t00053_class",
|
|
"package_type": "namespace",
|
|
"relationships": [],
|
|
"using_namespace": "clanguml::t00053"
|
|
}
|
|
```
|