summaryrefslogtreecommitdiffstats
path: root/src/serialisation/Parser.cpp
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2012-03-12 07:37:52 +0000
committerDavid Robillard <d@drobilla.net>2012-03-12 07:37:52 +0000
commit8a69f9bdbf45a049d9dbb93a198dd92bda733927 (patch)
tree869e9b25cd1eb3f473b8674644c3a60f326d6696 /src/serialisation/Parser.cpp
parentd2904911d85a2acf58543d831be27fc40b2e6841 (diff)
downloadingen-8a69f9bdbf45a049d9dbb93a198dd92bda733927.tar.gz
ingen-8a69f9bdbf45a049d9dbb93a198dd92bda733927.tar.bz2
ingen-8a69f9bdbf45a049d9dbb93a198dd92bda733927.zip
Move bundle patch finding stuff to ingen_lv2.cpp and simplify it to not require
the World. Remove all the heavyweight initialisation stuff from plugin library instantiation, just parse the manifest with Sord directly and don't initialise the World until the plugin is actually loaded. git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4056 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/serialisation/Parser.cpp')
-rw-r--r--src/serialisation/Parser.cpp31
1 files changed, 0 insertions, 31 deletions
diff --git a/src/serialisation/Parser.cpp b/src/serialisation/Parser.cpp
index 1477e167..b84bedae 100644
--- a/src/serialisation/Parser.cpp
+++ b/src/serialisation/Parser.cpp
@@ -538,37 +538,6 @@ Parser::Parser(Ingen::Shared::World& world)
{
}
-Parser::PatchRecords
-Parser::find_patches(Ingen::Shared::World* world,
- SerdEnv* env,
- const Glib::ustring& manifest_uri)
-{
- const Sord::URI ingen_Patch (*world->rdf_world(), NS_INGEN "Patch");
- const Sord::URI rdf_type (*world->rdf_world(), NS_RDF "type");
- const Sord::URI rdfs_seeAlso(*world->rdf_world(), NS_RDFS "seeAlso");
-
- Sord::Model model(*world->rdf_world(), manifest_uri);
- model.load_file(env, SERD_TURTLE, manifest_uri);
-
- std::list<PatchRecord> records;
- for (Sord::Iter i = model.find(nil, rdf_type, ingen_Patch); !i.end(); ++i) {
- const Sord::Node patch = i.get_subject();
- Sord::Iter f = model.find(patch, rdfs_seeAlso, nil);
- std::string patch_uri_str = patch.to_c_string();
- if (patch_uri_str[0] == '/') {
- // FIXME: Kludge path to be a proper URI (not sure why this is happening)
- patch_uri_str = string("file://") + patch_uri_str;
- }
- if (!f.end()) {
- records.push_back(PatchRecord(patch_uri_str,
- f.get_object().to_c_string()));
- } else {
- LOG(error) << "Patch has no rdfs:seeAlso" << endl;
- }
- }
- return records;
-}
-
/** Parse a patch from RDF into a CommonInterface (engine or client).
* @return whether or not load was successful.
*/