code_junkie

Key-Value coding and its scripting capability

Nov 13th, 2011
91
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. id key, value;
  2. key = [[attributes objectAtIndex:j] name];
  3. value = [[attributes objectAtIndex:j] stringValue];
  4. [obj setValue:value forKey:key];
  5.  
  6. id key, value;
  7. key = [[attributes objectAtIndex:j] name];
  8. value = [NSNumber numberWithInt:[[[attributes objectAtIndex:j] stringValue] intValue]];
  9. [obj setValue:value forKey:key];
Add Comment
Please, Sign In to add comment