My class has a method that takes a class ( data class) as parameter and I want to put a default value if the caller won't supply it like
Qt Code:
  1. class::function(int a = 3);
To copy to clipboard, switch view to plain text mode 
kinda thing.

so here's what i did

Qt Code:
  1. class A
  2. {
  3. public:
  4. class B
  5. {
  6. int x;
  7. };
  8. A()
  9. { defaultB.x = 3};
  10. run(B options = defaultB); // compiler complains about non-static defaultB which is correct
  11. private:
  12. B defaultB;
  13. };
To copy to clipboard, switch view to plain text mode 

do you guys know of any way that i can implement default on my methods passing a class ?

baray98