• 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
NSValueTransformer subclass doesn't recognise copyWithZone. So?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSValueTransformer subclass doesn't recognise copyWithZone. So?


  • Subject: NSValueTransformer subclass doesn't recognise copyWithZone. So?
  • From: John Lombardo <email@hidden>
  • Date: Thu, 6 May 2004 19:06:59 +0800

When trying to use my NSValueTransformer subclass I get the following error:

*** -[BBStringToNumberTransformer copyWithZone:]: selector not recognized

Has anyone else had this before? I haven't seen anyone else implementing any Copying protocols, so I don't understand where the problem is. I've even tried commenting out the entire -transformedValue: block to no avail. Replacing BBStringToNumberTransformer with NSValueTransformer gave the same copyWithZone: error, which isolated the problem to my use of it. Below are the relevant code samples:

+ (void)initialize
{
BBStringToNumberTransformer *transformer = [[[BBStringToNumberTransformer alloc] init] retain];
[NSValueTransformer setValueTransformer:transformer forName:@"StringToNumberTransformer"];
}


...
if ([[[recordArray lastObject] objectForKey:key] isEqualToString:@"int4"])
[bindingOptions setObject:[NSValueTransformer valueTransformerForName:@"StringToNumberTransformer"] forKey:@"NSValueTransformerName"];

[[lookupTable tableColumnWithIdentifier:key]
bind:@"value"
toObject: recordController
withKeyPath:[NSString stringWithFormat:@"arrangedObjects.%@", key]
options:bindingOptions];
...
_______________________________________________
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: NSValueTransformer subclass doesn't recognise copyWithZone. So?
      • From: Fritz Anderson <email@hidden>
  • Prev by Date: Re: Refreshing subviews
  • Next by Date: How to reset a long log...
  • Previous by thread: Re: script for setting up .app dir?
  • Next by thread: Re: NSValueTransformer subclass doesn't recognise copyWithZone. So?
  • Index(es):
    • Date
    • Thread