ReFRACtor
FullPhysics::ConnorIterationLog Class Reference

This is an observer of the ConnorSolver that writes out the state vector values in a nicely formated way on each iteration. More...

#include <connor_iteration_log.h>

+ Inheritance diagram for FullPhysics::ConnorIterationLog:
+ Collaboration diagram for FullPhysics::ConnorIterationLog:

Public Member Functions

 ConnorIterationLog (const boost::shared_ptr< StateVector > &Sv)
 
virtual void notify_add (ConnorSolver &Observed_object)
 Called when an object is added to an Observable. More...
 
virtual void notify_add ()
 
virtual void notify_remove (ConnorSolver &Observed_object)
 Called when an object is removed from an Observable. More...
 
virtual void notify_remove ()
 
void notify_update (const ConnorSolver &solver)
 Called when the Observed object is updated. More...
 
virtual void print (std::ostream &Os) const
 
std::string print_to_string () const
 Print to string. More...
 

Static Public Attributes

static const int SV_PRINT_WIDTH = 17
 

Detailed Description

This is an observer of the ConnorSolver that writes out the state vector values in a nicely formated way on each iteration.

For this to work it must be registered as an Observer of the instantiated ConnorSolver.

When we support more solvers, this can be made more generic.

Definition at line 18 of file connor_iteration_log.h.

Constructor & Destructor Documentation

◆ ConnorIterationLog()

FullPhysics::ConnorIterationLog::ConnorIterationLog ( const boost::shared_ptr< StateVector > &  Sv)
inline

Definition at line 22 of file connor_iteration_log.h.

Member Function Documentation

◆ notify_add() [1/2]

virtual void FullPhysics::Observer< ConnorSolver >::notify_add ( ConnorSolver Observed_object)
inlinevirtualinherited

Called when an object is added to an Observable.

Default is to do nothing.

Definition at line 47 of file observer.h.

◆ notify_add() [2/2]

virtual void FullPhysics::Observer< ConnorSolver >::notify_add ( )
inlinevirtualinherited

Definition at line 48 of file observer.h.

◆ notify_remove() [1/2]

virtual void FullPhysics::Observer< ConnorSolver >::notify_remove ( ConnorSolver Observed_object)
inlinevirtualinherited

Called when an object is removed from an Observable.

Default is to do nothing.

Definition at line 55 of file observer.h.

◆ notify_remove() [2/2]

virtual void FullPhysics::Observer< ConnorSolver >::notify_remove ( )
inlinevirtualinherited

Definition at line 56 of file observer.h.

◆ notify_update()

void ConnorIterationLog::notify_update ( const ConnorSolver Observed_object)
virtual

Called when the Observed object is updated.

Reimplemented from FullPhysics::Observer< ConnorSolver >.

Definition at line 18 of file connor_iteration_log.cc.

◆ print()

virtual void FullPhysics::ConnorIterationLog::print ( std::ostream &  Os) const
inlinevirtual

Definition at line 26 of file connor_iteration_log.h.

◆ print_to_string()

std::string FullPhysics::Printable< ConnorIterationLog >::print_to_string ( ) const
inlineinherited

Print to string.

This is primarily useful for SWIG wrappers to this class, e.g. a to_s method in ruby.

Definition at line 31 of file printable.h.

Member Data Documentation

◆ SV_PRINT_WIDTH

const int FullPhysics::ConnorIterationLog::SV_PRINT_WIDTH = 17
static

Definition at line 20 of file connor_iteration_log.h.


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

Copyright © 2017, California Institute of Technology.
ALL RIGHTS RESERVED.
U.S. Government Sponsorship acknowledged.
Generated Fri Aug 24 2018 15:44:12