Hi!

We have our own version of the classes in java.lang.* so this dicussion is not vital for us.

For us it is important that after the initial memory allocation there is no further memory allocation. So if we need to store native information we need to put it into the Java heap. To do this we allocate the required memory in the Java heap and mark it as a Java object of type Object. This allows us to handle this object like every other Java object. So we can store native information and connect it to a Java object and the garbage collector just frees the memory when the corresponding Java object is gone.

So we would rather use Object references in such places than byte[]. Byte arrays give programmers on the Java side the feeling the can work with the content where they really should not touch it.

Cheers,
ingo

--
Ingo Prötel                                          [EMAIL PROTECTED]
aicas GmbH                                        http://www.aicas.com
Haid-und-Neu-Str. 18                        phone   +49 721 663 968-32
76131 Karlsruhe                             fax     +49 721 663 968-93
Germany


_______________________________________________ Classpath mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/classpath

Reply via email to