From 1e01da451b279943ed51999ee06d64aba7c8faa2 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Wed, 4 Oct 2006 04:47:30 +0000 Subject: Bug fixes. Added copy to ingen (no cut or paste yet). Serialization work. git-svn-id: http://svn.drobilla.net/lad/ingen@153 a436a847-0d15-0410-975c-d299462d15a1 --- src/libs/client/Serializer.h | 38 ++++++++++++++++++++------------------ 1 file changed, 20 insertions(+), 18 deletions(-) (limited to 'src/libs/client/Serializer.h') diff --git a/src/libs/client/Serializer.h b/src/libs/client/Serializer.h index a563dbb8..1af18de7 100644 --- a/src/libs/client/Serializer.h +++ b/src/libs/client/Serializer.h @@ -68,37 +68,39 @@ public: MetadataMap initial_data, bool existing = false); - void start_to_filename(const string& filename); - void start_to_string(); - - void serialize_patch(CountedPtr patch) throw(std::logic_error); - - string finish() throw(std::logic_error); + void start_to_filename(const string& filename) throw (std::logic_error); + void start_to_string() throw (std::logic_error); + void serialize(CountedPtr object) throw (std::logic_error); + void serialize_connection(CountedPtr c) throw (std::logic_error); + string finish() throw (std::logic_error); private: // Model -> RDF - void add_node_to_rdf(raptor_serializer* rdf, - CountedPtr node, const string ns_prefix=""); + void serialize_patch(CountedPtr p); + + void serialize_node(CountedPtr n, const string ns_prefix=""); - void add_port_to_rdf(raptor_serializer* rdf, - CountedPtr port, const string ns_prefix=""); + void serialize_port(CountedPtr p, const string ns_prefix=""); - void add_connection_to_rdf(raptor_serializer* rdf, - CountedPtr connection, const string port_ns_prefix=""); + // Triple -> RDF - void add_resource_to_rdf(raptor_serializer* rdf, - const string& subject_uri, const string& predicate_uri, const string& object_uri); + void serialize_resource(const string& subject_uri, + const string& predicate_uri, + const string& object_uri); - //void add_resource_to_rdf(raptor_serializer* rdf - // librdf_node* subject, const string& predicate_uri, const string& object_uri); + + void serialize_resource(raptor_identifier* subject, + const string& predicate_uri, + const string& object_uri); - void add_atom_to_rdf(raptor_serializer* rdf, - const string& subject_uri, const string& predicate_uri, const Atom& atom); + void serialize_atom(const string& subject_uri, + const string& predicate_uri, + const Atom& atom); void setup_prefixes(); string expand_uri(const string& uri); -- cgit v1.2.1