$extrastylesheet
Dakota
Version 6.2
|
Public Member Functions | |
template<typename StoredType > | |
void | array_allocate (const StrStrSizet &iterator_id, const std::string &data_name, size_t array_size, const MetaDataType &metadata) |
allocate an entry with sized array of the StoredType, e.g., array across response functions or optimization results sets | |
template<typename StoredType > | |
void | array_insert (const StrStrSizet &iterator_id, const std::string &data_name, size_t index, const StoredType &sent_data) |
insert sent_data in specified position in previously allocated array | |
template<typename StoredType > | |
StoredType | get_data (const StrStrSizet &iterator_id, const std::string &data_name) const |
return requested data by value in StoredType | |
template<typename StoredType > | |
StoredType | get_array_data (const StrStrSizet &iterator_id, const std::string &data_name, size_t index) const |
return requested data from array by value in StoredType | |
template<typename StoredType > | |
const StoredType * | get_data_ptr (const StrStrSizet &iterator_id, const std::string &result_key) const |
return pointer to stored data entry | |
template<typename StoredType > | |
const StoredType * | get_array_data_ptr (const StrStrSizet &iterator_id, const std::string &data_name, size_t index) const |
return pointer to stored data at given array location | |
void | insert (const StrStrSizet &iterator_id, const std::string &data_name, const boost::any &result, const MetaDataType &metadata) |
record addition with metadata map | |
void | dump_data (std::ostream &output_stream) |
coarsely dump the data to the passed output stream | |
void | print_data (std::ostream &output_stream) |
pretty print the data to the passed output stream | |
Private Member Functions | |
const ResultsValueType & | lookup_data (const StrStrSizet &iterator_id, const std::string &data_name) const |
attempt to find the requested data, erroring if not found | |
template<typename StoredType > | |
StoredType | cast_data (const boost::any &dataholder) const |
cast the reference to the any data to the requested type | |
template<typename StoredType > | |
const StoredType * | cast_data_ptr (const boost::any *dataholder) const |
cast the pointer to the any data to the requested type | |
void | print_metadata (std::ostream &os, const MetaDataType &md) |
print metadata to ostream | |
void | extract_data (const boost::any &dataholder, std::ostream &os) |
determine the type of contained data and output it to ostream | |
void | output_data (const std::vector< double > &data, std::ostream &os) |
output data to ostream | |
void | output_data (const std::vector< RealVector > &data, std::ostream &os) |
output data to ostream | |
void | output_data (const std::vector< std::string > &data, std::ostream &os) |
output data to ostream | |
void | output_data (const std::vector< std::vector< std::string > > &data, std::ostream &os) |
output data to ostream | |
void | output_data (const std::vector< RealMatrix > &data, std::ostream &os) |
output data to ostream | |
void | output_data (const RealMatrix &data, std::ostream &os) |
output data to ostream | |
Private Attributes | |
std::map< ResultsKeyType, ResultsValueType > | iteratorData |
core data storage (map from key to value type) |
Class: ResultsDBAny Description: A map-based container to store DAKOTA Iterator results in underlying boost::anys, with optional metadata
void array_insert | ( | const StrStrSizet & | iterator_id, |
const std::string & | data_name, | ||
size_t | index, | ||
const StoredType & | sent_data | ||
) |
insert sent_data in specified position in previously allocated array
insert requires previous allocation, and does not allow metadata update
References Dakota::abort_handler(), ResultsDBAny::iteratorData, and Dakota::make_key().
void insert | ( | const StrStrSizet & | iterator_id, |
const std::string & | data_name, | ||
const boost::any & | result, | ||
const MetaDataType & | metadata | ||
) |
record addition with metadata map
Add or update existing entry
References ResultsDBAny::iteratorData, and Dakota::make_key().
Referenced by ResultsDBAny::array_allocate().
void extract_data | ( | const boost::any & | dataholder, |
std::ostream & | os | ||
) | [private] |
determine the type of contained data and output it to ostream
Extract the data from the held any and map to supported concrete types int double RealVector (Teuchos::SerialDenseVector<int,double) RealMatrix (Teuchos::SerialDenseMatrix<int,double)
References ResultsDBAny::output_data().
Referenced by ResultsDBAny::dump_data(), and ResultsDBAny::print_data().