• 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: @selector not working with (id)anObject
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: @selector not working with (id)anObject


  • Subject: Re: @selector not working with (id)anObject
  • From: Sherm Pendley <email@hidden>
  • Date: Sat, 11 Apr 2009 21:08:21 -0400

2009/4/11 Trygve Inda <email@hidden>

I have a thread. Depending on how it is called, I need to do something
> different at the end of the main processing so I wanted to pass a selector
> into the thread so it could call it when it was ready.
>
> I could just pass an NSNumber and do case1, case2 etc, but thought it'd be
> nice to just do the equivalent of passing a function pointer.


You could create an NSInvocation object and pass that.

sherm--

--
Cocoa programming in Perl: http://camelbones.sourceforge.net
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: @selector not working with (id)anObject
      • From: Trygve Inda <email@hidden>
References: 
 >Re: @selector not working with (id)anObject (From: Bill Bumgarner <email@hidden>)
 >Re: @selector not working with (id)anObject (From: Trygve Inda <email@hidden>)

  • Prev by Date: Re: @selector not working with (id)anObject
  • Next by Date: Re: @selector not working with (id)anObject
  • Previous by thread: Re: @selector not working with (id)anObject
  • Next by thread: Re: @selector not working with (id)anObject
  • Index(es):
    • Date
    • Thread