gplate/gplate-library.h
author Gary Kramlich <grim@reaperworld.com>
Sat Jul 03 23:24:33 2010 -0500 (22 months ago)
changeset 394 ad26d98e20e6
parent 329 9429ccb6dcb2
permissions -rw-r--r--
Changed the license from gplv2 to gplv3
Updated copyrights to be 2007-2010 rather than 2007-2008 (since just about everything has been touched recently
Ignored the top level tests/ directory for now since that is slowly being replaced
     1 /*
     2  * Copyright (C) 2007-2010 Gary Kramlich <grim@reaperworld.com>
     3  *
     4  * This program is free software: you can redistribute it and/or modify
     5  * it under the terms of the GNU General Public License as published by
     6  * the Free Software Foundation, either version 3 of the License, or
     7  * (at your option) any later version.
     8  *
     9  * This program is distributed in the hope that it will be useful,
    10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
    11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    12  * GNU General Public License for more details.
    13  *
    14  * You should have received a copy of the GNU General Public License
    15  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
    16  */
    17 #ifndef GPLATE_LIBRARY_H
    18 #define GPLATE_LIBRARY_H
    19 
    20 #include <glib.h>
    21 
    22 #include <gplate/gplate-function.h>
    23 #include <gplate/gplate-tag.h>
    24 
    25 G_BEGIN_DECLS
    26 
    27 typedef void (*GPlateLibraryTagsForeachFunc)(GType tag, const gchar *prefix, const gchar *suffix, gpointer data);
    28 
    29 gboolean gplate_library_add_function(const gchar *name, GType function, GError **error);
    30 gboolean gplate_library_remove_function(const gchar *name, GError **error);
    31 
    32 gboolean gplate_library_add_tag(GType tag, GError **error);
    33 gboolean gplate_library_remove_tag(GType tag, GError **error);
    34 
    35 gboolean gplate_library_bind_function(const gchar *name, GType tag, GError **error);
    36 gboolean gplate_library_unbind_function(const gchar *name, GError **error);
    37 
    38 gboolean gplate_library_add_bound_function(const gchar *name, GType function, GType tag, GError **error);
    39 
    40 gboolean gplate_library_lookup_function(const gchar *name, GType *function, GType *tag, GError **error);
    41 GType gplate_library_lookup_function_for_tag(const gchar *name, GType tag, GError **error);
    42 
    43 gboolean gplate_library_lookup_tag(GType tag, gchar **prefix, gchar **suffix, GError **error);
    44 GType gplate_library_get_default_tag(void);
    45 
    46 gboolean gplate_library_set_default_function_for_tag(const gchar *name, GType tag, GError **error);
    47 GType gplate_library_get_default_function_for_tag(GType tag, GError **error);
    48 
    49 void gplate_library_tags_foreach(GPlateLibraryTagsForeachFunc func, gpointer data);
    50 
    51 G_END_DECLS
    52 
    53 #endif /* GPLATE_LIBRARY_H */