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

Go to the source code of this file.

Data Structures

struct  Crop
 

Functions

const CROP_PREFIX char *CR_NAME_S CROP_CONCAT_VAL (CONTEXT_PREFIX_SCHEMA_ORG_S, "name")
 
const CROP_PREFIX char *CR_AGROVOC_URL_S CROP_CONCAT_VAL (CONTEXT_PREFIX_SCHEMA_ORG_S, "url")
 
const CROP_PREFIX char *CR_AGROVOC_PREFERRED_TERM_S CROP_VAL ("preferred_term")
 
const CROP_PREFIX char *CR_SYNONYMS_S CROP_VAL ("synonyms")
 
CropAllocateCrop (bson_oid_t *id_p, const char *name_s, const char *argovoc_preferred_term_s, const char *agrovoc_uri_s, char **synonyms_ss)
 
void FreeCrop (Crop *crop_p)
 
json_t * GetCropAsJSON (Crop *crop_p, const ViewFormat format, const FieldTrialServiceData *data_p)
 
CropGetCropFromJSON (const json_t *crop_json_p, const FieldTrialServiceData *data_p)
 
bool SaveCrop (Crop *crop_p, const FieldTrialServiceData *data_p)
 
CropGetCropByIdString (const char *id_s, const FieldTrialServiceData *data_p)
 
CropGetCropById (const bson_oid_t *id_p, const FieldTrialServiceData *data_p)
 

Function Documentation

◆ CROP_CONCAT_VAL() [1/2]

const CROP_PREFIX char* CR_NAME_S CROP_CONCAT_VAL ( CONTEXT_PREFIX_SCHEMA_ORG_S  ,
"name"   
)

◆ CROP_CONCAT_VAL() [2/2]

const CROP_PREFIX char* CR_AGROVOC_URL_S CROP_CONCAT_VAL ( CONTEXT_PREFIX_SCHEMA_ORG_S  ,
"url"   
)

◆ CROP_VAL() [1/2]

const CROP_PREFIX char* CR_AGROVOC_PREFERRED_TERM_S CROP_VAL ( "preferred_term"  )

◆ CROP_VAL() [2/2]

const CROP_PREFIX char* CR_SYNONYMS_S CROP_VAL ( "synonyms"  )

◆ AllocateCrop()

Crop* AllocateCrop ( bson_oid_t *  id_p,
const char *  name_s,
const char *  argovoc_preferred_term_s,
const char *  agrovoc_uri_s,
char **  synonyms_ss 
)

◆ FreeCrop()

void FreeCrop ( Crop crop_p)

◆ GetCropAsJSON()

json_t* GetCropAsJSON ( Crop crop_p,
const ViewFormat  format,
const FieldTrialServiceData data_p 
)

◆ GetCropFromJSON()

Crop* GetCropFromJSON ( const json_t *  crop_json_p,
const FieldTrialServiceData data_p 
)

◆ SaveCrop()

bool SaveCrop ( Crop crop_p,
const FieldTrialServiceData data_p 
)

◆ GetCropByIdString()

Crop* GetCropByIdString ( const char *  id_s,
const FieldTrialServiceData data_p 
)

◆ GetCropById()

Crop* GetCropById ( const bson_oid_t *  id_p,
const FieldTrialServiceData data_p 
)