• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: class design issue
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: class design issue


  • Subject: Re: class design issue
  • From: Bob Savage <email@hidden>
  • Date: Wed, 30 Jan 2002 01:25:34 -0600

on 1/30/02 1:08 AM, email@hidden wrote:
>
> I may be showing my static typing heritage here, but, won't the compiler
> complain about not knowing about the method signature for someMethod?
> is it considered kosher to compile code with warnings in it? (I'd
> prefer to not import MainController.h)
>

Well you have three options that I know of:

[1] #import MainController.h -- but you said you didn't want to do that,
[2] ignore the compiler warnings -- I also prefer to not have compiler
warnings because I think it makes it difficult to see the real problems when
they arise.
[3] define a @protocol, import that header, and cast the id like so:

[ (id <MainController>)[[NSApplication sharedApplication] delegate]
someMethod ];

Maybe there are more ways of handling it than I know of.

Bob


  • Prev by Date: Re: NSDictionary
  • Next by Date: about UDP
  • Previous by thread: Re: class design issue
  • Next by thread: Re: class design issue
  • Index(es):
    • Date
    • Thread