#include <source/hierarchy/dlbg/LayerNode.h>
Support for message passing | |
void | putToIntBuffer (int *buffer) const |
Put self into a int buffer. | |
void | getFromIntBuffer (const int *buffer) |
Set self according to data in int buffer. | |
static int | commBufferSize () |
Give number of ints required in message passing buffer. | |
Public Types | |
typedef int | LocalIndex |
Public Member Functions | |
LayerNode () | |
Constructor. | |
LayerNode (const hier::Box< DIM > &box, const LocalIndex index=-1, const int owner_rank=-1) | |
Constructor. | |
virtual | ~LayerNode (void) |
Destructor. | |
int | getOwnerRank () const |
LocalIndex | getLocalIndex () const |
hier::Box< DIM > & | getBox () |
const hier::Box< DIM > & | getBox () const |
Comparison operators | |
bool | operator== (const LayerNode &r) const |
Equality operator. | |
bool | operator!= (const LayerNode &r) const |
Inequality operator. | |
bool | operator< (const LayerNode &r) const |
Less-than operator. | |
bool | operator> (const LayerNode &r) const |
Greater-than operator. | |
bool | operator<= (const LayerNode &r) const |
Less-than-or-equal-to operator. | |
bool | operator>= (const LayerNode &r) const |
Greater-thanor-equal-to operator. | |
Friends | |
template<int D> | |
std::ostream & | operator<< (std::ostream &co, const LayerNode< D > &r) |
A DLBG node is basically a box with a specific owner process and an index on that process.
Comparison operators are implemented for sorting nodes and instantiating (STL) sets of LayerNode's. The owners and local indices are used for all comparisons The owners ranks are compared first, followed by the local indices. Less-than and greater-than comparisons are primarily used for sorting nodes.
typedef int SAMRAI::hier::LayerNode< DIM >::LocalIndex |
SAMRAI::hier::LayerNode< DIM >::LayerNode | ( | ) | [inline] |
Constructor.
SAMRAI::hier::LayerNode< DIM >::LayerNode | ( | const hier::Box< DIM > & | box, | |
const LocalIndex | index = -1 , |
|||
const int | owner_rank = -1 | |||
) | [inline] |
Constructor.
SAMRAI::hier::LayerNode< DIM >::~LayerNode | ( | void | ) | [virtual] |
Destructor.
Deallocate internal data.
int SAMRAI::hier::LayerNode< DIM >::getOwnerRank | ( | ) | const [inline] |
int SAMRAI::hier::LayerNode< DIM >::getLocalIndex | ( | ) | const [inline] |
hier::Box< DIM > & SAMRAI::hier::LayerNode< DIM >::getBox | ( | ) | [inline] |
const hier::Box< DIM > & SAMRAI::hier::LayerNode< DIM >::getBox | ( | ) | const [inline] |
bool SAMRAI::hier::LayerNode< DIM >::operator== | ( | const LayerNode< DIM > & | r | ) | const [inline] |
Equality operator.
For the equality operator, The box should be the same if data is consistent. If debug is turned on and the boxes do not match while the owners and indices match, then an unrecoverable exception is thrown.
bool SAMRAI::hier::LayerNode< DIM >::operator!= | ( | const LayerNode< DIM > & | r | ) | const [inline] |
Inequality operator.
See note on comparison for operator==(const LayerNode&);
bool SAMRAI::hier::LayerNode< DIM >::operator< | ( | const LayerNode< DIM > & | r | ) | const [inline] |
Less-than operator.
See note on comparison for operator==(const LayerNode&);
bool SAMRAI::hier::LayerNode< DIM >::operator> | ( | const LayerNode< DIM > & | r | ) | const [inline] |
Greater-than operator.
See note on comparison for operator==(const LayerNode&);
bool SAMRAI::hier::LayerNode< DIM >::operator<= | ( | const LayerNode< DIM > & | r | ) | const [inline] |
Less-than-or-equal-to operator.
See note on comparison for operator==(const LayerNode&);
bool SAMRAI::hier::LayerNode< DIM >::operator>= | ( | const LayerNode< DIM > & | r | ) | const [inline] |
Greater-thanor-equal-to operator.
See note on comparison for operator==(const LayerNode&);
int SAMRAI::hier::LayerNode< DIM >::commBufferSize | ( | ) | [inline, static] |
Give number of ints required in message passing buffer.
This number is independent of instance (but dependent on dimension).
void SAMRAI::hier::LayerNode< DIM >::putToIntBuffer | ( | int * | buffer | ) | const [inline] |
Put self into a int buffer.
Number of ints written is given by communicationSize().
void SAMRAI::hier::LayerNode< DIM >::getFromIntBuffer | ( | const int * | buffer | ) | [inline] |
Set self according to data in int buffer.
Number of ints read is given by communicationSize().
std::ostream& operator<< | ( | std::ostream & | co, | |
const LayerNode< D > & | r | |||
) | [friend] |