MOAB: Mesh Oriented datABase  (version 5.4.1)
moab::SplitVertexIndex< _n > Class Template Reference

#include <SplitVertices.hpp>

+ Collaboration diagram for moab::SplitVertexIndex< _n >:

Public Member Functions

 SplitVertexIndex ()
 SplitVertexIndex (const int *src)
 SplitVertexIndex (const SplitVertexIndex< _n > &src)
SplitVertexIndexoperator= (const SplitVertexIndex< _n > &src)
void set_common_processes (const ProcessSet &procs)
ProcessSetcommon_processes ()
const ProcessSetcommon_processes () const
bool operator< (const SplitVertexIndex< _n > &other) const

Public Attributes

int ids [_n+1]
ProcessSet process_set

Detailed Description

template<int _n>
class moab::SplitVertexIndex< _n >

Definition at line 40 of file SplitVertices.hpp.


Constructor & Destructor Documentation

template<int _n>
moab::SplitVertexIndex< _n >::SplitVertexIndex ( ) [inline]

Definition at line 43 of file SplitVertices.hpp.

{}
template<int _n>
moab::SplitVertexIndex< _n >::SplitVertexIndex ( const int *  src) [inline]

Definition at line 44 of file SplitVertices.hpp.

References moab::SplitVertexIndex< _n >::ids.

    {
        for( int i = 0; i < _n; ++i )
            this->ids[i] = src[i];
        std::sort( this->ids, this->ids + _n );
    }
template<int _n>
moab::SplitVertexIndex< _n >::SplitVertexIndex ( const SplitVertexIndex< _n > &  src) [inline]

Definition at line 50 of file SplitVertices.hpp.

References moab::SplitVertexIndex< _n >::ids, and moab::SplitVertexIndex< _n >::process_set.

    {
        for( int i = 0; i < _n; ++i )
            this->ids[i] = src.ids[i];
        this->process_set = src.process_set;
    }

Member Function Documentation

template<int _n>
ProcessSet& moab::SplitVertexIndex< _n >::common_processes ( ) [inline]

Definition at line 68 of file SplitVertices.hpp.

References moab::SplitVertexIndex< _n >::process_set.

    {
        return this->process_set;
    }
template<int _n>
const ProcessSet& moab::SplitVertexIndex< _n >::common_processes ( ) const [inline]

Definition at line 72 of file SplitVertices.hpp.

References moab::SplitVertexIndex< _n >::process_set.

    {
        return this->process_set;
    }
template<int _n>
bool moab::SplitVertexIndex< _n >::operator< ( const SplitVertexIndex< _n > &  other) const [inline]

Definition at line 77 of file SplitVertices.hpp.

References moab::SplitVertexIndex< _n >::ids.

    {
        // Ignore the process set. Only program errors lead to mismatched process sets with
        // identical ids.
        for( int i = 0; i < _n; ++i )
            if( this->ids[i] < other.ids[i] )
                return true;
            else if( this->ids[i] > other.ids[i] )
                return false;
        return false;
    }
template<int _n>
SplitVertexIndex& moab::SplitVertexIndex< _n >::operator= ( const SplitVertexIndex< _n > &  src) [inline]

Definition at line 56 of file SplitVertices.hpp.

References moab::SplitVertexIndex< _n >::ids, and moab::SplitVertexIndex< _n >::process_set.

    {
        for( int i = 0; i < _n; ++i )
            this->ids[i] = src.ids[i];
        this->process_set = src.process_set;
        return *this;
    }
template<int _n>
void moab::SplitVertexIndex< _n >::set_common_processes ( const ProcessSet procs) [inline]

Definition at line 64 of file SplitVertices.hpp.

References moab::SplitVertexIndex< _n >::process_set.

Referenced by moab::SplitVertices< _n >::find_or_create().

    {
        this->process_set = procs;
    }

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