Smallest building block of an inference Rule.
More...
#include <Soprano/Inference/NodePattern>
List of all members.
Detailed Description
Smallest building block of an inference Rule.
There are two types of NodePattern:
- Simple nodes that wrap around an instance or Node and only match against that particular node.
- Variable nodes that match against every Node and have a name.
- Author:
- Sebastian Trueg <trueg@kde.org>
Definition at line 49 of file nodepattern.h.
Constructor & Destructor Documentation
Soprano::Inference::NodePattern::NodePattern |
( |
| ) |
|
Soprano::Inference::NodePattern::NodePattern |
( |
const Node & |
| ) |
|
Soprano::Inference::NodePattern::NodePattern |
( |
const QString & |
varname | ) |
|
Soprano::Inference::NodePattern::NodePattern |
( |
const NodePattern & |
| ) |
|
Soprano::Inference::NodePattern::~NodePattern |
( |
| ) |
|
Member Function Documentation
bool Soprano::Inference::NodePattern::isVariable |
( |
| ) |
const |
Node Soprano::Inference::NodePattern::resource |
( |
| ) |
const |
- Returns:
- the associated resource of an invalid Node if this is a variable.
QString Soprano::Inference::NodePattern::variableName |
( |
| ) |
const |
- Returns:
- The name of the variable or an empty string if this is not a variable.
bool Soprano::Inference::NodePattern::match |
( |
const Node & |
node | ) |
const |
Match a Node against this pattern. Variables will match any Node while specific node patterns will only match that one particular Node.
- Returns:
- true if node mathes this pattern.
QString Soprano::Inference::NodePattern::createSparqlNodePattern |
( |
const BindingSet & |
bindings | ) |
const |
bool Soprano::Inference::NodePattern::isValid |
( |
| ) |
const |
- Returns:
true
if the pattern is valid.
- Since:
- 2.3
The documentation for this class was generated from the following file:
- /builddir/build/BUILD/soprano-2.6.0/soprano/inference/nodepattern.h