|
Cholla 3.0.1-dev
Cholla - Massively parallel hydro on GPUs
|
#include <field_info.h>
Public Member Functions | |
| FieldInfo (FieldInfo &&)=default | |
| FieldInfo & | operator= (FieldInfo &&)=default |
| FieldInfo (const FieldInfo &)=delete | |
| FieldInfo & | operator= (const FieldInfo &)=delete |
| const utils::FrozenKeyIdxBiMap & | get_field_id_map () const |
| std::optional< int > | field_id (const char *field_name) const |
| std::optional< int > | field_id (std::string_view field_name) const |
| std::optional< std::string > | field_name (int field_id) const |
| std::optional< bool > | is_cell_centered (int field_id) const |
| std::optional< field::IOBuf > | io_buf (int field_id) const |
| int | n_fields () const |
| int | n_fields (field::Kind kind) const |
| std::optional< int > | scalar_start () const |
| field::IdRange | get_id_range (field::Kind kind) const |
Static Public Member Functions | |
| static FieldInfo | create () |
Dynamically describes the available fields and associated properties
|
static |
Factory method
Ideally, we would make it possible to customize the active scalars, but that's a topic for the future.
|
inline |
try to lookup the field_id associated with the field_name
|
inline |
try to look up the field name from the field id
|
inline |
Get the underlying mapping object between field names and ids
|
inline |
This returns a "range" over all ids
This might be used in a case like the following:
|
inline |
try to look up the IOBuf value associated with a field
|
inline |
try to look up whether the field id refers to a cell-centered field
{0,0,0} could represent a cell-centered value and {1,0,0}, or maybe {-1, 0, 0} (we need to think about conventions), could denote a field centered on x-faces.
|
inline |
Returns the number of fields
|
inline |
Returns the number of fields of a given category
|
inline |
Returns the first field_id corresponding to a passive scalar (if there are any)