Sync usage with man page.
[netbsd-mini2440.git] / gnu / lib / libg++ / g++-include / open.h
blobffe81a15ac17444750637fd1a416420b940da42d
2 #ifndef _open_h
3 #ifdef __GNUG__
4 #pragma once
5 #pragma interface
6 #endif
7 #define _open_h 1
9 #include <File.h>
10 #include <sys/file.h> // needed to determine values of O_RDONLY...
14 translation stuff for opening files.
19 enum sys_open_cmd_io_mode // These should be correct for most systems
21 sio_read = O_RDONLY,
22 sio_write = O_WRONLY,
23 sio_readwrite = O_RDWR,
24 sio_append = O_APPEND
27 enum sys_open_cmd_access_mode
29 sa_create = O_CREAT,
30 sa_truncate = O_TRUNC,
31 sa_createonly = O_EXCL | O_CREAT
35 int open_cmd_arg(io_mode i, access_mode a); // decode modes
36 char* fopen_cmd_arg(io_mode i);
37 int open_cmd_arg(const char* m);
39 #endif