1 #define _ASSERTION(expr, message) { if (!(expr)) __builtin_abort (); } (void)0
2
3 typedef unsigned int EnumStatusCode;
4
5 class StatusCode
6 {
7 public:
8 static const EnumStatusCode ERROR = 0x8000;
9 static const EnumStatusCode SUCCESS = 0x0000;
10 static bool isSUCCEEDED (EnumStatusCode res) { return (res == SUCCESS); }
11 };
12
13 class LocalizedTextStruct
14 {
15 public:
16 LocalizedTextStruct () {}
17 LocalizedTextStruct (const char *val)
18 {
19 __builtin_strcpy (t, val);
20 }
21 char *getT () { return t; }
22 private:
23 char t[99];
24 };
25
26 typedef union tagValueUnion
27 {
28 LocalizedTextStruct* LocalizedText;
29 } ValueStructUnion;
30
31 typedef struct ValueStruct
32 {
33 unsigned char arrayType;
34 unsigned short dataType;
35 ValueStructUnion value;
36 } ValueStruct;
37
38 class LocalizedText
39 {
40 public:
41 virtual LocalizedTextStruct* getInternHandle ();
42 private:
43 LocalizedTextStruct t;
44 };
45
46 class ValueHelper
47 {
48 public:
49 static EnumStatusCode getLocalizedText (const ValueStruct* pValueStruct, LocalizedText& target);
50 static LocalizedText getLocalizedText (const ValueStruct* pValueStruct);
51 };
52
53 EnumStatusCode LocalizedTextSet (LocalizedTextStruct* pTarget, LocalizedTextStruct* pSource);