NeoFOAM
WIP Prototype of a modern OpenFOAM core
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | List of all members
NeoFOAM::finiteVolume::cellCentred::FieldDocument Class Reference

A class representing a field document in a database. More...

#include <fieldCollection.hpp>

Public Member Functions

template<class FieldType >
 FieldDocument (const FieldType &field, std::int64_t timeIndex, std::int64_t iterationIndex, std::int64_t subCycleIndex)
 Constructs a FieldDocument with the given field and metadata.
 
 FieldDocument (const Document &doc)
 Constructs a FieldDocument with the given Document.
 
Documentdoc ()
 Retrieves the underlying Document.
 
const Documentdoc () const
 Retrieves the underlying Document (const version).
 
std::string id () const
 Retrieves the unique identifier of the field collection.
 
template<class FieldType >
FieldType & field ()
 Retrieves the field from the document.
 
template<class FieldType >
const FieldType & field () const
 Retrieves the field from the document (const version).
 
std::string name () const
 Retrieves the name of the field.
 
std::string & name ()
 Retrieves the time index of the field.
 
std::int64_t timeIndex () const
 Retrieves the time index of the field.
 
std::int64_t & timeIndex ()
 Retrieves the time index of the field.
 
std::int64_t iterationIndex () const
 Retrieves the iteration index of the field.
 
std::int64_t & iterationIndex ()
 Retrieves the iteration index of the field.
 
std::int64_t subCycleIndex () const
 Retrieves the sub-cycle index of the field.
 
std::int64_t & subCycleIndex ()
 Retrieves the sub-cycle index of the field.
 

Static Public Member Functions

static std::string typeName ()
 Retrieves the type name of the field.
 

Detailed Description

A class representing a field document in a database.

The FieldDocument class represents a field document in a database. It is a subclass of the Document class and provides additional functionality for accessing field-specific data.

Definition at line 34 of file fieldCollection.hpp.

Constructor & Destructor Documentation

◆ FieldDocument() [1/2]

template<class FieldType >
NeoFOAM::finiteVolume::cellCentred::FieldDocument::FieldDocument ( const FieldType &  field,
std::int64_t  timeIndex,
std::int64_t  iterationIndex,
std::int64_t  subCycleIndex 
)
inline

Constructs a FieldDocument with the given field and metadata.

Template Parameters
FieldTypeThe type of the field.
Parameters
fieldThe field to store in the document.
timeIndexThe time index of the field.
iterationIndexThe iteration index of the field.
subCycleIndexThe sub-cycle index of the field.

Definition at line 48 of file fieldCollection.hpp.

◆ FieldDocument() [2/2]

NeoFOAM::finiteVolume::cellCentred::FieldDocument::FieldDocument ( const Document doc)

Constructs a FieldDocument with the given Document.

Parameters
docThe Document to construct the FieldDocument from.

Member Function Documentation

◆ doc() [1/2]

Document & NeoFOAM::finiteVolume::cellCentred::FieldDocument::doc ( )

Retrieves the underlying Document.

Returns
Document& A reference to the underlying Document.

◆ doc() [2/2]

const Document & NeoFOAM::finiteVolume::cellCentred::FieldDocument::doc ( ) const

Retrieves the underlying Document (const version).

Returns
const Document& A const reference to the underlying Document.

◆ field() [1/2]

template<class FieldType >
FieldType & NeoFOAM::finiteVolume::cellCentred::FieldDocument::field ( )
inline

Retrieves the field from the document.

Template Parameters
FieldTypeThe type of the field.
Returns
A reference to the field.

Definition at line 109 of file fieldCollection.hpp.

◆ field() [2/2]

template<class FieldType >
const FieldType & NeoFOAM::finiteVolume::cellCentred::FieldDocument::field ( ) const
inline

Retrieves the field from the document (const version).

Template Parameters
FieldTypeThe type of the field.
Returns
A const reference to the field.

Definition at line 121 of file fieldCollection.hpp.

◆ id()

std::string NeoFOAM::finiteVolume::cellCentred::FieldDocument::id ( ) const

Retrieves the unique identifier of the field collection.

Returns
A string representing the unique identifier.

◆ iterationIndex() [1/2]

std::int64_t & NeoFOAM::finiteVolume::cellCentred::FieldDocument::iterationIndex ( )

Retrieves the iteration index of the field.

Returns
An integer representing the iteration index.

◆ iterationIndex() [2/2]

std::int64_t NeoFOAM::finiteVolume::cellCentred::FieldDocument::iterationIndex ( ) const

Retrieves the iteration index of the field.

Returns
An integer representing the iteration index.

◆ name() [1/2]

std::string & NeoFOAM::finiteVolume::cellCentred::FieldDocument::name ( )

Retrieves the time index of the field.

Returns
An integer representing the time index.

◆ name() [2/2]

std::string NeoFOAM::finiteVolume::cellCentred::FieldDocument::name ( ) const

Retrieves the name of the field.

Returns
A string representing the name of the field.

◆ subCycleIndex() [1/2]

std::int64_t & NeoFOAM::finiteVolume::cellCentred::FieldDocument::subCycleIndex ( )

Retrieves the sub-cycle index of the field.

Returns
An integer representing the sub-cycle index.

◆ subCycleIndex() [2/2]

std::int64_t NeoFOAM::finiteVolume::cellCentred::FieldDocument::subCycleIndex ( ) const

Retrieves the sub-cycle index of the field.

Returns
An integer representing the sub-cycle index.

◆ timeIndex() [1/2]

std::int64_t & NeoFOAM::finiteVolume::cellCentred::FieldDocument::timeIndex ( )

Retrieves the time index of the field.

Returns
An integer representing the time index.

◆ timeIndex() [2/2]

std::int64_t NeoFOAM::finiteVolume::cellCentred::FieldDocument::timeIndex ( ) const

Retrieves the time index of the field.

Returns
An integer representing the time index.

◆ typeName()

static std::string NeoFOAM::finiteVolume::cellCentred::FieldDocument::typeName ( )
static

Retrieves the type name of the field.

Returns
A string representing the type name.

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