MFEM  v4.5.2
Finite element discretization library
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
mfem::ParNCMesh::ElementSet Class Reference

#include <pncmesh.hpp>

Collaboration diagram for mfem::ParNCMesh::ElementSet:

Public Member Functions

 ElementSet (NCMesh *ncmesh=NULL, bool include_ref_types=false)
 ElementSet (const ElementSet &other)
void Encode (const Array< int > &elements)
void Dump (std::ostream &os) const
void Load (std::istream &is)
void Decode (Array< int > &elements) const
void SetNCMesh (NCMesh *ncmesh_)
const NCMeshGetNCMesh () const

Protected Member Functions

void EncodeTree (int elem)
void DecodeTree (int elem, int &pos, Array< int > &elements) const
void WriteInt (int value)
int GetInt (int pos) const
void FlagElements (const Array< int > &elements, char flag)
std::string RefPath () const

Protected Attributes

Array< unsigned char > data
 encoded refinement (sub-)trees More...
bool include_ref_types
Array< int > ref_path

Detailed Description

Uniquely encodes a set of leaf elements in the refinement hierarchy of an NCMesh. Can be dumped to a stream, sent to another processor, loaded, and decoded to identify the same set of elements (refinements) in a different but compatible NCMesh. The encoding can optionally include the refinement types needed to reach the leaves, so the element set can be decoded (recreated) even if the receiver has an incomplete tree.

Definition at line 355 of file pncmesh.hpp.

Constructor & Destructor Documentation

◆ ElementSet() [1/2]

mfem::ParNCMesh::ElementSet::ElementSet ( NCMesh ncmesh = NULL,
bool  include_ref_types = false 

Definition at line 358 of file pncmesh.hpp.

◆ ElementSet() [2/2]

mfem::ParNCMesh::ElementSet::ElementSet ( const ElementSet other)

Definition at line 2091 of file pncmesh.cpp.

Member Function Documentation

◆ Decode()

void mfem::ParNCMesh::ElementSet::Decode ( Array< int > &  elements) const

Definition at line 2248 of file pncmesh.cpp.

◆ DecodeTree()

void mfem::ParNCMesh::ElementSet::DecodeTree ( int  elem,
int &  pos,
Array< int > &  elements 
) const

Definition at line 2206 of file pncmesh.cpp.

◆ Dump()

void mfem::ParNCMesh::ElementSet::Dump ( std::ostream &  os) const

Definition at line 2258 of file pncmesh.cpp.

◆ Encode()

void mfem::ParNCMesh::ElementSet::Encode ( const Array< int > &  elements)

Definition at line 2167 of file pncmesh.cpp.

◆ EncodeTree()

void mfem::ParNCMesh::ElementSet::EncodeTree ( int  elem)

Definition at line 2130 of file pncmesh.cpp.

◆ FlagElements()

void mfem::ParNCMesh::ElementSet::FlagElements ( const Array< int > &  elements,
char  flag 

Definition at line 2115 of file pncmesh.cpp.

◆ GetInt()

int mfem::ParNCMesh::ElementSet::GetInt ( int  pos) const

Definition at line 2106 of file pncmesh.cpp.

◆ GetNCMesh()

const NCMesh* mfem::ParNCMesh::ElementSet::GetNCMesh ( ) const

Definition at line 369 of file pncmesh.hpp.

◆ Load()

void mfem::ParNCMesh::ElementSet::Load ( std::istream &  is)

Definition at line 2264 of file pncmesh.cpp.

◆ RefPath()

std::string mfem::ParNCMesh::ElementSet::RefPath ( ) const

Definition at line 2188 of file pncmesh.cpp.

◆ SetNCMesh()

void mfem::ParNCMesh::ElementSet::SetNCMesh ( NCMesh ncmesh_)

Definition at line 368 of file pncmesh.hpp.

◆ WriteInt()

void mfem::ParNCMesh::ElementSet::WriteInt ( int  value)

Definition at line 2097 of file pncmesh.cpp.

Member Data Documentation

◆ data

Array<unsigned char> mfem::ParNCMesh::ElementSet::data

encoded refinement (sub-)trees

Definition at line 372 of file pncmesh.hpp.

◆ include_ref_types

bool mfem::ParNCMesh::ElementSet::include_ref_types

Definition at line 374 of file pncmesh.hpp.

◆ ncmesh

NCMesh* mfem::ParNCMesh::ElementSet::ncmesh

Definition at line 373 of file pncmesh.hpp.

◆ ref_path

Array<int> mfem::ParNCMesh::ElementSet::ref_path

Definition at line 384 of file pncmesh.hpp.

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