diff options
author | David Robillard <d@drobilla.net> | 2010-03-12 01:27:02 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2010-03-12 01:27:02 +0000 |
commit | 0a18c35deb2dbc6efd4acd4a1ddc5c87b3887fb1 (patch) | |
tree | 1dc06da55503eda364794e47d0d6cd3a2af792d9 /src | |
parent | 4204ee4da991e652f3142b5d90c37849052c9484 (diff) | |
download | lilv-0a18c35deb2dbc6efd4acd4a1ddc5c87b3887fb1.tar.gz lilv-0a18c35deb2dbc6efd4acd4a1ddc5c87b3887fb1.tar.bz2 lilv-0a18c35deb2dbc6efd4acd4a1ddc5c87b3887fb1.zip |
Chop dead code.
git-svn-id: http://svn.drobilla.net/lad/trunk/slv2@2545 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src')
-rw-r--r-- | src/plugin.c | 20 | ||||
-rw-r--r-- | src/plugins.c | 15 | ||||
-rw-r--r-- | src/port.c | 13 | ||||
-rw-r--r-- | src/slv2_internal.h | 3 | ||||
-rw-r--r-- | src/world.c | 60 |
5 files changed, 0 insertions, 111 deletions
diff --git a/src/plugin.c b/src/plugin.c index 0be7c52..cc62ea8 100644 --- a/src/plugin.c +++ b/src/plugin.c @@ -106,24 +106,6 @@ slv2_plugin_free(SLV2Plugin p) } -/** comparator for sorting */ -#if 0 -static int -slv2_port_compare_by_index(const void* a, const void* b) -{ - SLV2Port port_a = *(SLV2Port*)a; - SLV2Port port_b = *(SLV2Port*)b; - - if (port_a->index < port_b->index) - return -1; - else if (port_a->index == port_b->index) - return 0; - else //if (port_a->index > port_b->index) - return 1; -} -#endif - - /* private */ void slv2_plugin_load_if_necessary(SLV2Plugin p) @@ -206,8 +188,6 @@ slv2_plugin_load_ports_if_necessary(SLV2Plugin p) void slv2_plugin_load(SLV2Plugin p) { - //printf("Loading cache for %s\n", slv2_value_as_string(p->plugin_uri)); - if (!p->storage) { assert(!p->rdf); p->storage = slv2_world_new_storage(p->world); diff --git a/src/plugins.c b/src/plugins.c index 4aee191..73fb20d 100644 --- a/src/plugins.c +++ b/src/plugins.c @@ -33,7 +33,6 @@ SLV2Plugins slv2_plugins_new() { - //return raptor_new_sequence((void (*)(void*))&slv2_plugin_free, NULL); return raptor_new_sequence(NULL, NULL); } @@ -45,20 +44,6 @@ slv2_plugins_free(SLV2World world, SLV2Plugins list) raptor_free_sequence(list); } -#if 0 -void -slv2_plugins_filter(SLV2Plugins dest, SLV2Plugins source, bool (*include)(SLV2Plugin)) -{ - assert(dest); - - for (int i=0; i < raptor_sequence_size(source); ++i) { - SLV2Plugin p = raptor_sequence_get_at(source, i); - if (include(p)) - raptor_sequence_push(dest, slv2_plugin_duplicate(p)); - } -} -#endif - unsigned slv2_plugins_size(SLV2Plugins list) @@ -52,19 +52,6 @@ slv2_port_free(SLV2Port port) } -/* private */ -#if 0 -SLV2Port -slv2_port_duplicate(SLV2Port port) -{ - SLV2Port ret = malloc(sizeof(struct _SLV2Port)); - ret->index = port->index; - ret->symbol = slv2_value_duplicate(port->symbol); - return ret; -} -#endif - - bool slv2_port_is_a(SLV2Plugin plugin, SLV2Port port, diff --git a/src/slv2_internal.h b/src/slv2_internal.h index 4202b92..9e3bdb5 100644 --- a/src/slv2_internal.h +++ b/src/slv2_internal.h @@ -50,7 +50,6 @@ struct _SLV2Port { SLV2Port slv2_port_new(SLV2World world, uint32_t index, const char* symbol); -//SLV2Port slv2_port_duplicate(SLV2Port port); void slv2_port_free(SLV2Port port); @@ -66,9 +65,7 @@ struct _SLV2Plugin { SLV2Value plugin_uri; SLV2Value bundle_uri; ///< Bundle directory plugin was loaded from SLV2Value binary_uri; ///< lv2:binary -//#ifdef SLV2_DYN_MANIFEST SLV2Value dynman_uri; ///< dynamic manifest binary -//#endif SLV2PluginClass plugin_class; raptor_sequence* data_uris; ///< rdfs::seeAlso SLV2Port* ports; diff --git a/src/world.c b/src/world.c index e057fd5..cec9feb 100644 --- a/src/world.c +++ b/src/world.c @@ -730,27 +730,6 @@ slv2_world_load_all(SLV2World world) } -#if 0 -void -slv2_world_serialize(const char* filename) -{ - librdf_uri* lv2_uri = librdf_new_uri(slv2_rdf_world, - (unsigned char*)"http://lv2plug.in/ns/lv2core#"); - - librdf_uri* rdfs_uri = librdf_new_uri(slv2_rdf_world, - (unsigned char*)"http://www.w3.org/2000/01/rdf-schema#"); - - // Write out test file - librdf_serializer* serializer = librdf_new_serializer(slv2_rdf_world, - "turtle", NULL, NULL); - librdf_serializer_set_namespace(serializer, lv2_uri, ""); - librdf_serializer_set_namespace(serializer, rdfs_uri, "rdfs"); - librdf_serializer_serialize_world_to_file(serializer, filename, NULL, slv2_model); - librdf_free_serializer(serializer); -} -#endif - - SLV2PluginClass slv2_world_get_plugin_class(SLV2World world) { @@ -786,42 +765,3 @@ slv2_world_get_plugins_by_filter(SLV2World world, bool (*include)(SLV2Plugin)) return result; } - -#if 0 -SLV2Plugins -slv2_world_get_plugins_by_query(SLV2World world, const char* query) -{ - SLV2Plugins list = slv2_plugins_new(); - - librdf_query* rq = librdf_new_query(world->world, "sparql", - NULL, (const unsigned char*)query, NULL); - - librdf_query_results* results = librdf_query_execute(rq, world->model); - - while (!librdf_query_results_finished(results)) { - librdf_node* plugin_node = librdf_query_results_get_binding_value(results, 0); - librdf_uri* plugin_uri = librdf_node_get_uri(plugin_node); - - SLV2Plugin plugin = slv2_plugins_get_by_uri(list, - (const char*)librdf_uri_as_string(plugin_uri)); - - /* Create a new SLV2Plugin */ - if (!plugin) { - SLV2Plugin new_plugin = slv2_plugin_new(world, plugin_uri); - raptor_sequence_push(list, new_plugin); - } - - librdf_free_node(plugin_node); - - librdf_query_results_next(results); - } - - if (results) - librdf_free_query_results(results); - - librdf_free_query(rq); - - return list; -} -#endif - |