#include <stdio.h>
#include <stdlib.h>
#include <assert.h>
#include <string.h>
#include <ctype.h>
#include <errno.h>
#include "zhash.h"
#include "zarray.h"
#include "getopt.h"
#include "common/math_util.h"
Go to the source code of this file.
|  | 
| static char * | get_arg_assignment (char *arg) | 
|  | 
| void | getopt_add_bool (getopt_t *gopt, char sopt, const char *lname, int def, const char *help) | 
|  | 
| void | getopt_add_double (getopt_t *gopt, char sopt, const char *lname, const char *def, const char *help) | 
|  | 
| void | getopt_add_int (getopt_t *gopt, char sopt, const char *lname, const char *def, const char *help) | 
|  | 
| void | getopt_add_spacer (getopt_t *gopt, const char *s) | 
|  | 
| void | getopt_add_string (getopt_t *gopt, char sopt, const char *lname, const char *def, const char *help) | 
|  | 
| getopt_t * | getopt_create () | 
|  | 
| void | getopt_destroy (getopt_t *gopt) | 
|  | 
| void | getopt_do_usage (getopt_t *gopt) | 
|  | 
| int | getopt_get_bool (getopt_t *getopt, const char *lname) | 
|  | 
| double | getopt_get_double (getopt_t *getopt, const char *lname) | 
|  | 
| const zarray_t * | getopt_get_extra_args (getopt_t *gopt) | 
|  | 
| int | getopt_get_int (getopt_t *getopt, const char *lname) | 
|  | 
| const char * | getopt_get_string (getopt_t *gopt, const char *lname) | 
|  | 
| char * | getopt_get_usage (getopt_t *gopt) | 
|  | 
| static void | getopt_modify_string (char **str, char *newvalue) | 
|  | 
| void | getopt_option_destroy (getopt_option_t *goo) | 
|  | 
| int | getopt_parse (getopt_t *gopt, int argc, char *argv[], int showErrors) | 
|  | 
| int | getopt_was_specified (getopt_t *getopt, const char *lname) | 
|  | 
◆ GOO_BOOL_TYPE
◆ GOO_STRING_TYPE
      
        
          | #define GOO_STRING_TYPE   2 | 
      
 
 
◆ getopt_option_t
◆ get_arg_assignment()
  
  | 
        
          | static char* get_arg_assignment | ( | char * | arg | ) |  |  | static | 
 
 
◆ getopt_add_bool()
      
        
          | void getopt_add_bool | ( | getopt_t * | gopt, | 
        
          |  |  | char | sopt, | 
        
          |  |  | const char * | lname, | 
        
          |  |  | int | def, | 
        
          |  |  | const char * | help | 
        
          |  | ) |  |  | 
      
 
 
◆ getopt_add_double()
      
        
          | void getopt_add_double | ( | getopt_t * | gopt, | 
        
          |  |  | char | sopt, | 
        
          |  |  | const char * | lname, | 
        
          |  |  | const char * | def, | 
        
          |  |  | const char * | help | 
        
          |  | ) |  |  | 
      
 
 
◆ getopt_add_int()
      
        
          | void getopt_add_int | ( | getopt_t * | gopt, | 
        
          |  |  | char | sopt, | 
        
          |  |  | const char * | lname, | 
        
          |  |  | const char * | def, | 
        
          |  |  | const char * | help | 
        
          |  | ) |  |  | 
      
 
 
◆ getopt_add_spacer()
      
        
          | void getopt_add_spacer | ( | getopt_t * | gopt, | 
        
          |  |  | const char * | s | 
        
          |  | ) |  |  | 
      
 
 
◆ getopt_add_string()
      
        
          | void getopt_add_string | ( | getopt_t * | gopt, | 
        
          |  |  | char | sopt, | 
        
          |  |  | const char * | lname, | 
        
          |  |  | const char * | def, | 
        
          |  |  | const char * | help | 
        
          |  | ) |  |  | 
      
 
 
◆ getopt_create()
◆ getopt_destroy()
◆ getopt_do_usage()
◆ getopt_get_bool()
      
        
          | int getopt_get_bool | ( | getopt_t * | getopt, | 
        
          |  |  | const char * | lname | 
        
          |  | ) |  |  | 
      
 
 
◆ getopt_get_double()
      
        
          | double getopt_get_double | ( | getopt_t * | getopt, | 
        
          |  |  | const char * | lname | 
        
          |  | ) |  |  | 
      
 
 
◆ getopt_get_extra_args()
◆ getopt_get_int()
      
        
          | int getopt_get_int | ( | getopt_t * | getopt, | 
        
          |  |  | const char * | lname | 
        
          |  | ) |  |  | 
      
 
 
◆ getopt_get_string()
      
        
          | const char* getopt_get_string | ( | getopt_t * | gopt, | 
        
          |  |  | const char * | lname | 
        
          |  | ) |  |  | 
      
 
 
◆ getopt_get_usage()
      
        
          | char* getopt_get_usage | ( | getopt_t * | gopt | ) |  | 
      
 
 
◆ getopt_modify_string()
  
  | 
        
          | static void getopt_modify_string | ( | char ** | str, |  
          |  |  | char * | newvalue |  
          |  | ) |  |  |  | static | 
 
 
◆ getopt_option_destroy()
◆ getopt_parse()
      
        
          | int getopt_parse | ( | getopt_t * | gopt, | 
        
          |  |  | int | argc, | 
        
          |  |  | char * | argv[], | 
        
          |  |  | int | showErrors | 
        
          |  | ) |  |  | 
      
 
 
◆ getopt_was_specified()
      
        
          | int getopt_was_specified | ( | getopt_t * | getopt, | 
        
          |  |  | const char * | lname | 
        
          |  | ) |  |  |