• 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
Calling class methods from other class methods
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Calling class methods from other class methods


  • Subject: Calling class methods from other class methods
  • From: Ken Tozier <email@hidden>
  • Date: Thu, 6 Feb 2003 23:33:38 -0500

Given a class MyClass with two class methods, the first:

+ (BOOL) method1:(unichar) inChar
{
/* do stuff here */
}


Which of the following is the correct way to call class method 1 from class method 2?

+ (BOOL) method2:(unichar) inChar
{
return [self method1:inChar];
}

or

+ (BOOL) method2:(unichar) inChar
{
return [MyClass method1:inChar];
}


Thanks,

Ken
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Calling class methods from other class methods
      • From: Jeff Disher <email@hidden>
  • Prev by Date: Drag&Drop onto Button
  • Next by Date: Re: NEWBIE: where to start my thread
  • Previous by thread: Re: Drag&Drop onto Button
  • Next by thread: Re: Calling class methods from other class methods
  • Index(es):
    • Date
    • Thread