Chi-Tech
chi::PostProcessor Class Referenceabstract

#include <PostProcessor.h>

Inheritance diagram for chi::PostProcessor:
ChiObject chi::EventSubscriber chi::AggregateNodalValuePostProcessor chi::CellVolumeIntegralPostProcessor chi::SolverInfoPostProcessor

Data Structures

struct  TimeHistoryEntry
 

Public Member Functions

const std::string & Name () const
 
PPType Type () const
 
PPNumericFormat NumericFormat () const
 
size_t NumericPrecision () const
 
void PushOntoStack (std::shared_ptr< ChiObject > &new_object) override
 
void ReceiveEventUpdate (const Event &event) override
 
virtual void Execute (const Event &event_context)=0
 
virtual const ParameterBlockGetValue () const
 
virtual const std::vector< TimeHistoryEntry > & GetTimeHistory () const
 
const std::vector< std::string > & PrintScope () const
 
std::string ConvertScalarValueToString (const ParameterBlock &value) const
 
std::string ConvertValueToString (const ParameterBlock &value) const
 
virtual ~PostProcessor ()=default
 
- Public Member Functions inherited from ChiObject
 ChiObject ()
 
 ChiObject (const chi::InputParameters &params)
 
void SetStackID (size_t stack_id)
 
size_t StackID () const
 
virtual void PushOntoStack (std::shared_ptr< ChiObject > &new_object)
 
virtual ~ChiObject ()=default
 
- Public Member Functions inherited from chi::EventSubscriber
 EventSubscriber ()=default
 
virtual void ReceiveEventUpdate (const Event &event)
 
virtual ~EventSubscriber ()=default
 

Static Public Member Functions

static InputParameters GetInputParameters ()
 
- Static Public Member Functions inherited from ChiObject
static chi::InputParameters GetInputParameters ()
 

Protected Member Functions

 PostProcessor (const InputParameters &params, PPType type)
 
void SetType (PPType type)
 

Static Protected Member Functions

static PPType FigureTypeFromValue (const ParameterBlock &value)
 

Protected Attributes

const std::string name_
 
std::vector< std::string > subscribed_events_for_execution_
 
std::vector< std::string > subscribed_events_for_printing_
 
PPType type_
 
ParameterBlock value_
 
std::vector< TimeHistoryEntrytime_history_
 
const PPNumericFormat print_numeric_format_ = PPNumericFormat::GENERAL
 
const size_t print_precision_ = 6
 
std::string solvername_filter_
 

Static Private Member Functions

static PPNumericFormat ConstructNumericFormat (const std::string &format_string)
 

Detailed Description

Base class for all post-processors.

Definition at line 27 of file PostProcessor.h.

Constructor & Destructor Documentation

◆ ~PostProcessor()

virtual chi::PostProcessor::~PostProcessor ( )
virtualdefault

◆ PostProcessor()

chi::PostProcessor::PostProcessor ( const InputParameters params,
PPType  type 
)
explicitprotected

Definition at line 71 of file PostProcessor.cc.

Member Function Documentation

◆ ConstructNumericFormat()

PPNumericFormat chi::PostProcessor::ConstructNumericFormat ( const std::string &  format_string)
staticprivate

Definition at line 93 of file PostProcessor.cc.

◆ ConvertScalarValueToString()

std::string chi::PostProcessor::ConvertScalarValueToString ( const ParameterBlock value) const

Converts a scalar value into a string format based on this post-processor's numeric specifications.

Definition at line 179 of file PostProcessor.cc.

◆ ConvertValueToString()

std::string chi::PostProcessor::ConvertValueToString ( const ParameterBlock value) const

Converts a scalar and vector values into a string format based on this post-processor's numeric specifications.

Definition at line 239 of file PostProcessor.cc.

◆ Execute()

virtual void chi::PostProcessor::Execute ( const Event event_context)
pure virtual

◆ FigureTypeFromValue()

PPType chi::PostProcessor::FigureTypeFromValue ( const ParameterBlock value)
staticprotected

