MOAB: Mesh Oriented datABase  (version 5.2.1)
moab::Remapper Class Reference

#include <Remapper.hpp>

+ Inheritance diagram for moab::Remapper:

Public Types

enum  IntersectionContext {
  DEFAULT = -1, SourceMesh = 0, TargetMesh = 1, OverlapMesh = 2,
  CoveringMesh = 3
}

Public Member Functions

 Remapper (moab::Interface *mbInt)
virtual ~Remapper ()
moab::Interface * get_interface ()
ErrorCode LoadNativeMesh (std::string filename, moab::EntityHandle &meshset, const char *readopts=0)

Protected Attributes

Interface * m_interface

Detailed Description

Definition at line 38 of file Remapper.hpp.


Member Enumeration Documentation

Enumerator:
DEFAULT 
SourceMesh 
TargetMesh 
OverlapMesh 
CoveringMesh 

Definition at line 57 of file Remapper.hpp.

    {
        DEFAULT      = -1,
        SourceMesh   = 0,
        TargetMesh   = 1,
        OverlapMesh  = 2,
        CoveringMesh = 3
    };

Constructor & Destructor Documentation

moab::Remapper::Remapper ( moab::Interface *  mbInt) [inline]

Definition at line 44 of file Remapper.hpp.

                                     : m_interface( mbInt )
#endif
    {
    }
virtual moab::Remapper::~Remapper ( ) [inline, virtual]

Definition at line 49 of file Remapper.hpp.

References m_interface.

    {
#ifdef MOAB_HAVE_MPI
        m_pcomm = NULL;
#endif
        m_interface = NULL;
    }

Member Function Documentation

moab::Interface* moab::Remapper::get_interface ( ) [inline]

Definition at line 66 of file Remapper.hpp.

References m_interface.

Referenced by moab::TempestOnlineMap::TempestOnlineMap().

    {
        return m_interface;
    }
ErrorCode moab::Remapper::LoadNativeMesh ( std::string  filename,
moab::EntityHandle meshset,
const char *  readopts = 0 
) [inline]

Definition at line 78 of file Remapper.hpp.

References m_interface, and readopts().

Referenced by CreateTempestMesh(), and main().

    {
#ifdef MOAB_HAVE_MPI
        size_t lastindex      = filename.find_last_of( "." );
        std::string extension = filename.substr( lastindex + 1, filename.size() );
        std::string opts      = "";
        if( m_pcomm->size() > 1 )
        {
            if( extension != "h5m" )
                opts = std::string( "PARALLEL=BCAST_DELETE;PARTITION=TRIVIAL;PARALLEL_RESOLVE_SHARED_ENTS" );
            else
                opts = std::string( "PARALLEL=READ_PART;PARTITION=PARALLEL_PARTITION;PARALLEL_"
                                    "RESOLVE_SHARED_ENTS" );
        }

        if( readopts )
        {
            if( opts.size() )
                opts = opts + ";" + std::string( readopts );
            else
                opts = std::string( readopts );
        }

        if( !m_pcomm->rank() ) std::cout << "Reading file (" << filename << ") with options = [" << opts << "]\n";
#else
        const std::string opts = std::string( ( readopts ? readopts : "" ) );
        std::cout << "Reading file (" << filename << ") with options = [" << opts << "]\n";
#endif
        return m_interface->load_file( filename.c_str(), &meshset, opts.c_str() );
    }

Member Data Documentation

List of all members.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines