I'm just looking at some example QT code, and I notice that someties in the header file there will be something like so:
Code:
class MyClassPrivate; { public: ...other non relevant stuff... protected: MyClassPrivate *const ptr; private: Q_DECLARE_PRIVATE( MyClass ); };
I'm just curious what does this "macro" do? Does it offer the ability to have a private version of the class? Why do they want a separate Protected Constructor? Can somebody give me an example why it is useful?
Thanks,
Michael