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.
SystemBlastFormatter Class Reference

This class calls a command line executable to convert a blast job between the available different formats. More...

#include <blast_formatter.h>

Inheritance diagram for SystemBlastFormatter:
[legend]
Collaboration diagram for SystemBlastFormatter:
[legend]

Public Member Functions

virtual ~SystemBlastFormatter ()
 The SystemBlastFormatter destructor. More...
 
virtual char * GetConvertedOutput (const char *job_id_s, const uint32 output_format_code, const char *custom_format_s, const BlastServiceData *data_p)
 The function gets the converted output as a c-style string using its specified command line executable. More...
 
- Public Member Functions inherited from BlastFormatter
 BlastFormatter ()
 
virtual ~BlastFormatter ()
 The BlastFormatter destructor. More...
 
virtual char * GetConvertedOutput (const char *job_id_s, const uint32 output_format_code, const char *custom_format_s, const struct BlastServiceData *data_p)=0
 The function to get the converted output as a c-style string. More...
 

Static Public Member Functions

static SystemBlastFormatterCreate (const json_t *config_p)
 Create a SystemBlastFormatter using the given configuration. More...
 
static char * GetOutputFormatAsString (const uint32 output_format_code, const char *custom_output_formats_s)
 
- Static Public Member Functions inherited from BlastFormatter
static char * GetConvertedOutputFilename (const char *const filename_s, const uint32 output_format_code)
 Get the output filename for the converted output in a given format. More...
 
static bool IsCustomisableOutputFormat (const uint32 output_format_code)
 

Static Public Attributes

static const char *const SBF_LOG_SUFFIX_S
 

Protected Member Functions

bool SaveCommandLine (const char *filename_s, const char *command_line_s)
 

Protected Attributes

const char * sbf_blast_formatter_command_s
 The command line executable used to convert between the different formats. More...
 

Detailed Description

This class calls a command line executable to convert a blast job between the available different formats.

The executable used is the value specified in the global Grassroots server configuration file by the

"services" -> "Blast service" -> "system_formatter_config" -> "command"

key.

Constructor & Destructor Documentation

◆ ~SystemBlastFormatter()

virtual ~SystemBlastFormatter ( )
virtual

The SystemBlastFormatter destructor.

Member Function Documentation

◆ Create()

static SystemBlastFormatter* Create ( const json_t *  config_p)
static

Create a SystemBlastFormatter using the given configuration.

Parameters
config_pThe JSON fragment that is the value of "system_formatter_config" from within the Blast service section of the global Server configuration file.
Returns
A new SystemBlastFormatter or 0 upon error.

◆ GetConvertedOutput()

virtual char* GetConvertedOutput ( const char *  job_id_s,
const uint32  output_format_code,
const char *  custom_format_s,
const BlastServiceData data_p 
)
virtual

The function gets the converted output as a c-style string using its specified command line executable.

Parameters
input_filename_sThe file that is in "BLAST archive format (ASN.1)" format.
output_format_codeThe required output code.
Returns
The converted outpur or NULL upon error.
See also
BlastFormatter::GetConvertedOutput
BlastOutputFormat

◆ GetOutputFormatAsString()

static char* GetOutputFormatAsString ( const uint32  output_format_code,
const char *  custom_output_formats_s 
)
static

◆ SaveCommandLine()

bool SaveCommandLine ( const char *  filename_s,
const char *  command_line_s 
)
protected

Field Documentation

◆ SBF_LOG_SUFFIX_S

const char* const SBF_LOG_SUFFIX_S
static

◆ sbf_blast_formatter_command_s

const char* sbf_blast_formatter_command_s
protected

The command line executable used to convert between the different formats.


The documentation for this class was generated from the following file: