#include <dependencytuple.h>
Public Member Functions | |
DependencyTuple (PathExpression *_path, bool _cond) | |
Constructor. | |
virtual | ~DependencyTuple () |
void | print (OutputStream &dos) |
Prints this single tuple. | |
PathExpression * | getPath () |
Returns the path of this single tuple. | |
void | setRole (Role *_role) |
Sets the role for this single tuple. | |
bool | isCondTuple () |
Returns if this single tuple results from a CondExpression. | |
bool | isPosTuple () |
Returns if this single tuple is a [positions ()=1] tuple. | |
bool | isDosTuple () |
Returns if this single tuple is a /dos : : node () tuple. | |
bool | isSyntacticallyEqualTo (DependencyTuple *tuple) |
Returns if this single tuple is syntactically equal to the entered single tuple. | |
bool | isSemanticallyContainedIn (DependencyTuple *tuple) |
Returns if this single tuple is semantically contained in the entered single tuple. | |
void | registerToPassiveProjectionTree (unsigned var, PassiveProjectionTree *ppt) |
Register the path described by this single tuple to the entered passive projection tree. | |
Private Attributes | |
PathExpression * | path |
The entered PathExpression. | |
bool | cond |
The entered boolean value. | |
Role * | role |
The set Role of this single tuple. |
Represents a single tuple of a set of dependency-tuples, i.e. of a DependencySet, which takes a PathExpression, e.g. /bib//book
or /bib/book/title
, a Role, and a boolean value, which indicates that this single tuple results from a CondExpression, as arguments.
Definition at line 51 of file dependencytuple.h.
DependencyTuple::DependencyTuple | ( | PathExpression * | _path, | |
bool | _cond | |||
) |
Constructor.
Constructor - creating object for a PathExpression and a boolean value.
[in] | _path | Pointer to a PathExpression object. |
[in] | _cond | true if this single tuple results from a CondExpression, false otherwise. |
Definition at line 37 of file dependencytuple.cpp.
DependencyTuple::~DependencyTuple | ( | ) | [virtual] |
PathExpression * DependencyTuple::getPath | ( | ) | [inline] |
Returns the path of this single tuple.
Returns the path of this single tuple, i.e. returns the member variable.
PathExpression* | Pointer to a PathExpression object. |
Definition at line 79 of file dependencytuple.h.
References path.
Referenced by isSemanticallyContainedIn(), and isSyntacticallyEqualTo().
bool DependencyTuple::isCondTuple | ( | ) | [inline] |
Returns if this single tuple results from a CondExpression.
Returns if this single tuple results from a CondExpression, i.e. returns the member variable.
bool | true if this single tuple results from a CondExpression, false otherwise. |
Definition at line 96 of file dependencytuple.h.
References cond.
bool DependencyTuple::isDosTuple | ( | ) |
Returns if this single tuple is a /dos
:
:
node
()
tuple.
Returns if this single tuple is a /dos
:
:
node
()
tuple.
bool | true if this single tuple is a /dos : : node () tuple, false otherwise. |
Definition at line 65 of file dependencytuple.cpp.
References PathExpression::getTailPathStep(), PathStepExpression::isDosNodeStep(), and path.
Referenced by isSyntacticallyEqualTo().
bool DependencyTuple::isPosTuple | ( | ) |
Returns if this single tuple is a [positions
()=1]
tuple.
Returns if this single tuple is a [positions
()=1]
tuple.
bool | true if this single tuple is a [positions ()=1] tuple, false otherwise. |
Definition at line 56 of file dependencytuple.cpp.
References PathStepExpression::getAttribute(), PathExpression::getTailPathStep(), PathStepAttribute::getType(), PathStepExpression::hasAttribute(), and path.
Referenced by isSyntacticallyEqualTo().
bool DependencyTuple::isSemanticallyContainedIn | ( | DependencyTuple * | tuple | ) |
Returns if this single tuple is semantically contained in the entered single tuple.
Returns if this single tuple is semantically contained in the entered single tuple, i.e. this single tuple is sematically contained if it locate a greater or greater equal set of nodes of an arbitrarily XML tree than the entered single tuple.
[in] | tuple | Pointer to a DependencyTuple object. |
bool | true if this single tuple is semantically contained in the entered single tuple, false otherwise. |
Definition at line 88 of file dependencytuple.cpp.
References getPath(), PathExpression::isSemanticallyContainedIn(), PathExpression::mightHasChildDescendantConflict(), and path.
bool DependencyTuple::isSyntacticallyEqualTo | ( | DependencyTuple * | tuple | ) |
Returns if this single tuple is syntactically equal to the entered single tuple.
Returns if this single tuple is syntactically equal to the entered single tuple with respect to their paths.
[in] | tuple | Pointer to a DependencyTuple object. |
bool | true if this single tuple if syntactically equal to the entered single tuple with respect to their paths, false otherwise. |
Definition at line 73 of file dependencytuple.cpp.
References getPath(), isDosTuple(), isPosTuple(), PathExpression::isSyntacticallyEqualTo(), and path.
void DependencyTuple::print | ( | OutputStream & | dos | ) |
Prints this single tuple.
Prints this single tuple.
[in] | dos | Pointer to a OutputStream object. |
void |
Definition at line 45 of file dependencytuple.cpp.
References Role::getId(), path, and role.
void DependencyTuple::registerToPassiveProjectionTree | ( | unsigned | var, | |
PassiveProjectionTree * | ppt | |||
) |
Register the path described by this single tuple to the entered passive projection tree.
Register the path described by this single tuple to the entered passive projection tree.
[in] | var | The basing variable. |
[in] | ppt | Pointer to a PassiveProjectionTree object. |
void |
Definition at line 97 of file dependencytuple.cpp.
References PathExpression::addPathStep(), PathStepExpression::clone(), PathExpression::clone(), PathEnvironment::getPath(), PassiveProjectionTree::getPathEnv(), PathExpression::getPathSize(), PathExpression::getPathStepAt(), path, and PassiveProjectionTree::registerPath().
void DependencyTuple::setRole | ( | Role * | _role | ) | [inline] |
Sets the role for this single tuple.
Sets the role for this single tuple, i.e. sets the member variable.
[in] | _role | Pointer to a Role object. |
void |
Definition at line 87 of file dependencytuple.h.
bool DependencyTuple::cond [private] |
The entered boolean value.
The entered boolean value, which is the second argument of the constructor.
Definition at line 152 of file dependencytuple.h.
Referenced by isCondTuple().
PathExpression * DependencyTuple::path [private] |
The entered PathExpression.
The entered PathExpression, which is the first argument of the constructor.
Definition at line 146 of file dependencytuple.h.
Referenced by getPath(), isDosTuple(), isPosTuple(), isSemanticallyContainedIn(), isSyntacticallyEqualTo(), print(), registerToPassiveProjectionTree(), and ~DependencyTuple().
Role * DependencyTuple::role [private] |
The set Role of this single tuple.
The set Role of this single tuple, which is NULL
on creation of object and will be set while constructing the ProjectionTree.
Definition at line 159 of file dependencytuple.h.
Referenced by print().