21 struct xmms_xform_plugin_St {
32 while (plugin->in_types) {
35 plugin->in_types = g_list_delete_link (plugin->in_types,
56 g_return_if_fail (plugin);
70 g_return_val_if_fail (plugin, FALSE);
83 gchar *config_key, config_value[32];
86 va_start (ap, plugin);
90 config_key = g_strconcat (
"priority.",
94 g_snprintf (config_value,
sizeof (config_value),
"%d", priority);
96 config_value, NULL, NULL);
99 plugin->in_types = g_list_prepend (plugin->in_types, t);
108 g_return_val_if_fail (st, FALSE);
109 g_return_val_if_fail (plugin, FALSE);
110 g_return_val_if_fail (priority, FALSE);
112 for (t = plugin->in_types; t; t = g_list_next (t)) {
114 const gchar *type_name;
123 config_key = g_strconcat (
"priority.", type_name, NULL);
128 if (config_priority) {
143 const gchar *default_value,
157 return !!plugin->methods.init;
163 return !!plugin->methods.read;
169 return !!plugin->methods.seek;
175 return !!plugin->methods.browse;
181 return !!plugin->methods.destroy;
187 return plugin->methods.init (xform);
194 return plugin->methods.read (xform, buf, length, error);
202 return plugin->methods.seek (xform, offset, whence, err);
210 return plugin->methods.browse (xform, url, error);
216 plugin->methods.destroy (xform);
gint xmms_stream_type_get_int(const xmms_stream_type_t *st, xmms_stream_type_key_t key)
#define xmms_object_unref(obj)
xmms_config_property_t * xmms_plugin_config_property_register(xmms_plugin_t *plugin, const gchar *name, const gchar *default_value, xmms_object_handler_t cb, gpointer userdata)
struct xmms_stream_type_St xmms_stream_type_t
const gchar * xmms_plugin_shortname_get(const xmms_plugin_t *plugin)
gint xmms_config_property_get_int(const xmms_config_property_t *prop)
Return the value of a config property as an int.
gboolean xmms_stream_type_match(const xmms_stream_type_t *in_type, const xmms_stream_type_t *out_type)
#define XMMS_STREAM_TYPE_PRIORITY_DEFAULT
void xmms_plugin_destroy(xmms_plugin_t *plugin)
#define XMMS_DBG(fmt,...)
#define xmms_object_new(objtype, destroyfunc)
G_BEGIN_DECLS struct xmms_error_St xmms_error_t
xmms_config_property_t * xmms_plugin_config_lookup(xmms_plugin_t *plugin, const gchar *key)
struct xmms_config_property_St xmms_config_property_t
const char * xmms_stream_type_get_str(const xmms_stream_type_t *st, xmms_stream_type_key_t key)
xmms_stream_type_t * xmms_stream_type_parse(va_list ap)
void(* xmms_object_handler_t)(xmms_object_t *object, xmmsv_t *data, gpointer userdata)