Re: Extending NSKeyValueCoding?
Re: Extending NSKeyValueCoding?
- Subject: Re: Extending NSKeyValueCoding?
- From: Anjo Krank <email@hidden>
- Date: Tue, 28 Oct 2003 10:15:06 +0100
- Xx-reply-to: email@hidden
Hi PA,
Am Dienstag, 28.10.03 um 09:20 Uhr schrieb petite_abeille:
On Oct 28, 2003, at 06:53, Max Muller wrote:
You can add a file named KeyValueCodingProtectedAccessor within a
package if you want to provide your own hooks for accessing
attributes. Included an example.
Thank you very much. I guess this is pretty much what I'm looking for
:)
Note that this class is mainly to provide access for protected
fields/methods as they need to reside in the same package as the
target. So they may or may not be invoked when using public methods.
Any ideas on how to smoothly extend the default NSKeyValueCoding
implementation in the first place? For example, if I want to use KVC in
conjunction with java.util.Collection or such, what do a need to do
short of writing my own KVC scheme or blast my way through
NSKeyValueCoding internals?
It may not help much, but Wonder now has a ERXMutableArray that
implements the List interface (untested, it was write-only for now:).
If you used EOF, then you could at least use this class when creating
relationship arrays and wouldn't need to morph.
If you used WO, then I have a (currently private) WORepetition that
deals with List instead of Vector.
And finally, I have bug report outstanding that NS* should implement
the various Collection interfaces. The argument given at WWDC 2000,
when this first came up (null is not supported as a value or key in
NS*) is moot anyway, as this is also not mandatory in the Collection
contract.
Lastly, it would help a lot if NSKeyValueCoding.Utility was an object
and not a class. Then one could extend it and re-set it to ones own
subclass...
Cheers, Anjo
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.