diff options
author | goodale <goodale@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 1999-08-26 15:34:20 +0000 |
---|---|---|
committer | goodale <goodale@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 1999-08-26 15:34:20 +0000 |
commit | 5e90d4682484a0b9cbc232d0005bcda3895f6c9f (patch) | |
tree | d14c7ec57f48fd431663326f9c7b55900846aa47 /src/include | |
parent | 9a643dc37c6334abd06d70688d2e1494c435bbf2 (diff) |
New parameter stuff.
Now a non-active thorn's extensions to parameters shouldn't be valid,
range checking is now done, even for strings, which must conform to
a regular expression.
Tom
git-svn-id: http://svn.cactuscode.org/flesh/trunk@859 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'src/include')
-rw-r--r-- | src/include/ActiveThorns.h | 5 | ||||
-rw-r--r-- | src/include/ParameterBindings.h | 21 | ||||
-rw-r--r-- | src/include/cctk_ActiveThorns.h | 7 |
3 files changed, 32 insertions, 1 deletions
diff --git a/src/include/ActiveThorns.h b/src/include/ActiveThorns.h index 69e54e66..eb1f2f60 100644 --- a/src/include/ActiveThorns.h +++ b/src/include/ActiveThorns.h @@ -21,6 +21,11 @@ int CCTK_IsThornActive(const char *name); int CCTK_IsImplementationActive(const char *name); int CCTKi_ListThorns(FILE *file, const char *format, int active); int CCTKi_ListImplementations(FILE *file, const char *format, int active); +const char *CCTK_ActivatingThorn(const char *imp); + + /* FIXME - should return a list or something */ +t_sktree *CCTK_ImpThornList(const char *imp); + #ifdef __cplusplus } diff --git a/src/include/ParameterBindings.h b/src/include/ParameterBindings.h index 97612df2..1f5da613 100644 --- a/src/include/ParameterBindings.h +++ b/src/include/ParameterBindings.h @@ -10,9 +10,30 @@ #ifndef _PARAMETERBINDINGS_H_ #define _PARAMETERBINDINGS_H_ + +#ifdef __cplusplus +extern "C" { +#endif + +int ParameterCreate(const char *name, /* The parameter name */ + const char *thorn, /* The thorn */ + const char *type, /* The parameter type */ + const char *scope, /* The scoping block */ + int steerable, /* Is it steerable ? */ + const char *description, /* The description */ + const char *defval, /* The default value */ + void *datapointer, /* The actual data */ + int n_ranges, /* How many allowed ranges it has */ + ...); + +#ifdef __cplusplus +} +#endif + #define PARAMETER_KEYWORD 1 #define PARAMETER_STRING 2 #define PARAMETER_SENTENCE 3 +#define PARAMETER_INT 4 #define PARAMETER_INTEGER 4 #define PARAMETER_REAL 5 #define PARAMETER_LOGICAL 6 diff --git a/src/include/cctk_ActiveThorns.h b/src/include/cctk_ActiveThorns.h index bfc6a6ba..eb1f2f60 100644 --- a/src/include/cctk_ActiveThorns.h +++ b/src/include/cctk_ActiveThorns.h @@ -1,5 +1,5 @@ /*@@ - @header cctk_ActiveThorns.h + @header ActiveThorns.h @date Sun Jul 4 17:39:50 1999 @author Tom Goodale @desc @@ -21,6 +21,11 @@ int CCTK_IsThornActive(const char *name); int CCTK_IsImplementationActive(const char *name); int CCTKi_ListThorns(FILE *file, const char *format, int active); int CCTKi_ListImplementations(FILE *file, const char *format, int active); +const char *CCTK_ActivatingThorn(const char *imp); + + /* FIXME - should return a list or something */ +t_sktree *CCTK_ImpThornList(const char *imp); + #ifdef __cplusplus } |