C/C++ Based Parameter Parsing Solution

darkjester

Golden Member
Aug 14, 2001
1,424
0
0
Hi! I'm writing a C program for work and it looks like it'll have quite a few parameters. I was thinking of taking the good ol' "positional parameter" route but I thought I might branch out and see what kind of parameter-parsing solutions are out there and recommended by you guys and gals.

The program is in C or C++ (I can write it in either) so I was thinking there might be some classes out there that would make it easy. In fact, I know there are a few out there, but I was wondering if anyone here on AT had any experience with any and could recommend one that was effective and somewhat easy.

Any advice is much appreciated! Thanks! :D
 

Armitage

Banned
Feb 23, 2001
8,086
0
0
I like GetPot myself (http://getpot.sourceforge.net/)

Apparently this guy has some issue with the military - on the site he has a note next to the LGPL notice that it is for "non-military" use only :roll:
But in the souce, it just references the LGPL

I doubt that it's enforceable, but I'll likely find another or roll my own sometime - much of my work is with the Air Force.
 

Barnaby W. Füi

Elite Member
Aug 14, 2001
12,343
0
0
I made one once, although I'm not quite sure I like the way I designed it. As happens all too often, I became annoyed at the issue and just stopped caring.

example.cc