Concept Record. More...
#include <gconceptrecord.h>
Public Member Functions | |
GConceptRecord (void) | |
GConceptRecord (const GConceptRecord &rec) | |
GConceptRecord (size_t conceptid) | |
GConceptRecord (tTokenType type, size_t conceptid, size_t synpos, size_t pos, size_t syndepth, size_t idx, size_t nbchildren) | |
int | Compare (const GConceptRecord &node) const |
tTokenType | GetType (void) const |
size_t | GetConceptId (void) const |
size_t | GetSyntacticPos (void) const |
size_t | GetPos (void) const |
size_t | GetSyntacticDepth (void) const |
size_t | GetIndex (void) const |
size_t | GetNbChildren (void) const |
GConceptRecord & | operator= (const GConceptRecord &rec) |
bool | operator== (const GConceptRecord &rec) const |
bool | operator!= (const GConceptRecord &rec) const |
void | Clear (void) |
void | Print (void) const |
virtual | ~GConceptRecord (void) |
Protected Attributes | |
tTokenType | Type |
size_t | ConceptId |
size_t | SyntacticPos |
size_t | Pos |
size_t | SyntacticDepth |
size_t | Index |
size_t | NbChildren |
Detailed Description
Concept Record.
The GConceptRecord provides a representation for a "concept record", i.a. an occurrence of a given concept in a given object (such as a document).
Constructor & Destructor Documentation
GConceptRecord | ( | void | ) |
Construct a concept node.
GConceptRecord | ( | const GConceptRecord & | rec | ) |
Construct a concept node. Record.
GConceptRecord | ( | size_t | conceptid | ) |
Construct a concept node.
- Parameters
-
conceptid Identifier of the concept.
GConceptRecord | ( | tTokenType | type, |
size_t | conceptid, | ||
size_t | synpos, | ||
size_t | pos, | ||
size_t | syndepth, | ||
size_t | idx, | ||
size_t | nbchildren | ||
) |
Construct a concept node.
- Parameters
-
type Type of the token. conceptid Identifier of the concept. synpos Syntactic position. pos Position in the file. syndepth Syntactic depth of the record. idx Index of the record. nbchildren Number of children.
|
virtual |
Destructor.
Member Function Documentation
int Compare | ( | const GConceptRecord & | node | ) | const |
Compare two nodes regarding their positions (first the syntactic one) and then their depths. The concept associated to the record is the last criteria used.
- Parameters
-
node Node to compare with.
- Returns
- a number compatible with R::RContainer.
tTokenType GetType | ( | void | ) | const |
- Returns
- the type of the token corresponding to the node.
size_t GetConceptId | ( | void | ) | const |
- Returns
- the concept identifier.
size_t GetSyntacticPos | ( | void | ) | const |
- Returns
- the syntactic position in the file.
size_t GetPos | ( | void | ) | const |
- Returns
- the position in the file.
size_t GetSyntacticDepth | ( | void | ) | const |
- Returns
- the depth of the record.
size_t GetIndex | ( | void | ) | const |
- Returns
- the index of the node.
size_t GetNbChildren | ( | void | ) | const |
- Returns
- the number of child records.
GConceptRecord& operator= | ( | const GConceptRecord & | rec | ) |
Assignment record.
- Parameters
-
rec Record which contain will be assign.
- Returns
- the record assigned.
bool operator== | ( | const GConceptRecord & | rec | ) | const |
Equality operator. Each field must be identical (except the index).
- Parameters
-
rec Record to compare with.
- Returns
- true if the two records are identical.
bool operator!= | ( | const GConceptRecord & | rec | ) | const |
Inequality operator. At least one field must be different (except the index).
- Parameters
-
rec Record to compare with.
- Returns
- true if the two records are different.
void Clear | ( | void | ) |
Clear the information from the record.
void Print | ( | void | ) | const |
Simply print the node information on the screen;
Member Data Documentation
|
protected |
Type of the token corresponding to the node.
|
protected |
Concept Identifier.
|
protected |
Syntactic position in the document.
|
protected |
Position in the document (in byte).
|
protected |
Syntactic depth of the node.
|
protected |
Index of the node.
|
protected |
Number of children records