From: Eloy D. <elo...@gm...> - 2006-10-31 08:53:22
|
> To speed up the invocation, you don't have to create an objective-c > instance for passing as an argument. If it's necessary, it occur > implicitly by the bridge. > > # create a NSDictionary object with two elements. > d = OSX::NSDictionary.alloc.initWithDictionary({ "a" => "b", "b" > => "a" }) > # The type of all keys and values of d is NSString. > > # convert "a" to a NSString object implicitly befor the invocation > b = d.objectForKey("a") > > # b.isKindOfclass? NSString > # b.to_s = "b" > > # no any convertion because b is a NSString instance already > a = d.objectForKey(b) Okay, so that's just the way it is :) I was just wondering about this, not that I really need the extra speed at the moment. > Sorry, seems too hard to describe my mean by English. > Could you allow me to use by Japanese? ;) Oh how I wish I could read Japanese. Well there's always babelfish ;) Eloy. |