Hide class implementation from driver?

This is a discussion on Hide class implementation from driver? within the C++ Programming forums, part of the General Programming Boards category; Is there a way to hide a class implementation from a driver?
I want to be able to have a ...

>I want to be able to have a driver file that can instantiate an object from CLASS A, but not be able to instantiate anything or access anything from CLASS B.
Nest class B within class A's private section and make class A a friend of class B to access B's private members from A: