3

Is it possible to repeat the same option with multitoken? For instance, is it possible from this line :

-t algo1 5 7 9 -t algo2 6 2

to obtain something like the following vector of vector?

  ___   ___
| ___ | ___ |
   |     |
   v     v
  ___   ___
 algo1 algo2
  ___   ___
   5     6
  ___   ___
   7     2
  ___   ___
   9
  ___

I tried:

value<vector<vector<string>>>()->multitoken()

but I have:

  ___   ___   ___   ___   ___   ___   ___
| ___ | ___ | ___ | ___ | ___ | ___ | ___ |
   |     |     |     |     |     |     |
   v     v     v     v     v     v     v
  ___   ___   ___   ___   ___   ___   ___
 algo1   5     7     9   algo2   6     2
  ___   ___   ___   ___   ___   ___   ___

What can I do ?

Thanks

benlaug
  • 2,691
  • 2
  • 17
  • 15
  • The answer is given here: https://stackoverflow.com/questions/35133523/c-boost-program-options-multiple-lists-of-arguments – benlaug Oct 29 '18 at 16:04

0 Answers0