#include <include/ling_class/EST_Relation.h>
Public Types | |
typedef EST_Relation_Iterator | Iterator |
Public Attributes | |
EST_Features | f |
Friends | |
class | EST_Item |
ostream & | operator<< (ostream &s, const EST_Relation &u) |
Relations are a container class for EST_Item. Three types of relation structure are supported:
Definition at line 65 of file EST_Relation.h.
Iteration
Definition at line 188 of file EST_Relation.h.
EST_Relation::EST_Relation | ( | ) |
default constructor
Definition at line 59 of file EST_Relation.cc.
EST_Relation::EST_Relation | ( | const EST_String & | name | ) |
Constructor which sets name of relation
Definition at line 51 of file EST_Relation.cc.
|
inline |
Constructor which copies relation r
Definition at line 96 of file EST_Relation.h.
EST_Relation::~EST_Relation | ( | ) |
default destructor
Definition at line 144 of file EST_Relation.cc.
void EST_Relation::evaluate_item_features | ( | ) |
Evaluate the relation's feature functions Evaluate the feature functions of all the items in the relation
Definition at line 161 of file EST_Relation.cc.
void EST_Relation::clear | ( | void | ) |
Clear the relation of items
Definition at line 167 of file EST_Relation.cc.
|
inline |
Return the EST_Utterance to which this relation belongs
Definition at line 112 of file EST_Relation.h.
|
inline |
Set the EST_Utterance to which this relation belongs
Definition at line 115 of file EST_Relation.h.
|
inline |
Return the name of the relation
Definition at line 118 of file EST_Relation.h.
|
inline |
Return the head (first) item of the relation
Definition at line 121 of file EST_Relation.h.
|
inline |
Return the root item of the relation
Definition at line 124 of file EST_Relation.h.
|
inline |
Return the tail (last) item of the relation
Definition at line 127 of file EST_Relation.h.
|
inline |
Definition at line 130 of file EST_Relation.h.
EST_Item * EST_Relation::first_leaf | ( | ) | const |
Definition at line 663 of file EST_Relation.cc.
|
inline |
Definition at line 132 of file EST_Relation.h.
EST_Item * EST_Relation::last_leaf | ( | ) | const |
Definition at line 668 of file EST_Relation.cc.
int EST_Relation::length | ( | void | ) | const |
Return the tail (last) item of the relation number of items in this relation
Definition at line 149 of file EST_Relation.cc.
|
inline |
return true if relation does not contain any items
Definition at line 143 of file EST_Relation.h.
void EST_Relation::remove_item | ( | EST_Item * | item | ) |
remove EST_Item item
from relation
Definition at line 179 of file EST_Relation.cc.
void EST_Relation::remove_item_feature | ( | const EST_String & | name | ) |
remove all occurrences of feature name
from relation's items
Definition at line 188 of file EST_Relation.cc.
EST_read_status EST_Relation::load | ( | const EST_String & | filename, |
const EST_String & | type = "esps" |
||
) |
Load relation from file
Definition at line 633 of file EST_Relation.cc.
EST_read_status EST_Relation::load | ( | EST_TokenStream & | ts, |
const EST_TVector< EST_Item_Content * > & | contents | ||
) |
Load relation from already open tokenstream Load relation from already open tokenstream
Definition at line 320 of file EST_Relation.cc.
EST_read_status EST_Relation::load | ( | const EST_String & | filename, |
EST_TokenStream & | ts, | ||
const EST_String & | type | ||
) |
Load relation from already open tokenstream
Definition at line 609 of file EST_Relation.cc.
EST_write_status EST_Relation::save | ( | const EST_String & | filename, |
bool | evaluate_ff = false |
||
) | const |
Save relation to file
Definition at line 238 of file EST_Relation.cc.
EST_write_status EST_Relation::save | ( | const EST_String & | filename, |
const EST_String & | type, | ||
bool | evaluate_ff = false |
||
) | const |
Save relation to file, evaluating all feature functions before hand
Definition at line 223 of file EST_Relation.cc.
EST_write_status EST_Relation::save | ( | ostream & | outf, |
EST_TKVL< void *, int > | contents | ||
) | const |
Save relation from already open ostream
Definition at line 244 of file EST_Relation.cc.
EST_write_status EST_Relation::save | ( | ostream & | outf, |
const EST_String & | type, | ||
bool | evaluate_ff | ||
) | const |
Save relation from already open ostream
Definition at line 208 of file EST_Relation.cc.
EST_Relation & EST_Relation::operator= | ( | const EST_Relation & | s | ) |
Definition at line 688 of file EST_Relation.cc.
Definition at line 88 of file EST_Relation.cc.
EST_Item * EST_Relation::append | ( | ) |
Definition at line 113 of file EST_Relation.cc.
Definition at line 123 of file EST_Relation.cc.
EST_Item * EST_Relation::prepend | ( | ) |
Definition at line 118 of file EST_Relation.cc.
|
friend |
Definition at line 198 of file EST_Relation.h.
|
friend |
Definition at line 694 of file EST_Relation.cc.
EST_Features EST_Relation::f |
Features which belong to the relation rather than its items
Definition at line 101 of file EST_Relation.h.