#include <LabelSet.h>


Public Member Functions | |
| LabelSet () | |
| LabelSet (const FileName &, const Config &) | |
| LabelSet (const LabelSet &) | |
| const LabelSet & | operator= (const LabelSet &) |
| bool | operator== (const LabelSet &) |
| bool | operator!= (const LabelSet &) |
| virtual | ~LabelSet () |
| void | load (const FileName &f, const Config &c) |
| void | addLabel (real_t b, real_t e, const String &n) |
| const String & | getName (unsigned long i) const |
| real_t | getBegin (unsigned long index) const |
| real_t | getEnd (unsigned long index) const |
| unsigned long | size () const |
| void | clear () |
| virtual String | toString () const |
| virtual String | getClassName () const |
Private Attributes | |
| RefVector< String > | _nameVect |
| DoubleVector | _beginVect |
| DoubleVector | _endVect |
Friends | |
| class | TestLabelSet |
This class represents a set of labels. Each label got a name, a begin value and a end value
Definition at line 85 of file LabelSet.h.
| LabelSet::LabelSet | ( | ) |
Create a LabelSet object
Definition at line 67 of file LabelSet.cpp.
Definition at line 70 of file LabelSet.cpp.
References load().
| LabelSet::LabelSet | ( | const LabelSet & | s ) |
Definition at line 73 of file LabelSet.cpp.
References _nameVect, alize::RefVector< T >::addObject(), alize::String::duplicate(), getName(), and alize::RefVector< T >::size().
| LabelSet::~LabelSet | ( | ) | [virtual] |
Definition at line 152 of file LabelSet.cpp.
References _nameVect, and alize::RefVector< T >::deleteAllObjects().
Adds a new line to the list
| b | the begin value in seconds |
| e | the end value in seconds |
| n | the name of the label |
Definition at line 104 of file LabelSet.cpp.
References _beginVect, _endVect, _nameVect, alize::RefVector< T >::addObject(), alize::RealVector< T >::addValue(), and alize::String::duplicate().
| void LabelSet::clear | ( | ) |
Clears the set.
Definition at line 145 of file LabelSet.cpp.
References _beginVect, _endVect, _nameVect, alize::RealVector< T >::clear(), and alize::RefVector< T >::deleteAllObjects().
| real_t LabelSet::getBegin | ( | unsigned long | index ) | const |
Gets the begin value of the line i
| i | the index of the line |
| IndexOutOfBoundsException |
Definition at line 123 of file LabelSet.cpp.
References _beginVect.
| String LabelSet::getClassName | ( | ) | const [virtual] |
Returns the name of the class
Implements alize::Object.
Definition at line 129 of file LabelSet.cpp.
| real_t LabelSet::getEnd | ( | unsigned long | index ) | const |
Gets the end value of the line i
| i | the index of the line |
| IndexOutOfBoundsException |
Definition at line 126 of file LabelSet.cpp.
References _endVect.
| const String & LabelSet::getName | ( | unsigned long | i ) | const |
Gets the label of the line i
| i | the index of the line |
| IndexOutOfBoundsException |
Definition at line 117 of file LabelSet.cpp.
References _nameVect, and alize::RefVector< T >::getObject().
Referenced by LabelSet(), operator=(), operator==(), and toString().
Load a set of labels from a file
| f | the file to read |
| c | the configuration to use |
| IOException | if an I/O error occurs |
| FileNotFoundException |
Definition at line 111 of file LabelSet.cpp.
References alize::LabelFileReader::readLabels().
Referenced by LabelSet().
| bool LabelSet::operator!= | ( | const LabelSet & | s ) |
Definition at line 102 of file LabelSet.cpp.
Definition at line 80 of file LabelSet.cpp.
References _beginVect, _endVect, _nameVect, alize::RefVector< T >::addObject(), alize::String::duplicate(), getName(), and alize::RefVector< T >::size().
| bool LabelSet::operator== | ( | const LabelSet & | s ) |
Definition at line 89 of file LabelSet.cpp.
References _beginVect, _endVect, _nameVect, getName(), and alize::RefVector< T >::size().
| unsigned long LabelSet::size | ( | ) | const |
Gets the number of labels in the set
Definition at line 131 of file LabelSet.cpp.
References _nameVect, and alize::RefVector< T >::size().
Referenced by toString().
| String LabelSet::toString | ( | ) | const [virtual] |
This method is frequently overridden in the derived classes. If it is not, it returns the name of the class of the object and the address of the object
Reimplemented from alize::Object.
Definition at line 133 of file LabelSet.cpp.
References _beginVect, _endVect, getName(), size(), and alize::String::valueOf().
friend class TestLabelSet [friend] |
Definition at line 87 of file LabelSet.h.
DoubleVector alize::LabelSet::_beginVect [private] |
Definition at line 153 of file LabelSet.h.
Referenced by addLabel(), clear(), getBegin(), operator=(), operator==(), and toString().
DoubleVector alize::LabelSet::_endVect [private] |
Definition at line 154 of file LabelSet.h.
Referenced by addLabel(), clear(), getEnd(), operator=(), operator==(), and toString().
RefVector<String> alize::LabelSet::_nameVect [private] |
Definition at line 152 of file LabelSet.h.
Referenced by addLabel(), clear(), getName(), LabelSet(), operator=(), operator==(), size(), and ~LabelSet().
1.7.2