Re: Do IMPs move once they're loaded?
Re: Do IMPs move once they're loaded?
- Subject: Re: Do IMPs move once they're loaded?
- From: Marcel Weiher <email@hidden>
- Date: Sun, 30 Jan 2005 23:54:23 +0000
On 30 Jan 2005, at 05:35, Ken Tozier wrote:
If you read a chunk of data off disk and don't know beforehand what
it's type is,
Why don't you know what its "type" is?
you have to do some sort of test, either of a predefined code, or a
string or something saved with the data and dispatch it yourself.
Why do you "have" to do this? I would just make *all* my objects
respond to a *single* message and make it their responsibility to then
map that to whatever is appropriate for them. No need to encode
selectors...
Originally I was hoping that SELs were fixed in size and value so that
it would be possible to save them as a sort of data prefix and read
them back at a later time something like this
You are aware of the fact that you can just archive SELs? Foundation
will do the right thing with them.
(Assume "data_chunk" has just been read from disk)
[self performSelector: *(SEL*) data_chunk ...];
Seemed like a pretty clean way to solve the problem but alas it was
not to be...
What's wrong with -encodeValueOfObjCType and the correspinding decode
method?
Cheers,
Marcel
--
Marcel Weiher Metaobject Software Technologies
email@hidden www.metaobject.com
The simplicity of power HOM, IDEAs, MetaAd etc.
1d480c25f397c4786386135f8e8938e4
_______________________________________________
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