Add missing binaty and statis library
[jabaws.git] / binaries / src / ViennaRNA / Progs / RNAfold_cmdl.h
1 /** @file RNAfold_cmdl.h
2  *  @brief The header file for the command line option parser
3  *  generated by GNU Gengetopt version 2.22.5
4  *  http://www.gnu.org/software/gengetopt.
5  *  DO NOT modify this file, since it can be overwritten
6  *  @author GNU Gengetopt by Lorenzo Bettini */
7
8 #ifndef RNAFOLD_CMDL_H
9 #define RNAFOLD_CMDL_H
10
11 /* If we use autoconf.  */
12 #ifdef HAVE_CONFIG_H
13 #include "config.h"
14 #endif
15
16 #include <stdio.h> /* for FILE */
17
18 #ifdef __cplusplus
19 extern "C" {
20 #endif /* __cplusplus */
21
22 #ifndef RNAFOLD_CMDLINE_PARSER_PACKAGE
23 /** @brief the program name (used for printing errors) */
24 #define RNAFOLD_CMDLINE_PARSER_PACKAGE "RNAfold"
25 #endif
26
27 #ifndef RNAFOLD_CMDLINE_PARSER_PACKAGE_NAME
28 /** @brief the complete program name (used for help and version) */
29 #define RNAFOLD_CMDLINE_PARSER_PACKAGE_NAME "RNAfold"
30 #endif
31
32 #ifndef RNAFOLD_CMDLINE_PARSER_VERSION
33 /** @brief the program version */
34 #define RNAFOLD_CMDLINE_PARSER_VERSION VERSION
35 #endif
36
37 /** @brief Where the command line options are stored */
38 struct RNAfold_args_info
39 {
40   const char *help_help; /**< @brief Print help and exit help description.  */
41   const char *detailed_help_help; /**< @brief Print help, including all details and hidden options, and exit help description.  */
42   const char *full_help_help; /**< @brief Print help, including hidden options, and exit help description.  */
43   const char *version_help; /**< @brief Print version and exit help description.  */
44   int constraint_flag;  /**< @brief Calculate structures subject to constraints.
45  (default=off).  */
46   const char *constraint_help; /**< @brief Calculate structures subject to constraints.
47  help description.  */
48   int noconv_flag;      /**< @brief Do not automatically substitude nucleotide \"T\" with \"U\"
49   
50  (default=off).  */
51   const char *noconv_help; /**< @brief Do not automatically substitude nucleotide \"T\" with \"U\"
52   
53  help description.  */
54   int noPS_flag;        /**< @brief Do not produce postscript drawing of the mfe structure.
55   
56  (default=off).  */
57   const char *noPS_help; /**< @brief Do not produce postscript drawing of the mfe structure.
58   
59  help description.  */
60   int partfunc_arg;     /**< @brief Calculate the partition function and base pairing probability matrix.
61  (default='1').  */
62   char * partfunc_orig; /**< @brief Calculate the partition function and base pairing probability matrix.
63  original value given at command line.  */
64   const char *partfunc_help; /**< @brief Calculate the partition function and base pairing probability matrix.
65  help description.  */
66   float MEA_arg;        /**< @brief Calculate an MEA (maximum expected accuracy) structure, where the expected accuracy is computed from the pair probabilities: each base pair (i,j) gets a score 2*gamma*p_ij and the score of an unpaired base is given by the probability of not forming a pair.
67  (default='1.').  */
68   char * MEA_orig;      /**< @brief Calculate an MEA (maximum expected accuracy) structure, where the expected accuracy is computed from the pair probabilities: each base pair (i,j) gets a score 2*gamma*p_ij and the score of an unpaired base is given by the probability of not forming a pair.
69  original value given at command line.  */
70   const char *MEA_help; /**< @brief Calculate an MEA (maximum expected accuracy) structure, where the expected accuracy is computed from the pair probabilities: each base pair (i,j) gets a score 2*gamma*p_ij and the score of an unpaired base is given by the probability of not forming a pair.
71  help description.  */
72   double pfScale_arg;   /**< @brief In the calculation of the pf use scale*mfe as an estimate for the ensemble free energy (used to avoid overflows).
73 .  */
74   char * pfScale_orig;  /**< @brief In the calculation of the pf use scale*mfe as an estimate for the ensemble free energy (used to avoid overflows).
75  original value given at command line.  */
76   const char *pfScale_help; /**< @brief In the calculation of the pf use scale*mfe as an estimate for the ensemble free energy (used to avoid overflows).
77  help description.  */
78   int circ_flag;        /**< @brief Assume a circular (instead of linear) RNA molecule.
79  (default=off).  */
80   const char *circ_help; /**< @brief Assume a circular (instead of linear) RNA molecule.
81  help description.  */
82   int ImFeelingLucky_flag;      /**< @brief Return exactly one stochastically backtracked structure
83  (default=off).  */
84   const char *ImFeelingLucky_help; /**< @brief Return exactly one stochastically backtracked structure
85  help description.  */
86   double bppmThreshold_arg;     /**< @brief Set the threshold for base pair probabilities included in the postscript output
87  (default='1e-5').  */
88   char * bppmThreshold_orig;    /**< @brief Set the threshold for base pair probabilities included in the postscript output
89  original value given at command line.  */
90   const char *bppmThreshold_help; /**< @brief Set the threshold for base pair probabilities included in the postscript output
91  help description.  */
92   int gquad_flag;       /**< @brief Incoorporate G-Quadruplex formation into the structure prediction algorithm
93  (default=off).  */
94   const char *gquad_help; /**< @brief Incoorporate G-Quadruplex formation into the structure prediction algorithm
95  help description.  */
96   double temp_arg;      /**< @brief Rescale energy parameters to a temperature of temp C. Default is 37C.
97   
98 .  */
99   char * temp_orig;     /**< @brief Rescale energy parameters to a temperature of temp C. Default is 37C.
100   
101  original value given at command line.  */
102   const char *temp_help; /**< @brief Rescale energy parameters to a temperature of temp C. Default is 37C.
103   
104  help description.  */
105   int noTetra_flag;     /**< @brief Do not include special tabulated stabilizing energies for tri-, tetra- and hexaloop hairpins. Mostly for testing.
106   
107  (default=off).  */
108   const char *noTetra_help; /**< @brief Do not include special tabulated stabilizing energies for tri-, tetra- and hexaloop hairpins. Mostly for testing.
109   
110  help description.  */
111   int dangles_arg;      /**< @brief How to treat \"dangling end\" energies for bases adjacent to helices in free ends and multi-loops
112  (default='2').  */
113   char * dangles_orig;  /**< @brief How to treat \"dangling end\" energies for bases adjacent to helices in free ends and multi-loops
114  original value given at command line.  */
115   const char *dangles_help; /**< @brief How to treat \"dangling end\" energies for bases adjacent to helices in free ends and multi-loops
116  help description.  */
117   int noLP_flag;        /**< @brief Produce structures without lonely pairs (helices of length 1).
118  (default=off).  */
119   const char *noLP_help; /**< @brief Produce structures without lonely pairs (helices of length 1).
120  help description.  */
121   int noGU_flag;        /**< @brief Do not allow GU pairs
122   
123  (default=off).  */
124   const char *noGU_help; /**< @brief Do not allow GU pairs
125   
126  help description.  */
127   int noClosingGU_flag; /**< @brief Do not allow GU pairs at the end of helices
128   
129  (default=off).  */
130   const char *noClosingGU_help; /**< @brief Do not allow GU pairs at the end of helices
131   
132  help description.  */
133   char * paramFile_arg; /**< @brief Read energy parameters from paramfile, instead of using the default parameter set.
134 .  */
135   char * paramFile_orig;        /**< @brief Read energy parameters from paramfile, instead of using the default parameter set.
136  original value given at command line.  */
137   const char *paramFile_help; /**< @brief Read energy parameters from paramfile, instead of using the default parameter set.
138  help description.  */
139   char * nsp_arg;       /**< @brief Allow other pairs in addition to the usual AU,GC,and GU pairs.
140 .  */
141   char * nsp_orig;      /**< @brief Allow other pairs in addition to the usual AU,GC,and GU pairs.
142  original value given at command line.  */
143   const char *nsp_help; /**< @brief Allow other pairs in addition to the usual AU,GC,and GU pairs.
144  help description.  */
145   int energyModel_arg;  /**< @brief Rarely used option to fold sequences from the artificial ABCD... alphabet, where A pairs B, C-D etc.  Use the energy parameters for GC (-e 1) or AU (-e 2) pairs.
146   
147 .  */
148   char * energyModel_orig;      /**< @brief Rarely used option to fold sequences from the artificial ABCD... alphabet, where A pairs B, C-D etc.  Use the energy parameters for GC (-e 1) or AU (-e 2) pairs.
149   
150  original value given at command line.  */
151   const char *energyModel_help; /**< @brief Rarely used option to fold sequences from the artificial ABCD... alphabet, where A pairs B, C-D etc.  Use the energy parameters for GC (-e 1) or AU (-e 2) pairs.
152   
153  help description.  */
154   double betaScale_arg; /**< @brief Set the scaling of the Boltzmann factors
155  (default='1.').  */
156   char * betaScale_orig;        /**< @brief Set the scaling of the Boltzmann factors
157  original value given at command line.  */
158   const char *betaScale_help; /**< @brief Set the scaling of the Boltzmann factors
159  help description.  */
160   
161   unsigned int help_given ;     /**< @brief Whether help was given.  */
162   unsigned int detailed_help_given ;    /**< @brief Whether detailed-help was given.  */
163   unsigned int full_help_given ;        /**< @brief Whether full-help was given.  */
164   unsigned int version_given ;  /**< @brief Whether version was given.  */
165   unsigned int constraint_given ;       /**< @brief Whether constraint was given.  */
166   unsigned int noconv_given ;   /**< @brief Whether noconv was given.  */
167   unsigned int noPS_given ;     /**< @brief Whether noPS was given.  */
168   unsigned int partfunc_given ; /**< @brief Whether partfunc was given.  */
169   unsigned int MEA_given ;      /**< @brief Whether MEA was given.  */
170   unsigned int pfScale_given ;  /**< @brief Whether pfScale was given.  */
171   unsigned int circ_given ;     /**< @brief Whether circ was given.  */
172   unsigned int ImFeelingLucky_given ;   /**< @brief Whether ImFeelingLucky was given.  */
173   unsigned int bppmThreshold_given ;    /**< @brief Whether bppmThreshold was given.  */
174   unsigned int gquad_given ;    /**< @brief Whether gquad was given.  */
175   unsigned int temp_given ;     /**< @brief Whether temp was given.  */
176   unsigned int noTetra_given ;  /**< @brief Whether noTetra was given.  */
177   unsigned int dangles_given ;  /**< @brief Whether dangles was given.  */
178   unsigned int noLP_given ;     /**< @brief Whether noLP was given.  */
179   unsigned int noGU_given ;     /**< @brief Whether noGU was given.  */
180   unsigned int noClosingGU_given ;      /**< @brief Whether noClosingGU was given.  */
181   unsigned int paramFile_given ;        /**< @brief Whether paramFile was given.  */
182   unsigned int nsp_given ;      /**< @brief Whether nsp was given.  */
183   unsigned int energyModel_given ;      /**< @brief Whether energyModel was given.  */
184   unsigned int betaScale_given ;        /**< @brief Whether betaScale was given.  */
185
186 } ;
187
188 /** @brief The additional parameters to pass to parser functions */
189 struct RNAfold_cmdline_parser_params
190 {
191   int override; /**< @brief whether to override possibly already present options (default 0) */
192   int initialize; /**< @brief whether to initialize the option structure RNAfold_args_info (default 1) */
193   int check_required; /**< @brief whether to check that all required options were provided (default 1) */
194   int check_ambiguity; /**< @brief whether to check for options already specified in the option structure RNAfold_args_info (default 0) */
195   int print_errors; /**< @brief whether getopt_long should print an error message for a bad option (default 1) */
196 } ;
197
198 /** @brief the purpose string of the program */
199 extern const char *RNAfold_args_info_purpose;
200 /** @brief the usage string of the program */
201 extern const char *RNAfold_args_info_usage;
202 /** @brief all the lines making the help output */
203 extern const char *RNAfold_args_info_help[];
204 /** @brief all the lines making the full help output (including hidden options) */
205 extern const char *RNAfold_args_info_full_help[];
206 /** @brief all the lines making the detailed help output (including hidden options and details) */
207 extern const char *RNAfold_args_info_detailed_help[];
208
209 /**
210  * The command line parser
211  * @param argc the number of command line options
212  * @param argv the command line options
213  * @param args_info the structure where option information will be stored
214  * @return 0 if everything went fine, NON 0 if an error took place
215  */
216 int RNAfold_cmdline_parser (int argc, char **argv,
217   struct RNAfold_args_info *args_info);
218
219 /**
220  * The command line parser (version with additional parameters - deprecated)
221  * @param argc the number of command line options
222  * @param argv the command line options
223  * @param args_info the structure where option information will be stored
224  * @param override whether to override possibly already present options
225  * @param initialize whether to initialize the option structure my_args_info
226  * @param check_required whether to check that all required options were provided
227  * @return 0 if everything went fine, NON 0 if an error took place
228  * @deprecated use RNAfold_cmdline_parser_ext() instead
229  */
230 int RNAfold_cmdline_parser2 (int argc, char **argv,
231   struct RNAfold_args_info *args_info,
232   int override, int initialize, int check_required);
233
234 /**
235  * The command line parser (version with additional parameters)
236  * @param argc the number of command line options
237  * @param argv the command line options
238  * @param args_info the structure where option information will be stored
239  * @param params additional parameters for the parser
240  * @return 0 if everything went fine, NON 0 if an error took place
241  */
242 int RNAfold_cmdline_parser_ext (int argc, char **argv,
243   struct RNAfold_args_info *args_info,
244   struct RNAfold_cmdline_parser_params *params);
245
246 /**
247  * Save the contents of the option struct into an already open FILE stream.
248  * @param outfile the stream where to dump options
249  * @param args_info the option struct to dump
250  * @return 0 if everything went fine, NON 0 if an error took place
251  */
252 int RNAfold_cmdline_parser_dump(FILE *outfile,
253   struct RNAfold_args_info *args_info);
254
255 /**
256  * Save the contents of the option struct into a (text) file.
257  * This file can be read by the config file parser (if generated by gengetopt)
258  * @param filename the file where to save
259  * @param args_info the option struct to save
260  * @return 0 if everything went fine, NON 0 if an error took place
261  */
262 int RNAfold_cmdline_parser_file_save(const char *filename,
263   struct RNAfold_args_info *args_info);
264
265 /**
266  * Print the help
267  */
268 void RNAfold_cmdline_parser_print_help(void);
269 /**
270  * Print the full help (including hidden options)
271  */
272 void RNAfold_cmdline_parser_print_full_help(void);
273 /**
274  * Print the detailed help (including hidden options and details)
275  */
276 void RNAfold_cmdline_parser_print_detailed_help(void);
277 /**
278  * Print the version
279  */
280 void RNAfold_cmdline_parser_print_version(void);
281
282 /**
283  * Initializes all the fields a RNAfold_cmdline_parser_params structure 
284  * to their default values
285  * @param params the structure to initialize
286  */
287 void RNAfold_cmdline_parser_params_init(struct RNAfold_cmdline_parser_params *params);
288
289 /**
290  * Allocates dynamically a RNAfold_cmdline_parser_params structure and initializes
291  * all its fields to their default values
292  * @return the created and initialized RNAfold_cmdline_parser_params structure
293  */
294 struct RNAfold_cmdline_parser_params *RNAfold_cmdline_parser_params_create(void);
295
296 /**
297  * Initializes the passed RNAfold_args_info structure's fields
298  * (also set default values for options that have a default)
299  * @param args_info the structure to initialize
300  */
301 void RNAfold_cmdline_parser_init (struct RNAfold_args_info *args_info);
302 /**
303  * Deallocates the string fields of the RNAfold_args_info structure
304  * (but does not deallocate the structure itself)
305  * @param args_info the structure to deallocate
306  */
307 void RNAfold_cmdline_parser_free (struct RNAfold_args_info *args_info);
308
309 /**
310  * Checks that all the required options were specified
311  * @param args_info the structure to check
312  * @param prog_name the name of the program that will be used to print
313  *   possible errors
314  * @return
315  */
316 int RNAfold_cmdline_parser_required (struct RNAfold_args_info *args_info,
317   const char *prog_name);
318
319
320 #ifdef __cplusplus
321 }
322 #endif /* __cplusplus */
323 #endif /* RNAFOLD_CMDL_H */