• 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: loading in accessors from dictionary item...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: loading in accessors from dictionary item...


  • Subject: Re: loading in accessors from dictionary item...
  • From: Ondra Cada <email@hidden>
  • Date: Fri, 20 Feb 2004 23:38:56 +0100

On Friday, Feb 20, 2004, at 23:28 Europe/Prague, email@hidden wrote:

the accessors are just strings in the dictionary when i try

[subclass [dict objectForKey:@"accessor"]];

to references the accessor it just says parse error before "objectForKey"
i figure i'm doing this wrong but i can't figure out how to make it work?

any suggestions?

I guess you actually want something like

[subclass performSelector:NSSelectorFromString([dict objectForKey:@"accessor"])];

but it is quite possible another approach would be better. Do read the ObjC and Foundation documentation!
---
Ondra Hada
OCSoftware: email@hidden http://www.ocs.cz
private email@hidden http://www.ocs.cz/oc
_______________________________________________
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.
References: 
 >loading in accessors from dictionary item... (From: email@hidden)

  • Prev by Date: Parsing an apache config file
  • Next by Date: Re: loading in accessors from dictionary item...
  • Previous by thread: loading in accessors from dictionary item...
  • Next by thread: Re: loading in accessors from dictionary item...
  • Index(es):
    • Date
    • Thread