amroc/hds/Coords.h File Reference

A point in the computational domain in global index coordinates. More...

#include "DAGHDefaults.h"
#include "lparx_copyright.h"
#include <iosfwd>
#include <cstdlib>
#include <cassert>

Go to the source code of this file.

Classes

class  Coords
 Implementation of a point in the computational domain in global index coordinates. More...

Defines

#define CoordsNULL   ((Coords *)0)
#define Point_Point_Operator(ope, op)
#define Point_Scalar_Operator(ope, op)

Functions

Coords Max (const Coords &a, const Coords &b)
Coords Min (const Coords &a, const Coords &b)
std::istream & operator>> (std::istream &s, Coords &c)
std::ostream & operator<< (std::ostream &s, const Coords &c)
std::ifstream & operator>> (std::ifstream &s, Coords &c)
std::ofstream & operator<< (std::ofstream &s, const Coords &c)

Detailed Description

A point in the computational domain in global index coordinates.

Author:
Manish Parashar

Define Documentation

#define CoordsNULL   ((Coords *)0)

Referenced by operator<<(), and operator>>().

#define Point_Point_Operator ( ope,
op   ) 
Value:
Coords& operator ope (Coords const &rhs)                     \
     {                                                          \
      c[0] ope rhs.c[0];                                        \
      if (rank>1) c[1] ope rhs.c[1];                            \
      if (rank>2) c[2] ope rhs.c[2];                            \
      return(*this);                                            \
     }                                                          \
   Coords operator op (Coords const &rhs) const                 \
     {                                                          \
      Coords coords(*this);                                     \
      coords ope rhs;                                           \
      return(coords);                                           \
     }
#define Point_Scalar_Operator ( ope,
op   ) 
Value:
Coords& operator ope (int const rhs)                         \
     {                                                          \
      c[0] ope rhs;                                             \
      if (rank>1) c[1] ope rhs;                                 \
      if (rank>2) c[2] ope rhs;                                 \
      return(*this);                                            \
     }                                                          \
   Coords operator op (int const rhs) const                     \
     {                                                          \
      Coords coords(*this);                                     \
      coords ope rhs;                                           \
      return(coords);                                           \
     }

Function Documentation

std::ofstream& operator<< ( std::ofstream &  s,
const Coords c 
)

References CoordsNULL.

std::ostream& operator<< ( std::ostream &  s,
const Coords c 
)
std::ifstream& operator>> ( std::ifstream &  s,
Coords c 
)

References CoordsNULL.

std::istream& operator>> ( std::istream &  s,
Coords c 
)

References MATCH.

Generated on Thu Jun 30 02:19:00 2016 for AMROC's Hierachical Data Structures by  doxygen 1.6.3