48 lines
727 B
Markdown
48 lines
727 B
Markdown
# t00010 - Basic template instantiation
|
|
## Config
|
|
```yaml
|
|
compilation_database_dir: ..
|
|
output_directory: puml
|
|
diagrams:
|
|
t00010_class:
|
|
type: class
|
|
glob:
|
|
- ../../tests/t00010/t00010.cc
|
|
using_namespace:
|
|
- clanguml::t00010
|
|
include:
|
|
namespaces:
|
|
- clanguml::t00010
|
|
|
|
```
|
|
## Source code
|
|
File t00010.cc
|
|
```cpp
|
|
#include <string>
|
|
#include <vector>
|
|
|
|
namespace clanguml {
|
|
namespace t00010 {
|
|
|
|
template <typename T, typename P> class A {
|
|
public:
|
|
T first;
|
|
P second;
|
|
};
|
|
|
|
template <typename T> class B {
|
|
public:
|
|
A<T, std::string> astring;
|
|
};
|
|
|
|
class C {
|
|
public:
|
|
B<int> aintstring;
|
|
};
|
|
}
|
|
}
|
|
|
|
```
|
|
## Generated UML diagrams
|
|

|