summaryrefslogtreecommitdiffstats
path: root/ingen
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2012-07-26 15:27:03 +0000
committerDavid Robillard <d@drobilla.net>2012-07-26 15:27:03 +0000
commit3c5931bb13b5f88edcebb375fa6964dde8b85563 (patch)
tree9801897576b7fb9d8a9f700847c670f216fc93b7 /ingen
parentb83ed4f83cf4c9b5054dcf55bea710313c369633 (diff)
downloadingen-3c5931bb13b5f88edcebb375fa6964dde8b85563.tar.gz
ingen-3c5931bb13b5f88edcebb375fa6964dde8b85563.tar.bz2
ingen-3c5931bb13b5f88edcebb375fa6964dde8b85563.zip
Report subject with errors to client for more meaningful error messages.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4556 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'ingen')
-rw-r--r--ingen/Interface.hpp4
-rw-r--r--ingen/client/ClientStore.hpp2
-rw-r--r--ingen/client/SigClientInterface.hpp6
-rw-r--r--ingen/client/ThreadedSigClientInterface.hpp6
-rw-r--r--ingen/shared/AtomWriter.hpp2
-rw-r--r--ingen/shared/ClashAvoider.hpp2
-rw-r--r--ingen/shared/URIs.hpp1
7 files changed, 13 insertions, 10 deletions
diff --git a/ingen/Interface.hpp b/ingen/Interface.hpp
index 94faeab9..0ad9e1ba 100644
--- a/ingen/Interface.hpp
+++ b/ingen/Interface.hpp
@@ -94,7 +94,9 @@ public:
virtual void get(const Raul::URI& uri) = 0;
// Response
- virtual void response(int32_t id, Status status) = 0;
+ virtual void response(int32_t id,
+ Status status,
+ const std::string& subject) = 0;
// Non-response error
virtual void error(const std::string& msg) = 0;
diff --git a/ingen/client/ClientStore.hpp b/ingen/client/ClientStore.hpp
index 1512b941..b5a51a83 100644
--- a/ingen/client/ClientStore.hpp
+++ b/ingen/client/ClientStore.hpp
@@ -102,7 +102,7 @@ public:
void set_response_id(int32_t id) {}
void get(const Raul::URI& uri) {}
- void response(int32_t id, Status status) {}
+ void response(int32_t id, Status status, const std::string& subject) {}
void error(const std::string& msg) {}
INGEN_SIGNAL(new_object, void, SharedPtr<ObjectModel>);
diff --git a/ingen/client/SigClientInterface.hpp b/ingen/client/SigClientInterface.hpp
index 8b43bca0..4aef5a40 100644
--- a/ingen/client/SigClientInterface.hpp
+++ b/ingen/client/SigClientInterface.hpp
@@ -47,7 +47,7 @@ public:
Raul::URI uri() const { return "http://drobilla.net/ns/ingen#internal"; }
- INGEN_SIGNAL(response, void, int32_t, Status)
+ INGEN_SIGNAL(response, void, int32_t, Status, std::string)
INGEN_SIGNAL(bundle_begin, void)
INGEN_SIGNAL(bundle_end, void)
INGEN_SIGNAL(error, void, std::string)
@@ -75,8 +75,8 @@ protected:
void bundle_end()
{ EMIT(bundle_end); }
- void response(int32_t id, Status status)
- { EMIT(response, id, status); }
+ void response(int32_t id, Status status, const std::string& subject)
+ { EMIT(response, id, status, subject); }
void error(const std::string& msg)
{ EMIT(error, msg); }
diff --git a/ingen/client/ThreadedSigClientInterface.hpp b/ingen/client/ThreadedSigClientInterface.hpp
index 71e1b2ee..c321f438 100644
--- a/ingen/client/ThreadedSigClientInterface.hpp
+++ b/ingen/client/ThreadedSigClientInterface.hpp
@@ -73,8 +73,8 @@ public:
void bundle_end()
{ push_sig(bundle_end_slot); }
- void response(int32_t id, Status status)
- { push_sig(sigc::bind(response_slot, id, status)); }
+ void response(int32_t id, Status status, const std::string& subject)
+ { push_sig(sigc::bind(response_slot, id, status, subject)); }
void error(const std::string& msg)
{ push_sig(sigc::bind(error_slot, msg)); }
@@ -149,7 +149,7 @@ private:
sigc::slot<void> bundle_begin_slot;
sigc::slot<void> bundle_end_slot;
- sigc::slot<void, int32_t, Status> response_slot;
+ sigc::slot<void, int32_t, Status, std::string> response_slot;
sigc::slot<void, std::string> error_slot;
sigc::slot<void, Raul::URI, Raul::URI, Raul::Symbol> new_plugin_slot;
sigc::slot<void, Raul::URI, Resource::Properties,
diff --git a/ingen/shared/AtomWriter.hpp b/ingen/shared/AtomWriter.hpp
index 585c362a..7087bfd6 100644
--- a/ingen/shared/AtomWriter.hpp
+++ b/ingen/shared/AtomWriter.hpp
@@ -73,7 +73,7 @@ public:
void get(const Raul::URI& uri);
- void response(int32_t id, Status status);
+ void response(int32_t id, Status status, const std::string& subject);
void error(const std::string& msg);
diff --git a/ingen/shared/ClashAvoider.hpp b/ingen/shared/ClashAvoider.hpp
index 40b1bdb6..e3f4faaf 100644
--- a/ingen/shared/ClashAvoider.hpp
+++ b/ingen/shared/ClashAvoider.hpp
@@ -83,7 +83,7 @@ public:
virtual void set_response_id(int32_t id) {}
virtual void get(const Raul::URI& uri) {}
- virtual void response(int32_t id, Status status) {}
+ virtual void response(int32_t id, Status status, const std::string& subject) {}
virtual void error(const std::string& msg) {}
private:
diff --git a/ingen/shared/URIs.hpp b/ingen/shared/URIs.hpp
index 7e27bb34..9e604841 100644
--- a/ingen/shared/URIs.hpp
+++ b/ingen/shared/URIs.hpp
@@ -91,6 +91,7 @@ public:
const Quark ingen_polyphony;
const Quark ingen_prototype;
const Quark ingen_sampleRate;
+ const Quark ingen_status;
const Quark ingen_tail;
const Quark ingen_uiEmbedded;
const Quark ingen_value;