Generic field type. More...
#include <OpenFOAM/FieldField.H>
Generic field type.
Definition at line 74 of file FieldField.H.
Public Types | |
typedef pTraits< Type >::cmptType | cmptType |
Component type. | |
![]() | |
typedef Field< Type > | value_type |
Type of values the PtrList contains. | |
typedef Field< Type > & | reference |
Type that can be used for storing into PtrList::value_type objects. | |
typedef const Field< Type > & | const_reference |
Type that can be used for storing into constant PtrList::value_type. |
Public Member Functions | |
FieldField () | |
Construct null. | |
FieldField (const label) | |
Construct given size. | |
FieldField (const word &, const FieldField< Field, Type > &) | |
Construct using the Field sizes from the given FieldField. | |
FieldField (const FieldField< Field, Type > &) | |
Construct as copy. | |
FieldField (FieldField< Field, Type > &, bool reUse) | |
Construct as copy or re-use as specified. | |
FieldField (const PtrList< Field< Type > > &) | |
Construct as copy of a PtrList<Field, Type> | |
FieldField (Istream &) | |
Construct as copy of tmp<FieldField> | |
tmp< FieldField< Field, Type > > | clone () const |
Clone. | |
void | negate () |
Negate this field. | |
tmp< FieldField< Field, cmptType > > | component (const direction) const |
Return a component field of the field. | |
void | replace (const direction, const FieldField< Field, cmptType > &) |
Replace a component field of the field. | |
void | replace (const direction, const cmptType &) |
Replace a component field of the field. | |
tmp< FieldField< Field, Type > > | T () const |
Return the field transpose (only defined for second rank tensors) | |
void | operator= (const FieldField< Field, Type > &) |
void | operator= (const tmp< FieldField< Field, Type > > &) |
void | operator= (const Type &) |
void | operator+= (const FieldField< Field, Type > &) |
void | operator+= (const tmp< FieldField< Field, Type > > &) |
void | operator-= (const FieldField< Field, Type > &) |
void | operator-= (const tmp< FieldField< Field, Type > > &) |
void | operator*= (const FieldField< Field, scalar > &) |
void | operator*= (const tmp< FieldField< Field, scalar > > &) |
void | operator/= (const FieldField< Field, scalar > &) |
void | operator/= (const tmp< FieldField< Field, scalar > > &) |
void | operator+= (const Type &) |
void | operator-= (const Type &) |
void | operator*= (const scalar &) |
void | operator/= (const scalar &) |
![]() | |
refCount () | |
Construct null with zero count. | |
int | count () const |
Return the reference count. | |
bool | okToDelete () const |
Return true if the reference count is zero. | |
void | resetRefCount () |
Reset the reference count to zero. | |
void | operator++ () |
Increment the reference count. | |
void | operator++ (int) |
Increment the reference count. | |
void | operator-- () |
Decrement the reference count. | |
void | operator-- (int) |
Decrement the reference count. | |
![]() | |
PtrList () | |
Null Constructor. | |
PtrList (const label) | |
Construct with length specified. | |
PtrList (const PtrList< Field< Type > > &) | |
Copy constructor. | |
PtrList (const PtrList< Field< Type > > &, const CloneArg &) | |
Copy constructor with additional argument for clone. | |
PtrList (const Xfer< PtrList< Field< Type > > > &) | |
Construct by transferring the parameter contents. | |
PtrList (PtrList< Field< Type > > &, bool reUse) | |
Construct as copy or re-use as specified. | |
PtrList (const SLPtrList< Field< Type > > &) | |
Construct as copy of SLPtrList<T> | |
PtrList (Istream &, const INew &) | |
Construct from Istream using given Istream constructor class. | |
PtrList (Istream &) | |
Construct from Istream using default Istream constructor class. | |
~PtrList () | |
label | size () const |
Return the number of elements in the PtrList. | |
bool | empty () const |
Return true if the PtrList is empty (ie, size() is zero). | |
void | setSize (const label) |
Reset size of PtrList. This can only be used to set the size. | |
void | resize (const label) |
Reset size of PtrList. This can only be used to set the size. | |
void | clear () |
Clear the PtrList, i.e. set size to zero deleting all the. | |
void | transfer (PtrList< Field< Type > > &) |
Transfer the contents of the argument PtrList into this PtrList. | |
Xfer< PtrList< Field< Type > > > | xfer () |
Transfer contents to the Xfer container. | |
bool | set (const label) const |
Is element set. | |
autoPtr< Field< Type > > | set (const label, Field< Type > *) |
Set element. Return old element (can be NULL). | |
autoPtr< Field< Type > > | set (const label, const autoPtr< Field< Type > > &) |
autoPtr< Field< Type > > | set (const label, const tmp< Field< Type > > &) |
void | reorder (const UList< label > &) |
Reorders elements. Ordering does not have to be done in. | |
const Field< Type > & | operator[] (const label) const |
Return element const reference. | |
Field< Type > & | operator[] (const label) |
Return element reference. | |
const Field< Type > * | operator() (const label) const |
Return element const pointer. | |
PtrList< Field< Type > > & | operator= (const PtrList< Field< Type > > &) |
Assignment. | |
iterator | begin () |
Return an iterator to begin traversing the PtrList. | |
iterator | end () |
Return an iterator to end traversing the PtrList. |
Static Public Member Functions | |
template<class Type2 > | |
static tmp< FieldField< Field, Type > > | NewCalculatedType (const FieldField< Field, Type2 > &ff) |
Return a pointer to a new calculatedFvPatchFieldField created on. |
Friends | |
Ostream & | operator (Ostream &, const FieldField< Field, Type > &) |
Ostream & | operator (Ostream &, const tmp< FieldField< Field, Type > > &) |
Additional Inherited Members | |
![]() | |
void | read (Istream &, const INew &inewt) |
Read from Istream using given Istream constructor class. |
Component type.
Definition at line 83 of file FieldField.H.
FieldField | ( | ) |
Construct null.
Used for temporary fields which are initialised after construction
Definition at line 118 of file FieldField.C.
|
explicit |
Construct given size.
Used for temporary fields which are initialised after construction
Definition at line 125 of file FieldField.C.
FieldField | ( | const word & | type, |
const FieldField< Field, Type > & | ff | ||
) |
Construct using the Field sizes from the given FieldField.
and the given Field type. Used for temporary fields which are initialised after construction
Definition at line 133 of file FieldField.C.
References forAll.
FieldField | ( | const FieldField< Field, Type > & | f | ) |
Construct as copy.
Definition at line 148 of file FieldField.C.
FieldField | ( | FieldField< Field, Type > & | f, |
bool | reUse | ||
) |
Construct as copy or re-use as specified.
Definition at line 156 of file FieldField.C.
FieldField | ( | const PtrList< Field< Type > > & | tl | ) |
Construct as copy of a PtrList<Field, Type>
Definition at line 164 of file FieldField.C.
FieldField | ( | Istream & | is | ) |
Construct as copy of tmp<FieldField>
Construct from Istream
Definition at line 187 of file FieldField.C.
tmp< FieldField< Field, Type > > clone | ( | ) | const |
Clone.
Definition at line 194 of file FieldField.C.
|
static |
Return a pointer to a new calculatedFvPatchFieldField created on.
freestore without setting patchField values
Definition at line 204 of file FieldField.C.
References forAll, PtrList< Field< Type > >::set(), and PtrList< Field< Type > >::size().
void negate | ( | ) |
tmp< FieldField< Field, typename FieldField< Field, Type >::cmptType > > component | ( | const direction | d | ) | const |
Return a component field of the field.
Definition at line 238 of file FieldField.C.
References Foam::component().
void replace | ( | const direction | d, |
const FieldField< Field, cmptType > & | sf | ||
) |
Replace a component field of the field.
Definition at line 256 of file FieldField.C.
References forAll.
Replace a component field of the field.
Definition at line 270 of file FieldField.C.
References forAll.
tmp< FieldField< Field, Type > > T | ( | ) | const |
Return the field transpose (only defined for second rank tensors)
Definition at line 283 of file FieldField.C.
References Foam::T().
void operator= | ( | const FieldField< Field, Type > & | f | ) |
Reimplemented in GeometricField< Type, PatchField, GeoMesh >::GeometricBoundaryField.
Definition at line 298 of file FieldField.C.
References Foam::abort(), Foam::FatalError, FatalErrorIn, and forAll.
Referenced by GeometricField< Type, PatchField, GeoMesh >::GeometricBoundaryField::operator=().
void operator= | ( | const tmp< FieldField< Field, Type > > & | ) |
void operator= | ( | const Type & | t | ) |
Reimplemented in GeometricField< Type, PatchField, GeoMesh >::GeometricBoundaryField.
Definition at line 337 of file FieldField.C.
References forAll.
void operator+= | ( | const FieldField< Field, Type > & | f | ) |
Definition at line 376 of file FieldField.C.
void operator+= | ( | const tmp< FieldField< Field, Type > > & | tf | ) |
Definition at line 376 of file FieldField.C.
void operator-= | ( | const FieldField< Field, Type > & | f | ) |
Definition at line 377 of file FieldField.C.
void operator-= | ( | const tmp< FieldField< Field, Type > > & | tf | ) |
Definition at line 377 of file FieldField.C.
void operator*= | ( | const FieldField< Field, scalar > & | f | ) |
Definition at line 378 of file FieldField.C.
void operator*= | ( | const tmp< FieldField< Field, scalar > > & | tf | ) |
Definition at line 378 of file FieldField.C.
void operator/= | ( | const FieldField< Field, scalar > & | f | ) |
Definition at line 379 of file FieldField.C.
void operator/= | ( | const tmp< FieldField< Field, scalar > > & | tf | ) |
Definition at line 379 of file FieldField.C.
void operator+= | ( | const Type & | t | ) |
Definition at line 376 of file FieldField.C.
void operator-= | ( | const Type & | t | ) |
Definition at line 377 of file FieldField.C.
void operator*= | ( | const scalar & | t | ) |
Definition at line 378 of file FieldField.C.
void operator/= | ( | const scalar & | t | ) |
Definition at line 379 of file FieldField.C.
|
friend |
|
friend |