Lambda to check if this is a scalar

Definition at line 274 of file PostProcessor.cc.

◆ GetInputParameters()

InputParameters chi::PostProcessor::GetInputParameters ( )
static

Definition at line 15 of file PostProcessor.cc.

◆ GetTimeHistory()

const std::vector< PostProcessor::TimeHistoryEntry > & chi::PostProcessor::GetTimeHistory ( ) const
virtual

Definition at line 166 of file PostProcessor.cc.

◆ GetValue()

const ParameterBlock & chi::PostProcessor::GetValue ( ) const
virtual

Gets the scalar value currently stored for the post-processor.

Definition at line 163 of file PostProcessor.cc.

◆ Name()

const std::string & chi::PostProcessor::Name ( ) const

Returns the name of the post-processors.

Definition at line 106 of file PostProcessor.cc.

◆ NumericFormat()

PPNumericFormat chi::PostProcessor::NumericFormat ( ) const

Returns the numeric format of the post-processor for printing.

Definition at line 109 of file PostProcessor.cc.

◆ NumericPrecision()

size_t chi::PostProcessor::NumericPrecision ( ) const

Returns the numeric precision of the post-processor for printing.

Definition at line 114 of file PostProcessor.cc.

◆ PrintScope()

const std::vector< std::string > & chi::PostProcessor::PrintScope ( ) const

Definition at line 171 of file PostProcessor.cc.

◆ PushOntoStack()

void chi::PostProcessor::PushOntoStack ( std::shared_ptr< ChiObject > &  new_object)
overridevirtual

Calls the base ChiObject's method and adds a subscription to chi_physics::PhysicsEventPublisher singleton.

Pushes onto the post-processor stack and adds a subscription to chi_physics::PhysicsEventPublisher singleton.

Reimplemented from ChiObject.

Definition at line 118 of file PostProcessor.cc.

◆ ReceiveEventUpdate()

void chi::PostProcessor::ReceiveEventUpdate ( const Event event)
overridevirtual

A method called by publishers to inform the object of events, only if the object subscribed to the publisher.

Reimplemented from chi::EventSubscriber.

Definition at line 138 of file PostProcessor.cc.

◆ SetType()

void chi::PostProcessor::SetType ( PPType  type)
protected

Sets the post-processor's generic type.

Definition at line 309 of file PostProcessor.cc.

◆ Type()

PPType chi::PostProcessor::Type ( ) const

Returns the type of the post-processors. This is the generic type SCALAR, VECTOR, etc. not the c++ type.

Definition at line 107 of file PostProcessor.cc.

Field Documentation

◆ name_

const std::string chi::PostProcessor::name_
protected

Definition at line 84 of file PostProcessor.h.

◆ print_numeric_format_

const PPNumericFormat chi::PostProcessor::print_numeric_format_ = PPNumericFormat::GENERAL
protected

Definition at line 92 of file PostProcessor.h.

◆ print_precision_

const size_t chi::PostProcessor::print_precision_ = 6
protected

Definition at line 93 of file PostProcessor.h.

◆ solvername_filter_

std::string chi::PostProcessor::solvername_filter_
protected

Definition at line 94 of file PostProcessor.h.

◆ subscribed_events_for_execution_

std::vector<std::string> chi::PostProcessor::subscribed_events_for_execution_
protected

Definition at line 85 of file PostProcessor.h.

◆ subscribed_events_for_printing_

std::vector<std::string> chi::PostProcessor::subscribed_events_for_printing_
protected

Definition at line 86 of file PostProcessor.h.

◆ time_history_

std::vector<TimeHistoryEntry> chi::PostProcessor::time_history_
protected

Definition at line 90 of file PostProcessor.h.

◆ type_

PPType chi::PostProcessor::type_
protected

Definition at line 87 of file PostProcessor.h.

◆ value_

ParameterBlock chi::PostProcessor::value_
protected

Definition at line 88 of file PostProcessor.h.


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