summaryrefslogtreecommitdiffstats
path: root/src/engine/events/SetPortValue.cpp
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2010-02-03 20:39:18 +0000
committerDavid Robillard <d@drobilla.net>2010-02-03 20:39:18 +0000
commitaef3c9348218029a077f40081fd078a9e2ee85ca (patch)
treeb77d6ef50f66004129a03cb0751b653336c50f14 /src/engine/events/SetPortValue.cpp
parent3e495d47f06cca50521076e8f77a966dfec521ab (diff)
downloadingen-aef3c9348218029a077f40081fd078a9e2ee85ca.tar.gz
ingen-aef3c9348218029a077f40081fd078a9e2ee85ca.tar.bz2
ingen-aef3c9348218029a077f40081fd078a9e2ee85ca.zip
Responder => Request, and handle EventSource unblocking from Request (simplify Event interfaces).
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@2417 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/engine/events/SetPortValue.cpp')
-rw-r--r--src/engine/events/SetPortValue.cpp54
1 files changed, 27 insertions, 27 deletions
diff --git a/src/engine/events/SetPortValue.cpp b/src/engine/events/SetPortValue.cpp
index 33cf628c..aaa387b0 100644
--- a/src/engine/events/SetPortValue.cpp
+++ b/src/engine/events/SetPortValue.cpp
@@ -33,7 +33,7 @@
#include "ObjectBuffer.hpp"
#include "PortImpl.hpp"
#include "ProcessContext.hpp"
-#include "Responder.hpp"
+#include "Request.hpp"
#include "SetPortValue.hpp"
using namespace std;
@@ -46,13 +46,13 @@ using namespace Shared;
/** Omni (all voices) control setting */
-SetPortValue::SetPortValue(Engine& engine,
- SharedPtr<Responder> responder,
- bool queued,
- SampleCount timestamp,
- const Raul::Path& port_path,
- const Raul::Atom& value)
- : QueuedEvent(engine, responder, timestamp)
+SetPortValue::SetPortValue(Engine& engine,
+ SharedPtr<Request> request,
+ bool queued,
+ SampleCount timestamp,
+ const Raul::Path& port_path,
+ const Raul::Atom& value)
+ : QueuedEvent(engine, request, timestamp)
, _queued(queued)
, _omni(true)
, _voice_num(0)
@@ -65,14 +65,14 @@ SetPortValue::SetPortValue(Engine& engine,
/** Voice-specific control setting */
-SetPortValue::SetPortValue(Engine& engine,
- SharedPtr<Responder> responder,
- bool queued,
- SampleCount timestamp,
- uint32_t voice_num,
- const Raul::Path& port_path,
- const Raul::Atom& value)
- : QueuedEvent(engine, responder, timestamp)
+SetPortValue::SetPortValue(Engine& engine,
+ SharedPtr<Request> request,
+ bool queued,
+ SampleCount timestamp,
+ uint32_t voice_num,
+ const Raul::Path& port_path,
+ const Raul::Atom& value)
+ : QueuedEvent(engine, request, timestamp)
, _queued(queued)
, _omni(false)
, _voice_num(voice_num)
@@ -84,12 +84,12 @@ SetPortValue::SetPortValue(Engine& engine,
}
/** Internal */
-SetPortValue::SetPortValue(Engine& engine,
- SharedPtr<Responder> responder,
- SampleCount timestamp,
- PortImpl* port,
- const Raul::Atom& value)
- : QueuedEvent(engine, responder, timestamp)
+SetPortValue::SetPortValue(Engine& engine,
+ SharedPtr<Request> request,
+ SampleCount timestamp,
+ PortImpl* port,
+ const Raul::Atom& value)
+ : QueuedEvent(engine, request, timestamp)
, _queued(false)
, _omni(true)
, _voice_num(0)
@@ -228,7 +228,7 @@ SetPortValue::post_process()
switch (_error) {
case NO_ERROR:
assert(_port != NULL);
- _responder->respond_ok();
+ _request->respond_ok();
if (_omni)
_engine.broadcaster()->set_property(_port_path,
_engine.world()->uris->ingen_value, _value);
@@ -238,22 +238,22 @@ SetPortValue::post_process()
case TYPE_MISMATCH:
ss << "Illegal value type " << _value.type()
<< " for port " << _port_path << endl;
- _responder->respond_error(ss.str());
+ _request->respond_error(ss.str());
break;
case ILLEGAL_VOICE:
ss << "Illegal voice number " << _voice_num;
- _responder->respond_error(ss.str());
+ _request->respond_error(ss.str());
break;
case PORT_NOT_FOUND:
msg = "Unable to find port ";
msg.append(_port_path.str()).append(" to set value");
- _responder->respond_error(msg);
+ _request->respond_error(msg);
break;
case NO_SPACE:
ss << "Attempt to write " << _value.data_size() << " bytes to "
<< _port_path.str() << ", with capacity "
<< _port->buffer_size() << endl;
- _responder->respond_error(ss.str());
+ _request->respond_error(ss.str());
break;
}
}