dimanche 5 avril 2015

Alternative to unistd.h getopt using c++ stl

I'm writing a C++ command line application for users that we will be used on various platforms. For this reason, I am writing using only stl. I'm wondering if stl has a nice way to parse input arguments similar to the getopt function used in unistd.h/getopt.h (as these are not platform independent to my knowledge). I've already thought of doing something like while/for loop and switch statements, but wondering if there something a bit more elegant. C++11 is ok, boost is not.


Aucun commentaire:

Enregistrer un commentaire