Libpf::User::CaseDescriptor Class Reference

Extends Defaults to include the name of the type and a list of quantities. More...

#include <CaseDescriptor.h>

Inheritance diagram for Libpf::User::CaseDescriptor:
Collaboration diagram for Libpf::User::CaseDescriptor:

Public Member Functions

 CaseDescriptor (std::string type, std::string tag, std::string description)
 
 CaseDescriptor (const std::string &jcd)
 
bool operator== (const CaseDescriptor &rhs) const
 comparison More...
 
const std::string & type (void) const
 return type More...
 
std::string json (void) const
 
bool sqCheck (const std::string &s) const
 
const std::map< std::string, double > & msq (void) const
 
void set (const std::string &jcd)
 
void addQuantity (std::string name, double value)
 set Quantity with name to the value, but only if that option is not already set More...
 

Detailed Description

Extends Defaults to include the name of the type and a list of quantities.

Constructor & Destructor Documentation

◆ CaseDescriptor() [1/2]

Libpf::User::CaseDescriptor::CaseDescriptor ( std::string  type,
std::string  tag,
std::string  description 
)

◆ CaseDescriptor() [2/2]

Libpf::User::CaseDescriptor::CaseDescriptor ( const std::string &  jcd)

initialize from JSON

Parameters
jcdUTF-8 encoded string with the JSON-serialized object

Member Function Documentation

◆ addQuantity()

void Libpf::User::CaseDescriptor::addQuantity ( std::string  name,
double  value 
)

set Quantity with name to the value, but only if that option is not already set

◆ json()

std::string Libpf::User::CaseDescriptor::json ( void  ) const
Returns
UTF-8 encoded string with the JSON-serialized object

◆ msq()

const std::map< std::string, double > & Libpf::User::CaseDescriptor::msq ( void  ) const
Returns
reference to the associative array of Quantity tags / values

◆ operator==()

bool Libpf::User::CaseDescriptor::operator== ( const CaseDescriptor rhs) const

comparison

◆ set()

void Libpf::User::CaseDescriptor::set ( const std::string &  jcd)

set from JSON

Parameters
jcdUTF-8 encoded string with the JSON-serialized object

◆ sqCheck()

bool Libpf::User::CaseDescriptor::sqCheck ( const std::string &  s) const

check for existence of Quantity with tag s

Returns
true if Quantity with tag s exists
Parameters
stag of Quantity

◆ type()

const std::string & Libpf::User::CaseDescriptor::type ( void  ) const

return type


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