summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2014-01-18 06:25:36 +0000
committerDavid Robillard <d@drobilla.net>2014-01-18 06:25:36 +0000
commitec8939dd7ef5267b43bd8ae3590e783495f0cfc9 (patch)
treece151c34851e8a275f35aedb67ea6b4a25676baf /src
parent59492c673f5de893e8b91ca50a945a697ddfa404 (diff)
downloadingen-ec8939dd7ef5267b43bd8ae3590e783495f0cfc9.tar.gz
ingen-ec8939dd7ef5267b43bd8ae3590e783495f0cfc9.tar.bz2
ingen-ec8939dd7ef5267b43bd8ae3590e783495f0cfc9.zip
Consolidate URIs.
Add missing definition to ontology. git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@5317 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src')
-rw-r--r--src/Configuration.cpp9
-rw-r--r--src/Resource.cpp7
-rw-r--r--src/URIs.cpp57
-rw-r--r--src/World.cpp5
-rw-r--r--src/client/ClientStore.cpp11
-rw-r--r--src/gui/App.cpp2
-rw-r--r--src/gui/GraphBox.cpp6
-rw-r--r--src/gui/GraphCanvas.cpp5
-rw-r--r--src/gui/GraphPortModule.cpp4
-rw-r--r--src/gui/NodeModule.cpp4
-rw-r--r--src/gui/ObjectMenu.cpp8
-rw-r--r--src/gui/PortMenu.cpp2
-rw-r--r--src/gui/SubgraphModule.cpp4
-rw-r--r--src/gui/ingen_gui_lv2.cpp3
-rw-r--r--src/serialisation/Parser.cpp21
-rw-r--r--src/serialisation/Serialiser.cpp3
16 files changed, 73 insertions, 78 deletions
diff --git a/src/Configuration.cpp b/src/Configuration.cpp
index ad4ab09a..67899d9a 100644
--- a/src/Configuration.cpp
+++ b/src/Configuration.cpp
@@ -25,11 +25,10 @@
#include "ingen/Configuration.hpp"
#include "ingen/Log.hpp"
+#include "ingen/ingen.h"
#include "sord/sordmm.hpp"
#include "sratom/sratom.h"
-#define NS_INGEN "http://drobilla.net/ns/ingen#"
-
namespace Ingen {
Configuration::Configuration(Forge& forge)
@@ -209,8 +208,8 @@ Configuration::load(const std::string& path)
for (Sord::Iter i = model.find(nodemm, nil, nil); !i.end(); ++i) {
const Sord::Node& pred = i.get_predicate();
const Sord::Node& obj = i.get_object();
- if (pred.to_string().substr(0, sizeof(NS_INGEN) - 1) == NS_INGEN) {
- const std::string key = pred.to_string().substr(sizeof(NS_INGEN) - 1);
+ if (pred.to_string().substr(0, sizeof(INGEN_NS) - 1) == INGEN_NS) {
+ const std::string key = pred.to_string().substr(sizeof(INGEN_NS) - 1);
const Keys::iterator k = _keys.find(key);
if (k != _keys.end() && obj.type() == Sord::Node::LITERAL) {
set_value_from_string(_options.find(k->second)->second,
@@ -259,7 +258,7 @@ Configuration::save(URIMap& uri_map,
// Create environment with ingen prefix
SerdEnv* env = serd_env_new(&base);
serd_env_set_prefix_from_strings(
- env, (const uint8_t*)"ingen", (const uint8_t*)NS_INGEN);
+ env, (const uint8_t*)"ingen", (const uint8_t*)INGEN_NS);
// Create Turtle writer
SerdWriter* writer = serd_writer_new(
diff --git a/src/Resource.cpp b/src/Resource.cpp
index aa6adf07..79f998a0 100644
--- a/src/Resource.cpp
+++ b/src/Resource.cpp
@@ -53,8 +53,9 @@ Resource::set_property(const Raul::URI& uri,
Properties::iterator next = i;
++next;
if (i->second.context() == ctx) {
+ const Atom value(i->second);
_properties.erase(i);
- on_property_removed(uri, i->second);
+ on_property_removed(uri, value);
}
i = next;
}
@@ -68,7 +69,7 @@ Resource::set_property(const Raul::URI& uri,
void
Resource::remove_property(const Raul::URI& uri, const Atom& value)
{
- if (value == _uris.wildcard) {
+ if (value == _uris.patch_wildcard) {
_properties.erase(uri);
} else {
for (Properties::iterator i = _properties.find(uri);
@@ -163,7 +164,7 @@ Resource::set_properties(const Properties& props)
// Erase existing properties with matching keys
for (const auto& p : props) {
_properties.erase(p.first);
- on_property_removed(p.first, _uris.wildcard);
+ on_property_removed(p.first, _uris.patch_wildcard);
}
// Set new properties
diff --git a/src/URIs.cpp b/src/URIs.cpp
index 02e03a70..b810259b 100644
--- a/src/URIs.cpp
+++ b/src/URIs.cpp
@@ -16,11 +16,13 @@
#include "ingen/URIMap.hpp"
#include "ingen/URIs.hpp"
+#include "ingen/ingen.h"
#include "lv2/lv2plug.in/ns/ext/atom/atom.h"
#include "lv2/lv2plug.in/ns/ext/buf-size/buf-size.h"
#include "lv2/lv2plug.in/ns/ext/log/log.h"
#include "lv2/lv2plug.in/ns/ext/midi/midi.h"
#include "lv2/lv2plug.in/ns/ext/morph/morph.h"
+#include "lv2/lv2plug.in/ns/ext/parameters/parameters.h"
#include "lv2/lv2plug.in/ns/ext/patch/patch.h"
#include "lv2/lv2plug.in/ns/ext/port-props/port-props.h"
#include "lv2/lv2plug.in/ns/ext/resize-port/resize-port.h"
@@ -36,7 +38,6 @@ URIs::Quark::Quark(Forge& forge, URIMap* map, const char* c_str)
{
}
-#define NS_INGEN "http://drobilla.net/ns/ingen#"
#define NS_RDF "http://www.w3.org/1999/02/22-rdf-syntax-ns#"
#define NS_RDFS "http://www.w3.org/2000/01/rdf-schema#"
@@ -62,32 +63,27 @@ URIs::URIs(Forge& f, URIMap* map)
, bufsz_minBlockLength (forge, map, LV2_BUF_SIZE__minBlockLength)
, bufsz_sequenceSize (forge, map, LV2_BUF_SIZE__sequenceSize)
, doap_name (forge, map, "http://usefulinc.com/ns/doap#name")
- , ingen_Arc (forge, map, NS_INGEN "Arc")
- , ingen_Block (forge, map, NS_INGEN "Block")
- , ingen_Graph (forge, map, NS_INGEN "Graph")
- , ingen_GraphPrototype (forge, map, NS_INGEN "GraphPrototype")
- , ingen_Internal (forge, map, NS_INGEN "Internal")
- , ingen_activity (forge, map, NS_INGEN "activity")
- , ingen_arc (forge, map, NS_INGEN "arc")
- , ingen_block (forge, map, NS_INGEN "block")
- , ingen_broadcast (forge, map, NS_INGEN "broadcast")
- , ingen_canvasX (forge, map, NS_INGEN "canvasX")
- , ingen_canvasY (forge, map, NS_INGEN "canvasY")
- , ingen_controlBinding (forge, map, NS_INGEN "controlBinding")
- , ingen_document (forge, map, NS_INGEN "document")
- , ingen_enabled (forge, map, NS_INGEN "enabled")
- , ingen_engine (forge, map, NS_INGEN "engine")
- , ingen_head (forge, map, NS_INGEN "head")
- , ingen_incidentTo (forge, map, NS_INGEN "incidentTo")
- , ingen_nil (forge, map, NS_INGEN "nil")
- , ingen_polyphonic (forge, map, NS_INGEN "polyphonic")
- , ingen_polyphony (forge, map, NS_INGEN "polyphony")
- , ingen_prototype (forge, map, NS_INGEN "prototype")
- , ingen_sampleRate (forge, map, NS_INGEN "sampleRate")
- , ingen_status (forge, map, NS_INGEN "status")
- , ingen_tail (forge, map, NS_INGEN "tail")
- , ingen_uiEmbedded (forge, map, NS_INGEN "uiEmbedded")
- , ingen_value (forge, map, NS_INGEN "value")
+ , ingen_Arc (forge, map, INGEN__Arc)
+ , ingen_Block (forge, map, INGEN__Block)
+ , ingen_Graph (forge, map, INGEN__Graph)
+ , ingen_GraphPrototype (forge, map, INGEN__GraphPrototype)
+ , ingen_Internal (forge, map, INGEN__Internal)
+ , ingen_activity (forge, map, INGEN__activity)
+ , ingen_arc (forge, map, INGEN__arc)
+ , ingen_block (forge, map, INGEN__block)
+ , ingen_broadcast (forge, map, INGEN__broadcast)
+ , ingen_canvasX (forge, map, INGEN__canvasX)
+ , ingen_canvasY (forge, map, INGEN__canvasY)
+ , ingen_enabled (forge, map, INGEN__enabled)
+ , ingen_file (forge, map, INGEN__file)
+ , ingen_head (forge, map, INGEN__head)
+ , ingen_incidentTo (forge, map, INGEN__incidentTo)
+ , ingen_polyphonic (forge, map, INGEN__polyphonic)
+ , ingen_polyphony (forge, map, INGEN__polyphony)
+ , ingen_prototype (forge, map, INGEN__prototype)
+ , ingen_tail (forge, map, INGEN__tail)
+ , ingen_uiEmbedded (forge, map, INGEN__uiEmbedded)
+ , ingen_value (forge, map, INGEN__value)
, log_Error (forge, map, LV2_LOG__Error)
, log_Note (forge, map, LV2_LOG__Note)
, log_Warning (forge, map, LV2_LOG__Warning)
@@ -119,9 +115,11 @@ URIs::URIs(Forge& f, URIMap* map)
, midi_Controller (forge, map, LV2_MIDI__Controller)
, midi_MidiEvent (forge, map, LV2_MIDI__MidiEvent)
, midi_NoteOn (forge, map, LV2_MIDI__NoteOn)
+ , midi_binding (forge, map, LV2_MIDI__binding)
, midi_controllerNumber (forge, map, LV2_MIDI__controllerNumber)
, midi_noteNumber (forge, map, LV2_MIDI__noteNumber)
, morph_currentType (forge, map, LV2_MORPH__currentType)
+ , param_sampleRate (forge, map, LV2_PARAMETERS__sampleRate)
, patch_Delete (forge, map, LV2_PATCH__Delete)
, patch_Get (forge, map, LV2_PATCH__Get)
, patch_Move (forge, map, LV2_PATCH__Move)
@@ -137,6 +135,7 @@ URIs::URIs(Forge& f, URIMap* map)
, patch_request (forge, map, LV2_PATCH__request)
, patch_subject (forge, map, LV2_PATCH__subject)
, patch_value (forge, map, LV2_PATCH__value)
+ , patch_wildcard (forge, map, LV2_PATCH__wildcard)
, pprops_logarithmic (forge, map, LV2_PORT_PROPS__logarithmic)
, rdf_type (forge, map, NS_RDF "type")
, rdfs_seeAlso (forge, map, NS_RDFS "seeAlso")
@@ -149,8 +148,6 @@ URIs::URIs(Forge& f, URIMap* map)
, time_beatsPerMinute (forge, map, LV2_TIME__beatsPerMinute)
, time_frame (forge, map, LV2_TIME__frame)
, time_speed (forge, map, LV2_TIME__speed)
- , wildcard (forge, map, NS_INGEN "wildcard")
-{
-}
+{}
} // namespace Ingen
diff --git a/src/World.cpp b/src/World.cpp
index bb837783..2236c28e 100644
--- a/src/World.cpp
+++ b/src/World.cpp
@@ -29,6 +29,7 @@
#include "ingen/URIMap.hpp"
#include "ingen/URIs.hpp"
#include "ingen/World.hpp"
+#include "ingen/ingen.h"
#include "ingen/runtime_paths.hpp"
#include "lilv/lilv.h"
#include "sord/sordmm.hpp"
@@ -130,7 +131,7 @@ public:
rdf_world->add_prefix("atom", "http://lv2plug.in/ns/ext/atom#");
rdf_world->add_prefix("patch", "http://lv2plug.in/ns/ext/patch#");
rdf_world->add_prefix("doap", "http://usefulinc.com/ns/doap#");
- rdf_world->add_prefix("ingen", "http://drobilla.net/ns/ingen#");
+ rdf_world->add_prefix("ingen", INGEN_NS);
rdf_world->add_prefix("lv2", "http://lv2plug.in/ns/lv2core#");
rdf_world->add_prefix("midi", "http://lv2plug.in/ns/ext/midi#");
rdf_world->add_prefix("owl", "http://www.w3.org/2002/07/owl#");
@@ -142,7 +143,7 @@ public:
LilvNode* rdf_type = lilv_new_uri(
lilv_world, "http://www.w3.org/1999/02/22-rdf-syntax-ns#type");
LilvNode* ingen_Plugin = lilv_new_uri(
- lilv_world, "http://drobilla.net/ns/ingen#Plugin");
+ lilv_world, INGEN__Plugin);
LilvNodes* internals = lilv_world_find_nodes(
lilv_world, NULL, rdf_type, ingen_Plugin);
LILV_FOREACH(nodes, i, internals) {
diff --git a/src/client/ClientStore.cpp b/src/client/ClientStore.cpp
index 56c74cd8..02f5f4f0 100644
--- a/src/client/ClientStore.cpp
+++ b/src/client/ClientStore.cpp
@@ -270,10 +270,11 @@ ClientStore::put(const Raul::URI& uri,
if (p->second.is_valid() && p->second.type() == _uris.forge.URI) {
if (!(plug = _plugin(Raul::URI(p->second.ptr<char>())))) {
plug = SPtr<PluginModel>(
- new PluginModel(uris(),
- Raul::URI(p->second.ptr<char>()),
- _uris.ingen_nil,
- Resource::Properties()));
+ new PluginModel(
+ uris(),
+ Raul::URI(p->second.ptr<char>()),
+ Raul::URI("http://www.w3.org/2002/07/owl#Nothing"),
+ Resource::Properties()));
add_plugin(plug);
}
@@ -350,7 +351,7 @@ ClientStore::set_property(const Raul::URI& subject_uri,
const Raul::URI& predicate,
const Atom& value)
{
- if (subject_uri == _uris.ingen_engine) {
+ if (subject_uri == Raul::URI("ingen:/engine")) {
_log.info(fmt("Engine property <%1%> = %2%\n")
% predicate.c_str() % _uris.forge.str(value));
return;
diff --git a/src/gui/App.cpp b/src/gui/App.cpp
index 357f4a4a..1b71cf06 100644
--- a/src/gui/App.cpp
+++ b/src/gui/App.cpp
@@ -239,7 +239,7 @@ App::property_change(const Raul::URI& subject,
const Raul::URI& key,
const Atom& value)
{
- if (subject == uris().ingen_engine && key == uris().ingen_sampleRate) {
+ if (subject == Raul::URI("ingen:/engine") && key == uris().param_sampleRate) {
if (value.type() == forge().Int) {
log().info(fmt("Sample rate: %1%\n") % uris().forge.str(value));
_sample_rate = value.get<int32_t>();
diff --git a/src/gui/GraphBox.cpp b/src/gui/GraphBox.cpp
index 1e1669cb..081cf413 100644
--- a/src/gui/GraphBox.cpp
+++ b/src/gui/GraphBox.cpp
@@ -424,7 +424,7 @@ GraphBox::event_import()
void
GraphBox::event_save()
{
- const Atom& document = _graph->get_property(_app->uris().ingen_document);
+ const Atom& document = _graph->get_property(_app->uris().ingen_file);
if (!document.is_valid() || document.type() != _app->uris().forge.URI) {
event_save_as();
} else {
@@ -470,7 +470,7 @@ GraphBox::event_save_as()
dialog.set_filter(filt);
// Set current folder to most sensible default
- const Atom& document = _graph->get_property(uris.ingen_document);
+ const Atom& document = _graph->get_property(uris.ingen_file);
const Atom& dir = _app->world()->conf().option("graph-directory");
if (document.type() == uris.forge.URI)
dialog.set_uri(document.ptr<char>());
@@ -540,7 +540,7 @@ GraphBox::event_save_as()
const Glib::ustring uri = Glib::filename_to_uri(filename);
_app->loader()->save_graph(_graph, uri);
const_cast<GraphModel*>(_graph.get())->set_property(
- uris.ingen_document,
+ uris.ingen_file,
_app->forge().alloc_uri(uri.c_str()),
Resource::Graph::EXTERNAL);
_status_bar->push(
diff --git a/src/gui/GraphCanvas.cpp b/src/gui/GraphCanvas.cpp
index bb7c968c..f2a23f9f 100644
--- a/src/gui/GraphCanvas.cpp
+++ b/src/gui/GraphCanvas.cpp
@@ -33,6 +33,7 @@
#include "ingen/client/ClientStore.hpp"
#include "ingen/client/GraphModel.hpp"
#include "ingen/client/PluginModel.hpp"
+#include "ingen/ingen.h"
#include "ingen/serialisation/Serialiser.hpp"
#include "lv2/lv2plug.in/ns/ext/atom/atom.h"
@@ -563,7 +564,7 @@ serialise_arc(GanvEdge* arc, void* data)
void
GraphCanvas::copy_selection()
{
- static const char* base_uri = "http://drobilla.net/ns/ingen/selection/";
+ static const char* base_uri = INGEN_NS "selection/";
Serialisation::Serialiser serialiser(*_app.world());
serialiser.start_to_string(_graph->path(), base_uri);
@@ -625,7 +626,7 @@ GraphCanvas::paste()
}
ClashAvoider avoider(*_app.store().get(), clipboard, &clipboard);
- static const char* base_uri = "http://drobilla.net/ns/ingen/selection/";
+ static const char* base_uri = INGEN_NS "selection/";
parser->parse_string(_app.world(), &avoider, str, base_uri,
parent, symbol);
diff --git a/src/gui/GraphPortModule.cpp b/src/gui/GraphPortModule.cpp
index 7cca3869..3c9004e3 100644
--- a/src/gui/GraphPortModule.cpp
+++ b/src/gui/GraphPortModule.cpp
@@ -108,9 +108,9 @@ GraphPortModule::store_location(double ax, double ay)
{
Resource::Properties remove;
remove.insert(make_pair(uris.ingen_canvasX,
- Resource::Property(uris.wildcard)));
+ Resource::Property(uris.patch_wildcard)));
remove.insert(make_pair(uris.ingen_canvasY,
- Resource::Property(uris.wildcard)));
+ Resource::Property(uris.patch_wildcard)));
Resource::Properties add;
add.insert(make_pair(uris.ingen_canvasX,
Resource::Property(x, Resource::Graph::INTERNAL)));
diff --git a/src/gui/NodeModule.cpp b/src/gui/NodeModule.cpp
index 7185d9bd..cd801a05 100644
--- a/src/gui/NodeModule.cpp
+++ b/src/gui/NodeModule.cpp
@@ -403,9 +403,9 @@ NodeModule::store_location(double ax, double ay)
{
Resource::Properties remove;
remove.insert(make_pair(uris.ingen_canvasX,
- Resource::Property(uris.wildcard)));
+ Resource::Property(uris.patch_wildcard)));
remove.insert(make_pair(uris.ingen_canvasY,
- Resource::Property(uris.wildcard)));
+ Resource::Property(uris.patch_wildcard)));
Resource::Properties add;
add.insert(make_pair(uris.ingen_canvasX, x));
add.insert(make_pair(uris.ingen_canvasY, y));
diff --git a/src/gui/ObjectMenu.cpp b/src/gui/ObjectMenu.cpp
index 3bd0be38..f19913ac 100644
--- a/src/gui/ObjectMenu.cpp
+++ b/src/gui/ObjectMenu.cpp
@@ -92,8 +92,8 @@ void
ObjectMenu::on_menu_learn()
{
_app->interface()->set_property(_object->uri(),
- _app->uris().ingen_controlBinding,
- _app->uris().wildcard);
+ _app->uris().midi_binding,
+ _app->uris().patch_wildcard);
}
void
@@ -101,8 +101,8 @@ ObjectMenu::on_menu_unlearn()
{
Resource::Properties remove;
remove.insert(std::make_pair(
- _app->uris().ingen_controlBinding,
- Resource::Property(_app->uris().wildcard)));
+ _app->uris().midi_binding,
+ Resource::Property(_app->uris().patch_wildcard)));
_app->interface()->delta(_object->uri(), remove, Resource::Properties());
}
diff --git a/src/gui/PortMenu.cpp b/src/gui/PortMenu.cpp
index babc37a1..9c428dd8 100644
--- a/src/gui/PortMenu.cpp
+++ b/src/gui/PortMenu.cpp
@@ -150,7 +150,7 @@ PortMenu::on_menu_expose()
const Raul::Path path = Raul::Path(block->path() + Raul::Symbol("_" + port->symbol()));
Ingen::Resource r(*_object.get());
- r.remove_property(uris.lv2_index, uris.wildcard);
+ r.remove_property(uris.lv2_index, uris.patch_wildcard);
r.set_property(uris.lv2_symbol, _app->forge().alloc(path.symbol()));
r.set_property(uris.lv2_name, _app->forge().alloc(label.c_str()));
diff --git a/src/gui/SubgraphModule.cpp b/src/gui/SubgraphModule.cpp
index 63c70278..295d3d16 100644
--- a/src/gui/SubgraphModule.cpp
+++ b/src/gui/SubgraphModule.cpp
@@ -72,9 +72,9 @@ SubgraphModule::store_location(double ax, double ay)
{
Resource::Properties remove;
remove.insert(make_pair(uris.ingen_canvasX,
- Resource::Property(uris.wildcard)));
+ Resource::Property(uris.patch_wildcard)));
remove.insert(make_pair(uris.ingen_canvasY,
- Resource::Property(uris.wildcard)));
+ Resource::Property(uris.patch_wildcard)));
Resource::Properties add;
add.insert(make_pair(uris.ingen_canvasX,
Resource::Property(x, Resource::Graph::EXTERNAL)));
diff --git a/src/gui/ingen_gui_lv2.cpp b/src/gui/ingen_gui_lv2.cpp
index 489fbf39..f2cd54e7 100644
--- a/src/gui/ingen_gui_lv2.cpp
+++ b/src/gui/ingen_gui_lv2.cpp
@@ -21,6 +21,7 @@
#include "ingen/client/ClientStore.hpp"
#include "ingen/client/GraphModel.hpp"
#include "ingen/client/SigClientInterface.hpp"
+#include "ingen/ingen.h"
#include "ingen/runtime_paths.hpp"
#include "ingen/types.hpp"
#include "lv2/lv2plug.in/ns/extensions/ui/ui.h"
@@ -28,7 +29,7 @@
#include "App.hpp"
#include "GraphBox.hpp"
-#define INGEN_LV2_UI_URI "http://drobilla.net/ns/ingen#GraphUIGtk2"
+#define INGEN_LV2_UI_URI INGEN_NS "GraphUIGtk2"
namespace Ingen {
diff --git a/src/serialisation/Parser.cpp b/src/serialisation/Parser.cpp
index c0f8cf3a..3d8ba96d 100644
--- a/src/serialisation/Parser.cpp
+++ b/src/serialisation/Parser.cpp
@@ -83,12 +83,12 @@ get_basename(const std::string& uri)
}
static bool
-skip_property(const Sord::Node& predicate)
+skip_property(Ingen::URIs& uris, const Sord::Node& predicate)
{
- return (predicate.to_string() == "http://drobilla.net/ns/ingen#node"
- || predicate.to_string() == "http://drobilla.net/ns/ingen#edge"
- || predicate.to_string() == "http://drobilla.net/ns/ingen#arc"
- || predicate.to_string() == LV2_CORE__port);
+ return (predicate.to_string() == INGEN__file ||
+ predicate.to_string() == uris.ingen_arc ||
+ predicate.to_string() == uris.ingen_block ||
+ predicate.to_string() == uris.lv2_port);
}
static Resource::Properties
@@ -108,7 +108,7 @@ get_properties(Ingen::World* world,
const Sord::Node nil;
Resource::Properties props;
for (Sord::Iter i = model.find(subject, nil, nil); !i.end(); ++i) {
- if (!skip_property(i.get_predicate())) {
+ if (!skip_property(world->uris(), i.get_predicate())) {
out.len = 0;
sratom_read(sratom, &forge, world->rdf_world()->c_obj(),
model.c_obj(), i.get_object().c_obj());
@@ -453,13 +453,6 @@ parse_arcs(Ingen::World* world,
parse_arc(world, target, model, i.get_object(), graph);
}
- // Backwards compatibility, support ingen:edge predicate
- const Sord::URI ingen_edge(*world->rdf_world(),
- "http://drobilla.net/ns/ingen#edge");
- for (Sord::Iter i = model.find(subject, ingen_edge, nil); !i.end(); ++i) {
- parse_arc(world, target, model, i.get_object(), graph);
- }
-
return true;
}
@@ -605,7 +598,7 @@ Parser::parse_file(Ingen::World* world,
if (parsed_path) {
target->set_property(Node::path_to_uri(*parsed_path),
- Raul::URI("http://drobilla.net/ns/ingen#document"),
+ Raul::URI(INGEN__file),
world->forge().alloc_uri(uri));
} else {
world->log().warn("Document URI lost\n");
diff --git a/src/serialisation/Serialiser.cpp b/src/serialisation/Serialiser.cpp
index bbc23081..a8140c23 100644
--- a/src/serialisation/Serialiser.cpp
+++ b/src/serialisation/Serialiser.cpp
@@ -525,7 +525,8 @@ Serialiser::Impl::serialise_arc(const Sord::Node& parent,
static bool
skip_property(Ingen::URIs& uris, const Sord::Node& predicate)
{
- return (predicate.to_string() == "http://drobilla.net/ns/ingen#document" ||
+ return (predicate.to_string() == INGEN__file ||
+ predicate.to_string() == uris.ingen_arc ||
predicate.to_string() == uris.ingen_block ||
predicate.to_string() == uris.lv2_port);
}