bindings: Add Session::context().

This commit is contained in:
Uwe Hermann 2014-11-13 19:15:37 +01:00
parent 57621c6d60
commit 624d16100e
2 changed files with 7 additions and 0 deletions

View File

@ -1147,6 +1147,11 @@ string Session::filename()
return _filename; return _filename;
} }
shared_ptr<Context> Session::context()
{
return _context;
}
Packet::Packet(shared_ptr<Device> device, Packet::Packet(shared_ptr<Device> device,
const struct sr_datafeed_packet *structure) : const struct sr_datafeed_packet *structure) :
UserOwned(structure), UserOwned(structure),

View File

@ -706,6 +706,8 @@ public:
void append(void *data, size_t length, unsigned int unit_size); void append(void *data, size_t length, unsigned int unit_size);
/** Get current trigger setting. */ /** Get current trigger setting. */
shared_ptr<Trigger> trigger(); shared_ptr<Trigger> trigger();
/** Get the context. */
shared_ptr<Context> context();
/** Set trigger setting. /** Set trigger setting.
* @param trigger Trigger object to use. */ * @param trigger Trigger object to use. */
void set_trigger(shared_ptr<Trigger> trigger); void set_trigger(shared_ptr<Trigger> trigger);