using friend
-
Visual Studio 2008, c++ Class C_Messages does a bunch of work with structures loosely named messages. There is much configuration required so it instantiates a class called C_Configuration to read a text file and initialize many things. Right now a method in C_Messages calls some methods in C_Configuration and hands it pointers to the various structures within Messages. Then C_Configuration can directly access those structures. Is there a way I can declare C_Configuration as a friend of C_Messages and dispense with the pointer passing. Something like: In file C_Messages.h
Class C_Configuration;
Class C_Messages
{ ...
friend C_Configuration;
int x;
};Thank you for your time If you work with telemetry, please check this bulletin board: www.irigbb.com