[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
friend Object Scope Modifier
friend identifier;
A friend can be either an object or a class that, while not a member
of another class, can access fully any private and protected members
of that class.
-------------------------------- Example ---------------------------------
class birds {
friend bees;
int num_finches;
int increment_num_finches(void);
};
class bees {
int num_honeybees;
int increment_num_honeybees(void);
}
See Also: class private protected public
Online resources provided by: http://www.ClipX.Net --- NG 2 HTML conversion by Dave Pearson