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.
|
#include "blast_app_parameters.h"
#include "blast_formatter.h"
#include "blast_service_api.h"
#include "parameter_set.h"
#include "temp_file.hpp"
#include "async_tasks_manager.h"
Go to the source code of this file.
Data Structures | |
struct | DatabaseInfo |
A datatype describing the details of each database available to search against. More... | |
struct | BlastServiceData |
The configuration data for the Blast Service. More... | |
Macros | |
#define | BS_DEFAULT_OUTPUT_FORMAT (11) |
The default output format as a number to use. More... | |
#define | BS_GROUP_ALIAS_PREFIX_S "blast" |
The prefix to use for Blast Service aliases. More... | |
Typedefs | |
typedef bool(* | AddAdditionalParamsFn) (BlastServiceData *data_p, ParameterSet *param_set_p, ParameterGroup *group_p, const void *callback_data_p) |
A callback function used to amend a given ParameterSet. More... | |
Enumerations | |
enum | DatabaseType { DT_NUCLEOTIDE, DT_PROTEIN, DT_NUM_TYPES } |
An enumeration for differentiating between the different types of database that the BLAST algorithms can be used with. More... | |
enum | BlastServiceType { BST_BLASTN, BST_BLASTP, BST_BLASTX, BST_NUM_TYPES } |
An enumeration for differentiating between the differentBLAST algorithms that can be used. More... | |
Functions | |
ServicesArray * | GetServices (User *user_p, GrassrootsServer *grassroots_p) |
Get the Services available for running BLAST jobs. More... | |
void | ReleaseServices (ServicesArray *services_p) |
Free the ServicesArray and its associated BLAST Services. More... | |
ServiceJobSet * | RunBlastService (Service *service_p, ParameterSet *param_set_p, User *user_p, ProvidersStateTable *providers_p, BlastAppParameters *app_params_p) |
Run a Blast Service. More... | |
bool | CloseBlastService (Service *service_p) |
Close a Blast Service. More... | |
ParameterSet * | IsResourceForBlastService (Service *service_p, DataResource *resource_p, Handler *handler_p) |
Check whether a given Resource is suitable for running a Blast Service for and if so return the partially-completed ParameterSet. More... | |
bool | AddBaseBlastServiceParameters (Service *blast_service_p, ParameterSet *param_set_p, DataResource *resource_p, const DatabaseType db_type, AddAdditionalParamsFn query_sequence_callback_fn, void *callback_data_p) |
Add the common Blast Service parameters to a given ParameterSet. More... | |
bool | GetBaseBlastServiceParameterTypeForNamedParameter (const Service *service_p, const char *param_name_s, ParameterType *pt_p) |
void | ReleaseBlastServiceParameters (Service *service_p, ParameterSet *params_p) |
Free a ParameterSet of Blast Service parameters. More... | |
bool | DetermineBlastResult (struct BlastServiceJob *job_p) |
Get the results of a given BlastServiceJob and store them within it. More... | |
OperationStatus | GetBlastServiceStatus (Service *service_p, const uuid_t service_id) |
Get the OperationStatus for a BlastServiceJob with the given job id. More... | |
TempFile * | GetInputTempFile (const ParameterSet *params_p, const char *working_directory_s, const uuid_t job_id) |
Get the TempFile detailing the query for a given BlastServiceJob UUID. More... | |
char * | GetBlastResultByUUID (const BlastServiceData *data_p, const uuid_t job_id, const uint32 output_format_code, const char *output_format_params_s) |
Get the result of a previously ran BlastServiceJob in a given output format. More... | |
char * | GetBlastResultByUUIDString (const BlastServiceData *data_p, const char *job_id_s, const uint32 output_format_code, const char *output_format_params_s) |
Get the result of a previously ran BlastServiceJob in a given output format. More... | |
ServiceJobSet * | GetPreviousJobResults (LinkedList *ids_p, BlastServiceData *blast_data_p, const uint32 output_format_code, const char *output_format_params_s) |
Get the results of previously ran BlastServiceJobs in a given output format. More... | |
ServiceJobSet * | CreateJobsForPreviousResults (ParameterSet *params_p, const char *ids_s, BlastServiceData *blast_data_p) |
Get the results of previously ran BlastServiceJobs in a given output format. More... | |
void | PrepareBlastServiceJobs (const DatabaseInfo *db_p, const ParameterSet *const param_set_p, Service *service_p, BlastServiceData *data_p) |
Prepare a ServiceJobSet of BlastServiceJobs prior to running them. More... | |
ServiceJob * | BuildBlastServiceJob (struct Service *service_p, const json_t *service_job_json_p) |
Create a BlastServiceJob from a JSON-based serialisation. More... | |
json_t * | BuildBlastServiceJobJSON (Service *service_p, ServiceJob *service_job_p, bool omit_results_flag) |
Get the JSON representation of a BlastServiceJob. More... | |
const char * | GetMatchingDatabaseFilename (const BlastServiceData *data_p, const char *name_s) |
For a given service-configured name, find the corresponding BLAST database filename. More... | |
const char * | GetMatchingDatabaseName (const BlastServiceData *data_p, const char *filename_s) |
For a given BLAST database filename, find the corresponding service-configured name. More... | |
ServiceMetadata * | GetGeneralBlastServiceMetadata (Service *service_p) |
const DatabaseInfo * | GetMatchingDatabaseByFilename (const BlastServiceData *data_p, const char *filename_s) |
For a given BLAST database filename, find the corresponding DatabaseInfo object. More... | |
void | ReleaseBlastService (Service *service_p) |
json_t * | GetBlastIndexingData (Service *service_p) |
Variables | |
const char * | BS_INPUT_SUFFIX_S = ".input" |
The suffix to use for Blast Service input files. More... | |
const char * | BS_OUTPUT_SUFFIX_S = ".output" |
The suffix to use for Blast Service output files. More... | |
const char * | BS_LOG_SUFFIX_S = ".log" |
The suffix to use for Blast Service log files. More... | |
const char * | BS_DEFAULT_OUTPUT_FORMAT_S = "11" |
The default output format as a string to use. More... | |
const char * | BS_DATABASE_GROUP_NAME_S = "Available Databases" |
The prefix to use for the ParameterGroup names for available databases from all of the connected servers. More... | |
const char * | BS_DATABASES_S = "databases" |
const char * | BS_TOOL_TYPE_NAME_S = "blast_tool" |
The configuration key used to declare which type of BlastTool to use. More... | |
const char * | BS_COMMAND_NAME_S = "blast_command" |
The configuration key used to declare the Blast executable file to use. More... | |
const char * | BS_APP_NAME_S = "blast_app_type" |
The configuration key used to declare the type of Blast application to use. More... | |
#define BS_DEFAULT_OUTPUT_FORMAT (11) |
The default output format as a number to use.
#define BS_GROUP_ALIAS_PREFIX_S "blast" |
The prefix to use for Blast Service aliases.
typedef bool(* AddAdditionalParamsFn) (BlastServiceData *data_p, ParameterSet *param_set_p, ParameterGroup *group_p, const void *callback_data_p) |
A callback function used to amend a given ParameterSet.
data_p | The configuration data for the Blast Service. |
param_set_p | The ParameterSet that the callback function's Parameters will be added to. |
group_p | The optional ParameterGroup to add the generated Parameter to. This can be NULL . |
true
if the callback function's parameters were added successfully, false
otherwise. bool GetBaseBlastServiceParameterTypeForNamedParameter | ( | const Service * | service_p, |
const char * | param_name_s, | ||
ParameterType * | pt_p | ||
) |
ServiceMetadata* GetGeneralBlastServiceMetadata | ( | Service * | service_p | ) |
void ReleaseBlastService | ( | Service * | service_p | ) |
json_t* GetBlastIndexingData | ( | Service * | service_p | ) |
const char* BS_INPUT_SUFFIX_S = ".input" |
The suffix to use for Blast Service input files.
const char* BS_OUTPUT_SUFFIX_S = ".output" |
The suffix to use for Blast Service output files.
const char* BS_LOG_SUFFIX_S = ".log" |
The suffix to use for Blast Service log files.
const char* BS_DEFAULT_OUTPUT_FORMAT_S = "11" |
The default output format as a string to use.
const char* BS_DATABASE_GROUP_NAME_S = "Available Databases" |
The prefix to use for the ParameterGroup names for available databases from all of the connected servers.
const char* BS_DATABASES_S = "databases" |
const char* BS_TOOL_TYPE_NAME_S = "blast_tool" |
The configuration key used to declare which type of BlastTool to use.
const char* BS_COMMAND_NAME_S = "blast_command" |
The configuration key used to declare the Blast executable file to use.
const char* BS_APP_NAME_S = "blast_app_type" |
The configuration key used to declare the type of Blast application to use.