The title might be a bit misleading. I have the following problem: I have a tree consisting of leaves and internal nodes. The user should be able to store any information in
You may do
class Outer { private: // maybe protected: class Inner { public: .... }; };
or
class Outer { public: class Inner { friend class Outer; private: .... }; };