Diffusion C API  6.3.3
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
args.h File Reference

Utilities for parsing command line arguments, as used in the examples. More...

Data Structures

struct  arg_opts_s
 This structure represents a possible argument to an application. More...
 

Macros

#define ARG_REQUIRED
 The argument is mandatory. More...
 
#define ARG_OPTIONAL
 The argument is optional. More...
 
#define ARG_HAS_VALUE
 The argument is followed by a value. More...
 
#define ARG_NO_VALUE
 The argument is not followed by a value. More...
 
#define ARG_OPTS_HELP
 Default argument declaration for "help". More...
 
#define END_OF_ARG_OPTS
 Default "end of arguments" declaration. More...
 

Typedefs

typedef struct arg_opts_s ARG_OPTS_T
 This structure represents a possible argument to an application.
 

Functions

HASH_Tparse_cmdline (int argc, char **argv, ARG_OPTS_T *arg_opts)
 Parse argc/argv according to an array of ARG_OPTS_T (which itself is terminated by a entry in the form of END_OF_ARG_OPTS).
 
void show_usage (int argc, char **argv, ARG_OPTS_T *arg_opts)
 Display usage information to stdout.
 

Detailed Description

Utilities for parsing command line arguments, as used in the examples.

Copyright © 2014, 2015 Push Technology Ltd., All Rights Reserved.

Use is subject to license terms.

NOTICE: All information contained herein is, and remains the property of Push Technology. The intellectual and technical concepts contained herein are proprietary to Push Technology and may be covered by U.S. and Foreign Patents, patents in process, and are protected by trade secret or copyright law.

Macro Definition Documentation

#define ARG_HAS_VALUE

The argument is followed by a value.

#define ARG_NO_VALUE

The argument is not followed by a value.

#define ARG_OPTIONAL

The argument is optional.

#define ARG_OPTS_HELP

Default argument declaration for "help".

#define ARG_REQUIRED

The argument is mandatory.

#define END_OF_ARG_OPTS

Default "end of arguments" declaration.