Phalanx
Development
|
A pure virtual class to distinguish a unique data layout in a cell. More...
#include <Phalanx_DataLayout.hpp>
Public Types | |
typedef PHX::Device::size_type | size_type |
Public Member Functions | |
virtual PHX::Device::size_type | rank () const =0 |
virtual PHX::Device::size_type | dimension (size_type ordinal) const =0 |
virtual PHX::Device::size_type | extent (size_type ordinal) const =0 |
virtual int | extent_int (size_type ordinal) const =0 |
virtual void | dimensions (std::vector< PHX::Device::size_type > &dim) const =0 |
virtual std::string | name (size_type ordinal) const =0 |
Returns the name of the input ordinal. | |
virtual void | names (std::vector< std::string > &names) const =0 |
Returns the names of all ordinals in a vector. | |
virtual PHX::Device::size_type | size () const =0 |
virtual bool | operator== (const DataLayout &left) const =0 |
virtual bool | operator!= (const DataLayout &left) const |
virtual std::string | identifier () const =0 |
Unique name identifier that can be used for strict weak ordering in stl std::map keys. | |
virtual void | print (std::ostream &os, int indent=0) const =0 |
A pure virtual class to distinguish a unique data layout in a cell.
The DataLayout class is used to (1) specify the array size of a an algebraic type in a single cell, and (2) to differentiate FieldTags that have the same name, but have different DataLayouts in the FieldManager. For example suppose we want to store density at both the nodes and the quadrature points in a cell. If we use the same string name for the FieldTag, the DataLayout will differentiate the objects. We could probably just use an enumerated type here, but the DataLayout class allows users to derive and pass in auxiliary data via the tag.