Tiger App Fails: loadDataRepresentation:ofType: ??
Tiger App Fails: loadDataRepresentation:ofType: ??
- Subject: Tiger App Fails: loadDataRepresentation:ofType: ??
- From: Seth Willits <email@hidden>
- Date: Mon, 25 Jul 2005 12:39:04 -0700
I have a document class which has implemented:
- (NSData *)dataOfType:(NSString *)typeName error:(NSError **)outError;
- (BOOL)readFromData:(NSData *)data ofType:(NSString *)typeName error:
(NSError **)outError;
Which are the two new methods in NSDocument for Tiger which replace
the data representation methods. However, whenever I try to open a
document, my app complains:
"loadDataRepresentation:ofType: is a subclass responsibility but has
not been overridden."
The NSDocument header states:
"For backward binary compatibility with Mac OS 10.3 and earlier, the
default implementation of [readFromData:ofType:error:] instead
invokes [self loadDataRepresentation:data ofType:typeName] if -
loadDataRepresentation:ofType: is overridden."
So it seems to me something strange is going on. I don't use
loadDataRepresentation:ofType:, and I definitely do use
readFromData:ofType:error:, so how or why the superclass's
readFromData:ofType:error: method is calling
loadDataRepresentation:ofType: and then causing an error is beyond me.
Ideas?
--
Seth Willits
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden