WSF
usmtf::TabularSet Class Reference

Useful conveniences for Sets that are Tabular in nature, see Onetrack.hpp for example. More...

#include <TabularSet.hpp>

Inheritance diagram for usmtf::TabularSet:
Collaboration diagram for usmtf::TabularSet:

Public Types

using Series = std::vector<const Field*>
 Row Or Column.
using NSeries = std::vector<Series>
 Multiple Rows Or Columns.

Public Member Functions

 TabularSet (const std::string &aSTF, const std::vector< Field > &aFields, const size_t aHeaderOffset=1) noexcept
Public Member Functions inherited from usmtf::Set
 Set (const std::string &aSTF, const std::vector< Field > &aFields) noexcept
virtual ~Set ()=default
const std::string & GetType () const noexcept
 Return the Set Identifiers/Set Text Format of the set instance.
bool IsEmpty () const noexcept
int GetFieldCount () const noexcept
const FieldGetField (size_t aIndex) const
 Returns a field at a index position in the Set.
const std::string & GetFieldContent (size_t aIndex) const
 Returns the Contents of a field at specified index.
const std::string GetReconstructedSet () const noexcept
Public Member Functions inherited from usmtf::Validatable
bool IsValid () const noexcept
Public Member Functions inherited from usmtf::ErrorManager
virtual ~ErrorManager ()=default
bool HasErrors () const noexcept
void LogErrors (std::ostream &aOut) const noexcept
const std::vector< ValidationError > & GetErrors () const

Protected Member Functions

Series GetRow (const size_t aRowIndex) const
std::vector< std::string > GetRowContent (const size_t aRowIndex) const
Series GetColumn (const size_t aColumnIndex) const
std::vector< std::string > GetColumnContent (const size_t aColumnIndex) const
bool IsValidFieldCount () const noexcept
size_t GetRowCount () const noexcept
size_t GetColumnCount () const noexcept
const FieldGetField (const size_t aRow, const size_t aColumn) const
const std::string & GetFieldContent (const size_t aRow, const size_t aColumn) const
Protected Member Functions inherited from usmtf::ErrorManager
void AddError (const ValidationError &aError) noexcept
void AddError (const std::string &aFailureReason, const std::string &aValueValidatied, const std::string &aOptionalSuggestion="") noexcept
void AddError (const std::string &aErrorMessage) noexcept
void AddErrors (const std::vector< ValidationError > &aErrors) noexcept
void ClearErrors () noexcept

Protected Attributes

const size_t mHeaderOffset
Protected Attributes inherited from usmtf::Set
std::string mSetTextFormat
std::vector< FieldmFields

Detailed Description

Useful conveniences for Sets that are Tabular in nature, see Onetrack.hpp for example.

Member Typedef Documentation

◆ NSeries

using usmtf::TabularSet::NSeries = std::vector<Series>

Multiple Rows Or Columns.

◆ Series

using usmtf::TabularSet::Series = std::vector<const Field*>

Row Or Column.

Constructor & Destructor Documentation

◆ TabularSet()

usmtf::TabularSet::TabularSet ( const std::string & aSTF,
const std::vector< Field > & aFields,
const size_t aHeaderOffset = 1 )
noexcept

Member Function Documentation

◆ GetColumn()

TabularSet::Series usmtf::TabularSet::GetColumn ( const size_t aColumnIndex) const
protected

References GetField(), and GetRowCount().

◆ GetColumnContent()

std::vector< std::string > usmtf::TabularSet::GetColumnContent ( const size_t aColumnIndex) const
protected

References GetFieldContent(), and GetRowCount().

◆ GetColumnCount()

size_t usmtf::TabularSet::GetColumnCount ( ) const
protectednoexcept

References mHeaderOffset.

Referenced by GetRow(), and GetRowContent().

◆ GetField()

const Field & usmtf::TabularSet::GetField ( const size_t aRow,
const size_t aColumn ) const
protected

References usmtf::Set::GetField(), and mHeaderOffset.

Referenced by GetColumn(), and GetRow().

◆ GetFieldContent()

const std::string & usmtf::TabularSet::GetFieldContent ( const size_t aRow,
const size_t aColumn ) const
protected

◆ GetRow()

TabularSet::Series usmtf::TabularSet::GetRow ( const size_t aRowIndex) const
protected

◆ GetRowContent()

std::vector< std::string > usmtf::TabularSet::GetRowContent ( const size_t aRowIndex) const
protected

◆ GetRowCount()

size_t usmtf::TabularSet::GetRowCount ( ) const
protectednoexcept

◆ IsValidFieldCount()

bool usmtf::TabularSet::IsValidFieldCount ( ) const
protectednoexcept

Member Data Documentation

◆ mHeaderOffset

const size_t usmtf::TabularSet::mHeaderOffset
protected

The documentation for this class was generated from the following files:
Copyrights Multiple, All Rights Reserved