csvTableReader< Type > Class Template Reference

Reads an interpolation table from a file - CSV-format. More...

Inheritance diagram for csvTableReader< Type >:
[legend]
Collaboration diagram for csvTableReader< Type >:
[legend]

Public Member Functions

 TypeName ("csv")
 Declare type-name, virtual type (with debug switch) More...
 
 csvTableReader (const dictionary &dict)
 Construct from dictionary. More...
 
virtual autoPtr< tableReader< Type > > clone () const
 Construct and return a copy. More...
 
virtual ~csvTableReader ()=default
 Destructor. More...
 
virtual void operator() (const fileName &fName, List< Tuple2< scalar, Type >> &data)
 Read 1D table. More...
 
virtual void operator() (const fileName &fName, List< Tuple2< scalar, List< Tuple2< scalar, Type >>>> &data)
 Read 2D table - NotImplemented. More...
 
virtual void write (Ostream &os) const
 Write the remaining parameters. More...
 
- Public Member Functions inherited from tableReader< Type >
 TypeName ("tableReader")
 Declare type-name, virtual type (with debug switch) More...
 
 declareRunTimeSelectionTable (autoPtr, tableReader, dictionary,(const dictionary &dict),(dict))
 
 tableReader ()=default
 Default construct. More...
 
 tableReader (const dictionary &dict)
 Construct from dictionary. More...
 
virtual ~tableReader ()=default
 Destructor. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from tableReader< Type >
static autoPtr< tableReaderNew (const dictionary &spec)
 Return a reference to the selected tableReader. More...
 

Detailed Description

template<class Type>
class Foam::csvTableReader< Type >

Reads an interpolation table from a file - CSV-format.

Source files

Definition at line 53 of file csvTableReader.H.

Constructor & Destructor Documentation

◆ csvTableReader()

csvTableReader ( const dictionary dict)

Construct from dictionary.

Definition at line 113 of file csvTableReader.C.

◆ ~csvTableReader()

virtual ~csvTableReader ( )
virtualdefault

Destructor.

Member Function Documentation

◆ TypeName()

TypeName ( "csv"  )

Declare type-name, virtual type (with debug switch)

◆ clone()

virtual autoPtr<tableReader<Type> > clone ( ) const
inlinevirtual

Construct and return a copy.

Implements tableReader< Type >.

Definition at line 98 of file csvTableReader.H.

◆ operator()() [1/2]

void operator() ( const fileName fName,
List< Tuple2< scalar, Type >> &  data 
)
virtual

Read 1D table.

Implements tableReader< Type >.

Definition at line 130 of file csvTableReader.C.

References DynamicList< T, SizeMin >::append(), DynamicList< T, SizeMin >::clear(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, Foam::fileHandler(), Foam::findMax(), ISstream::getLine(), IOstream::good(), Foam::max(), n, Foam::nl, Foam::pos(), dictionary::transfer(), Foam::HashTableOps::values(), and x.

Here is the call graph for this function:

◆ operator()() [2/2]

void operator() ( const fileName fName,
List< Tuple2< scalar, List< Tuple2< scalar, Type >>>> &  data 
)
virtual

Read 2D table - NotImplemented.

Implements tableReader< Type >.

Definition at line 210 of file csvTableReader.C.

References NotImplemented.

◆ write()

void write ( Ostream os) const
virtual

Write the remaining parameters.

Reimplemented from tableReader< Type >.

Definition at line 220 of file csvTableReader.C.

References IOstreamOption::ASCII, IOstreamOption::format(), os(), tableReader< Type >::write(), and Ostream::writeEntry().

Here is the call graph for this function:

The documentation for this class was generated from the following files: