Updated test cases documentation
This commit is contained in:
48
docs/test_cases/t00049.md
Normal file
48
docs/test_cases/t00049.md
Normal file
@@ -0,0 +1,48 @@
|
||||
# t00049 - Test case configurable type aliases
|
||||
## Config
|
||||
```yaml
|
||||
compilation_database_dir: ..
|
||||
output_directory: puml
|
||||
diagrams:
|
||||
t00049_class:
|
||||
type: class
|
||||
using_namespace: clanguml::t00049
|
||||
type_aliases:
|
||||
"std::vector<std::string>": string_vector
|
||||
"std::basic_string<char>": thestring
|
||||
"std::map<int,int>": intmap
|
||||
glob:
|
||||
- ../../tests/t00049/t00049.cc
|
||||
include:
|
||||
namespaces:
|
||||
- clanguml::t00049
|
||||
```
|
||||
## Source code
|
||||
File t00049.cc
|
||||
```cpp
|
||||
#include <map>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
namespace clanguml {
|
||||
namespace t00049 {
|
||||
template <typename T> struct A {
|
||||
T a;
|
||||
|
||||
T &get_a() { return a; }
|
||||
};
|
||||
|
||||
struct R {
|
||||
A<std::basic_string<char>> a_string;
|
||||
A<std::vector<std::string>> a_vector_string;
|
||||
A<std::map<int, int>> a_int_map;
|
||||
|
||||
A<std::map<int, int>> get_int_map() { return a_int_map; }
|
||||
|
||||
void set_int_map(A<std::map<int, int>> &&int_map) { a_int_map = int_map; }
|
||||
};
|
||||
}
|
||||
}
|
||||
```
|
||||
## Generated UML diagrams
|
||||

|
||||
Reference in New Issue
Block a user