Nektar++
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
Nektar::Utilities::OutputXml Class Reference

Converter from fld to vtk. More...

#include <OutputXml.h>

Inheritance diagram for Nektar::Utilities::OutputXml:
Inheritance graph
[legend]
Collaboration diagram for Nektar::Utilities::OutputXml:
Collaboration graph
[legend]

Public Member Functions

 OutputXml (FieldSharedPtr f)
 
virtual ~OutputXml ()
 
virtual void Process (po::variables_map &vm)
 Write fld to output file. More...
 
virtual std::string GetModuleName ()
 
- Public Member Functions inherited from Nektar::Utilities::OutputModule
 OutputModule (FieldSharedPtr p_f)
 
void OpenStream ()
 Open a file for output. More...
 
 OutputModule (MeshSharedPtr p_m)
 
void OpenStream ()
 
- Public Member Functions inherited from Nektar::Utilities::Module
 Module (FieldSharedPtr p_f)
 
void RegisterConfig (string key, string value)
 Register a configuration option with a module. More...
 
void PrintConfig ()
 Print out all configuration options for a module. More...
 
void SetDefaults ()
 Sets default configuration options for those which have not been set. More...
 
bool GetRequireEquiSpaced (void)
 
void SetRequireEquiSpaced (bool pVal)
 
void EvaluateTriFieldAtEquiSpacedPts (LocalRegions::ExpansionSharedPtr &exp, const Array< OneD, const NekDouble > &infield, Array< OneD, NekDouble > &outfield)
 
 Module (MeshSharedPtr p_m)
 
virtual void Process ()=0
 
void RegisterConfig (std::string key, std::string value)
 
void PrintConfig ()
 
void SetDefaults ()
 
MeshSharedPtr GetMesh ()
 
virtual void ProcessVertices ()
 Extract element vertices. More...
 
virtual void ProcessEdges (bool ReprocessEdges=true)
 Extract element edges. More...
 
virtual void ProcessFaces (bool ReprocessFaces=true)
 Extract element faces. More...
 
virtual void ProcessElements ()
 Generate element IDs. More...
 
virtual void ProcessComposites ()
 Generate composites. More...
 
virtual void ClearElementLinks ()
 

Static Public Member Functions

static boost::shared_ptr< Modulecreate (FieldSharedPtr f)
 Creates an instance of this class. More...
 

Static Public Attributes

static ModuleKey m_className
 

Additional Inherited Members

- Protected Member Functions inherited from Nektar::Utilities::Module
 Module ()
 
void ReorderPrisms (PerMap &perFaces)
 Reorder node IDs so that prisms and tetrahedra are aligned correctly. More...
 
void PrismLines (int prism, PerMap &perFaces, std::set< int > &prismsDone, std::vector< ElementSharedPtr > &line)
 
- Protected Attributes inherited from Nektar::Utilities::OutputModule
ofstream m_fldFile
 Output stream. More...
 
std::ofstream m_mshFile
 Output stream. More...
 
- Protected Attributes inherited from Nektar::Utilities::Module
FieldSharedPtr m_f
 Field object. More...
 
map< string, ConfigOptionm_config
 List of configuration values. More...
 
bool m_requireEquiSpaced
 
MeshSharedPtr m_mesh
 Mesh object. More...
 
std::map< std::string,
ConfigOption
m_config
 List of configuration values. More...
 

Detailed Description

Converter from fld to vtk.

Definition at line 47 of file OutputXml.h.

Constructor & Destructor Documentation

Nektar::Utilities::OutputXml::OutputXml ( FieldSharedPtr  f)

Definition at line 52 of file OutputXml.cpp.

52  : OutputModule(f)
53 {
54 
55 }
Nektar::Utilities::OutputXml::~OutputXml ( )
virtual

Definition at line 57 of file OutputXml.cpp.

58 {
59 }

Member Function Documentation

static boost::shared_ptr<Module> Nektar::Utilities::OutputXml::create ( FieldSharedPtr  f)
inlinestatic

Creates an instance of this class.

Definition at line 51 of file OutputXml.h.

References Nektar::MemoryManager< DataType >::AllocateSharedPtr().

51  {
53  }
static boost::shared_ptr< DataType > AllocateSharedPtr()
Allocate a shared pointer from the memory pool.
virtual std::string Nektar::Utilities::OutputXml::GetModuleName ( )
inlinevirtual

Implements Nektar::Utilities::Module.

Definition at line 62 of file OutputXml.h.

63  {
64  return "OutputXml";
65  }
void Nektar::Utilities::OutputXml::Process ( po::variables_map &  vm)
virtual

Write fld to output file.

Implements Nektar::Utilities::Module.

Definition at line 61 of file OutputXml.cpp.

References Nektar::Utilities::Module::m_config, and Nektar::Utilities::Module::m_f.

62 {
63  if(!m_f->m_exp.size()) // do nothing if no expansion defined
64  {
65  return;
66  }
67 
68  if (m_f->m_verbose)
69  {
70  if(m_f->m_comm->TreatAsRankZero())
71  {
72  cout << "OutputXml: Writing file..." << endl;
73  }
74  }
75 
76  // Extract the output filename and extension
77  string filename = m_config["outfile"].as<string>();
78 
79  m_f->m_graph->WriteGeometry(filename);
80  cout << "Written file: " << filename << endl;
81 }
map< string, ConfigOption > m_config
List of configuration values.
FieldSharedPtr m_f
Field object.

Member Data Documentation

ModuleKey Nektar::Utilities::OutputXml::m_className
static
Initial value:

Definition at line 54 of file OutputXml.h.