#include <SnapshotParameter.hpp>
Public Types | |
enum class | Identifier { InitialMass , CurrentMass , Metallicity , Age , Temperature , Custom } |
Public Member Functions | |
const string & | defaultUnit () const |
const string & | description () const |
Identifier | identifier () const |
const string & | quantity () const |
Static Public Member Functions | |
static SnapshotParameter | age () |
static SnapshotParameter | currentMass () |
static SnapshotParameter | custom (string description, string quantity=string(), string defaultUnit=string()) |
static SnapshotParameter | initialMass () |
static SnapshotParameter | metallicity () |
static SnapshotParameter | temperature () |
Private Member Functions | |
SnapshotParameter (Identifier identifier, string description, string quantity, string defaultUnit) | |
Private Attributes | |
string | _defaultUnit |
string | _description |
Identifier | _identifier |
string | _quantity |
SnapshotParameter is a helper class for holding metadata about a configurable parameter to be imported from a snapshot text column file. For example, an SEDFamily object would return a list of SnapshotParameter objects to define the parameters needed to select a particular SED template from the family. Similarly, a MaterialMix object can request parameters to be imported from a snapshot.
The SnapshotParameter class offers specific support for a number of frequently-used snapshot parameters, so that these can be discovered and, for example, used for probing. Examples include metallicity and age. Use one of the factory functions to construct a SnapshotParameter instance.
|
strong |
This enumeration lists the identifiers for the supported snapshot parameter types.
|
private |
This constructor initializes a snapshot parameter object with the given information for each field. The constructor is private; use one of the factory functions instead.
|
static |
This function returns a SnapshotParameter instance of type Age with default units of year.
|
static |
This function returns a SnapshotParameter instance of type CurrentMass with default units of solar mass.
|
static |
This function returns a custom SnapshotParameter instance. The description argument is used only for logging purposes. The quantity argument specifies the physical quantity represented by the parameter. It must match one of the quantity strings supported by the Units system, or one of the special quantity strings recognized by the TextInFile::addColumn() function. The defaultUnit argument specifies the default unit string, which is used in case the input file does not contain unit information for the parameter.
|
inline |
This function returns the default units to be used for the snapshot parameter in case the input file does not contain unit information for it.
|
inline |
This function returns the description of the snapshot parameter.
|
inline |
This function returns the identifier for the snapshot parameter. All custom snapshot parameters have the same identifier; there is no formal way to tell them apart.
|
static |
This function returns a SnapshotParameter instance of type InitialMass with default units of solar mass.
|
static |
This function returns a SnapshotParameter instance of type Metallicity.
|
inline |
This function returns the string defining the physical quantity represented by the snapshot parameter.
|
static |
This function returns a SnapshotParameter instance of type Temperature with default units of Kelvin.