Public Member Functions | Static Public Member Functions | Data Fields | Protected Attributes | Private Member Functions | Friends
DataEntry Class Reference

Top level data entry class for use in dictionaries. Provides a mechanism to specify a variable as a certain type, e.g. constant or table, and provide functions to return the (interpolated) value, and integral between limits. More...

Collaboration diagram for DataEntry:
Collaboration graph
[legend]

Public Member Functions

 TypeName ("DataEntry") declareRunTimeSelectionTable(autoPtr
 Runtime type information. More...
 
 DataEntry (const word &entryName)
 Construct from entry name. More...
 
 DataEntry (const DataEntry< Type > &de)
 Copy constructor. More...
 
virtual tmp< DataEntry< Type > > clone () const
 Construct and return a clone. More...
 
virtual ~DataEntry ()
 Destructor. More...
 
const wordname () const
 Return the name of the entry. More...
 
virtual void convertTimeBase (const Time &t)
 Convert time. More...
 
virtual Type value (const scalar x) const
 Return value as a function of (scalar) independent variable. More...
 
virtual tmp< Field< Type > > value (const scalarField &x) const
 Return value as a function of (scalar) independent variable. More...
 
virtual Type integrate (const scalar x1, const scalar x2) const
 Integrate between two (scalar) values. More...
 
virtual tmp< Field< Type > > integrate (const scalarField &x1, const scalarField &x2) const
 Integrate between two (scalar) values. More...
 
virtual dimensioned< Type > dimValue (const scalar x) const
 Return dimensioned type. More...
 
virtual tmp< Field< dimensioned< Type > > > dimValue (const scalarField &x) const
 Return dimensioned type as a function of (scalar) More...
 
virtual dimensioned< Type > dimIntegrate (const scalar x1, const scalar x2) const
 Integrate between two scalars and return a dimensioned type. More...
 
virtual tmp< Field< dimensioned< Type > > > dimIntegrate (const scalarField &x1, const scalarField &x2) const
 Integrate between two scalar fields and return a field of. More...
 
virtual void writeData (Ostream &os) const
 Write in dictionary format. More...
 

Static Public Member Functions

static autoPtr< DataEntry< Type > > New (const word &entryName, const dictionary &dict)
 Selector. More...
 

Data Fields

 DataEntry
 
 dictionary
 
const wordentryName
 
const word const dictionarydict
 
const word const dictionary entryName
 
const word const dictionary dict
 

Protected Attributes

const word name_
 Name of entry. More...
 

Private Member Functions

void operator= (const DataEntry< Type > &)
 Disallow default bitwise assignment. More...
 

Friends

Ostreamoperator (Ostream &os, const DataEntry< Type > &de)
 Ostream Operator. More...
 

Detailed Description

Top level data entry class for use in dictionaries. Provides a mechanism to specify a variable as a certain type, e.g. constant or table, and provide functions to return the (interpolated) value, and integral between limits.

Source files

Definition at line 52 of file DataEntry.H.

Constructor & Destructor Documentation

◆ DataEntry() [1/2]

DataEntry ( const word entryName)

Construct from entry name.

Definition at line 32 of file DataEntry.C.

◆ DataEntry() [2/2]

DataEntry ( const DataEntry< Type > &  de)

Copy constructor.

Definition at line 40 of file DataEntry.C.

◆ ~DataEntry()

~DataEntry ( )
virtual

Destructor.

Definition at line 50 of file DataEntry.C.

Member Function Documentation

◆ operator=()

void operator= ( const DataEntry< Type > &  )
private

Disallow default bitwise assignment.

◆ TypeName()

TypeName ( "DataEntry"  )

Runtime type information.

Declare runtime constructor selection table

◆ clone()

virtual tmp<DataEntry<Type> > clone ( ) const
inlinevirtual

Construct and return a clone.

Definition at line 112 of file DataEntry.H.

◆ New()

Foam::autoPtr< Foam::DataEntry< Type > > New ( const word entryName,
const dictionary dict 
)
static

Selector.

Definition at line 32 of file DataEntryNew.C.

References dict, Foam::exit(), Foam::FatalError, FatalErrorInFunction, token::isWord(), Foam::nl, and token::wordToken().

Referenced by setTimeStepFunctionObject::read().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ name()

const Foam::word & name ( ) const

Return the name of the entry.

Definition at line 57 of file DataEntry.C.

◆ convertTimeBase()

void convertTimeBase ( const Time t)
virtual

Convert time.

Definition at line 64 of file DataEntry.C.

◆ value() [1/2]

Type value ( const scalar  x) const
virtual

Return value as a function of (scalar) independent variable.

Definition at line 71 of file DataEntry.C.

References NotImplemented.

◆ value() [2/2]

Foam::tmp< Foam::Field< Type > > value ( const scalarField x) const
virtual

Return value as a function of (scalar) independent variable.

Definition at line 90 of file DataEntry.C.

References fld(), forAll, and x.

Here is the call graph for this function:

◆ integrate() [1/2]

Type integrate ( const scalar  x1,
const scalar  x2 
) const
virtual

Integrate between two (scalar) values.

Definition at line 80 of file DataEntry.C.

References NotImplemented.

◆ integrate() [2/2]

Foam::tmp< Foam::Field< Type > > integrate ( const scalarField x1,
const scalarField x2 
) const
virtual

Integrate between two (scalar) values.

Definition at line 107 of file DataEntry.C.

References fld(), and forAll.

Here is the call graph for this function:

◆ dimValue() [1/2]

Foam::dimensioned< Type > dimValue ( const scalar  x) const
virtual

Return dimensioned type.

Definition at line 125 of file DataEntry.C.

References Foam::dimless, and NotImplemented.

◆ dimValue() [2/2]

Foam::tmp< Foam::Field< Foam::dimensioned< Type > > > dimValue ( const scalarField x) const
virtual

Return dimensioned type as a function of (scalar)

Definition at line 149 of file DataEntry.C.

References Foam::dimless, fld(), forAll, and x.

Here is the call graph for this function:

◆ dimIntegrate() [1/2]

Foam::dimensioned< Type > dimIntegrate ( const scalar  x1,
const scalar  x2 
) const
virtual

Integrate between two scalars and return a dimensioned type.

Definition at line 135 of file DataEntry.C.

References Foam::dimless, and NotImplemented.

◆ dimIntegrate() [2/2]

Foam::tmp< Foam::Field< Foam::dimensioned< Type > > > dimIntegrate ( const scalarField x1,
const scalarField x2 
) const
virtual

Integrate between two scalar fields and return a field of.

dimensioned type

Definition at line 176 of file DataEntry.C.

References fld(), and forAll.

Here is the call graph for this function:

◆ writeData()

void writeData ( Ostream os) const
virtual

Write in dictionary format.

Definition at line 50 of file DataEntryIO.C.

References Foam::type(), and Ostream::writeKeyword().

Here is the call graph for this function:

Friends And Related Function Documentation

◆ operator

Ostream& operator ( Ostream os,
const DataEntry< Type > &  de 
)
friend

Ostream Operator.

Field Documentation

◆ name_

const word name_
protected

Name of entry.

Definition at line 81 of file DataEntry.H.

◆ DataEntry

Definition at line 93 of file DataEntry.H.

◆ dictionary

Definition at line 94 of file DataEntry.H.

◆ entryName [1/2]

const word& entryName

Definition at line 96 of file DataEntry.H.

◆ dict [1/2]

const word const dictionary& dict

Definition at line 98 of file DataEntry.H.

◆ entryName [2/2]

const word const dictionary entryName

Definition at line 99 of file DataEntry.H.

◆ dict [2/2]

const word const dictionary dict

Definition at line 100 of file DataEntry.H.


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