SciDAVis
1.D4
|
Aspect that manages a column. More...
#include <Column.h>
Classes | |
class | Private |
Private data class of Column. More... |
Public Member Functions | |
ColumnStringIO * | asStringColumn () const |
Return a wrapper column object used for String I/O. | |
void | clear () |
Clear the whole column. | |
Column (const QString &name, SciDAVis::ColumnMode mode) | |
Ctor. | |
Column (const QString &name, QVector< qreal > data, IntervalAttribute< bool > validity=IntervalAttribute< bool >()) | |
Ctor. | |
Column (const QString &name, QStringList data, IntervalAttribute< bool > validity=IntervalAttribute< bool >()) | |
Ctor. | |
Column (const QString &name, QList< QDateTime > data, IntervalAttribute< bool > validity=IntervalAttribute< bool >()) | |
Ctor. | |
SciDAVis::ColumnMode | columnMode () const |
Return the column mode. | |
bool | copy (const AbstractColumn *other) |
Copy another column of the same type. | |
bool | copy (const AbstractColumn *source, int source_start, int dest_start, int num_rows) |
Copies a part of another column of the same type. | |
SciDAVis::ColumnDataType | dataType () const |
Return the data type of the column. | |
void | insertRows (int before, int count) |
Insert some empty (or initialized with zero) rows. | |
bool | isReadOnly () const |
Return whether the object is read-only. | |
void | notifyReplacement (const AbstractColumn *replacement) |
This must be called before the column is replaced by another. | |
AbstractSimpleFilter * | outputFilter () const |
Return the output filter (for data type -> string conversion) | |
SciDAVis::PlotDesignation | plotDesignation () const |
Return the column plot designation. | |
void | removeRows (int first, int count) |
Remove 'count' rows starting from row 'first'. | |
int | rowCount () const |
Return the data vector size. | |
void | setColumnMode (SciDAVis::ColumnMode mode, AbstractFilter *conversion_filter=0) |
Set the column mode. | |
void | setPlotDesignation (SciDAVis::PlotDesignation pd) |
Set the column plot designation. | |
~Column () | |
Dtor. | |
aspect related functions | |
virtual QIcon | icon () const |
Return an icon to be used for decorating the views and table column headers. | |
IntervalAttribute related functions | |
bool | isInvalid (int row) const |
Return whether a certain row contains an invalid value. | |
bool | isInvalid (Interval< int > i) const |
Return whether a certain interval of rows contains only invalid values. | |
QList< Interval< int > > | invalidIntervals () const |
Return all intervals of invalid rows. | |
bool | isMasked (int row) const |
Return whether a certain row is masked. | |
bool | isMasked (Interval< int > i) const |
Return whether a certain interval of rows rows is fully masked. | |
QList< Interval< int > > | maskedIntervals () const |
Return all intervals of masked rows. | |
void | clearValidity () |
Clear all validity information. | |
void | clearMasks () |
Clear all masking information. | |
void | setInvalid (Interval< int > i, bool invalid=true) |
Set an interval invalid or valid. | |
void | setInvalid (int row, bool invalid=true) |
Overloaded function for convenience. | |
void | setMasked (Interval< int > i, bool mask=true) |
Set an interval masked. | |
void | setMasked (int row, bool mask=true) |
Overloaded function for convenience. | |
Formula related functions | |
QString | formula (int row) const |
Return the formula associated with row 'row'. | |
QList< Interval< int > > | formulaIntervals () const |
Return the intervals that have associated formulas. | |
void | setFormula (Interval< int > i, QString formula) |
Set a formula string for an interval of rows. | |
void | setFormula (int row, QString formula) |
Overloaded function for convenience. | |
void | clearFormulas () |
Clear all formulas. | |
type specific functions | |
QString | textAt (int row) const |
Return the content of row 'row'. | |
void | setTextAt (int row, const QString &new_value) |
Set the content of row 'row'. | |
void | replaceTexts (int first, const QStringList &new_values) |
Replace a range of values. | |
QDate | dateAt (int row) const |
Return the date part of row 'row'. | |
void | setDateAt (int row, const QDate &new_value) |
Set the content of row 'row'. | |
QTime | timeAt (int row) const |
Return the time part of row 'row'. | |
void | setTimeAt (int row, const QTime &new_value) |
Set the content of row 'row'. | |
QDateTime | dateTimeAt (int row) const |
Return the QDateTime in row 'row'. | |
void | setDateTimeAt (int row, const QDateTime &new_value) |
Set the content of row 'row'. | |
void | replaceDateTimes (int first, const QList< QDateTime > &new_values) |
Replace a range of values. | |
double | valueAt (int row) const |
Return the double value in row 'row'. | |
void | setValueAt (int row, double new_value) |
Set the content of row 'row'. | |
virtual void | replaceValues (int first, const QVector< qreal > &new_values) |
Replace a range of values. | |
Public Member Functions inherited from AbstractColumn | |
AbstractColumn (const QString &name) | |
Ctor. | |
virtual void | setColumnMode (SciDAVis::ColumnMode mode) |
Set the column mode. | |
virtual | ~AbstractColumn () |
Dtor. | |
virtual void | replaceValues (int first, const QVector< double > &new_values) |
Set the content of row 'row'. | |
Public Member Functions inherited from AbstractAspect | |
AbstractAspect (const QString &name) | |
void | addChild (AbstractAspect *child) |
Add the given Aspect to my list of children. | |
QString | caption () const |
QString | captionSpec () const |
Return the specification string used for constructing the caption(). | |
AbstractAspect * | child (int index) const |
Get a child by its position in my list of children. | |
int | childCount () const |
Return the number of child Aspects. | |
QString | comment () const |
virtual QMenu * | createContextMenu () const |
Return a new context menu. | |
QDateTime | creationTime () const |
QList< AbstractAspect * > | descendantsThatInherit (const char *class_name) |
Get all descendents that inherit the given class. | |
future::Folder * | folder () |
Return the folder the Aspect is contained in or 0 if not. | |
void | importV0x0001XXCreationTime (const QString &str) |
int | index () const |
Return my position in my parent's list of children. | |
int | indexOfChild (const AbstractAspect *child) const |
Return the position of child in my list of children. | |
void | insertChild (AbstractAspect *child, int index) |
Insert the given Aspect at a specific position in my list of children. | |
bool | isDescendantOf (AbstractAspect *other) |
Return whether the there is a path upwards to the given aspect. | |
void | moveChild (int from, int to) |
Change the positon of a child in my list of children. | |
QString | name () const |
AbstractAspect * | parentAspect () const |
Return my parent Aspect or 0 if I currently don't have one. | |
virtual QString | path () const |
Return the path that leads from the top-most Aspect (usually a Project) to me. | |
virtual const Project * | project () const |
Return the Project this Aspect belongs to, or 0 if it is currently not part of one. | |
virtual Project * | project () |
Return the Project this Aspect belongs to, or 0 if it is currently not part of one. | |
virtual void | removeAllChildAspects () |
Remove all child aspects. | |
void | removeChild (AbstractAspect *child, bool detach=false) |
Remove the given Aspect from my list of children. | |
void | removeChild (int index) |
Remove the Aspect at the given index from my list of children. | |
void | reparentChild (AbstractAspect *new_parent, AbstractAspect *child, int d_new_index) |
Move a child to another aspect and transfer ownership. | |
void | reparentChild (AbstractAspect *new_parent, AbstractAspect *child) |
Move a child to another aspect and transfer ownership. | |
virtual | ~AbstractAspect () |
virtual QUndoStack * | undoStack () const |
Return the undo stack of the Project, or 0 if this Aspect is not part of a Project. | |
void | exec (QUndoCommand *command) |
Execute the given command, pushing it on the undoStack() if available. | |
void | beginMacro (const QString &text) |
Begin an undo stack macro (series of commands) | |
void | endMacro () |
End the undo stack macro. |
Private Slots | |
void | notifyDisplayChange () |
Private Attributes | |
Private * | d_column_private |
Pointer to the private data object. | |
ColumnStringIO * | d_string_io |
Friends | |
class | ColumnStringIO |
class | Private |
XML related functions | |
void | save (QXmlStreamWriter *writer) const |
Save the column as XML. | |
bool | load (XmlStreamReader *reader) |
Load the column from XML. | |
bool | XmlReadInputFilter (XmlStreamReader *reader) |
Read XML input filter element. | |
bool | XmlReadOutputFilter (XmlStreamReader *reader) |
Read XML output filter element. | |
bool | XmlReadMask (XmlStreamReader *reader) |
Read XML mask element. | |
bool | XmlReadFormula (XmlStreamReader *reader) |
Read XML formula element. | |
bool | XmlReadRow (XmlStreamReader *reader) |
Read XML row element. |
Additional Inherited Members | |
Signals inherited from AbstractColumn | |
void | aboutToBeDestroyed (const AbstractColumn *source) |
Emitted shortly before this data source is deleted. | |
void | aboutToBeReplaced (const AbstractColumn *source, const AbstractColumn *new_col) |
The column will be replaced. | |
void | dataAboutToChange (const AbstractColumn *source) |
Data (including validity) of the column will be changed. | |
void | dataChanged (const AbstractColumn *source) |
Data (including validity) of the column has changed. | |
void | maskingAboutToChange (const AbstractColumn *source) |
IntervalAttribute related signal. | |
void | maskingChanged (const AbstractColumn *source) |
IntervalAttribute related signal. | |
void | modeAboutToChange (const AbstractColumn *source) |
Column mode (possibly also the data type) will be changed. | |
void | modeChanged (const AbstractColumn *source) |
Column mode (possibly also the data type) changed. | |
void | plotDesignationAboutToChange (const AbstractColumn *source) |
Column plot designation will be changed. | |
void | plotDesignationChanged (const AbstractColumn *source) |
Column plot designation changed. | |
void | rowsAboutToBeInserted (const AbstractColumn *source, int before, int count) |
Rows will be inserted. | |
void | rowsAboutToBeRemoved (const AbstractColumn *source, int first, int count) |
Rows will be deleted. | |
void | rowsInserted (const AbstractColumn *source, int before, int count) |
Rows have been inserted. | |
void | rowsRemoved (const AbstractColumn *source, int first, int count) |
Rows have been deleted. | |
Signals inherited from AbstractAspect | |
void | aspectAboutToBeAdded (const AbstractAspect *parent, int index) |
Emit this when a parent aspect is about to get a new child inserted. | |
void | aspectAboutToBeRemoved (const AbstractAspect *aspect) |
Emit this from an aspect about to be removed from its parent's children. | |
void | aspectAboutToBeRemoved (const AbstractAspect *parent, int index) |
Emit this from a parent before removing its child. | |
void | aspectAdded (const AbstractAspect *aspect) |
Emit this from a newly added aspect. | |
void | aspectAdded (const AbstractAspect *parent, int index) |
Emit this from a parent after adding a new child to it. | |
void | aspectDescriptionAboutToChange (const AbstractAspect *aspect) |
Emit this before the name, comment or caption spec is changed. | |
void | aspectDescriptionChanged (const AbstractAspect *aspect) |
Emit this when the name, comment or caption spec changed. | |
void | aspectRemoved (const AbstractAspect *parent, int index) |
Emit this from the parent after removing a child. | |
void | statusInfo (const QString &text) |
Emit this to give status information to the user. |
Aspect that manages a column.
This class represents a column, i.e., (mathematically) a 1D vector of values with a header. It provides a public reading and (undo aware) writing interface as defined in AbstractColumn. It manages special attributes of column rows such as masking and a validity flag. A column can have one of currently three data types: double, QString, or QDateTime. The string representation of the values can differ depending on the mode of the column.
Column inherits from AbstractAspect and is intended to be a child of the corresponding Table in the aspect hierarchy. Columns don't have a view as they are intended to be displayed inside a table.
Column::Column | ( | const QString & | name, |
SciDAVis::ColumnMode | mode | ||
) |
Ctor.
name | the column name (= aspect name) |
mode | initial column mode |
References AbstractAspect::addChild(), ColumnStringIO, d_column_private, d_string_io, AbstractFilter::input(), Column::Private::inputFilter(), outputFilter(), and Private.
Referenced by Column::Private::setColumnMode().
Column::Column | ( | const QString & | name, |
QVector< qreal > | data, | ||
IntervalAttribute< bool > | validity = IntervalAttribute<bool>() |
||
) |
Ctor.
name | the column name (= aspect name) |
data | initial data vector |
validity | a list of invalid intervals (optional) |
References AbstractAspect::addChild(), ColumnStringIO, d_column_private, d_string_io, AbstractFilter::input(), Column::Private::inputFilter(), SciDAVis::Numeric, outputFilter(), Private, and SciDAVis::TypeDouble.
Column::Column | ( | const QString & | name, |
QStringList | data, | ||
IntervalAttribute< bool > | validity = IntervalAttribute<bool>() |
||
) |
Ctor.
name | the column name (= aspect name) |
data | initial data vector |
validity | a list of invalid intervals (optional) |
References AbstractAspect::addChild(), ColumnStringIO, d_column_private, d_string_io, AbstractFilter::input(), Column::Private::inputFilter(), outputFilter(), Private, SciDAVis::Text, and SciDAVis::TypeQString.
Column::Column | ( | const QString & | name, |
QList< QDateTime > | data, | ||
IntervalAttribute< bool > | validity = IntervalAttribute<bool>() |
||
) |
Ctor.
name | the column name (= aspect name) |
data | initial data vector |
validity | a list of invalid intervals (optional) |
References AbstractAspect::addChild(), ColumnStringIO, d_column_private, d_string_io, SciDAVis::DateTime, AbstractFilter::input(), Column::Private::inputFilter(), outputFilter(), Private, and SciDAVis::TypeQDateTime.
Column::~Column | ( | ) |
Dtor.
References d_column_private, and d_string_io.
|
inline |
Return a wrapper column object used for String I/O.
References d_string_io.
Referenced by future::Table::clearSelectedCells(), TableModel::data(), future::Table::export_to_TeX(), Table::exportASCII(), Table::importASCII(), future::Table::pasteIntoSelection(), Table::recalculate(), TableModel::setData(), Table::setText(), and Table::text().
|
virtual |
Clear the whole column.
Reimplemented from AbstractColumn.
References d_column_private, and AbstractAspect::exec().
Referenced by future::Table::clear(), future::Table::clearSelectedColumns(), and MuParserScript::resolveColumnPath().
|
virtual |
Clear all formulas.
Reimplemented from AbstractColumn.
References d_column_private, and AbstractAspect::exec().
Referenced by future::Table::clearSelectedColumns(), and load().
|
virtual |
Clear all masking information.
Reimplemented from AbstractColumn.
References d_column_private, and AbstractAspect::exec().
Referenced by future::Table::clearMasks(), and load().
|
virtual |
Clear all validity information.
Reimplemented from AbstractColumn.
References d_column_private, and AbstractAspect::exec().
Referenced by load().
|
virtual |
Return the column mode.
This function is most used by tables but can also be used by plots. The column mode specifies how to interpret the values in the column additional to the data type.
Implements AbstractColumn.
References Column::Private::columnMode(), and d_column_private.
Referenced by TableView::applyType(), Table::cell(), Table::columnFormat(), Table::columnType(), Table::columnTypes(), DataCurve::convertData(), future::Table::copy(), future::Table::fillSelectedCellsWithRandomNumbers(), future::Table::fillSelectedCellsWithRowNumbers(), ApplicationWindow::importASCII(), Graph::plotHistogram(), Table::recalculate(), save(), Table::saveColumnTypes(), TableView::setColumnForControlTabs(), setColumnMode(), future::Table::sortColumns(), TableStatistics::update(), and Graph::updateCurvesData().
|
virtual |
Copy another column of the same type.
This function will return false if the data type of 'other' is not the same as the type of 'this'. The validity information for the rows is also copied. Use a filter to convert a column to another type.
Reimplemented from AbstractColumn.
References d_column_private, AbstractColumn::dataType(), dataType(), and AbstractAspect::exec().
Referenced by future::Table::copy(), ColumnStringIO::copy(), Table::importASCII(), ApplicationWindow::importASCII(), AsciiTableImportFilter::importAspect(), ColumnFullCopyCmd::redo(), ColumnPartialCopyCmd::redo(), ColumnRemoveRowsCmd::redo(), Column::Private::setColumnMode(), ColumnStringIO::setTextAt(), and future::Table::sortColumns().
|
virtual |
Copies a part of another column of the same type.
This function will return false if the data type of 'other' is not the same as the type of 'this'. The validity information for the rows is also copied.
other | pointer to the column to copy |
src_start | first row to copy in the column to copy |
dest_start | first row to copy in |
num_rows | the number of rows to copy |
Reimplemented from AbstractColumn.
References d_column_private, AbstractColumn::dataType(), dataType(), and AbstractAspect::exec().
|
virtual |
Return the data type of the column.
Implements AbstractColumn.
References d_column_private, and Column::Private::dataType().
Referenced by Column::Private::copy(), copy(), future::Table::copySelection(), ApplicationWindow::defineErrorBars(), icon(), ApplicationWindow::importASCII(), load(), future::Table::normalizeColumns(), future::Table::normalizeSelection(), save(), future::Table::sortColumns(), and XmlReadRow().
|
virtual |
Return the date part of row 'row'.
Use this only when dataType() is QDateTime
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::dateAt().
Referenced by DataCurve::convertData(), setTimeAt(), and Column::Private::setTimeAt().
|
virtual |
Return the QDateTime in row 'row'.
Use this only when dataType() is QDateTime
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::dateTimeAt().
Referenced by DataCurve::convertData(), Column::Private::dateAt(), future::Table::fillSelectedCellsWithRandomNumbers(), save(), future::Table::sortColumns(), and Column::Private::timeAt().
|
virtual |
Return the formula associated with row 'row'.
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::formula().
Referenced by future::Table::copy(), future::Table::copySelection(), TableModel::data(), Table::handleAspectDescriptionChange(), Table::recalculate(), save(), Table::saveCommands(), and TableView::setColumnForControlTabs().
|
virtual |
Return the intervals that have associated formulas.
This can be used to make a list of formulas with their intervals. Here is some example code:
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::formulaIntervals().
Referenced by future::Table::copy(), Table::handleAspectDescriptionChange(), Table::recalculate(), and save().
|
virtual |
Return an icon to be used for decorating the views and table column headers.
Reimplemented from AbstractAspect.
References dataType(), SciDAVis::TypeDouble, SciDAVis::TypeQDateTime, and SciDAVis::TypeQString.
|
virtual |
Insert some empty (or initialized with zero) rows.
Reimplemented from AbstractColumn.
References d_column_private, and AbstractAspect::exec().
Referenced by Table::applyFormula(), and future::Table::insertRows().
|
virtual |
Return all intervals of invalid rows.
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::invalidIntervals().
|
virtual |
Return whether a certain row contains an invalid value.
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::isInvalid().
Referenced by Graph3D::addData(), Table::cell(), DataCurve::convertData(), TableModel::data(), ColumnStringIO::isInvalid(), QwtHistogram::loadData(), QwtPieCurve::loadData(), BoxCurve::loadData(), Graph::plotPie(), save(), TranslateCurveTool::selectDestination(), Graph::setLabelsTextFormat(), MuParserScript::tableCell_Function(), MuParserScript::tableCellFunction(), MuParserScript::tableColumn__Function(), MuParserScript::tableColumn_Function(), MuParserScript::tableColumnFunction(), future::Table::text(), TableStatistics::update(), Graph3D::updateDataXY(), Graph3D::updateDataXYZ(), and Graph3D::updateScales().
|
virtual |
Return whether a certain interval of rows contains only invalid values.
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::isInvalid().
|
virtual |
Return whether a certain row is masked.
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::isMasked().
Referenced by TableModel::data(), and future::Table::sortColumns().
|
virtual |
Return whether a certain interval of rows rows is fully masked.
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::isMasked().
|
inlinevirtual |
Return whether the object is read-only.
Reimplemented from AbstractColumn.
|
virtual |
Load the column from XML.
Reimplemented from AbstractAspect.
References clearFormulas(), clearMasks(), clearValidity(), dataType(), SciDAVis::enumStringToValue(), SciDAVis::noDesignation, XmlStreamReader::raiseError(), XmlStreamReader::raiseWarning(), AbstractAspect::readBasicAttributes(), AbstractAspect::readCommentElement(), removeRows(), rowCount(), setColumnMode(), AbstractAspect::setComment(), setPlotDesignation(), XmlStreamReader::skipToEndElement(), XmlReadFormula(), XmlReadInputFilter(), XmlReadMask(), XmlReadOutputFilter(), and XmlReadRow().
Referenced by future::Table::load(), and future::Folder::readChildAspectElement().
|
virtual |
Return all intervals of masked rows.
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::maskedIntervals().
Referenced by future::Table::copy(), and save().
|
privateslot |
References AbstractAspect::aspectDescriptionChanged(), and AbstractColumn::dataChanged().
Referenced by Column::Private::Private(), Column::Private::replaceModeData(), and Column::Private::setColumnMode().
|
virtual |
This must be called before the column is replaced by another.
Reimplemented from AbstractColumn.
References AbstractColumn::aboutToBeReplaced().
AbstractSimpleFilter * Column::outputFilter | ( | ) | const |
Return the output filter (for data type -> string conversion)
This method is mainly used to get a filter that can convert the column's data type to strings (usualy to display in a view).
References d_column_private, and Column::Private::outputFilter().
Referenced by TableView::applyType(), Column(), Table::columnFormat(), DataCurve::convertData(), future::Table::copySelection(), ImportOPJ::importTables(), save(), TableView::setColumnForControlTabs(), Column::Private::setColumnMode(), setColumnMode(), TableStatistics::TableStatistics(), future::Table::text(), and XmlReadOutputFilter().
|
virtual |
Return the column plot designation.
Implements AbstractColumn.
References d_column_private, and Column::Private::plotDesignation().
Referenced by Table::colPlotDesignation(), future::Table::copy(), Table::drawableColumnSelection(), Table::firstXCol(), ColumnStringIO::plotDesignation(), Table::plotDesignations(), save(), Table::saveHeader(), TableView::selectedColumnCount(), Table::selectedErrColumns(), Table::selectedYColumns(), Table::selectedYLabels(), setPlotDesignation(), and Table::YColumns().
|
virtual |
Remove 'count' rows starting from row 'first'.
Reimplemented from AbstractColumn.
References d_column_private, and AbstractAspect::exec().
Referenced by Column::Private::clear(), future::Table::clearSelectedCells(), load(), future::Table::removeRows(), and future::Table::setRowCount().
|
virtual |
Replace a range of values.
Use this only when dataType() is QDateTime
Reimplemented from AbstractColumn.
References d_column_private, and AbstractAspect::exec().
Referenced by future::Table::fillSelectedCellsWithRandomNumbers().
|
virtual |
Replace a range of values.
Use this only when dataType() is QString
Reimplemented from AbstractColumn.
References d_column_private, and AbstractAspect::exec().
Referenced by future::Table::fillSelectedCellsWithRandomNumbers(), and future::Table::fillSelectedCellsWithRowNumbers().
|
virtual |
Replace a range of values.
Use this only when dataType() is double
References d_column_private, and AbstractAspect::exec().
Referenced by future::Table::fillSelectedCellsWithRandomNumbers(), future::Table::fillSelectedCellsWithRowNumbers(), future::Table::normalizeColumns(), future::Table::normalizeSelection(), and Table::recalculate().
|
virtual |
Return the data vector size.
This returns the number of rows that actually contain data. Rows beyond this can be masked etc. but should be ignored by filters, plots etc.
Implements AbstractColumn.
References d_column_private, and Column::Private::rowCount().
Referenced by Table::applyFormula(), Column::Private::clear(), future::Table::clearSelectedCells(), DataCurve::convertData(), Column::Private::copy(), ApplicationWindow::defineErrorBars(), ApplicationWindow::importASCII(), Column::Private::insertRows(), load(), QwtHistogram::loadData(), QwtPieCurve::loadData(), BoxCurve::loadData(), future::Table::normalizeColumns(), future::Table::normalizeSelection(), Graph::plotPie(), Table::recalculate(), Column::Private::removeRows(), Column::Private::replaceDateTimes(), Column::Private::replaceTexts(), Column::Private::replaceValues(), Column::Private::resizeTo(), ColumnStringIO::rowCount(), save(), Column::Private::setDateTimeAt(), Graph::setLabelsTextFormat(), future::Table::setRowCount(), Column::Private::setTextAt(), Column::Private::setValueAt(), future::Table::sortColumns(), and TableStatistics::update().
|
virtual |
Save the column as XML.
Reimplemented from AbstractAspect.
References columnMode(), d_column_private, dataType(), dateTimeAt(), IntervalBase< T >::end(), SciDAVis::enumValueToString(), formula(), formulaIntervals(), Column::Private::inputFilter(), isInvalid(), maskedIntervals(), outputFilter(), plotDesignation(), rowCount(), AbstractSimpleFilter::save(), IntervalBase< T >::start(), textAt(), SciDAVis::TypeDouble, SciDAVis::TypeQDateTime, SciDAVis::TypeQString, valueAt(), AbstractAspect::writeBasicAttributes(), and AbstractAspect::writeCommentElement().
Referenced by future::Table::save().
void Column::setColumnMode | ( | SciDAVis::ColumnMode | mode, |
AbstractFilter * | conversion_filter = 0 |
||
) |
Set the column mode.
This sets the column mode and, if necessary, converts it to another datatype.
References AbstractAspect::addChild(), AbstractAspect::beginMacro(), columnMode(), d_column_private, d_string_io, AbstractAspect::endMacro(), AbstractAspect::exec(), AbstractFilter::input(), Column::Private::inputFilter(), AbstractAspect::name(), outputFilter(), and AbstractAspect::removeChild().
Referenced by TableView::applyType(), ImportOPJ::importTables(), load(), Fit::parametersTable(), Table::setColumnType(), and Table::setColumnTypes().
void Column::setDateAt | ( | int | row, |
const QDate & | new_value | ||
) |
Set the content of row 'row'.
Use this only when dataType() is QDateTime
References setDateTimeAt(), and timeAt().
void Column::setDateTimeAt | ( | int | row, |
const QDateTime & | new_value | ||
) |
Set the content of row 'row'.
Use this only when dataType() is QDateTime
References d_column_private, and AbstractAspect::exec().
Referenced by Table::clearCell(), setDateAt(), Column::Private::setDateAt(), setTimeAt(), Column::Private::setTimeAt(), and XmlReadRow().
void Column::setFormula | ( | Interval< int > | i, |
QString | formula | ||
) |
Set a formula string for an interval of rows.
References d_column_private, and AbstractAspect::exec().
Referenced by Table::applyFormula(), future::Table::clearSelectedCells(), future::Table::copy(), Table::handleAspectDescriptionChange(), ImportOPJ::importTables(), future::Table::pasteIntoSelection(), Table::setCommand(), Table::setCommands(), TableModel::setData(), setFormula(), Column::Private::setFormula(), and XmlReadFormula().
void Column::setFormula | ( | int | row, |
QString | formula | ||
) |
Overloaded function for convenience.
References setFormula().
void Column::setInvalid | ( | Interval< int > | i, |
bool | invalid = true |
||
) |
Set an interval invalid or valid.
i | the interval |
invalid | true: set invalid, false: set valid |
References d_column_private, and AbstractAspect::exec().
Referenced by Table::clearCell(), future::Table::pasteIntoSelection(), DataPickerTool::removePoint(), setInvalid(), Column::Private::setInvalid(), TableStatistics::update(), and XmlReadRow().
void Column::setInvalid | ( | int | row, |
bool | invalid = true |
||
) |
Overloaded function for convenience.
References setInvalid().
void Column::setMasked | ( | Interval< int > | i, |
bool | mask = true |
||
) |
Set an interval masked.
i | the interval |
mask | true: mask, false: unmask |
References d_column_private, and AbstractAspect::exec().
Referenced by future::Table::copy(), future::Table::maskSelection(), setMasked(), Column::Private::setMasked(), future::Table::sortColumns(), future::Table::unmaskSelection(), and XmlReadMask().
void Column::setMasked | ( | int | row, |
bool | mask = true |
||
) |
Overloaded function for convenience.
References setMasked().
void Column::setPlotDesignation | ( | SciDAVis::PlotDesignation | pd | ) |
Set the column plot designation.
References d_column_private, AbstractAspect::exec(), and plotDesignation().
Referenced by Filter::addResultCurve(), LineProfileTool::calculateLineProfile(), future::Table::copy(), Graph::createTable(), ApplicationWindow::defineErrorBars(), Table::importASCII(), ApplicationWindow::importASCII(), AsciiTableImportFilter::importAspect(), Table::importV0x0001XXHeader(), future::Table::insertEmptyColumns(), load(), Differentiation::output(), Fit::parametersTable(), future::Table::pasteIntoSelection(), Table::setColPlotDesignation(), future::Table::setColumnCount(), future::Table::setSelectionAs(), and future::Table::Table().
void Column::setTextAt | ( | int | row, |
const QString & | new_value | ||
) |
Set the content of row 'row'.
Use this only when dataType() is QString
References d_column_private, and AbstractAspect::exec().
Referenced by Table::clearCell(), ImportOPJ::importTables(), Fit::parametersTable(), TableStatistics::renameCol(), TableStatistics::update(), and XmlReadRow().
void Column::setTimeAt | ( | int | row, |
const QTime & | new_value | ||
) |
Set the content of row 'row'.
Use this only when dataType() is QDateTime
References dateAt(), and setDateTimeAt().
void Column::setValueAt | ( | int | row, |
double | new_value | ||
) |
Set the content of row 'row'.
Use this only when dataType() is double
References d_column_private, and AbstractAspect::exec().
Referenced by Correlation::addResultCurve(), Convolution::addResultCurve(), Filter::addResultCurve(), LineProfileTool::calculateLineProfile(), Table::clearCell(), Graph::createTable(), ApplicationWindow::defineErrorBars(), DataPickerTool::end(), ImportOPJ::importTables(), Differentiation::output(), Fit::parametersTable(), DataPickerTool::removePoint(), TranslateCurveTool::selectDestination(), Table::setCell(), PlotDialog::showStatistics(), TableStatistics::update(), and XmlReadRow().
|
virtual |
Return the content of row 'row'.
Use this only when dataType() is QString
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::textAt().
Referenced by Table::cell(), future::Table::fillSelectedCellsWithRandomNumbers(), future::Table::fillSelectedCellsWithRowNumbers(), QwtHistogram::loadData(), QwtPieCurve::loadData(), BoxCurve::loadData(), Graph::plotPie(), save(), Graph::setLabelsTextFormat(), and future::Table::sortColumns().
|
virtual |
Return the time part of row 'row'.
Use this only when dataType() is QDateTime
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::timeAt().
Referenced by DataCurve::convertData(), setDateAt(), and Column::Private::setDateAt().
|
virtual |
Return the double value in row 'row'.
Reimplemented from AbstractColumn.
References d_column_private, and Column::Private::valueAt().
Referenced by Table::cell(), future::Table::copySelection(), ApplicationWindow::defineErrorBars(), future::Table::fillSelectedCellsWithRandomNumbers(), future::Table::fillSelectedCellsWithRowNumbers(), QwtHistogram::loadData(), QwtPieCurve::loadData(), BoxCurve::loadData(), future::Table::normalizeColumns(), future::Table::normalizeSelection(), Graph::plotPie(), save(), future::Table::sortColumns(), MuParserScript::tableCell_Function(), MuParserScript::tableCellFunction(), MuParserScript::tableColumn__Function(), MuParserScript::tableColumn_Function(), MuParserScript::tableColumnFunction(), and TableStatistics::update().
|
private |
Read XML formula element.
References XmlStreamReader::raiseError(), XmlStreamReader::readAttributeInt(), and setFormula().
Referenced by load().
|
private |
Read XML input filter element.
References d_column_private, Column::Private::inputFilter(), AbstractSimpleFilter::load(), and XmlStreamReader::skipToNextTag().
Referenced by load().
|
private |
Read XML mask element.
References XmlStreamReader::raiseError(), XmlStreamReader::readAttributeInt(), setMasked(), and XmlStreamReader::skipToEndElement().
Referenced by load().
|
private |
Read XML output filter element.
References AbstractSimpleFilter::load(), outputFilter(), and XmlStreamReader::skipToNextTag().
Referenced by load().
|
private |
Read XML row element.
References dataType(), SciDAVis::enumStringToValue(), AbstractAspect::index(), XmlStreamReader::raiseError(), XmlStreamReader::readAttributeInt(), setDateTimeAt(), setInvalid(), setTextAt(), setValueAt(), SciDAVis::TypeDouble, SciDAVis::TypeQDateTime, and SciDAVis::TypeQString.
Referenced by load().
|
friend |
Referenced by Column().
|
friend |
Reimplemented from AbstractAspect.
Referenced by Column().
|
private |
Pointer to the private data object.
Referenced by clear(), clearFormulas(), clearMasks(), clearValidity(), Column(), columnMode(), copy(), ColumnStringIO::copy(), dataType(), dateAt(), dateTimeAt(), formula(), formulaIntervals(), insertRows(), invalidIntervals(), isInvalid(), isMasked(), maskedIntervals(), outputFilter(), plotDesignation(), removeRows(), replaceDateTimes(), replaceTexts(), replaceValues(), rowCount(), save(), setColumnMode(), setDateTimeAt(), setFormula(), setInvalid(), setMasked(), setPlotDesignation(), setTextAt(), ColumnStringIO::setTextAt(), setValueAt(), textAt(), ColumnStringIO::textAt(), timeAt(), valueAt(), XmlReadInputFilter(), and ~Column().
|
private |
Referenced by asStringColumn(), Column(), setColumnMode(), and ~Column().