ThunderEgg  1.0.0
ThunderEgg::NbrInfoBase Class Referenceabstract

Represents information about a patch's neighbor. More...

#include <NbrInfoBase.h>

Inheritance diagram for ThunderEgg::NbrInfoBase:
Collaboration diagram for ThunderEgg::NbrInfoBase:

Public Member Functions

virtual ~NbrInfoBase ()=default
 Destroy the NbrInfo object.
 
virtual NbrType getNbrType () const =0
 Get the NbrType.
 
virtual void getNbrIds (std::deque< int > &nbr_ids) const =0
 Add to a deque of neighbor ids.
 
virtual void getNbrRanks (std::deque< int > &nbr_ranks) const =0
 Add to a deque of neighbor ranks.
 
virtual void setGlobalIndexes (const std::map< int, int > &rev_map)=0
 Set the local indexes in the NbrInfo objects. More...
 
virtual void setLocalIndexes (const std::map< int, int > &rev_map)=0
 Set the global indexes in the NbrInfo objects. More...
 
virtual std::unique_ptr< NbrInfoBaseclone () const =0
 get a clone of this object (equivalent to copy constructor) More...
 
- Public Member Functions inherited from ThunderEgg::Serializable
virtual ~Serializable ()=default
 Destroy the Serializable object.
 
virtual int serialize (char *buffer) const =0
 Serialize object into buffer. More...
 
virtual int deserialize (char *buffer)=0
 Deserialize an object. More...
 

Detailed Description

Represents information about a patch's neighbor.

Includes information like neighbor id and and indexes.

Member Function Documentation

◆ clone()

virtual std::unique_ptr<NbrInfoBase> ThunderEgg::NbrInfoBase::clone ( ) const
pure virtual

get a clone of this object (equivalent to copy constructor)

Returns
std::unique_ptr<NbrInfo> the cloned object

Implemented in ThunderEgg::FineNbrInfo< D >, ThunderEgg::CoarseNbrInfo< D >, and ThunderEgg::NormalNbrInfo< D >.

◆ setGlobalIndexes()

virtual void ThunderEgg::NbrInfoBase::setGlobalIndexes ( const std::map< int, int > &  rev_map)
pure virtual

Set the local indexes in the NbrInfo objects.

Parameters
rev_mapmap from id to local_index

Implemented in ThunderEgg::FineNbrInfo< D >, ThunderEgg::CoarseNbrInfo< D >, and ThunderEgg::NormalNbrInfo< D >.

◆ setLocalIndexes()

virtual void ThunderEgg::NbrInfoBase::setLocalIndexes ( const std::map< int, int > &  rev_map)
pure virtual

Set the global indexes in the NbrInfo objects.

Parameters
rev_mapmap from local_index to global_index

Implemented in ThunderEgg::FineNbrInfo< D >, ThunderEgg::CoarseNbrInfo< D >, and ThunderEgg::NormalNbrInfo< D >.


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