2 * Copyright (C) 1997-2001 Free Software Foundation
3 * Copyright (C) 2000, 2001 Eazel, Inc.
6 * This file is part of the Gnome Library.
8 * The Gnome Library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public License as
10 * published by the Free Software Foundation; either version 2 of the
11 * License, or (at your option) any later version.
13 * The Gnome Library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Library General Public License for more details.
18 * You should have received a copy of the GNU Library General Public
19 * License along with the Gnome Library; see the file COPYING.LIB. If not,
20 * write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
21 * Boston, MA 02111-1307, USA.
24 #ifndef GNOME_VFS_MIME_H
25 #define GNOME_VFS_MIME_H
29 #include <libgnomevfs/gnome-vfs-uri.h>
35 #ifndef GNOME_VFS_DISABLE_DEPRECATED
36 void gnome_vfs_mime_shutdown (void);
39 const char *gnome_vfs_mime_type_from_name (const char *filename);
40 const char *gnome_vfs_mime_type_from_name_or_default (const char *filename,
41 const char *defaultv);
43 const char *gnome_vfs_get_mime_type_common (GnomeVFSURI *uri);
44 /* FIXME: This function should be named more clearly, maybe
45 to show that it gets the mime type only using the uri information. */
46 const char *gnome_vfs_get_mime_type_from_uri (GnomeVFSURI *uri);
48 #ifndef GNOME_VFS_DISABLE_DEPRECATED
49 const char *gnome_vfs_get_mime_type_from_file_data (GnomeVFSURI *uri);
52 const char *gnome_vfs_get_file_mime_type (const char *path,
53 const struct stat *optional_stat_info,
54 gboolean suffix_only);
56 gboolean gnome_vfs_mime_type_is_supertype (const char *mime_type);
57 char *gnome_vfs_get_supertype_from_mime_type (const char *mime_type);