update dev300-m58
[ooovba.git] / sal / inc / rtl / tres.h
blob9535d0b2adc27fec1c24082dae29b24d890157bc
1 #ifndef _RTL_TRES_H_
2 #define _RTL_TRES_H_
4 #include <osl/diagnose.h>
5 #include <rtl/string.h>
7 #ifdef __cplusplus
8 extern "C" {
9 #endif
11 /* comandline flags */
12 #define rtl_tres_Flag_BOOM 0x00000001
13 #define rtl_tres_Flag_VERBOSE 0x00000002
14 #define rtl_tres_Flag_SKIP 0x00000004
15 #define rtl_tres_Flag_LOG 0x00000010
16 #define rtl_tres_Flag_HIS 0x00000100
17 #define rtl_tres_Flag_TIME 0x00000200
18 #define rtl_tres_Flag_MSG 0x00000400
19 #define rtl_tres_Flag_QUIET 0x00000800
21 /* state flags */
22 #define rtl_tres_Flag_SUB 0x01000000
23 #define rtl_tres_Flag_PASSED 0x10000000
24 #define rtl_tres_Flag_OK 0x20000000
28 /* forward declaration and type definition */
29 struct _rtl_TestResult;
30 typedef struct _rtl_TestResult rtl_TestResult;
33 typedef void* rtl_funcstate;
34 typedef void* rtl_cmpstate;
36 /* type definitions of function pointers wich can be overloaded */
37 typedef sal_Bool (SAL_CALL *rtl_tres_state_ptr)(
38 rtl_TestResult*,
39 sal_Bool,
40 const sal_Char*,
41 const sal_Char*,
42 sal_Bool
45 typedef void (SAL_CALL *rtl_tres_end_ptr)( rtl_TestResult*, const sal_Char* );
46 typedef sal_Bool (SAL_CALL *rtl_tres_ispassed_ptr)( rtl_TestResult* );
47 typedef sal_Bool (SAL_CALL *rtl_tres_isok_ptr)( rtl_TestResult* );
48 typedef rtl_funcstate (SAL_CALL *rtl_tres_funcstate_ptr)( rtl_TestResult* );
49 typedef sal_Bool (SAL_CALL *rtl_tres_isbit_ptr)( rtl_TestResult*,
50 sal_uInt32 );
52 typedef rtl_funcstate (SAL_CALL *rtl_tres_getnextfuncstate_ptr)
53 ( rtl_funcstate );
54 typedef rtl_funcstate (SAL_CALL *rtl_tres_getprevfuncstate_ptr)
55 ( rtl_funcstate );
56 typedef sal_uInt32 (SAL_CALL *rtl_tres_getflags_ptr)( rtl_funcstate );
57 typedef rtl_String* (SAL_CALL *rtl_tres_getname_ptr)( rtl_funcstate );
58 typedef sal_uInt32 (SAL_CALL *rtl_tres_getstart_ptr)( rtl_funcstate );
59 typedef sal_uInt32 (SAL_CALL *rtl_tres_getstop_ptr)( rtl_funcstate );
60 typedef rtl_cmpstate (SAL_CALL *rtl_tres_getcmpstate_ptr)( rtl_funcstate );
62 typedef sal_Bool (SAL_CALL *rtl_tres_getstat_ptr)( rtl_cmpstate );
63 typedef rtl_String* (SAL_CALL *rtl_tres_getmsg_ptr)( rtl_cmpstate );
64 typedef rtl_cmpstate (SAL_CALL *rtl_tres_getnextcmpstate_ptr)( rtl_cmpstate );
66 /* type definition of vtable structure for testresult */
67 typedef struct _rtl_TestResult_vtable
69 sal_uInt32 vtablesize;
70 rtl_tres_state_ptr state_;
71 rtl_tres_end_ptr end_;
72 rtl_tres_ispassed_ptr ispassed;
73 rtl_tres_isok_ptr isok;
74 rtl_tres_funcstate_ptr funcstate;
75 rtl_tres_isbit_ptr isbit;
76 rtl_tres_getnextfuncstate_ptr nextfuncstate;
77 rtl_tres_getprevfuncstate_ptr prevfuncstate;
78 rtl_tres_getflags_ptr flags;
79 rtl_tres_getname_ptr name;
80 rtl_tres_getstart_ptr start;
81 rtl_tres_getstop_ptr stop;
82 rtl_tres_getcmpstate_ptr cmpstate;
83 rtl_tres_getstat_ptr stat;
84 rtl_tres_getmsg_ptr msg;
85 rtl_tres_getnextcmpstate_ptr nextcmpstate;
87 } rtl_TestResult_vtable;
89 /* type definition of testresult structure */
90 struct _rtl_TestResult
92 rtl_TestResult_vtable * pFuncs;
93 void * pExternalData;
98 /* exports */
99 rtl_TestResult* SAL_CALL rtl_tres_create( const sal_Char* meth, sal_uInt32 flags );
100 void SAL_CALL rtl_tres_destroy( rtl_TestResult* res );
102 #ifdef __cplusplus
104 #endif
106 #endif /* _RTL_TRES_H_ */