summaryrefslogtreecommitdiffstats
path: root/src/serialisation
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2013-02-02 16:58:42 +0000
committerDavid Robillard <d@drobilla.net>2013-02-02 16:58:42 +0000
commit3265e8f01cd4e878661973730349a5ed44329713 (patch)
tree9e62a609edeba00bba462efc242952af7476b41d /src/serialisation
parent05d020a36581fdc9c5038339e52208f7d9f3e60e (diff)
downloadingen-3265e8f01cd4e878661973730349a5ed44329713.tar.gz
ingen-3265e8f01cd4e878661973730349a5ed44329713.tar.bz2
ingen-3265e8f01cd4e878661973730349a5ed44329713.zip
More generic Atom class.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@5024 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/serialisation')
-rw-r--r--src/serialisation/Parser.cpp6
-rw-r--r--src/serialisation/Serialiser.cpp4
2 files changed, 5 insertions, 5 deletions
diff --git a/src/serialisation/Parser.cpp b/src/serialisation/Parser.cpp
index 1cea22d6..427b0f02 100644
--- a/src/serialisation/Parser.cpp
+++ b/src/serialisation/Parser.cpp
@@ -151,11 +151,11 @@ get_port(Ingen::World* world,
Resource::Properties::const_iterator i = props.find(uris.lv2_index);
if (i == props.end()
|| i->second.type() != world->forge().Int
- || i->second.get_int32() < 0) {
+ || i->second.get<int32_t>() < 0) {
world->log().warn(Raul::fmt("Port %1% has no valid index\n") % subject);
return boost::optional<PortRecord>();
}
- index = i->second.get_int32();
+ index = i->second.get<int32_t>();
// Get symbol
Resource::Properties::const_iterator s = props.find(uris.lv2_symbol);
@@ -163,7 +163,7 @@ get_port(Ingen::World* world,
world->log().warn(Raul::fmt("Port %1% has no symbol\n") % subject);
return boost::optional<PortRecord>();
}
- const Raul::Symbol port_sym(s->second.get_string());
+ const Raul::Symbol port_sym(s->second.ptr<char>());
const Raul::Path port_path = parent.child(port_sym);
return make_pair(port_path, props);
diff --git a/src/serialisation/Serialiser.cpp b/src/serialisation/Serialiser.cpp
index 41ae45dc..5ff672e0 100644
--- a/src/serialisation/Serialiser.cpp
+++ b/src/serialisation/Serialiser.cpp
@@ -327,7 +327,7 @@ Serialiser::Impl::serialise_graph(SPtr<const Node> graph,
Node::Properties::const_iterator s = graph->properties().find(uris.lv2_symbol);
if (s == graph->properties().end()
|| !s->second.type() == _world.forge().String
- || !Raul::Symbol::is_valid(s->second.get_string())) {
+ || !Raul::Symbol::is_valid(s->second.ptr<char>())) {
const std::string base = Glib::path_get_basename(
_model->base_uri().to_c_string());
symbol = Raul::Symbol::symbolify(base.substr(0, base.find('.')));
@@ -336,7 +336,7 @@ Serialiser::Impl::serialise_graph(SPtr<const Node> graph,
Sord::URI(world, uris.lv2_symbol),
Sord::Literal(world, symbol.c_str()));
} else {
- symbol = Raul::Symbol::symbolify(s->second.get_string());
+ symbol = Raul::Symbol::symbolify(s->second.ptr<char>());
}
// If the graph has no doap:name (required by LV2), use the symbol