79 template<
class Type,
class ValueType,
class Enable =
void>
82 static const bool value =
false;
89 static const bool value =
true;
93 template<
class Type,
class ValueType>
98 typename std::enable_if
100 (pTraits<ValueType>::rank > 0)
101 && (pTraits<ValueType>::rank <= pTraits<Type>::rank)
105 static const bool value =
129 inline const Type&
operator()(
const Type& value)
const
134 template<
class WrongType>
135 const Type&
operator()(
const WrongType& value)
const
137 return NullObjectRef<Type>();
146 template<class Type, direction rank = pTraits<Type>::rank>
157 typename std::conditional
191 inline Type
value(
const scalar
x,
const scalar
y)
const;
230 inline Type
value(
const scalar
x,
const scalar
y)
const;
279 virtual inline Type
value(
const scalar
x,
const scalar
y)
const;
312 template<
class Type,
class ValueType>
Run-time selectable general function of one variable.
const word & name() const
Return the name of the entry.
Pair< autoPtr< function1Type > > fs
Functions.
void write(Ostream &os, const unitConversions &units) const
Write to a stream.
Type value(const scalar x, const scalar y) const
Evaluate.
ProductFunction1s(const unitConversions &units, const dictionary &dict, const Pair< Tuple2< word, label >> &typeAndRanks)
Construct from a dictionary.
Function2 which returns the product of two independent Function1-s of the two input arguments....
void operator=(const Product< Type > &)=delete
Disallow default bitwise assignment.
virtual ~Product()
Destructor.
virtual void write(Ostream &os, const unitConversions &units) const
Write in dictionary format.
Product(const word &name, const unitConversions &units, const dictionary &dict)
Construct from name and dictionary.
virtual Type value(const scalar x, const scalar y) const
Return value.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
An ordered pair of two objects of type <T> with first() and second() elements.
A 2-tuple for storing two objects of different types.
A list of keyword definitions, which are a keyword followed by any number of values (e....
Traits class for primitives.
A class for handling words, derived from string.
Include the header files for all the primitive types that Fields are instantiated for.
void lookupValueTypeAndRank(const dictionary &dict, const direction argument, Tuple2< word, label > &typeAndRank, label &found)
Lookup the type and rank for the value entry for the given argument.
Pair< Tuple2< word, label > > lookupValueTypeAndRanks(const dictionary &dict)
Lookup the types and ranks for the value entries.
word valueName(const direction argument)
Return the name of the value entry for the given argument.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
const HashTable< unitConversion > & units()
Get the table of unit conversions.
fileType type(const fileName &, const bool checkVariants=true, const bool followLink=true)
Return the file type: directory or file.
const Type & operator()(const Type &value) const