forked from mceSystems/nbind
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathreflect.txt
192 lines (170 loc) · 5.26 KB
/
reflect.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
class Array {
Array();
static std::array<int32_t, 3> getInts();
static std::array<int32_t, 3> callWithInts(cbFunction &, std::array<int32_t, 3>);
};
class Buffer {
static uint32_t sum(Buffer);
static void mul2(Buffer);
};
class Callback {
Callback();
static void callVoidFunc(cbFunction &);
static void callVoidFunc2(std::function<void ()>);
static bool callNegate(cbFunction &, bool);
static bool callNegate2(std::function<bool (bool)>, bool);
static int32_t callAddInt(const cbFunction &, int32_t, int32_t);
static int32_t callAddInt2(const std::function<int32_t (int32_t, int32_t)> &, int32_t, int32_t);
static float64_t callIncrementDouble(const cbFunction &, float64_t);
static std::string callCatenate(cbFunction &, const char *, const char *);
static std::string callCatenate2(cbFunction &, const char *, const char *);
static void callCStrings(cbFunction &);
};
class Coord {
Coord(uint32_t, uint32_t);
};
class GetterSetter {
GetterSetter();
int32_t x; // Read-only
int32_t y;
int32_t z;
const char * t;
int32_t XYZ; // Read-only
};
class InheritanceA {
InheritanceA();
uint32_t useA();
static uint32_t staticA(InheritanceA &);
};
class InheritanceB : public InheritanceA {
InheritanceB();
uint32_t useB();
static uint32_t staticA(InheritanceB &);
static uint32_t staticB(InheritanceB &);
InheritanceA * a; // Read-only
};
class InheritanceC : public InheritanceA {
InheritanceC();
uint32_t useC();
static uint32_t staticA(InheritanceC &);
static uint32_t staticC(InheritanceC &);
InheritanceA * a; // Read-only
};
class InheritanceD : public InheritanceC, public InheritanceB {
InheritanceD();
uint32_t useD();
static uint32_t staticA(InheritanceD &);
static uint32_t staticB(InheritanceD &);
static uint32_t staticC(InheritanceD &);
static uint32_t staticD(InheritanceD &);
InheritanceA * a; // Read-only
InheritanceB * b; // Read-only
InheritanceC * c; // Read-only
};
class Nullable {
static Coord * getCoord();
static Coord * getNull();
static void foo(Coord *);
static void bar(Coord *); // Nullable
};
class Overload {
Overload();
uint32_t test(uint32_t);
uint32_t test2(uint32_t, uint32_t);
uint32_t testConst(uint32_t);
uint32_t testConst2(uint32_t, uint32_t);
static uint32_t testStatic(uint32_t);
static uint32_t testStatic2(uint32_t, uint32_t);
};
class PrimitiveMethods {
PrimitiveMethods();
PrimitiveMethods(int32_t);
PrimitiveMethods(int32_t, std::string);
static bool negateStatic(bool);
bool negate(bool);
static int32_t incrementIntStatic(int32_t);
int32_t incrementInt(int32_t);
static void incrementStateStatic();
void incrementState();
static int32_t getStateStatic();
int32_t getState();
std::string getString();
static std::string getStringStatic();
static int32_t strLengthStatic(const char *);
int32_t strLength(const unsigned char *);
static char * catenateStatic(const char *, const char *);
unsigned char * catenate(const unsigned char *, const unsigned char *);
std::string catenate2(const std::string &, const std::string &);
static int64_t ftol(float64_t);
static uint64_t ftoul(float64_t);
static int64_t ftoll(float64_t);
static uint64_t ftoull(float64_t);
static float64_t ltof(int64_t);
static float64_t ultof(uint64_t);
static float64_t lltof(int64_t);
static float64_t ulltof(uint64_t);
};
class Reference {
Reference();
void read();
void write();
static Reference getValue();
static Reference * getPtr();
static Reference & getRef();
static const Reference * getConstPtr();
static const Reference & getConstRef();
static void readPtr(const Reference *);
static void readRef(const Reference &);
static void writePtr(Reference *);
static void writeRef(Reference *);
};
class Smart {
static std::shared_ptr<Smart> make(int32_t);
void test();
static void testStatic(Smart *);
static void testShared(std::shared_ptr<Smart>);
};
class Strict {
Strict();
int32_t testInt(int32_t);
bool testBool(bool);
std::string testString(std::string);
const char * testCString(const char *);
int32_t strictInt(int32_t); // Strict
bool strictBool(bool); // Strict
std::string strictString(std::string); // Strict
const char * strictCString(const char *); // Strict
};
class StrictStatic {
static int32_t testInt(int32_t);
static bool testBool(bool);
static std::string testString(std::string);
static const char * testCString(const char *);
static int32_t strictInt(int32_t); // Strict
static bool strictBool(bool); // Strict
static std::string strictString(std::string); // Strict
static const char * strictCString(const char *); // Strict
};
class Value {
Value();
static Coord getCoord();
static Coord callWithCoord(cbFunction &, Coord, Coord);
};
class Vector {
Vector();
static std::vector<int32_t> getInts();
static std::vector<int32_t> callWithInts(cbFunction &, std::vector<int32_t>);
static std::vector<std::string> callWithStrings(cbFunction &, std::vector<std::string>);
};
int32_t decrementInt(int32_t);
int32_t incrementInt(int32_t);
uint32_t multiTest(uint32_t);
uint32_t multiTest2(uint32_t, uint32_t);
bool strictBool(bool); // Strict
const char * strictCString(const char *); // Strict
int32_t strictInt(int32_t); // Strict
std::string strictString(std::string); // Strict
bool testBool(bool);
const char * testCString(const char *);
int32_t testInt(int32_t);
std::string testString(std::string);