Chi-Tech
chi_mesh::MeshHandler Class Reference

#include <chi_meshhandler.h>

Public Member Functions

chi_mesh::MeshContinuumPtrGetGrid () const
 
bool HasSurfaceMesher () const
 
bool HasVolumeMesher () const
 
chi_mesh::SurfaceMesherGetSurfaceMesher ()
 
chi_mesh::VolumeMesherGetVolumeMesher ()
 
const chi_mesh::SurfaceMesherGetSurfaceMesher () const
 
const chi_mesh::VolumeMesherGetVolumeMesher () const
 
void SetSurfaceMesher (std::shared_ptr< chi_mesh::SurfaceMesher > surface_mesher)
 
void SetVolumeMesher (std::shared_ptr< chi_mesh::VolumeMesher > volume_mesher)
 
 MeshHandler ()=default
 
 MeshHandler (const MeshHandler &)=delete
 
MeshHandleroperator= (const MeshHandler &)=delete
 

Protected Attributes

std::shared_ptr< chi_mesh::SurfaceMeshersurface_mesher_ = nullptr
 
std::shared_ptr< chi_mesh::VolumeMeshervolume_mesher_ = nullptr
 

Detailed Description

Object for containing all mesh related variables.

Definition at line 12 of file chi_meshhandler.h.

Constructor & Destructor Documentation

◆ MeshHandler() [1/2]

chi_mesh::MeshHandler::MeshHandler ( )
default

Defaulted constructor.

◆ MeshHandler() [2/2]

chi_mesh::MeshHandler::MeshHandler ( const MeshHandler )
delete

Member Function Documentation

◆ GetGrid()

chi_mesh::MeshContinuumPtr & chi_mesh::MeshHandler::GetGrid ( ) const

Obtains the grid from the volume mesher.

Obtains a pointer to the last created grid. This method will get a smart-pointer to a grid object. If a volume-mesher has not been created, or if a grid is not available, this method will throw std::logic_error.

Definition at line 12 of file chi_meshhandler.cc.

◆ GetSurfaceMesher() [1/2]

chi_mesh::SurfaceMesher & chi_mesh::MeshHandler::GetSurfaceMesher ( )

Obtains a reference to the surface mesher. If not set, will throw std::logic_error.

Obtains a reference to the surface mesher.

Definition at line 32 of file chi_meshhandler.cc.

◆ GetSurfaceMesher() [2/2]

const chi_mesh::SurfaceMesher & chi_mesh::MeshHandler::GetSurfaceMesher ( ) const

Obtains a const reference to the surface mesher. If not set, will throw std::logic_error.

Obtains a reference to the surface mesher.

Definition at line 56 of file chi_meshhandler.cc.

◆ GetVolumeMesher() [1/2]

chi_mesh::VolumeMesher & chi_mesh::MeshHandler::GetVolumeMesher ( )

Obtains a reference to the volume mesher. If not set, will throw std::logic_error.

Obtains a reference to the surface mesher.

Definition at line 44 of file chi_meshhandler.cc.

◆ GetVolumeMesher() [2/2]

const chi_mesh::VolumeMesher & chi_mesh::MeshHandler::GetVolumeMesher ( ) const

Obtains a const reference to the volume mesher. If not set, will throw std::logic_error.

Obtains a reference to the surface mesher.

Definition at line 67 of file chi_meshhandler.cc.

◆ HasSurfaceMesher()

bool chi_mesh::MeshHandler::HasSurfaceMesher ( ) const
inline

Returns true if the surface mesher has been set.

Definition at line 23 of file chi_meshhandler.h.

◆ HasVolumeMesher()

bool chi_mesh::MeshHandler::HasVolumeMesher ( ) const
inline

Returns true if the volume mesher has been set.

Definition at line 26 of file chi_meshhandler.h.

◆ operator=()

MeshHandler & chi_mesh::MeshHandler::operator= ( const MeshHandler )
delete

◆ SetSurfaceMesher()

void chi_mesh::MeshHandler::SetSurfaceMesher ( std::shared_ptr< chi_mesh::SurfaceMesher surface_mesher)
inline

Sets the active surface mesher.

Definition at line 45 of file chi_meshhandler.h.

◆ SetVolumeMesher()

void chi_mesh::MeshHandler::SetVolumeMesher ( std::shared_ptr< chi_mesh::VolumeMesher volume_mesher)
inline

Sets the active volume mesher.

Definition at line 49 of file chi_meshhandler.h.

Field Documentation

◆ surface_mesher_

std::shared_ptr<chi_mesh::SurfaceMesher> chi_mesh::MeshHandler::surface_mesher_ = nullptr
protected

Definition at line 15 of file chi_meshhandler.h.

◆ volume_mesher_

std::shared_ptr<chi_mesh::VolumeMesher> chi_mesh::MeshHandler::volume_mesher_ = nullptr
protected

Definition at line 16 of file chi_meshhandler.h.


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