From: Arno P. <ar...@pu...> - 2011-09-01 18:37:12
|
a few comments: - Objective-C has the notion of value types, Java does not. A value type in Objective-C can only be mapped to a class in Java (e.g., CGRect, CGImage, etc). - We try to mimic the class hierarchy as much as possible, hence the existence of class NSObject that serves as the base class of all Objective-C classes. - Value types are not classes and therefore do not have a base class. Since they are mapped to classes on the Java side, they still have java.lang.Object as the base class in Java. I agree with Markus that value types should not be derived from NSObject on the Java side. That should be fixed. Arno On 9/1/11 5:28 AM, Panayotis Katsaloulis wrote: > > On 1 Σεπ 2011, at 1:48 μ.μ., Markus Heberling wrote: > >> Hi, >> >> Currently NSObject is the superclass of CGImage/CGContext/CG... and the like in the Java Compatibility Layer. In the "real world" this is not the case. CG... are no ObjectiveC objects altogether. > > You are right - this is my fault. > > First, in the Java context: > CG* should not be NSObject derivative. It is still an Object derivative though. > > In native context: > CG* *is* an Object since it is re-implemented here and is a wrapper for native CG* references. > >> Wouldn't it be better to remove the NSObject from the class hierarchy in java, too? > > In C you mean? > > NSObject in Java context *is* an Object, and as such, shouldn't NSObject and Object stay synonyms? > > > ------------------------------------------------------------------------------ > Special Offer -- Download ArcSight Logger for FREE! > Finally, a world-class log management solution at an even better > price-free! And you'll get a free "Love Thy Logs" t-shirt when you > download Logger. Secure your free ArcSight Logger TODAY! > http://p.sf.net/sfu/arcsisghtdev2dev > _______________________________________________ > Xmlvm-developers mailing list > Xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-developers |