KeyValue Observing rant
KeyValue Observing rant
- Subject: KeyValue Observing rant
- From: Michael Keller <email@hidden>
- Date: Mon, 26 Apr 2004 12:19:32 +0200
Hello,
following the initial discussion about Cocoa's "Controller" or
"Bindings" architecture it seems that I'm not the only one to be a
"little angry".
What really worse about it is that one (ore more) Apple engineers
stated that they make a "clever" use of Objective-C by posing a
NSNotifying_nameOfOriginalClass when an instance of original class is
being observed.
Well it saves two lines of code in every set-accessor, thats seems to
be fine firsthand.
That is a fine demonstration of how flexible Objective-C is.
But one of those "little" drawbacks is, that so basic things like
-description won't work anymore.
Was there ANY quality assurance at Apple before releasing this?
Let's dig a bit further:
I'm not ranting because they forget to call the original class
-description method. This would be an easy fix (if they choose to do
it).
But I'm ranting because this hidden posing or on-the-fly changing of
the isa is not documented and it limits other code (like plugins) doing
it too.
Given also the lack of "delegate" patterns within the NSController
subclasses leads me to the conclusion that these classes are far
sub-Apple standards because
PROGRAMMING IS ABOUT CONTROL.
As the developer I want to and must know and control whats going on.
How "clever" is it to loose this control? Just for saving two lines of
code?
Did they at Apple thought this is "clever" use of the Objective-C
runtime? It seems to me that the guy who designed this wanted to show
us how "clever" HE is...
I can only hope that Apple will change this braindead NSNotifying_
subclassing before its too late. That will break some existing software
but it's no effort to change the affected products source.
Having back the control is worth the change.
Michael
_______________________________________________
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.