[interfacekit] Re: BRoster & BWindow
- From: "Adi Oanca" <e2joseph@xxxxxxxxxx>
- To: <interfacekit@xxxxxxxxxxxxx>
- Date: Thu, 10 Apr 2003 20:52:15 +0300
"Adi Oanca" <e2joseph@xxxxxxxxxx> wrote:
> > Hello Ingo!
> >
> > Ingo, I want to make the following call:
> > be_roster->UpdateActiveApp( be_app->Team() );
> >
> > BRoster::UpdateActiveApp( tead_id );
> > is private. I see that BWindow is not a friend of BRoster.
> > What should I do?
> Sorry, I forgot to mention that.
> To clean up the mess a bit, I removed
> all of BRoster's friends, save a new class BRoster::Private
> (declared in headers/private/app/RosterPrivate.h).
> Just add a UpdateActiveApp() method there, that simply
> invokes the roster's private method. Then, you can call
> BRoster::Private().UpdateActiveApp(be_app->Team()).
It seems to me that you've complicated things! What's wrong in BRoster
having BWindow as a friend?
I've read "An Idea" topic Erik opened in Oct 2001, and I must say, that,
I do not agree! Why is it you guys do not want to see more than 2 friends
for a class? What's wrong a class having 2 or more friends? Image, if I
would implement, as Erik said, the BWindowInternals class. By the number of
private method calls and private member access between BView and BWindow(
also valuable for BWindow - BView), I would have to write dozens of new
lines! And those lines would look like the one Ingo wrote to me:
BWindow::Private().xxxxxyyyy(...);
or
BWindow::Private().member; <----- ???!!!
Come on... that is no way to write a clear source code!!!
Adi.
- Follow-Ups:
- [interfacekit] Re: BRoster & BWindow
- From: Ingo Weinhold
Other related posts:
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- » [interfacekit] Re: BRoster & BWindow
- [interfacekit] Re: BRoster & BWindow
- From: Ingo Weinhold