Grassroots Infrastructure
The Grassroots Infrastructure is a suite of computing tools to help users and developers use scientific data infrastructure that can easily be interconnected.
|
Go to the documentation of this file.
23 #ifndef CORE_SHARED_PARAMETERS_INCLUDE_JSON_PARAMETER_H_
24 #define CORE_SHARED_PARAMETERS_INCLUDE_JSON_PARAMETER_H_
42 #ifndef DOXYGEN_SHOULD_SKIP_THIS
44 #ifdef ALLOCATE_JSON_PARAMETER_TAGS
45 #define JSON_PARAM_PREFIX GRASSROOTS_SERVICE_API
46 #define JSON_PARAM_VAL(x) = x
48 #define JSON_PARAM_PREFIX extern GRASSROOTS_SERVICE_API
49 #define JSON_PARAM_VAL(x)
61 JSON_PARAM_PREFIX
const char *TABLE_PARAM_ROW_S
JSON_PARAM_VAL(
"row");
62 JSON_PARAM_PREFIX
const char *TABLE_PARAM_COLUMN_S
JSON_PARAM_VAL(
"column");
93 const char *
const name_s,
const char *
const display_name_s,
const char *
const description_s,
94 const json_t *default_value_p, uint8 level);
98 const char *
const name_s,
const char *
const display_name_s,
const char *
const description_s,
99 const json_t *default_value_p,
const json_t *current_value_p, uint8 level);
The datatype that stores all of the information about a Parameter.
Definition: parameter.h:121
A datatype to tell the system that certain parameters should be grouped together in the client's user...
Definition: parameter_group.h:85
const JSON_PARAM_PREFIX char *TABLE_PARAM_ROW_S JSON_PARAM_VAL("row")
Definition: json_parameter.h:32
ParameterType
The different types that a Parameter can take.
Definition: parameter_type.h:35
json_t * jp_current_value_p
Definition: json_parameter.h:36
Parameter jp_base_param
Definition: json_parameter.h:34
Parameter * CreateAndAddJSONParameterToParameterSet(const struct ServiceData *service_data_p, ParameterSet *params_p, ParameterGroup *group_p, ParameterType type, const char *const name_s, const char *const display_name_s, const char *const description_s, const json_t *default_value_p, const json_t *current_value_p, uint8 level)
#define GRASSROOTS_SERVICE_API
Definition: grassroots_service_library.h:49
const json_t * GetJSONParameterCurrentValue(const JSONParameter *param_p)
const json_t * GetJSONParameterDefaultValue(const JSONParameter *param_p)
json_t * jp_default_value_p
Definition: json_parameter.h:38
JSONParameter * AllocateJSONParameter(const struct ServiceData *service_data_p, const ParameterType pt, const char *const name_s, const char *const display_name_s, const char *const description_s, const json_t *default_value_p, const json_t *current_value_p, ParameterLevel level)
Allocate a JSONParameter.
bool SetJSONParameterCurrentValueFromJSON(JSONParameter *param_p, const json_t *value_p)
void FreeJSONParameter(JSONParameter *param_p)
A datatype which defines an available service, its capabilities and its parameters.
Definition: service.h:153
bool IsJSONParameter(Parameter *param_p)
Parameter * EasyCreateAndAddJSONParameterToParameterSet(const struct ServiceData *service_data_p, ParameterSet *params_p, ParameterGroup *group_p, ParameterType type, const char *const name_s, const char *const display_name_s, const char *const description_s, const json_t *default_value_p, uint8 level)
ParameterLevel
The ParameterLevel defines the level that a user should be to adjust the Parameter.
Definition: parameter.h:52
bool SetJSONParameterCurrentValue(JSONParameter *param_p, const json_t *value_p)
bool GetCurrentJSONParameterValueFromParameterSet(const ParameterSet *const params_p, const char *const name_s, const json_t **value_pp)
JSONParameter * AllocateJSONParameterFromJSON(const json_t *param_json_p, const struct Service *service_p, const bool concise_flag, const ParameterType *pt_p)
A datatype for holding the configuration data for a Service.
Definition: service.h:126
A set of Parameters along with an optional name and description.
Definition: parameter_set.h:46
bool SetJSONParameterDefaultValue(JSONParameter *param_p, const json_t *value_p)