LORENE
|
Storage of array dimensions. More...
#include <dim_tbl.h>
Public Member Functions | |
Dim_tbl (int size0) | |
1D constructor More... | |
Dim_tbl (int size1, int size0) | |
2D constructor More... | |
Dim_tbl (int size2, int size1, int size0) | |
3D constructor More... | |
Dim_tbl (int n, int *sizes) | |
N_dimensional constructor. More... | |
Dim_tbl (const Dim_tbl &) | |
Copy constructor. More... | |
Dim_tbl (FILE *) | |
Constructor from a file (see sauve(FILE*) ) More... | |
~Dim_tbl () | |
Destructor. More... | |
void | operator= (const Dim_tbl &) |
Assignment. More... | |
void | sauve (FILE *) const |
Save in a file. More... | |
bool | operator== (const Dim_tbl &) const |
Comparison operator. More... | |
Public Attributes | |
int | ndim |
Number of dimensions of the Tbl: can be 1, 2 or 3. More... | |
int * | dim |
Array of dimensions (size: ndim ). More... | |
int | taille |
Total size of the array Tbl::t . More... | |
Friends | |
ostream & | operator<< (ostream &, const Dim_tbl &) |
Display. More... | |
Storage of array dimensions.
This class is designed for internal purposes related to the class Tbl}
, namely the storage of the Tbl}
dimensions. ()
|
explicit |
Lorene::Dim_tbl::Dim_tbl | ( | int | size1, |
int | size0 | ||
) |
2D constructor
size1 | [input] Defines the range [0, size1-1] of the outermost index in the storage of the array Tbl::t . Will be assigned to dim [1]. |
size0 | [input] Defines the range [0, size0-1] of the innermost index in the storage of the array Tbl::t . Will be assigned to dim [0]. |
Lorene::Dim_tbl::Dim_tbl | ( | int | size2, |
int | size1, | ||
int | size0 | ||
) |
3D constructor
size2 | [input] Defines the range [0, size2-1] of the outermost index in the storage of the array Tbl::t . Will be assigned to dim [2]. |
size1 | [input] Defines the range [0, size1-1] of the intermediate index in the storage of the array Tbl::t . Will be assigned to dim [1]. |
size0 | [input] Defines the range [0, size0-1] of the innermost index in the storage of the array Tbl::t . Will be assigned to dim [0]. |
Lorene::Dim_tbl::Dim_tbl | ( | int | n, |
int * | sizes | ||
) |
Lorene::Dim_tbl::Dim_tbl | ( | const Dim_tbl & | titi | ) |
|
explicit |
void Lorene::Dim_tbl::operator= | ( | const Dim_tbl & | titi | ) |
bool Lorene::Dim_tbl::operator== | ( | const Dim_tbl & | ti | ) | const |
void Lorene::Dim_tbl::sauve | ( | FILE * | fd | ) | const |
Save in a file.
Definition at line 185 of file dim_tbl.C.
References dim, Lorene::fwrite_be(), and ndim.
|
friend |
int* Lorene::Dim_tbl::dim |
int Lorene::Dim_tbl::ndim |
int Lorene::Dim_tbl::taille |