LORENE
dim_tbl.h
1/*
2 * Definition of Lorene class Dim_tbl
3 *
4 */
5
6/*
7 * Copyright (c) 1999-2000 Jean-Alain Marck
8 * Copyright (c) 1999-2001 Eric Gourgoulhon
9 *
10 * This file is part of LORENE.
11 *
12 * LORENE is free software; you can redistribute it and/or modify
13 * it under the terms of the GNU General Public License as published by
14 * the Free Software Foundation; either version 2 of the License, or
15 * (at your option) any later version.
16 *
17 * LORENE is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
21 *
22 * You should have received a copy of the GNU General Public License
23 * along with LORENE; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
26 */
27
28
29#ifndef __DIM_TBL_H_
30#define __DIM_TBL_H_
31
32
33/*
34 * $Id: dim_tbl.h,v 1.7 2014/10/13 08:52:33 j_novak Exp $
35 * $Log: dim_tbl.h,v $
36 * Revision 1.7 2014/10/13 08:52:33 j_novak
37 * Lorene classes and functions now belong to the namespace Lorene.
38 *
39 * Revision 1.6 2014/10/06 15:09:39 j_novak
40 * Modified #include directives to use c++ syntax.
41 *
42 * Revision 1.5 2006/09/25 10:01:45 p_grandclement
43 * Addition of N-dimensional Tbl
44 *
45 * Revision 1.4 2004/03/22 13:12:40 j_novak
46 * Modification of comments to use doxygen instead of doc++
47 *
48 * Revision 1.3 2002/10/16 14:36:28 j_novak
49 * Reorganization of #include instructions of standard C++, in order to
50 * use experimental version 3 of gcc.
51 *
52 * Revision 1.2 2002/06/17 14:05:16 j_novak
53 * friend functions are now also declared outside the class definition
54 *
55 * Revision 1.1.1.1 2001/11/20 15:19:27 e_gourgoulhon
56 * LORENE
57 *
58 * Revision 2.7 1999/11/23 12:16:24 eric
59 * Modif commentaires (dimension 0 autorisee).
60 *
61 * Revision 2.6 1999/10/01 10:17:10 eric
62 * Amelioration des commentaires.
63 *
64 * Revision 2.5 1999/09/30 12:49:09 eric
65 * Constructeur a 1 parametre rendu explicit.
66 * Amelioration des commentaires
67 *
68 * Revision 2.4 1999/09/24 14:22:36 eric
69 * Declaration de methodes const
70 * Amelioration commentaires.
71 *
72 * Revision 2.3 1999/09/22 11:38:59 eric
73 * *** empty log message ***
74 *
75 * Revision 2.2 1999/09/22 11:24:39 eric
76 * Amelioration commentaires
77 *
78 * Revision 2.1 1999/09/16 16:23:52 eric
79 * Doc++
80 *
81 * Revision 2.0 1999/02/15 10:41:51 hyc
82 * *** empty log message ***
83 *
84 * $Header: /cvsroot/Lorene/C++/Include/dim_tbl.h,v 1.7 2014/10/13 08:52:33 j_novak Exp $
85 *
86 */
87
88#include <cstdio>
89
90#include "headcpp.h"
91
92namespace Lorene {
99class Dim_tbl {
100 public:
101 int ndim ;
102 int* dim ;
103
112 int taille ;
113
114 public:
115 // Constructeurs
123 explicit Dim_tbl(int size0) ;
124
137 Dim_tbl(int size1, int size0) ;
138
154 Dim_tbl(int size2, int size1, int size0) ;
155
161 Dim_tbl(int n, int* sizes) ;
162
163 Dim_tbl(const Dim_tbl & ) ;
164
166 explicit Dim_tbl(FILE* ) ;
167
168 ~Dim_tbl() ;
169
170 void operator=(const Dim_tbl &) ;
171
172 void sauve(FILE* ) const ;
173
174 bool operator==(const Dim_tbl &) const ;
175
176 friend ostream& operator<<(ostream& , const Dim_tbl &) ;
177
178};
179ostream& operator<<(ostream& , const Dim_tbl &) ;
180
181}
182#endif
Storage of array dimensions.
Definition dim_tbl.h:99
int taille
Total size of the array Tbl::t.
Definition dim_tbl.h:112
~Dim_tbl()
Destructor.
Definition dim_tbl.C:161
bool operator==(const Dim_tbl &) const
Comparison operator.
Definition dim_tbl.C:208
void sauve(FILE *) const
Save in a file.
Definition dim_tbl.C:185
int * dim
Array of dimensions (size: ndim).
Definition dim_tbl.h:102
friend ostream & operator<<(ostream &, const Dim_tbl &)
Display.
Definition dim_tbl.C:195
int ndim
Number of dimensions of the Tbl: can be 1, 2 or 3.
Definition dim_tbl.h:101
void operator=(const Dim_tbl &)
Assignment.
Definition dim_tbl.C:170
Lorene prototypes.
Definition app_hor.h:64