Re: [Pyobjc-dev] Key/Value Coding
Brought to you by:
ronaldoussoren
From: b.bum <bb...@ma...> - 2003-08-14 18:49:28
|
Right -- it is of my opinion that the support for K/V coding as presented in PyObjC should follow the rules of Objective-C as closely as possible. Hence, a callable attribute in the path should be called and the value returned. If the callable returns a callable -- then that callable is returned. It sounds confusing, but it really isn't. Follow the path.... evaluate each element through getKey().... if the thing returned is callable, call it and return the result.... go to next element in path w/whatever was returned and repeat. b.bum On Thursday, August 14, 2003, at 12:38 PM, Pierce T. Wetter III wrote: > > On Tuesday, August 12, 2003, at 09:41 PM, b.bum wrote: > >> I committed a new Key/Value coding unit test and a bit of additional >> functionality in the KeyValueCoding module within PyObjCTools. It >> includes a compiled module. >> >> The unit tests do not pass and are currently, more or less, a feature >> request. >> >> The goal is to make PyObjC's key/value coding support compliant with >> ObjC to the point where Python, ObjC or mixed PyObjC instances can be >> transparently passed into K/V dependent functionality. We need this >> to fully support the increasing emphasis on Key/Value Coding found >> within Mac OS X. > > As a WO hacker, I love KVC, so having KVC support would be cool and > possibly should be a python feature separate from pyobjc. I forsee > some problems on the Python side because python doesn't have separate > name spaces based on type. > > That is: > class.method.method.value > ..... |