https://mooseframework.inl.gov
Public Member Functions | Protected Attributes | Private Member Functions | List of all members
Moose::Kokkos::MaterialPropertyValue< T, 2 > Class Template Reference

#include <KokkosMaterialPropertyValueDecl.h>

Inheritance diagram for Moose::Kokkos::MaterialPropertyValue< T, 2 >:
[legend]

Public Member Functions

KOKKOS_FUNCTION MaterialPropertyValue (const MaterialProperty< T, 2 > &property, const Datum &datum, unsigned int qp)
 Constructor. More...
 
KOKKOS_FUNCTION T & operator() (unsigned int i0, unsigned int i1)
 Get the writeable reference of a property value. More...
 
KOKKOS_FUNCTION const T & operator() (unsigned int i0, unsigned int i1) const
 Get the const reference of a property value. More...
 
KOKKOS_FUNCTION dof_id_type n (unsigned int dim) const
 Get the size of a dimension. More...
 

Protected Attributes

const dof_id_type _qp
 Global quadrature point index. More...
 
Array< T, dimension+1 > const * _data
 Pointer to the property data storage. More...
 
const T & _value
 Default value. More...
 

Private Member Functions

 usingKokkosMaterialPropertyValueBaseMembers (T, 2)
 

Detailed Description

template<typename T>
class Moose::Kokkos::MaterialPropertyValue< T, 2 >

Definition at line 143 of file KokkosMaterialPropertyValueDecl.h.

Constructor & Destructor Documentation

◆ MaterialPropertyValue()

template<typename T >
Moose::Kokkos::MaterialPropertyValue< T, 2 >::MaterialPropertyValue ( const MaterialProperty< T, 2 > &  property,
const Datum datum,
unsigned int  qp 
)

Constructor.

Parameters
propertyThe material property constructing this object
datumThe Datum object of the current thread
qpThe local quadrature point index

Definition at line 48 of file KokkosMaterialPropertyValue.h.

51  : MaterialPropertyValueBase<T, 2>(property, datum, qp)
52 {
53 }

Member Function Documentation

◆ n()

KOKKOS_FUNCTION dof_id_type Moose::Kokkos::MaterialPropertyValueBase< T, dimension >::n ( unsigned int  dim) const
inlineinherited

Get the size of a dimension.

Parameters
dimThe dimension index
Returns
The size of the dimension

Definition at line 54 of file KokkosMaterialPropertyValueDecl.h.

54 { return _data->n(dim); }
static constexpr std::size_t dim
This is the dimension of all vector and tensor datastructures used in MOOSE.
Definition: Moose.h:159
Array< T, dimension+1 > const * _data
Pointer to the property data storage.

◆ operator()() [1/2]

template<typename T >
KOKKOS_FUNCTION T& Moose::Kokkos::MaterialPropertyValue< T, 2 >::operator() ( unsigned int  i0,
unsigned int  i1 
)
inline

Get the writeable reference of a property value.

Parameters
i0The first dimension index
i1The second dimension index
Returns
The writeable reference of the property value

Definition at line 165 of file KokkosMaterialPropertyValueDecl.h.

165 { return (*_data)(i0, i1, _qp); }
Array< T, dimension+1 > const * _data
Pointer to the property data storage.
const dof_id_type _qp
Global quadrature point index.

◆ operator()() [2/2]

template<typename T >
KOKKOS_FUNCTION const T& Moose::Kokkos::MaterialPropertyValue< T, 2 >::operator() ( unsigned int  i0,
unsigned int  i1 
) const
inline

Get the const reference of a property value.

Parameters
i0The first dimension index
i1The second dimension index
Returns
The const reference of the property value

Definition at line 172 of file KokkosMaterialPropertyValueDecl.h.

173  {
174  return _data ? (*_data)(i0, i1, _qp) : _value;
175  }
Array< T, dimension+1 > const * _data
Pointer to the property data storage.
const dof_id_type _qp
Global quadrature point index.

◆ usingKokkosMaterialPropertyValueBaseMembers()

template<typename T >
Moose::Kokkos::MaterialPropertyValue< T, 2 >::usingKokkosMaterialPropertyValueBaseMembers ( ,
 
)
private

Member Data Documentation

◆ _data

Array<T, dimension + 1> const* Moose::Kokkos::MaterialPropertyValueBase< T, dimension >::_data
protectedinherited

Pointer to the property data storage.

Definition at line 64 of file KokkosMaterialPropertyValueDecl.h.

◆ _qp

const dof_id_type Moose::Kokkos::MaterialPropertyValueBase< T, dimension >::_qp
protectedinherited

Global quadrature point index.

Definition at line 60 of file KokkosMaterialPropertyValueDecl.h.

◆ _value

const T& Moose::Kokkos::MaterialPropertyValueBase< T, dimension >::_value
protectedinherited

Default value.

Definition at line 68 of file KokkosMaterialPropertyValueDecl.h.


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