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.
treatment_jobs.h
Go to the documentation of this file.
1 /*
2 ** Copyright 2014-2020 The Earlham Institute
3 **
4 ** Licensed under the Apache License, Version 2.0 (the "License");
5 ** you may not use this file except in compliance with the License.
6 ** You may obtain a copy of the License at
7 **
8 ** http://www.apache.org/licenses/LICENSE-2.0
9 **
10 ** Unless required by applicable law or agreed to in writing, software
11 ** distributed under the License is distributed on an "AS IS" BASIS,
12 ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 ** See the License for the specific language governing permissions and
14 ** limitations under the License.
15 */
16 /*
17  * treatment_factor_jobs.h
18  *
19  * Created on: 9 Mar 2020
20  * Author: billy
21  */
22 
23 #ifndef SERVICES_FIELD_TRIALS_INCLUDE_TREATMENT_JOBS_H_
24 #define SERVICES_FIELD_TRIALS_INCLUDE_TREATMENT_JOBS_H_
25 
27 #include "treatment.h"
28 
29 
30 #ifdef __cplusplus
31 extern "C"
32 {
33 #endif
34 
35 
37 
38 
40 
41 
43 
44 
46 
47 
48 DFW_FIELD_TRIAL_SERVICE_LOCAL json_t *GetAllTreatmentsAsJSON (const FieldTrialServiceData *data_p, bson_t *opts_p);
49 
50 
51 DFW_FIELD_TRIAL_SERVICE_LOCAL Treatment *GetTreatmentByIdString (const char *treatment_id_s, const ViewFormat format, const FieldTrialServiceData *data_p);
52 
53 
54 DFW_FIELD_TRIAL_SERVICE_LOCAL Treatment *GetTreatmentById (const bson_oid_t *id_p, const ViewFormat format, const FieldTrialServiceData *data_p);
55 
56 
57 DFW_FIELD_TRIAL_SERVICE_LOCAL Treatment *GetTreatmentByURL (const char *term_url_s, const ViewFormat format, const FieldTrialServiceData *data_p);
58 
59 
61 
62 
63 #ifdef __cplusplus
64 }
65 #endif
66 
67 
68 #endif /* SERVICES_FIELD_TRIALS_INCLUDE_TREATMENT_JOBS_H_ */
AddTreatmentToServiceJob
bool AddTreatmentToServiceJob(ServiceJob *job_p, Treatment *treatment_p, const ViewFormat format, FieldTrialServiceData *data_p)
GetTreatmentIndexingData
json_t * GetTreatmentIndexingData(Service *service_p)
ParameterType
ParameterType
The different types that a Parameter can take.
Definition: parameter_type.h:35
ServiceJob
A datatype to represent a running task.
Definition: service_job.h:72
GetTreatmentById
Treatment * GetTreatmentById(const bson_oid_t *id_p, const ViewFormat format, const FieldTrialServiceData *data_p)
DataResource
A datatype representing a URI.
Definition: data_resource.h:40
Treatment
A treatment defines an experimental process that can be applied.
Definition: treatment.h:40
dfw_field_trial_service_library.h
DFW_FIELD_TRIAL_SERVICE_LOCAL
#define DFW_FIELD_TRIAL_SERVICE_LOCAL
Definition: dfw_field_trial_service_library.h:43
treatment.h
Service
A datatype which defines an available service, its capabilities and its parameters.
Definition: service.h:153
GetAllTreatmentsAsJSON
json_t * GetAllTreatmentsAsJSON(const FieldTrialServiceData *data_p, bson_t *opts_p)
AddSubmissionTreatmentParams
bool AddSubmissionTreatmentParams(ServiceData *data_p, ParameterSet *param_set_p, DataResource *resource_p)
ServiceData
A datatype for holding the configuration data for a Service.
Definition: service.h:126
GetTreatmentByURL
Treatment * GetTreatmentByURL(const char *term_url_s, const ViewFormat format, const FieldTrialServiceData *data_p)
RunForSubmissionTreatmentParams
bool RunForSubmissionTreatmentParams(FieldTrialServiceData *data_p, ParameterSet *param_set_p, ServiceJob *job_p)
FieldTrialServiceData
The configuration data used by the DFW Field Trial Service.
Definition: dfw_field_trial_service_data.h:118
ViewFormat
ViewFormat
An indicator of what the output destination is for the JSON data values.
Definition: view_format.h:19
ParameterSet
A set of Parameters along with an optional name and description.
Definition: parameter_set.h:46
GetSubmissionTreatmentParameterTypeForNamedParameter
bool GetSubmissionTreatmentParameterTypeForNamedParameter(const char *param_name_s, ParameterType *pt_p)
GetTreatmentByIdString
Treatment * GetTreatmentByIdString(const char *treatment_id_s, const ViewFormat format, const FieldTrialServiceData *data_p)