diff options
Diffstat (limited to 'src/iobasicGH.h')
-rw-r--r-- | src/iobasicGH.h | 50 |
1 files changed, 37 insertions, 13 deletions
diff --git a/src/iobasicGH.h b/src/iobasicGH.h index fe1cb16..d9c6b9a 100644 --- a/src/iobasicGH.h +++ b/src/iobasicGH.h @@ -1,9 +1,9 @@ /*@@ - @header iobasic.h + @header iobasicGH.h @date Friday 18th September 1999 @author Gabrielle Allen - @desc - The extensions to the GH structure from IOBasic. + @desc + The extensions to the GH structure from IOBasic. @enddesc @version $Header$ @@*/ @@ -11,25 +11,40 @@ #include "StoreNamedData.h" -typedef struct IOBASICGH { +typedef struct IOBASIC_REDUCTION +{ + int handle; + char *name; + char is_valid; + CCTK_REAL value; + struct IOBASIC_REDUCTION *next; +} iobasic_reduction_t; +typedef struct IOBASIC_REDUCTIONLIST +{ + unsigned int num_reductions; + iobasic_reduction_t *reductions; +} iobasic_reductionlist_t; + +typedef struct IOBASIC_GH +{ /* how often to output */ int outScalar_every; int outInfo_every; + char info_reductions_changed; - /* flags indicating output for var [i] */ - char *do_outInfo; + /* flags indicating output for variable i */ char *do_outScalar; - /* directory in which to output */ + /* directory in which to place scalar output */ char *outdirScalar; /* The last iteration output */ int *outInfo_last; int *outScalar_last; - /* The values for info */ - CCTK_REAL **infovals; + /* The reduction lists for info output for all variables */ + iobasic_reductionlist_t *info_reductions; /* database for names of output files that were already created */ pNamedData *filenameListScalar; @@ -37,7 +52,16 @@ typedef struct IOBASICGH { } iobasicGH; -/* function prototypes */ -void IOBasic_Write (cGH *GH, int vindex, const char *alias); -void IOBasic_WriteGF (cGH *GH, int vindex, const char *alias); -int IOBasic_WriteInfo (cGH *GH, CCTK_REAL *val,int vindex, const char *operator, const char *alias); +/* prototypes of functions to be registered */ +int IOBasic_InfoOutputGH (cGH *GH); +int IOBasic_TriggerInfoOutput (cGH *GH, int vindex); +int IOBasic_TimeForInfoOutput (cGH *GH, int vindex); +int IOBasic_ScalarOutputGH (cGH *GH); +int IOBasic_TriggerScalarOutput (cGH *GH, int vindex); +int IOBasic_TimeForScalarOutput (cGH *GH, int vindex); +int IOBasic_ScalarOutputVarAs (cGH *GH, const char *vname, const char *alias); + +/* other function prototypes */ +void IOBasic_WriteInfo (cGH *GH, int vindex); +void IOBasic_WriteScalarGS (cGH *GH, int vindex, const char *alias); +void IOBasic_WriteScalarGA (cGH *GH, int vindex, const char *alias); |