Main Page | Modules | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

UnitLevel Class Reference
[BOSS UnitSelection Module]

Data structure holding attributes of one speech unit level (word, syllable, etc.). More...

#include <unit_level.h>

List of all members.

Public Member Functions

 UnitLevel (BOSS::Config &config, string levelName, string elementTag, DOM_UserData::Node_Type type, string fileFlag, UnitLevel *nextLevel)
 Constructs a UnitLevel.

string getName ()
 Returns unit level name.

string getTag ()
 Returns unit level tag.

UnitLevelgetNextLevel ()
 Returns pointer to lower unit level e.g. Word -> Syllable.

DOM_UserData::Node_Type getNodeType ()
 Returns node type.

vector< PSA_VectorgetAttrMatrix ()
 Returns attribute matrix.

int checkMatrixSize ()

Private Member Functions

bool isComment (const string &s)
 Decides if the argument string is a comment.

void loadPreSelQueries ()
 Loads preselection queries for a unit level.

void loadPreSelFile (const string &file, vector< PSA_Vector > &ps)

Private Attributes

BOSS::Configcl
 configuration class storing system wide settings

string name
 name of this unit level

string tag
 name of tag of this unit level in BOSS XML file

UnitLevelnext
 pointer to finer unit level e.g. from Word to Syllable or from Syllable to Phone

vector< PSA_VectorattrMatrix
 matrix of PreSelAttr

DOM_UserData::Node_Type nodeType
string preselectionFileFlag
 a command line option flag pointing to file with preselection queries


Detailed Description

Data structure holding attributes of one speech unit level (word, syllable, etc.).

Author:
Michal Holcik

Todo:
This class may need renaming, I'm not sure if the name sufficiently describes what it represents


Constructor & Destructor Documentation

UnitLevel::UnitLevel BOSS::Config config,
string  levelName,
string  elementTag,
DOM_UserData::Node_Type  type,
string  fileFlag,
UnitLevel nextLevel
[inline]
 

Constructs a UnitLevel.

Parameters:
config system wide configuration container
levelName level name
elementTag name of the xml element containing data of this unit level
fileFlag commandline option switch to set a name of a file containing preselection attributes
nextLevel pointer to finer unit level


Member Function Documentation

int UnitLevel::checkMatrixSize  ) 
 

Returns the total size of attrMatrix of this and lower unit levels.

Returns:
sum of attribute matrices' sizes

vector< PSA_Vector > UnitLevel::getAttrMatrix  )  [inline]
 

Returns attribute matrix.

Returns:
attribute matrix

string UnitLevel::getName  )  [inline]
 

Returns unit level name.

Returns:
level name

UnitLevel* UnitLevel::getNextLevel  )  [inline]
 

Returns pointer to lower unit level e.g. Word -> Syllable.

Returns:
pointer to finer unit level

DOM_UserData::Node_Type UnitLevel::getNodeType  )  [inline]
 

Returns node type.

Returns:
node type

string UnitLevel::getTag  )  [inline]
 

Returns unit level tag.

Returns:
level name

bool UnitLevel::isComment const string &  s  )  [private]
 

Decides if the argument string is a comment.

Parameters:
s - an input string
Returns:
true if the input line is a comment, false otherwise

void UnitLevel::loadPreSelFile const string &  file,
vector< PSA_Vector > &  ps
[private]
 

Parses the file with preselection arguments and stores them in the ps PSA_Vector.

Parameters:
file filename to load preselection attributes from
ps vector to store the loaded preselection attributes vectors

void UnitLevel::loadPreSelQueries  )  [private]
 

Loads preselection queries for a unit level.


Member Data Documentation

vector< PSA_Vector > UnitLevel::attrMatrix [private]
 

matrix of PreSelAttr

BOSS::Config& UnitLevel::cl [private]
 

configuration class storing system wide settings

string UnitLevel::name [private]
 

name of this unit level

UnitLevel* UnitLevel::next [private]
 

pointer to finer unit level e.g. from Word to Syllable or from Syllable to Phone

DOM_UserData::Node_Type UnitLevel::nodeType [private]
 

string UnitLevel::preselectionFileFlag [private]
 

a command line option flag pointing to file with preselection queries

string UnitLevel::tag [private]
 

name of tag of this unit level in BOSS XML file


The documentation for this class was generated from the following files:
Generated on Tue Dec 20 23:14:41 2005 for BOSS by doxygen 1.3.6