Products Support Documentation Download
psp_internaltypes.h
Go to the documentation of this file.
1 /*
2  * Raima Database Manager
3  *
4  * Copyright (C) 2016 Raims Inc., All rights reserved.
5  *
6  * Use of this software, whether in source code format, or in executable,
7  * binary object code form, is governed by the Raima LICENSE which
8  * is fully described in the LICENSE.TXT file, included within this
9  * distribution of files.
10  */
11 
24 #ifndef RDM_DOXYGEN
25 
26 #ifndef PSP_INTERNALTYPES_H
27 #define PSP_INTERNALTYPES_H
28 
29 #include "psptypes.h"
30 #include "rdmretcodetypes.h"
31 
32 #if defined(RDM_WINDOWS) || defined(RDM_WINCE)
33  #define EXTVARARG_FCN __cdecl
34 #else
35  #define EXTVARARG_FCN
36 #endif
37 
38 typedef enum {
39  PSP_FILE_MODE_UNKNOWN,
40  PSP_FILE_MODE_UTF8,
41  PSP_FILE_MODE_UTF16
42 } PSP_FILE_MODE;
43 
44 typedef RDM_RETCODE (EXTERNAL_FCN *PSP_THREAD_FCN)(void *);
45 #if defined(RDM_NO_THREADS)
46  typedef struct {
47  uint32_t id;
48  RDM_RETCODE rc;
49  } psp_thread_t;
50  typedef uint32_t psp_thread_id_t;
51 #elif defined(RDM_INTEGRITY_TASKS)
52  #include <unistd.h>
53  typedef struct {
54  void *id;
55  PSP_THREAD_FCN fcn;
56  void *arg;
57  RDM_RETCODE rc;
58  RDM_BOOL_T initialized;
59  } psp_thread_t;
60  typedef Task psp_thread_id_t;
61 #elif defined(RDM_VXWORKS)
62  #if defined(RDM_64BIT)
63  typedef struct {
64  void * id;
65  PSP_THREAD_FCN fcn;
66  void *arg;
67  RDM_RETCODE rc;
68  RDM_BOOL_T initialized;
69  } psp_thread_t;
70  typedef void * psp_thread_id_t;
71  #else
72  typedef struct {
73  uint32_t id;
74  PSP_THREAD_FCN fcn;
75  void *arg;
76  RDM_RETCODE rc;
77  RDM_BOOL_T initialized;
78  } psp_thread_t;
79  typedef uint32_t psp_thread_id_t;
80  #endif
81 #elif defined(RDM_UNIX)
82  #include <pthread.h>
83  typedef struct {
84  pthread_t id;
85  RDM_RETCODE rc;
86  } psp_thread_t;
87  typedef pthread_t psp_thread_id_t;
88 #elif defined(RDM_WINDOWS) || defined(RDM_WINCE)
89  typedef struct {
90  uintptr_t id;
91  PSP_THREAD_FCN fcn;
92  void *arg;
93  } psp_thread_t;
94  typedef uintptr_t psp_thread_id_t;
95 #endif
96 
97 typedef enum {
98  PSP_UTF8_ERROR_BREAK,
99  PSP_UTF8_ERROR_CONTINUE
100 } PSP_UTF8_ERROR_BEHAVIOR;
101 
102 typedef enum {B_START, B_CURRENT, B_END} SEEK_TYPE;
103 
104 #endif
105 #endif
RDM_BOOL_T
Definition: psptypes.h:62
Header for the Platform Support Package - Platform dependent types.
RDM Status and Error Return Codes.
RDM_RETCODE
RDM status and error return codes.