Class DataSet::MockColumn#
Defined in File DataSet.h
Nested Relationships#
This class is a nested type of Template Class DataSet.
Class Documentation#
-
class MockColumn#
Technical column for internal use.
A mock column that is supposed to hold a pointer to the column storage. The DataColumns can be swapped between the MockColumn. MockColumns can be enabled and disabled which alters the number of cells in the DataRows accordingly.
Public Functions
-
inline MockColumn(DataColumn *column)#
Creates a MockColumn from a DataColumn. This MockColumn wraps and it and provides read-only access to all its components.
- Parameters:
_column – the DataColumn
-
inline const Cell &operator[](std::size_t i) const#
Accesses the i-th Cell in the stored column.
- Parameters:
i – the row index
- Returns:
the Cell
-
inline void set_range(double l_restr, double u_restr)#
-
inline void set_enabled(bool enabled)#
Sets the enabled flag of this MockColumn to the specified value.
- Parameters:
enabled – set enabled or not
-
inline ColumnType get_type() const#
Returns the ColumnType of this MockColumn. It is either INPUT or OUTPUT.
- Returns:
the ColumnType
-
inline Variable get_var() const#
Returns the Variable of this MockColumn.
- Returns:
the Variable
-
inline std::size_t size() const#
Returns the size of this MockColumn.
- Returns:
the size
-
inline bool is_enabled() const#
Returns the value of the enabled flag.
- Returns:
enabled or not
Public Static Functions
-
static inline void swap(MockColumn &m0, MockColumn &m1)#
Class function to swap the columns of two MockColumns.
- Parameters:
m0 – the first MockColumn
m1 – the second MockColumn
-
inline MockColumn(DataColumn *column)#