From 5268059f5d4ca9325a78da688a7622898354215a Mon Sep 17 00:00:00 2001 From: David Robillard Date: Wed, 13 May 2009 04:44:01 +0000 Subject: Remove 'using' declarations from headers. git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@1993 a436a847-0d15-0410-975c-d299462d15a1 --- src/serialisation/Parser.hpp | 127 ++++++++++++++++++------------------ src/serialisation/Serialiser.hpp | 31 +++++---- src/serialisation/serialisation.cpp | 2 +- 3 files changed, 79 insertions(+), 81 deletions(-) (limited to 'src/serialisation') diff --git a/src/serialisation/Parser.hpp b/src/serialisation/Parser.hpp index 6fbb8be6..eea5ca9b 100644 --- a/src/serialisation/Parser.hpp +++ b/src/serialisation/Parser.hpp @@ -28,9 +28,6 @@ namespace Raul { class Path; } namespace Redland { class World; class Model; class Node; } namespace Ingen { namespace Shared { class CommonInterface; } } - -using namespace Ingen::Shared; - namespace Ingen { namespace Serialisation { @@ -38,86 +35,88 @@ namespace Serialisation { class Parser { public: virtual ~Parser() {} + + typedef Shared::GraphObject::Properties Properties; virtual bool parse_document( - Ingen::Shared::World* world, - Shared::CommonInterface* target, - Glib::ustring document_uri, - boost::optional data_path=boost::optional(), - boost::optional parent=boost::optional(), - boost::optional symbol=boost::optional(), - boost::optional data=boost::optional()); + Ingen::Shared::World* world, + Shared::CommonInterface* target, + Glib::ustring document_uri, + boost::optional data_path=boost::optional(), + boost::optional parent=boost::optional(), + boost::optional symbol=boost::optional(), + boost::optional data=boost::optional()); virtual bool parse_string( - Ingen::Shared::World* world, - Shared::CommonInterface* target, - const Glib::ustring& str, - const Glib::ustring& base_uri, - boost::optional data_path=boost::optional(), - boost::optional parent=boost::optional(), - boost::optional symbol=boost::optional(), - boost::optional data=boost::optional()); + Ingen::Shared::World* world, + Shared::CommonInterface* target, + const Glib::ustring& str, + const Glib::ustring& base_uri, + boost::optional data_path=boost::optional(), + boost::optional parent=boost::optional(), + boost::optional symbol=boost::optional(), + boost::optional data=boost::optional()); virtual bool parse_update( - Ingen::Shared::World* world, - Shared::CommonInterface* target, - const Glib::ustring& str, - const Glib::ustring& base_uri, - boost::optional data_path=boost::optional(), - boost::optional parent=boost::optional(), - boost::optional symbol=boost::optional(), - boost::optional data=boost::optional()); + Ingen::Shared::World* world, + Shared::CommonInterface* target, + const Glib::ustring& str, + const Glib::ustring& base_uri, + boost::optional data_path=boost::optional(), + boost::optional parent=boost::optional(), + boost::optional symbol=boost::optional(), + boost::optional data=boost::optional()); private: boost::optional parse( - Ingen::Shared::World* world, - Shared::CommonInterface* target, - Redland::Model& model, - Glib::ustring document_uri, - boost::optional data_path=boost::optional(), - boost::optional parent=boost::optional(), - boost::optional symbol=boost::optional(), - boost::optional data=boost::optional()); + Ingen::Shared::World* world, + Shared::CommonInterface* target, + Redland::Model& model, + Glib::ustring document_uri, + boost::optional data_path=boost::optional(), + boost::optional parent=boost::optional(), + boost::optional symbol=boost::optional(), + boost::optional data=boost::optional()); boost::optional parse_patch( - Ingen::Shared::World* world, - Ingen::Shared::CommonInterface* target, - Redland::Model& model, - const Redland::Node& subject, - boost::optional parent=boost::optional(), - boost::optional symbol=boost::optional(), - boost::optional data=boost::optional()); + Ingen::Shared::World* world, + Ingen::Shared::CommonInterface* target, + Redland::Model& model, + const Redland::Node& subject, + boost::optional parent=boost::optional(), + boost::optional symbol=boost::optional(), + boost::optional data=boost::optional()); boost::optional parse_node( - Ingen::Shared::World* world, - Ingen::Shared::CommonInterface* target, - Redland::Model& model, - const Redland::Node& subject, - const Raul::Path& path, - boost::optional data=boost::optional()); + Ingen::Shared::World* world, + Ingen::Shared::CommonInterface* target, + Redland::Model& model, + const Redland::Node& subject, + const Raul::Path& path, + boost::optional data=boost::optional()); boost::optional parse_port( - Ingen::Shared::World* world, - Ingen::Shared::CommonInterface* target, - Redland::Model& model, - const Redland::Node& subject, - const Raul::Path& path, - boost::optional data=boost::optional()); + Ingen::Shared::World* world, + Ingen::Shared::CommonInterface* target, + Redland::Model& model, + const Redland::Node& subject, + const Raul::Path& path, + boost::optional data=boost::optional()); bool parse_variables( - Ingen::Shared::World* world, - Ingen::Shared::CommonInterface* target, - Redland::Model& model, - const Redland::Node& subject, - const Raul::Path& path, - boost::optional data=boost::optional()); + Ingen::Shared::World* world, + Ingen::Shared::CommonInterface* target, + Redland::Model& model, + const Redland::Node& subject, + const Raul::Path& path, + boost::optional data=boost::optional()); bool parse_connections( - Ingen::Shared::World* world, - Ingen::Shared::CommonInterface* target, - Redland::Model& model, - const Glib::ustring& subject, - const Raul::Path& patch); + Ingen::Shared::World* world, + Ingen::Shared::CommonInterface* target, + Redland::Model& model, + const Glib::ustring& subject, + const Raul::Path& patch); }; diff --git a/src/serialisation/Serialiser.hpp b/src/serialisation/Serialiser.hpp index a2863871..95425bad 100644 --- a/src/serialisation/Serialiser.hpp +++ b/src/serialisation/Serialiser.hpp @@ -30,9 +30,6 @@ #include "interface/GraphObject.hpp" #include "shared/Store.hpp" -using namespace Raul; -using namespace Ingen::Shared; - namespace Ingen { namespace Shared { @@ -56,14 +53,16 @@ class Serialiser { public: Serialiser(Shared::World& world, SharedPtr store); + + typedef Shared::GraphObject::Properties Properties; struct Record { - Record(SharedPtr o, const std::string& u) + Record(SharedPtr o, const std::string& u) : object(o), uri(u) {} - const SharedPtr object; - const std::string uri; + const SharedPtr object; + const std::string uri; }; typedef std::list Records; @@ -75,15 +74,15 @@ public: void write_manifest(const std::string& bundle_uri, const Records& records); - std::string to_string(SharedPtr object, - const std::string& base_uri, - const GraphObject::Properties& extra_rdf); + std::string to_string(SharedPtr object, + const std::string& base_uri, + const Properties& extra_rdf); void start_to_string(const Raul::Path& root, const std::string& base_uri); - void serialise(SharedPtr object) throw (std::logic_error); + void serialise(SharedPtr object) throw (std::logic_error); void serialise_plugin(const Shared::Plugin& p); - void serialise_connection(SharedPtr parent, - SharedPtr c) throw (std::logic_error); + void serialise_connection(SharedPtr parent, + SharedPtr c) throw (std::logic_error); std::string finish(); @@ -100,11 +99,11 @@ private: void serialise_port(const Shared::Port* p, const Redland::Node& id); void serialise_port_class(const Shared::Port* p, const Redland::Node& id); - void serialise_properties(Redland::Node subject, const GraphObject::Properties& properties); - void serialise_variables(Redland::Node subject, const GraphObject::Properties& variables); + void serialise_properties(Redland::Node subject, const Properties& properties); + void serialise_variables(Redland::Node subject, const Properties& variables); - Redland::Node instance_rdf_node(const Path& path); - Redland::Node class_rdf_node(const Path& path); + Redland::Node instance_rdf_node(const Raul::Path& path); + Redland::Node class_rdf_node(const Raul::Path& path); Raul::Path _root_path; SharedPtr _store; diff --git a/src/serialisation/serialisation.cpp b/src/serialisation/serialisation.cpp index 3615d8c9..172db2a1 100644 --- a/src/serialisation/serialisation.cpp +++ b/src/serialisation/serialisation.cpp @@ -33,7 +33,7 @@ new_parser() Ingen::Serialisation::Serialiser* -new_serialiser(Ingen::Shared::World* world, SharedPtr store) +new_serialiser(Ingen::Shared::World* world, SharedPtr store) { assert(world->rdf_world); return new Serialiser(*world, store); -- cgit v1.2.1