summaryrefslogtreecommitdiff
path: root/PACE/pace/aio.h
blob: c9c4b2a1c838944c2677baa1199b1ffe04561be5 (plain)
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
/* $Id$

 * ============================================================================
 *
 * = LIBRARY
 *    pace
 *
 * = FILENAME
 *    pace/aio.h
 *
 * = AUTHOR
 *    Luther Baker
 *
 * ============================================================================ */

#ifndef PACE_AIO_H
#define PACE_AIO_H

#include "pace/config/defines.h"

#if (PACE_HAS_POSIX)
# include "pace/posix/aio.h"
#elif (PACE_VXWORKS)
# include "pace/vxworks/aio.h"
#elif (PACE_WIN32)
# include "pace/win32/aio.h"
#endif

#if defined (PACE_HAS_CPLUSPLUS)
extern "C" {
#endif /* PACE_HAS_CPLUSPLUS */

  /**
     PACE's implementation of the POSIX function aio_cancel.
     See POSIX standard (Internation Standard ISO/IEC 9945-1:1996;
     IEEE Std 1003.1, 1996 Edition), section 6.7.7.
   */
#if (PACE_HAS_POSIX_NONUOF_FUNCS)
  PACE_INLINE int pace_aio_cancel (PACE_HANDLE fildes, pace_aiocb * aiocb);
#endif /* PACE_HAS_POSIX_NONUOF_FUNCS */

  /**
     PACE's implementation of the POSIX function aio_error.
     See POSIX standard (Internation Standard ISO/IEC 9945-1:1996;
     IEEE Std 1003.1, 1996 Edition), section 6.7.5.
   */
#if (PACE_HAS_POSIX_NONUOF_FUNCS)
  PACE_INLINE int pace_aio_error (const pace_aiocb * aiocbp);
#endif /* PACE_HAS_POSIX_NONUOF_FUNCS */

  /**
     PACE's implementation of the POSIX function aio_fsync.
     See POSIX standard (Internation Standard ISO/IEC 9945-1:1996;
     IEEE Std 1003.1, 1996 Edition), section 6.7.9.
   */
#if (PACE_HAS_POSIX_NONUOF_FUNCS)
  PACE_INLINE int pace_aio_fsync (int op, pace_aiocb * aiocbp);
#endif /* PACE_HAS_POSIX_NONUOF_FUNCS */

  /**
     PACE's implementation of the POSIX function aio_read.
     See POSIX standard (Internation Standard ISO/IEC 9945-1:1996;
     IEEE Std 1003.1, 1996 Edition), section 6.7.2.
   */
#if (PACE_HAS_POSIX_NONUOF_FUNCS)
  PACE_INLINE int pace_aio_read (pace_aiocb * aiocbp);
#endif /* PACE_HAS_POSIX_NONUOF_FUNCS */

  /**
     PACE's implementation of the POSIX function aio_return.
     See POSIX standard (Internation Standard ISO/IEC 9945-1:1996;
     IEEE Std 1003.1, 1996 Edition), section 6.7.6.
   */
#if (PACE_HAS_POSIX_NONUOF_FUNCS)
  PACE_INLINE int pace_aio_return (pace_aiocb * aiocbp);
#endif /* PACE_HAS_POSIX_NONUOF_FUNCS */

  /**
     PACE's implementation of the POSIX function aio_suspend.
     See POSIX standard (Internation Standard ISO/IEC 9945-1:1996;
     IEEE Std 1003.1, 1996 Edition), section 6.7.8.
   */
#if (PACE_HAS_POSIX_NONUOF_FUNCS)
  PACE_INLINE int pace_aio_suspend (const pace_aiocb * const list[],
                                    int nent,
                                    const pace_timespec * timeout);
#endif /* PACE_HAS_POSIX_NONUOF_FUNCS */

  /**
     PACE's implementation of the POSIX function aio_write.
     See POSIX standard (Internation Standard ISO/IEC 9945-1:1996;
     IEEE Std 1003.1, 1996 Edition), section 6.7.3.
   */
#if (PACE_HAS_POSIX_NONUOF_FUNCS)
  PACE_INLINE int pace_aio_write (pace_aiocb * aiocbp);
#endif /* PACE_HAS_POSIX_NONUOF_FUNCS */

  /**
     PACE's implementation of the POSIX function lio_listio.
     See POSIX standard (Internation Standard ISO/IEC 9945-1:1996;
     IEEE Std 1003.1, 1996 Edition), section 6.7.4.
   */
#if (PACE_HAS_POSIX_NONUOF_FUNCS)
  PACE_INLINE int pace_lio_listio (int mode,
                                   pace_aiocb * const list[],
                                   int nent,
                                   pace_sigevent * sig);
#endif /* PACE_HAS_POSIX_NONUOF_FUNCS */

#if defined (PACE_HAS_INLINE)
#  if (PACE_HAS_POSIX)
#    include "pace/posix/aio.inl"
#  elif (PACE_VXWORKS)
#    include "pace/vxworks/aio.inl"
#  elif (PACE_WIN32)
#    include "pace/win32/aio.inl"
#  endif
#endif /* PACE_HAS_INLINE */

#if defined (PACE_HAS_CPLUSPLUS)
}
#endif /* PACE_HAS_CPLUSPLUS */

#endif /* PACE_AIO_H */