trim whitespace so gtk-doc groks the function name
[platform/upstream/glib.git] / gio / gvfs.h
1 /* GIO - GLib Input, Output and Streaming Library
2  * 
3  * Copyright (C) 2006-2007 Red Hat, Inc.
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Lesser General Public
7  * License as published by the Free Software Foundation; either
8  * version 2 of the License, or (at your option) any later version.
9  *
10  * This library 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
16  * Public License along with this library; if not, write to the
17  * Free Software Foundation, Inc., 59 Temple Place, Suite 330,
18  * Boston, MA 02111-1307, USA.
19  *
20  * Author: Alexander Larsson <alexl@redhat.com>
21  */
22
23 #if !defined (__GIO_GIO_H_INSIDE__) && !defined (GIO_COMPILATION)
24 #error "Only <gio/gio.h> can be included directly."
25 #endif
26
27 #ifndef __G_VFS_H__
28 #define __G_VFS_H__
29
30 #include <glib-object.h>
31 #include <gio/gfile.h>
32
33 G_BEGIN_DECLS
34
35 #define G_TYPE_VFS         (g_vfs_get_type ())
36 #define G_VFS(o)           (G_TYPE_CHECK_INSTANCE_CAST ((o), G_TYPE_VFS, GVfs))
37 #define G_VFS_CLASS(k)     (G_TYPE_CHECK_CLASS_CAST((k), G_TYPE_VFS, GVfsClass))
38 #define G_VFS_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), G_TYPE_VFS, GVfsClass))
39 #define G_IS_VFS(o)        (G_TYPE_CHECK_INSTANCE_TYPE ((o), G_TYPE_VFS))
40 #define G_IS_VFS_CLASS(k)  (G_TYPE_CHECK_CLASS_TYPE ((k), G_TYPE_VFS))
41
42 /**
43  * G_VFS_EXTENSION_POINT_NAME:
44  *
45  * Extension point for #GVfs functionality. 
46  * See <link linkend="gio-extension-points">Extending GIO</link>.
47  */
48 #define G_VFS_EXTENSION_POINT_NAME "gio-vfs"
49
50 /**
51  * GVfs:
52  * 
53  * Virtual File System object.
54  **/
55 typedef struct _GVfs         GVfs; /* Dummy typedef */
56 typedef struct _GVfsClass    GVfsClass;
57
58 struct _GVfs {
59   GObject parent_instance;
60 };
61
62 struct _GVfsClass
63 {
64   GObjectClass parent_class;
65
66   /* Virtual Table */
67
68   gboolean             (*is_active)                 (GVfs *vfs);
69   GFile               *(*get_file_for_path)         (GVfs *vfs,
70                                                      const char *path);
71   GFile               *(*get_file_for_uri)          (GVfs *vfs,
72                                                      const char *uri);
73   const gchar * const *(*get_supported_uri_schemes) (GVfs *vfs);
74   GFile               *(*parse_name)                (GVfs *vfs,
75                                                      const char *parse_name);
76
77
78   /*< private >*/
79   /* Padding for future expansion */
80   void (*_g_reserved1) (void);
81   void (*_g_reserved2) (void);
82   void (*_g_reserved3) (void);
83   void (*_g_reserved4) (void);
84   void (*_g_reserved5) (void);
85   void (*_g_reserved6) (void);
86   void (*_g_reserved7) (void);
87   void (*_g_reserved8) (void);
88   void (*_g_reserved9) (void);
89   void (*_g_reserved10) (void);
90   void (*_g_reserved11) (void);
91   void (*_g_reserved12) (void);
92   
93 };
94
95 GType g_vfs_get_type (void) G_GNUC_CONST;
96
97 gboolean              g_vfs_is_active                 (GVfs       *vfs);
98 GFile *               g_vfs_get_file_for_path         (GVfs       *vfs,
99                                                        const char *path);
100 GFile *               g_vfs_get_file_for_uri          (GVfs       *vfs,
101                                                        const char *uri);
102 const gchar* const * g_vfs_get_supported_uri_schemes  (GVfs *vfs);
103
104 GFile *               g_vfs_parse_name                (GVfs       *vfs,
105                                                        const char *parse_name);
106
107 GVfs *                g_vfs_get_default               (void);
108 GVfs *                g_vfs_get_local                 (void);
109
110 G_END_DECLS
111
112 #endif /* __G_VFS_H__ */