siplasplas
A library for C++ reflection and introspection
class.hpp
1 #ifndef SIPLASPLAS_REFLECTION_STATIC_CLASS_HPP
2 #define SIPLASPLAS_REFLECTION_STATIC_CLASS_HPP
3 
4 #include "sourceinfo.hpp"
5 #include <siplasplas/utility/meta.hpp>
6 
7 namespace cpp
8 {
9 
10 namespace static_reflection
11 {
12 
13 namespace meta
14 {
15 
16 #ifndef SIPLASPLAS_DOXYGEN_RUNNING
17 template<typename SourceInfo_, typename Class_,
18  typename Methods_,
19  typename Fields_,
20  typename Constructors_,
21  typename Classes_,
22  typename Enums_
23 >
24 class Class
25 #else
26 
31 class Class
32 #endif // SIPLASPLAS_DOXYGEN_RUNNING
33 {
34 public:
35  using class_type = Class_;
36  using type = class_type;
37 
48  using SourceInfo = SourceInfo_;
49 
57  using Methods = Methods_;
58 
66  using Fields = Fields_;
67 
72  using Constructors = Constructors_;
73 
79  using Classes = Classes_;
80 
86  using Enums = Enums_;
87 };
88 
89 }
90 
91 namespace codegen
92 {
93  template<typename T>
94  class Class :
96  static_reflection::meta::EmptySourceInfo<T>,
97  T,
98  ::cpp::meta::list<>,
99  ::cpp::meta::list<>,
100  ::cpp::meta::list<>,
101  ::cpp::meta::list<>,
102  ::cpp::meta::list<>
103  >
104  {};
105 }
106 
121 template<typename T>
122 class Class : public codegen::Class<T>
123 {
124  using type = T;
125 };
126 
127 }
128 
129 }
130 
131 #endif // SIPLASPLAS_REFLECTION_STATIC_CLASS_HPP
Definition: canary_allocator.hpp:7
Returns static reflection information of a given class.
Definition: class.hpp:122
Constructors_ Constructors
Returns information about the public constructors of the class. Returns an empty cpp::meta::list<>, constructor information is not currently collected by the reflection parser
Definition: class.hpp:72
Stores static reflection information of a given class.
Definition: class.hpp:31