CompactIOField< T, BaseType > Class Template Reference

A Field of objects of type <T> with automated input and output using a compact storage. Behaves like IOField except when binary output in case it writes a CompactListList. More...

Public Member Functions

 TypeName ("FieldField")
 Runtime type information. More...
 
 CompactIOField (const CompactIOField &)=default
 Default copy construct. More...
 
 CompactIOField (const IOobject &io)
 Construct from IOobject. More...
 
 CompactIOField (const IOobject &io, const bool valid)
 Construct from IOobject; does local processor require reading? More...
 
 CompactIOField (const IOobject &io, const label size)
 Construct from IOobject and size. More...
 
 CompactIOField (const IOobject &io, const UList< T > &content)
 Construct from IOobject and a List/Field content. More...
 
 CompactIOField (const IOobject &io, Field< T > &&content)
 Construct by transferring the Field contents. More...
 
virtual ~CompactIOField ()=default
 Destructor. More...
 
virtual bool writeObject (IOstreamOption streamOpt, const bool valid) const
 Write using stream options. More...
 
virtual bool writeData (Ostream &os) const
 
void operator= (const CompactIOField< T, BaseType > &rhs)
 Copy assignment of entries. More...
 

Detailed Description

template<class T, class BaseType>
class Foam::CompactIOField< T, BaseType >

A Field of objects of type <T> with automated input and output using a compact storage. Behaves like IOField except when binary output in case it writes a CompactListList.

Useful for fields of small subfields e.g. in lagrangian

Source files

Definition at line 53 of file CompactIOField.H.

Constructor & Destructor Documentation

◆ CompactIOField() [1/6]

CompactIOField ( const CompactIOField< T, BaseType > &  )
default

Default copy construct.

◆ CompactIOField() [2/6]

CompactIOField ( const IOobject io)
explicit

Construct from IOobject.

Definition at line 67 of file CompactIOField.C.

References IOobject::MUST_READ, IOobject::READ_IF_PRESENT, and IOobject::readOpt().

Here is the call graph for this function:

◆ CompactIOField() [3/6]

CompactIOField ( const IOobject io,
const bool  valid 
)

Construct from IOobject; does local processor require reading?

Definition at line 84 of file CompactIOField.C.

References IOobject::MUST_READ, IOobject::READ_IF_PRESENT, and IOobject::readOpt().

Here is the call graph for this function:

◆ CompactIOField() [4/6]

CompactIOField ( const IOobject io,
const label  size 
)

Construct from IOobject and size.

Definition at line 105 of file CompactIOField.C.

References IOobject::MUST_READ, IOobject::READ_IF_PRESENT, IOobject::readOpt(), and setSize().

Here is the call graph for this function:

◆ CompactIOField() [5/6]

CompactIOField ( const IOobject io,
const UList< T > &  content 
)

Construct from IOobject and a List/Field content.

Definition at line 129 of file CompactIOField.C.

References IOobject::MUST_READ, Field< Type >::operator=(), IOobject::READ_IF_PRESENT, and IOobject::readOpt().

Here is the call graph for this function:

◆ CompactIOField() [6/6]

CompactIOField ( const IOobject io,
Field< T > &&  content 
)

Construct by transferring the Field contents.

Definition at line 153 of file CompactIOField.C.

References IOobject::MUST_READ, IOobject::READ_IF_PRESENT, and IOobject::readOpt().

Here is the call graph for this function:

◆ ~CompactIOField()

virtual ~CompactIOField ( )
virtualdefault

Destructor.

Member Function Documentation

◆ TypeName()

TypeName ( "FieldField"  )

Runtime type information.

◆ writeObject()

bool writeObject ( IOstreamOption  streamOpt,
const bool  valid 
) const
virtual

Write using stream options.

Definition at line 177 of file CompactIOField.C.

References IOstreamOption::ASCII, IOstreamOption::format(), and regIOobject::writeObject().

Here is the call graph for this function:

◆ writeData()

bool writeData ( Ostream os) const
virtual

Definition at line 202 of file CompactIOField.C.

References os().

Here is the call graph for this function:

◆ operator=()

void operator= ( const CompactIOField< T, BaseType > &  rhs)

Copy assignment of entries.

Definition at line 212 of file CompactIOField.C.

References Field< Type >::operator=().

Here is the call graph for this function:

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