From 91d5cb109563c67bdad5f3ebeaafc8e1e8f7e14a Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 3 Oct 2006 22:24:22 +0000 Subject: shared_ptr bugfixes. Updated Ingen to work with new FlowCanvas. Updated Patchage to work with new(er) FlowCanvas. git-svn-id: http://svn.drobilla.net/lad/ingen@152 a436a847-0d15-0410-975c-d299462d15a1 --- src/libs/client/Serializer.h | 36 ++++++++++++++++++------------------ 1 file changed, 18 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 b2dbf000..a563dbb8 100644 --- a/src/libs/client/Serializer.h +++ b/src/libs/client/Serializer.h @@ -20,7 +20,8 @@ #include #include #include -#include +#include +#include #include #include "util/CountedPtr.h" #include "util/Path.h" @@ -60,52 +61,51 @@ public: string find_file(const string& filename, const string& additional_path = ""); - void save_patch(CountedPtr patch_model, const string& filename, bool recursive); - string load_patch(const string& filename, const string& parent_path, const string& name, size_t poly, 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); private: // Model -> RDF - void add_patch_to_rdf(librdf_model* rdf, - CountedPtr patch, const string& uri); - - void add_node_to_rdf(librdf_model* rdf, + void add_node_to_rdf(raptor_serializer* rdf, CountedPtr node, const string ns_prefix=""); - void add_port_to_rdf(librdf_model* rdf, + void add_port_to_rdf(raptor_serializer* rdf, CountedPtr port, const string ns_prefix=""); - void add_connection_to_rdf(librdf_model* rdf, + void add_connection_to_rdf(raptor_serializer* rdf, CountedPtr connection, const string port_ns_prefix=""); // Triple -> RDF - void add_resource_to_rdf(librdf_model* model, + void add_resource_to_rdf(raptor_serializer* rdf, const string& subject_uri, const string& predicate_uri, const string& object_uri); - void add_resource_to_rdf(librdf_model* model, - librdf_node* subject, 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 add_atom_to_rdf(librdf_model* model, + void add_atom_to_rdf(raptor_serializer* rdf, const string& subject_uri, const string& predicate_uri, const Atom& atom); - - void create(); - void destroy(); void setup_prefixes(); string expand_uri(const string& uri); - librdf_world* _world; - librdf_serializer* _serializer; + raptor_serializer* _serializer; + unsigned char* _string_output; string _patch_search_path; map _prefixes; CountedPtr _engine; -- cgit v1.2.1