www.mooseframework.org
Public Member Functions | Protected Attributes | Private Attributes | List of all members
OutputDataWarehouse Class Reference

A helper warehouse for storing OutputData objects for the various output types. More...

#include <AdvancedOutputUtils.h>

Inheritance diagram for OutputDataWarehouse:
[legend]

Public Member Functions

 OutputDataWarehouse ()
 Populate the OutputData structures for all output types that are 'variable' based. More...
 
bool hasShowList ()
 False when the show lists for all variables is empty. More...
 
void setHasShowList (bool value)
 Set the show list bool. More...
 
OutputDataoperator[] (const std::string &name)
 A map accessor that errors if the key is not found. More...
 
bool contains (const std::string &name)
 A method for testing of a key exists. More...
 
std::map< std::string, OutputData >::iterator begin ()
 Provide iterator and find access to the underlying map data. More...
 
std::map< std::string, OutputData >::const_iterator begin () const
 
std::map< std::string, OutputData >::iterator end ()
 
std::map< std::string, OutputData >::const_iterator end () const
 
std::map< std::string, OutputData >::iterator find (const std::string &name)
 
const std::map< std::string, OutputData >::const_iterator find (const std::string &name) const
 

Protected Attributes

std::map< std::string, OutputData_map
 Data storage. More...
 

Private Attributes

bool _has_show_list
 

Detailed Description

A helper warehouse for storing OutputData objects for the various output types.

To keep syntax consistent and to provide the error checking for accessing invalid map keys the OutputMapWrapper is used for accessing the OutputData classes as well.

See also
OutputOnWarehouse OutputMapWrapper OutputData

Definition at line 149 of file AdvancedOutputUtils.h.

Constructor & Destructor Documentation

OutputDataWarehouse::OutputDataWarehouse ( )

Populate the OutputData structures for all output types that are 'variable' based.

Definition at line 50 of file AdvancedOutputUtils.C.

51 {
52  _map["nodal"] = OutputData();
53  _map["elemental"] = OutputData();
54  _map["scalars"] = OutputData();
55  _map["postprocessors"] = OutputData();
56  _map["vector_postprocessors"] = OutputData();
57 }
std::map< std::string, OutputData > _map
Data storage.
A structure for storing the various lists that contain the names of the items to be exported...

Member Function Documentation

std::map<std::string, OutputData >::iterator OutputMapWrapper< OutputData >::begin ( )
inlineinherited

Provide iterator and find access to the underlying map data.

Definition at line 87 of file AdvancedOutputUtils.h.

87 { return _map.begin(); }
std::map< std::string, OutputData > _map
Data storage.
std::map<std::string, OutputData >::const_iterator OutputMapWrapper< OutputData >::begin ( ) const
inlineinherited

Definition at line 93 of file AdvancedOutputUtils.h.

93 { return _map.begin(); }
std::map< std::string, OutputData > _map
Data storage.
bool OutputMapWrapper< OutputData >::contains ( const std::string &  name)
inlineinherited

A method for testing of a key exists.

Definition at line 104 of file AdvancedOutputUtils.h.

104 { return find(name) != end(); }
std::map< std::string, OutputData >::iterator end()
std::map< std::string, OutputData >::iterator find(const std::string &name)
std::map<std::string, OutputData >::iterator OutputMapWrapper< OutputData >::end ( )
inlineinherited

Definition at line 88 of file AdvancedOutputUtils.h.

88 { return _map.end(); }
std::map< std::string, OutputData > _map
Data storage.
std::map<std::string, OutputData >::const_iterator OutputMapWrapper< OutputData >::end ( ) const
inlineinherited

Definition at line 94 of file AdvancedOutputUtils.h.

94 { return _map.end(); }
std::map< std::string, OutputData > _map
Data storage.
std::map<std::string, OutputData >::iterator OutputMapWrapper< OutputData >::find ( const std::string &  name)
inlineinherited

Definition at line 89 of file AdvancedOutputUtils.h.

90  {
91  return _map.find(name);
92  }
std::map< std::string, OutputData > _map
Data storage.
const std::map<std::string, OutputData >::const_iterator OutputMapWrapper< OutputData >::find ( const std::string &  name) const
inlineinherited

Definition at line 95 of file AdvancedOutputUtils.h.

96  {
97  return _map.find(name);
98  }
std::map< std::string, OutputData > _map
Data storage.
bool OutputDataWarehouse::hasShowList ( )
inline

False when the show lists for all variables is empty.

When false everything should output.

See also
AdvancedOutput::initOutputList

Definition at line 163 of file AdvancedOutputUtils.h.

Referenced by AdvancedOutput::initOutputList().

163 { return _has_show_list; }
OutputData & OutputMapWrapper< OutputData >::operator[] ( const std::string &  name)
inlineinherited

A map accessor that errors if the key is not found.

Definition at line 74 of file AdvancedOutputUtils.h.

75  {
76  // Locate the map entry, error if it is not found
77  typename std::map<std::string, T>::iterator iter = _map.find(name);
78  if (iter == _map.end())
79  mooseError("Unknown map key ", name);
80  return iter->second;
81  }
std::map< std::string, OutputData > _map
Data storage.
void mooseError(Args &&...args)
Emit an error message with the given stringified, concatenated args and terminate the application...
Definition: MooseError.h:182
void OutputDataWarehouse::setHasShowList ( bool  value)
inline

Set the show list bool.

This is set to true when the user supplies a show list.

See also
AdvancedOutput::initShowHideLists

Definition at line 171 of file AdvancedOutputUtils.h.

Referenced by AdvancedOutput::initShowHideLists().

171 { _has_show_list = value; }

Member Data Documentation

bool OutputDataWarehouse::_has_show_list
private

Definition at line 175 of file AdvancedOutputUtils.h.

std::map<std::string, OutputData > OutputMapWrapper< OutputData >::_map
protectedinherited

Data storage.

Definition at line 108 of file AdvancedOutputUtils.h.

Referenced by OutputDataWarehouse().


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