38 #ifndef Foam_expressions_exprValueFieldTag_H 39 #define Foam_expressions_exprValueFieldTag_H 135 void set(const Type* first, const Type* last)
141 value_.
set<Type>(*first);
155 value_.
set<Type>(val);
225 return !(*
this == rhs);
void set_empty()
Set as empty with zero value, leave type unchanged.
void write(Ostream &os) const
Write uniformity label and the value as pair.
exprValueFieldTag()=default
Default construct. Uniformity = empty, type = none.
A polymorphic typed union of simple primitive and VectorSpace types. It uses a 'fatter' representatio...
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
Binary combine operator, e.g. for global reduction.
int compare(const exprValueFieldTag &rhs) const
Compare (uniformity, type, value)
void set_nouniform()
Set as non-uniform with zero value, leave type unchanged.
static exprValueFieldTag make_empty()
Make an empty field tag with the specified type (zero-value)
enum uniformity check_uniformity(InputIt first, InputIt last)
Algorithm to determine list/container uniformity.
bool set(const Type &val)
Assign from type. Returns false and sets to 'none' for unsupported types.
void read(Istream &is)
Read uniformity label and the value as pair.
void set_value(const Type &val)
Set as uniform, with specified value.
void combine(const exprValueFieldTag &b)
Inplace combine - eg, for global uniformity.
static exprValueFieldTag returnReduce(const exprValueFieldTag &tag)
Perform a reduction on a copy and return the result.
const expressions::exprValue & value() const noexcept
Representative (uniform) value for the field.
const dimensionedScalar b
Wien displacement law constant: default SI units: [m.K].
Istream & operator>>(Istream &, directionInfo &)
Container (non-empty) with identical values.
exprValueFieldTag & operator=(const exprValueFieldTag &)=default
Copy assignment.
bool is_uniform() const noexcept
True if the uniformity is "uniform".
An Ostream is an abstract base class for all output systems (streams, files, token lists...
bool empty() const noexcept
True if the uniformity is "empty".
void reduce()
Inplace parallel reduction, uses worldComm.
OBJstream os(runTime.globalPath()/outputName)
bool operator==(const exprValueFieldTag &) const
Compare (uniformity,value) for equality.
Ostream & operator<<(Ostream &, const boundaryPatch &p)
Write boundaryPatch as dictionary entries (without surrounding braces)
bool is_nonuniform() const noexcept
True if the uniformity is "non-uniform".
bool operator!=(const exprValueFieldTag &rhs) const
Compare (uniformity,value) for inequality.
An expressions::exprValue (polymorphic typed union) with an additional flag for tracking Field conten...
A class representing the concept of 0 (zero) that can be used to avoid manipulating objects known to ...
bool operator<(const exprValueFieldTag &) const
Compare (uniformity,value)
void print(Ostream &os) const
Print description to Ostream.
bool equal(const exprValueFieldTag &rhs) const
Test for equality of the values.
void set(const Type *first, const Type *last)
Set value and uniformity from range of data.
void set_zero()
Set type and zero value (does not affect uniformity)