pelib  2.0.0
src/argument_parsing.cpp File Reference
#include <cstdlib>
#include <string>
#include <iostream>
#include <string.h>
#include <pelib/argument_parsing.hpp>
Include dependency graph for argument_parsing.cpp:

Go to the source code of this file.

Defines

#define debug(expr)   cerr << "[" << __FILE__ << ":" << __FUNCTION__ << ":" << __LINE__ << "] " << #expr << " = \"" << expr << "\"." << endl;
#define LIBPELIB   "libpelib-"
#define SO   ".so"

Functions

void pelib_argument_stream_init (pelib_argument_stream_t *pelib_argument_stream)
void pelib_argument_stream_destroy (const pelib_argument_stream_t pelib_argument_stream)
unsigned int pelib_argument_stream_parse (char **argv, pelib_argument_stream_t *stream)

Define Documentation

#define debug (   expr)    cerr << "[" << __FILE__ << ":" << __FUNCTION__ << ":" << __LINE__ << "] " << #expr << " = \"" << expr << "\"." << endl;

Definition at line 33 of file argument_parsing.cpp.

#define LIBPELIB   "libpelib-"
#define SO   ".so"

Function Documentation

Frees all memory that pointers in an instance of pelib argument stram structure points to

Definition at line 50 of file argument_parsing.cpp.

Give defaults values to an instance of pelib argument data structure

Definition at line 38 of file argument_parsing.cpp.

unsigned int pelib_argument_stream_parse ( char **  argv,
pelib_argument_stream_t stream 
)

Performs parsing operations stores data gather in a pelib_argument stream instance

Parameters:
argvArray of strings containing all data to be parsed. Its last element must be a NULL pointer.
streamInstance of pelib argument_stream that holds the data being parsed

Definition at line 99 of file argument_parsing.cpp.