Concrete definition of a parameter value for a specified type. More...
#include <DerivativeMaterialInterface.h>
Public Member Functions | |
MaterialProperty (bool use_ad=false) | |
Explicitly declare a public constructor because we made the copy constructor private. More... | |
virtual | ~MaterialProperty () |
const std::vector< MooseADWrapper< T > > & | get () const |
std::vector< MooseADWrapper< T > > & | set () |
virtual std::string | type () override |
String identifying the type of parameter stored. More... | |
virtual PropertyValue * | init (int size) override |
Clone this value. More... | |
virtual void | resize (int n) override |
Resizes the property to the size n. More... | |
virtual unsigned int | size () const override |
T & | operator[] (const unsigned int i) |
Get element i out of the array as a writeable reference. More... | |
const T & | operator[] (const unsigned int i) const |
Get element i out of the array as a ready-only reference. More... | |
virtual void | swap (PropertyValue *rhs) override |
virtual void | qpCopy (const unsigned int to_qp, PropertyValue *rhs, const unsigned int from_qp) override |
Copy the value of a Property from one specific to a specific qp in this Property. More... | |
virtual void | store (std::ostream &stream) override |
Store the property into a binary stream. More... | |
virtual void | load (std::istream &stream) override |
Load the property from a binary stream. More... | |
void | copyDualNumberToValue (const unsigned int i) override |
copy the value portion (not the derivatives) of the DualNumber<Real> version of the material property to the Real version for the specified quadrature point More... | |
void | markAD (bool use_ad) override |
Mark whether this property is in AD mode. This method is necessary for switching the state after swapping material properties during stateful material calculations. More... | |
Protected Attributes | |
bool | _use_ad |
Whether this property was declared as AD. More... | |
std::vector< MooseADWrapper< T > > | _value |
Stored parameter value. More... | |
Private Member Functions | |
MaterialProperty (const MaterialProperty< T > &) | |
private copy constructor to avoid shallow copying of material properties More... | |
MaterialProperty< T > & | operator= (const MaterialProperty< T > &) |
private assignment operator to avoid shallow copying of material properties More... | |
Concrete definition of a parameter value for a specified type.
Definition at line 25 of file DerivativeMaterialInterface.h.
|
inline |
Explicitly declare a public constructor because we made the copy constructor private.
Definition at line 105 of file MaterialProperty.h.
|
inlinevirtual |
Definition at line 109 of file MaterialProperty.h.
|
inlineprivate |
private copy constructor to avoid shallow copying of material properties
Definition at line 183 of file MaterialProperty.h.
|
inlineoverridevirtual |
copy the value portion (not the derivatives) of the DualNumber<Real> version of the material property to the Real version for the specified quadrature point
Implements PropertyValue.
Definition at line 177 of file MaterialProperty.h.
|
inline |
Definition at line 114 of file MaterialProperty.h.
|
inlineoverridevirtual |
Clone this value.
Useful in copy-construction.
Implements PropertyValue.
Definition at line 220 of file MaterialProperty.h.
|
inlineoverridevirtual |
Load the property from a binary stream.
Implements PropertyValue.
Definition at line 265 of file MaterialProperty.h.
|
inlineoverridevirtual |
Mark whether this property is in AD mode. This method is necessary for switching the state after swapping material properties during stateful material calculations.
Implements PropertyValue.
Definition at line 206 of file MaterialProperty.h.
|
inlineprivate |
private assignment operator to avoid shallow copying of material properties
Definition at line 189 of file MaterialProperty.h.
|
inline |
Get element i out of the array as a writeable reference.
Definition at line 141 of file MaterialProperty.h.
|
inline |
Get element i out of the array as a ready-only reference.
Definition at line 146 of file MaterialProperty.h.
|
inlineoverridevirtual |
Copy the value of a Property from one specific to a specific qp in this Property.
to_qp | The quadrature point in this Property that you want to copy to. |
rhs | The Property you want to copy from. |
from_qp | The quadrature point in rhs you want to copy from. |
Implements PropertyValue.
Definition at line 247 of file MaterialProperty.h.
|
inlineoverridevirtual |
Resizes the property to the size n.
Implements PropertyValue.
Definition at line 227 of file MaterialProperty.h.
Referenced by _init_helper(), MaterialPropertyInterface::getZeroMaterialProperty(), and MaterialBase::getZeroMaterialProperty().
|
inline |
Definition at line 119 of file MaterialProperty.h.
|
inlineoverridevirtual |
Implements PropertyValue.
Definition at line 136 of file MaterialProperty.h.
Referenced by MaterialPropertyInterface::getZeroMaterialProperty(), MaterialBase::getZeroMaterialProperty(), and MooseUtils::MaterialPropertyStorageDump().
|
inlineoverridevirtual |
Store the property into a binary stream.
Implements PropertyValue.
Definition at line 257 of file MaterialProperty.h.
|
inlineoverridevirtual |
|
inlineoverridevirtual |
String identifying the type of parameter stored.
Implements PropertyValue.
Definition at line 213 of file MaterialProperty.h.
|
protected |
Whether this property was declared as AD.
Definition at line 196 of file MaterialProperty.h.
|
protected |
Stored parameter value.
Definition at line 198 of file MaterialProperty.h.
Referenced by MaterialProperty< Real >::copyDualNumberToValue(), MaterialProperty< Real >::get(), MaterialProperty< Real >::operator[](), ADMaterialPropertyObject< T >::operator[](), MaterialProperty< Real >::set(), and MaterialProperty< Real >::size().