knowrob
2.1.0
A Knowledge Base System for Cognition-enabled Robots
|
#include <ObserverJob.h>
Classes | |
struct | Node |
Public Member Functions | |
ObserverJob (const std::shared_ptr< ObserverManager > &manager, const GraphQueryPtr &query, const BindingsHandler &callback) | |
~ObserverJob () | |
void | stop () |
void | processInsertion (const TripleContainerPtr &triples) |
void | processRemoval (const TripleContainerPtr &triples) |
auto & | manager () const |
ObserverJob (const std::shared_ptr< ObserverManager > &manager, const GraphQueryPtr &query, const BindingsHandler &callback) | |
~ObserverJob () | |
void | stop () |
void | processInsertion (const TripleContainerPtr &triples) |
void | processRemoval (const TripleContainerPtr &triples) |
auto & | manager () const |
Protected Types | |
using | NodeParents = std::vector< std::shared_ptr< Node > > |
using | NodeParents = std::vector< std::shared_ptr< Node > > |
Protected Member Functions | |
NodeParents | createGraph (const std::shared_ptr< GraphTerm > &term, const NodeParents &parents) |
std::shared_ptr< ObserverJob::Node > | createNode (const std::shared_ptr< GraphPattern > &pattern) |
void | initializeNode (const std::shared_ptr< Node > &node) |
void | initializeNode (const std::shared_ptr< Node > &node, const BindingsPtr &bindings) |
GraphQueryPtr | makeQuery (const std::vector< Node * > &reverseSequence) |
GraphQueryPtr | makeAtomicQuery (const std::shared_ptr< Node > &node, const BindingsPtr &bindings) |
bool | matches (const Node &node, const Triple &triple) |
void | remove (const std::shared_ptr< Node > &node, const Triple &triple) |
void | insert (const std::shared_ptr< Node > &node, const Triple &triple) |
void | doInsert (const std::shared_ptr< Node > &node, const BindingsPtr &newBindings) |
void | doInsert (const std::shared_ptr< Node > &node, const BindingsPtr &parentBindings, const BindingsPtr &nodeBindings) |
BindingsPtr | applyBuiltins (const std::shared_ptr< Node > &node, const BindingsPtr &bindings) |
NodeParents | createGraph (const std::shared_ptr< GraphTerm > &term, const NodeParents &parents) |
std::shared_ptr< ObserverJob::Node > | createNode (const std::shared_ptr< GraphPattern > &pattern) |
void | initializeNode (const std::shared_ptr< Node > &node) |
void | initializeNode (const std::shared_ptr< Node > &node, const BindingsPtr &bindings) |
GraphQueryPtr | makeQuery (const std::vector< Node * > &reverseSequence) |
GraphQueryPtr | makeAtomicQuery (const std::shared_ptr< Node > &node, const BindingsPtr &bindings) |
bool | matches (const Node &node, const Triple &triple) |
void | remove (const std::shared_ptr< Node > &node, const Triple &triple) |
void | insert (const std::shared_ptr< Node > &node, const Triple &triple) |
void | doInsert (const std::shared_ptr< Node > &node, const BindingsPtr &newBindings) |
void | doInsert (const std::shared_ptr< Node > &node, const BindingsPtr &parentBindings, const BindingsPtr &nodeBindings) |
BindingsPtr | applyBuiltins (const std::shared_ptr< Node > &node, const BindingsPtr &bindings) |
Protected Attributes | |
std::shared_ptr< ObserverManager > | manager_ |
GraphQueryPtr | query_ |
BindingsHandler | callback_ |
std::vector< std::shared_ptr< Node > > | nodes_ |
NodeParents | terminalNodes_ |
An observer job is a query that is observed by an observer manager.
Definition at line 19 of file ObserverJob.h.
|
protected |
Definition at line 69 of file ObserverJob.h.
|
protected |
Definition at line 69 of file ObserverJob.h.
ObserverJob::ObserverJob | ( | const std::shared_ptr< ObserverManager > & | manager, |
const GraphQueryPtr & | query, | ||
const BindingsHandler & | callback | ||
) |
Create an observer job.
manager | the observer manager. |
query | the query to observe. |
callback | the callback to invoke when the query matches. |
Definition at line 10 of file ObserverJob.cpp.
ObserverJob::~ObserverJob | ( | ) |
Definition at line 23 of file ObserverJob.cpp.
knowrob::ObserverJob::ObserverJob | ( | const std::shared_ptr< ObserverManager > & | manager, |
const GraphQueryPtr & | query, | ||
const BindingsHandler & | callback | ||
) |
Create an observer job.
manager | the observer manager. |
query | the query to observe. |
callback | the callback to invoke when the query matches. |
knowrob::ObserverJob::~ObserverJob | ( | ) |
|
protected |
Definition at line 214 of file ObserverJob.cpp.
|
protected |
|
protected |
Definition at line 41 of file ObserverJob.cpp.
|
protected |
|
protected |
Definition at line 33 of file ObserverJob.cpp.
|
protected |
|
protected |
Definition at line 309 of file ObserverJob.cpp.
|
protected |
|
protected |
Definition at line 300 of file ObserverJob.cpp.
|
protected |
|
protected |
Definition at line 112 of file ObserverJob.cpp.
|
protected |
|
protected |
Definition at line 141 of file ObserverJob.cpp.
|
protected |
Definition at line 264 of file ObserverJob.cpp.
|
protected |
|
protected |
Definition at line 98 of file ObserverJob.cpp.
|
protected |
|
protected |
Definition at line 83 of file ObserverJob.cpp.
|
protected |
|
inline |
|
inline |
Definition at line 155 of file ObserverJob.cpp.
void ObserverJob::processInsertion | ( | const TripleContainerPtr & | triples | ) |
Process the insertion of triples.
triples | the triples to insert. |
Definition at line 192 of file ObserverJob.cpp.
void knowrob::ObserverJob::processInsertion | ( | const TripleContainerPtr & | triples | ) |
Process the insertion of triples.
triples | the triples to insert. |
void ObserverJob::processRemoval | ( | const TripleContainerPtr & | triples | ) |
Process the removal of triples.
triples | the triples to remove. |
Definition at line 203 of file ObserverJob.cpp.
void knowrob::ObserverJob::processRemoval | ( | const TripleContainerPtr & | triples | ) |
Process the removal of triples.
triples | the triples to remove. |
Definition at line 226 of file ObserverJob.cpp.
|
protected |
void ObserverJob::stop | ( | ) |
Stop the observer job.
Definition at line 27 of file ObserverJob.cpp.
void knowrob::ObserverJob::stop | ( | ) |
Stop the observer job.
|
protected |
Definition at line 58 of file ObserverJob.h.
|
protected |
Definition at line 56 of file ObserverJob.h.
|
protected |
Definition at line 67 of file ObserverJob.h.
|
protected |
Definition at line 57 of file ObserverJob.h.
|
protected |
Definition at line 70 of file ObserverJob.h.