aboutsummaryrefslogtreecommitdiff
path: root/Carpet/CarpetLib/src/gf.cc
diff options
context:
space:
mode:
authorschnetter <>2003-10-14 14:39:00 +0000
committerschnetter <>2003-10-14 14:39:00 +0000
commitfad00e54fbb8c02501d69318ad9a273bd426297a (patch)
treedec086d7cdf464cbb379c5488b7668c8f9b385f8 /Carpet/CarpetLib/src/gf.cc
parent4aa9136c5d2e909262f1d8ff84e32e936be97a28 (diff)
Make gf and data objects store a Cactus variable index that this
Make gf and data objects store a Cactus variable index that this object is associated with. This can be used to access various kinds of information, e.g. variable names. darcs-hash:20031014143916-07bb3-678d114393008db7790b5ed72d6462673414c06a.gz
Diffstat (limited to 'Carpet/CarpetLib/src/gf.cc')
-rw-r--r--Carpet/CarpetLib/src/gf.cc10
1 files changed, 6 insertions, 4 deletions
diff --git a/Carpet/CarpetLib/src/gf.cc b/Carpet/CarpetLib/src/gf.cc
index 5824bbcac..8de652672 100644
--- a/Carpet/CarpetLib/src/gf.cc
+++ b/Carpet/CarpetLib/src/gf.cc
@@ -1,7 +1,9 @@
-// $Header: /home/eschnett/C/carpet/Carpet/Carpet/CarpetLib/src/gf.cc,v 1.12 2003/09/19 16:06:41 schnetter Exp $
+// $Header: /home/eschnett/C/carpet/Carpet/Carpet/CarpetLib/src/gf.cc,v 1.13 2003/10/14 16:39:16 schnetter Exp $
#include <assert.h>
+#include "cctk.h"
+
#include "defs.hh"
#include "gf.hh"
@@ -13,9 +15,9 @@ using namespace std;
// Constructors
// VGF
template<class T,int D>
-gf<T,D>::gf (const string name, th<D>& t, dh<D>& d,
+gf<T,D>::gf (const int varindex, th<D>& t, dh<D>& d,
const int tmin, const int tmax, const int prolongation_order_time)
- : ggf<D>(name, t, d, tmin, tmax, prolongation_order_time)
+ : ggf<D>(varindex, t, d, tmin, tmax, prolongation_order_time)
{
// VGF
this->recompose();
@@ -53,7 +55,7 @@ template<class T,int D>
ostream& gf<T,D>::output (ostream& os) const {
T Tdummy;
os << "gf<" << typestring(Tdummy) << "," << D << ">:"
- << "\"" << this->name << "\","
+ << this->varindex << "[" << CCTK_VarName(this->varindex) << "],"
<< "dt=[" << this->tmin << ":" << this->tmax<< "]";
return os;
}