knowrob  2.1.0
A Knowledge Base System for Cognition-enabled Robots
knowrob::GraphPathQuery Class Reference

#include <GraphPathQuery.h>

Inheritance diagram for knowrob::GraphPathQuery:
Collaboration diagram for knowrob::GraphPathQuery:

Public Member Functions

 GraphPathQuery (const std::vector< TriplePatternPtr > &query, const QueryContextPtr &ctx=DefaultQueryContext())
 
 GraphPathQuery (const TriplePatternPtr &query)
 
 GraphPathQuery (const TriplePatternPtr &query, const QueryContextPtr &ctx)
 
auto & path () const
 
 GraphPathQuery (const std::vector< TriplePatternPtr > &query, const QueryContextPtr &ctx=DefaultQueryContext())
 
 GraphPathQuery (const TriplePatternPtr &query)
 
 GraphPathQuery (const TriplePatternPtr &query, const QueryContextPtr &ctx)
 
auto & path () const
 
- Public Member Functions inherited from knowrob::GraphQuery
 GraphQuery (const std::shared_ptr< GraphTerm > &query, const QueryContextPtr &ctx=DefaultQueryContext())
 
 GraphQuery (const std::vector< TriplePatternPtr > &query, const QueryContextPtr &ctx=DefaultQueryContext())
 
 GraphQuery (const TriplePatternPtr &query)
 
 GraphQuery (const TriplePatternPtr &query, const QueryContextPtr &ctx)
 
auto term () const
 
FormulaPtr toFormula () const
 
 GraphQuery (const std::shared_ptr< GraphTerm > &query, const QueryContextPtr &ctx=DefaultQueryContext())
 
 GraphQuery (const std::vector< TriplePatternPtr > &query, const QueryContextPtr &ctx=DefaultQueryContext())
 
 GraphQuery (const TriplePatternPtr &query)
 
 GraphQuery (const TriplePatternPtr &query, const QueryContextPtr &ctx)
 
auto term () const
 
FormulaPtr toFormula () const
 
- Public Member Functions inherited from knowrob::Query
 Query (QueryContextPtr ctx=DefaultQueryContext())
 
virtual ~Query ()=default
 
auto & ctx () const
 
void setContext (QueryContextPtr ctx)
 
 Query (QueryContextPtr ctx=DefaultQueryContext())
 
virtual ~Query ()=default
 
auto & ctx () const
 
void setContext (QueryContextPtr ctx)
 
- Public Member Functions inherited from knowrob::Printable
virtual ~Printable ()=default
 
virtual std::string format () const
 
virtual ~Printable ()=default
 
virtual std::string format () const
 

Protected Attributes

std::vector< TriplePatternPtrpath_
 
- Protected Attributes inherited from knowrob::GraphQuery
std::shared_ptr< GraphTermterm_
 
- Protected Attributes inherited from knowrob::Query
QueryContextPtr ctx_
 

Additional Inherited Members

- Protected Member Functions inherited from knowrob::GraphQuery
void write (std::ostream &os) const override
 
 GraphQuery (const QueryContextPtr &ctx=DefaultQueryContext())
 
void write (std::ostream &os) const override
 
 GraphQuery (const QueryContextPtr &ctx=DefaultQueryContext())
 

Detailed Description

A GraphQuery that is constructed from a sequence of triple patterns which are considered to be in a conjunction.

Definition at line 15 of file GraphPathQuery.h.

Constructor & Destructor Documentation

◆ GraphPathQuery() [1/6]

knowrob::GraphPathQuery::GraphPathQuery ( const std::vector< TriplePatternPtr > &  query,
const QueryContextPtr ctx = DefaultQueryContext() 
)
inlineexplicit
Parameters
queryan ordered sequence of triple patterns.
ctxthe query context.

Definition at line 21 of file GraphPathQuery.h.

23  : GraphQuery(query, ctx), path_(query) {}
std::vector< TriplePatternPtr > path_
GraphQuery(const std::shared_ptr< GraphTerm > &query, const QueryContextPtr &ctx=DefaultQueryContext())
Definition: GraphQuery.cpp:24
auto & ctx() const
Definition: Query.h:41

◆ GraphPathQuery() [2/6]

knowrob::GraphPathQuery::GraphPathQuery ( const TriplePatternPtr query)
inlineexplicit
Parameters
querya single triple pattern.

Definition at line 28 of file GraphPathQuery.h.

29  : GraphQuery(query), path_({query}) {}

◆ GraphPathQuery() [3/6]

knowrob::GraphPathQuery::GraphPathQuery ( const TriplePatternPtr query,
const QueryContextPtr ctx 
)
inlineexplicit
Parameters
querya single triple pattern.
ctxthe query context.

Definition at line 35 of file GraphPathQuery.h.

36  : GraphQuery(query, ctx), path_({query}) {}

◆ GraphPathQuery() [4/6]

knowrob::GraphPathQuery::GraphPathQuery ( const std::vector< TriplePatternPtr > &  query,
const QueryContextPtr ctx = DefaultQueryContext() 
)
inlineexplicit
Parameters
queryan ordered sequence of triple patterns.
ctxthe query context.

Definition at line 21 of file GraphPathQuery.h.

23  : GraphQuery(query, ctx), path_(query) {}

◆ GraphPathQuery() [5/6]

knowrob::GraphPathQuery::GraphPathQuery ( const TriplePatternPtr query)
inlineexplicit
Parameters
querya single triple pattern.

Definition at line 28 of file GraphPathQuery.h.

29  : GraphQuery(query), path_({query}) {}

◆ GraphPathQuery() [6/6]

knowrob::GraphPathQuery::GraphPathQuery ( const TriplePatternPtr query,
const QueryContextPtr ctx 
)
inlineexplicit
Parameters
querya single triple pattern.
ctxthe query context.

Definition at line 35 of file GraphPathQuery.h.

36  : GraphQuery(query, ctx), path_({query}) {}

Member Function Documentation

◆ path() [1/2]

auto& knowrob::GraphPathQuery::path ( ) const
inline
Returns
the path of the query.

Definition at line 41 of file GraphPathQuery.h.

41 { return path_; }

◆ path() [2/2]

auto& knowrob::GraphPathQuery::path ( ) const
inline
Returns
the path of the query.

Definition at line 41 of file GraphPathQuery.h.

41 { return path_; }

Member Data Documentation

◆ path_

std::vector< TriplePatternPtr > knowrob::GraphPathQuery::path_
protected

Definition at line 44 of file GraphPathQuery.h.


The documentation for this class was generated from the following file: