updated [and finally fixed my script to produce ready to go de-in(ed)
[platform/upstream/glib.git] / glib / gstdio.h
1 /* gstdio.h - GFilename wrappers for C library functions
2  *
3  * Copyright 2004 Tor Lillqvist
4  *
5  * GLib is free software; you can redistribute it and/or modify it
6  * under the terms of the GNU Lesser General Public License as
7  * published by the Free Software Foundation; either version 2 of the
8  * License, or (at your option) any later version.
9  *
10  * GLib is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13  * Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public
16  * License along with GLib; see the file COPYING.LIB.  If not,
17  * write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18  * Boston, MA 02111-1307, USA.
19  */
20
21 #ifndef __G_STDIO_H__
22 #define __G_STDIO_H__
23
24 #include <glib/gprintf.h>
25
26 #include <sys/stat.h>
27
28 /* Wrappers for C library functions that take pathname arguments. On
29  * Unix, the pathname is a file name as it literally is in the file
30  * system. On well-maintained systems with consistent users who know
31  * what they are doing and no exchange of files with others this would
32  * be a well-defined encoding, preferrably UTF-8. On Windows, the
33  * pathname is always in UTF-8, even if that is not the on-disk
34  * encoding or the encoding used by the Win32 API.
35  */
36
37 int g_open      (const gchar *filename,
38                  int          flags,
39                  int          mode);
40
41 int g_rename    (const gchar *oldfilename,
42                  const gchar *newfilename);
43
44 int g_mkdir     (const gchar *filename,
45                  int          mode);
46
47 int g_stat      (const gchar *filename,
48                  struct stat *buf);
49
50 int g_unlink    (const gchar *filename);
51
52 int g_remove    (const gchar *filename);
53
54 FILE *g_fopen   (const gchar *filename,
55                  const gchar *mode);
56
57 FILE *g_freopen (const gchar *filename,
58                  const gchar *mode,
59                  FILE        *stream);
60
61 #endif /* __G_STDIO_H__ */