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.h File Reference
#include "dfw_field_trial_service_library.h"
#include "dfw_field_trial_service_data.h"
#include "key_value_pair.h"
#include "schema_keys.h"
#include "jansson.h"
Include dependency graph for treatment.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  Treatment
 A treatment defines an experimental process that can be applied. More...
 
struct  TreatmentNode
 

Functions

const TREATMENT_PREFIX char *TR_NAME_S TREATMENT_CONCAT_VAL (CONTEXT_PREFIX_SCHEMA_ORG_S, "name")
 
const TREATMENT_PREFIX char *TR_TERM_S TREATMENT_VAL ("term")
 
const TREATMENT_PREFIX char *TR_PARENTS_S TREATMENT_VAL ("parent_name")
 
const TREATMENT_PREFIX char *TR_SYNONYMS_S TREATMENT_VAL ("synonyms")
 
TreatmentAllocateTreatment (SchemaTerm *term_p, char **parent_names_ss, const size_t num_parents, const bool copy_parents_flag, char **synonyms_ss, const size_t num_synonyms, const bool copy_synonyms_flag, bson_oid_t *id_p)
 
void FreeTreatment (Treatment *treatment_p)
 
bool AddTreatmentValueByParts (Treatment *treatment_p, const char *name_s, const char *value_s)
 
bool AddTreatmentValue (Treatment *treatment_p, KeyValuePair *pair_p)
 
void FreeTreatmentNode (ListItem *treatment_node_p)
 
json_t * GetTreatmentAsJSON (const Treatment *treatmnent_p)
 
bool AddTreatmentToJSON (const Treatment *treatment_p, json_t *root_p)
 
TreatmentGetTreatmentFromJSON (const json_t *treatmnent_json_p)
 
TreatmentNodeAllocateTreatmentNode (Treatment *treatment_p, MEM_FLAG treatment_mem)
 

Function Documentation

◆ TREATMENT_CONCAT_VAL()

const TREATMENT_PREFIX char* TR_NAME_S TREATMENT_CONCAT_VAL ( CONTEXT_PREFIX_SCHEMA_ORG_S  ,
"name"   
)

◆ TREATMENT_VAL() [1/3]

const TREATMENT_PREFIX char* TR_TERM_S TREATMENT_VAL ( "term"  )

◆ TREATMENT_VAL() [2/3]

const TREATMENT_PREFIX char* TR_PARENTS_S TREATMENT_VAL ( "parent_name"  )

◆ TREATMENT_VAL() [3/3]

const TREATMENT_PREFIX char* TR_SYNONYMS_S TREATMENT_VAL ( "synonyms"  )

◆ AllocateTreatment()

Treatment* AllocateTreatment ( SchemaTerm term_p,
char **  parent_names_ss,
const size_t  num_parents,
const bool  copy_parents_flag,
char **  synonyms_ss,
const size_t  num_synonyms,
const bool  copy_synonyms_flag,
bson_oid_t *  id_p 
)

◆ FreeTreatment()

void FreeTreatment ( Treatment treatment_p)

◆ AddTreatmentValueByParts()

bool AddTreatmentValueByParts ( Treatment treatment_p,
const char *  name_s,
const char *  value_s 
)

◆ AddTreatmentValue()

bool AddTreatmentValue ( Treatment treatment_p,
KeyValuePair pair_p 
)

◆ FreeTreatmentNode()

void FreeTreatmentNode ( ListItem treatment_node_p)

◆ GetTreatmentAsJSON()

json_t* GetTreatmentAsJSON ( const Treatment treatmnent_p)

◆ AddTreatmentToJSON()

bool AddTreatmentToJSON ( const Treatment treatment_p,
json_t *  root_p 
)

◆ GetTreatmentFromJSON()

Treatment* GetTreatmentFromJSON ( const json_t *  treatmnent_json_p)

◆ AllocateTreatmentNode()

TreatmentNode* AllocateTreatmentNode ( Treatment treatment_p,
MEM_FLAG  treatment_mem 
)