DoubleMetadata

class HPS::DoubleMetadata : public HPS::Metadata

The DoubleMetadata class is a smart pointer. It represents a piece of double Metadata.

Public Functions

DoubleMetadata()

The default constructor creates an uninitialized DoubleMetadata object. The Type() function will return Type::None.

DoubleMetadata(char const *in_name, double in_value)

This constructor creates a DoubleMetadata with a given name and value.

Parameters
DoubleMetadata(DoubleMetadata &&in_that)

The move constructor creates a DoubleMetadata by transferring the underlying object of the rvalue reference to this DoubleMetadata.

Parameters

in_that – An rvalue reference to a DoubleMetadata to take the underlying object from.

DoubleMetadata(DoubleMetadata const &in_that)

The copy constructor creates a DoubleMetadata object that shares the underlying smart-pointer of the source DoubleMetadata.

Parameters

in_that – The source DoubleMetadata to copy.

DoubleMetadata(Metadata const &in_that)

This constructor creates a DoubleMetadata object that shares the underlying smart-pointer of the source Metadata. The copy will only be successful if the source component is really an upcast of a DoubleMetadata object. Otherwise the copy will fail and the resulting DoubleMetadata will be invalid.

Parameters

in_that – The source Metadata to copy.

double GetValue() const

Gets the double value for this DoubleMetadata.

Returns

The double value for this DoubleMetadata.

inline virtual HPS::Type ObjectType() const

This function returns the type the object, as declared (if the object is derived, this does not give the true type of the derived object).

Returns

The declared type of the object in question, which may differ from the true, underlying type.

DoubleMetadata &operator=(DoubleMetadata &&in_that)

The move assignment operator transfers the underlying object of the rvalue reference to this DoubleMetadata.

Parameters

in_that – An rvalue reference to a DoubleMetadata to take the underlying object from.

Returns

A reference to this DoubleMetadata.

void SetValue(double in_value)

Sets the double value for this DoubleMetadata.

Parameters

in_value – The double value for this DoubleMetadata.

virtual ~DoubleMetadata()

Public Static Attributes

static const HPS::Type staticType = HPS::Type::DoubleMetadata