119 lines
2.6 KiB
Markdown
119 lines
2.6 KiB
Markdown
# t20027 - Filter call expressions based on access test case
|
|
## Config
|
|
```yaml
|
|
compilation_database_dir: ..
|
|
output_directory: puml
|
|
diagrams:
|
|
t20027_sequence:
|
|
type: sequence
|
|
glob:
|
|
- ../../tests/t20027/t20027.cc
|
|
include:
|
|
namespaces:
|
|
- clanguml::t20027
|
|
access:
|
|
- public
|
|
using_namespace:
|
|
- clanguml::t20027
|
|
start_from:
|
|
- function: "clanguml::t20027::tmain()"
|
|
```
|
|
## Source code
|
|
File t20027.cc
|
|
```cpp
|
|
namespace clanguml {
|
|
namespace t20027 {
|
|
|
|
class A {
|
|
public:
|
|
void a() { aa(); }
|
|
|
|
protected:
|
|
void aa() { aaa(); }
|
|
|
|
private:
|
|
void aaa() { }
|
|
};
|
|
|
|
void tmain()
|
|
{
|
|
A a;
|
|
|
|
a.a();
|
|
}
|
|
}
|
|
}
|
|
```
|
|
## Generated UML diagrams
|
|

|
|
## Generated JSON models
|
|
```json
|
|
{
|
|
"diagram_type": "sequence",
|
|
"metadata": {
|
|
"clang_uml_version": "0.3.7-47-g2104d93",
|
|
"llvm_version": "Ubuntu clang version 15.0.6",
|
|
"schema_version": 1
|
|
},
|
|
"name": "t20027_sequence",
|
|
"participants": [
|
|
{
|
|
"id": "1581009482994430286",
|
|
"name": "clanguml::t20027::tmain()",
|
|
"source_location": {
|
|
"column": 6,
|
|
"file": "../../tests/t20027/t20027.cc",
|
|
"line": 15,
|
|
"translation_unit": "../../tests/t20027/t20027.cc"
|
|
},
|
|
"type": "function"
|
|
},
|
|
{
|
|
"id": "583525629936262089",
|
|
"name": "clanguml::t20027::A",
|
|
"source_location": {
|
|
"column": 7,
|
|
"file": "../../tests/t20027/t20027.cc",
|
|
"line": 4,
|
|
"translation_unit": "../../tests/t20027/t20027.cc"
|
|
},
|
|
"type": "class"
|
|
}
|
|
],
|
|
"sequences": [
|
|
{
|
|
"messages": [
|
|
{
|
|
"from": {
|
|
"activity_id": "1581009482994430286",
|
|
"activity_name": "clanguml::t20027::tmain()",
|
|
"participant_id": "1581009482994430286",
|
|
"participant_name": "clanguml::t20027::tmain()"
|
|
},
|
|
"name": "a()",
|
|
"return_type": "void",
|
|
"scope": "normal",
|
|
"source_location": {
|
|
"column": 5,
|
|
"file": "../../tests/t20027/t20027.cc",
|
|
"line": 19,
|
|
"translation_unit": "../../tests/t20027/t20027.cc"
|
|
},
|
|
"to": {
|
|
"activity_id": "910514967786202717",
|
|
"activity_name": "clanguml::t20027::A::a()",
|
|
"participant_id": "583525629936262089"
|
|
},
|
|
"type": "message"
|
|
}
|
|
],
|
|
"start_from": {
|
|
"id": 1581009482994430286,
|
|
"location": "clanguml::t20027::tmain()"
|
|
}
|
|
}
|
|
],
|
|
"using_namespace": "clanguml::t20027"
|
|
}
|
|
```
|