When Structure.read() is called on nested Structures with large sub-structures
it takes a very long time, even if one only needs to fill the first level of
fields (i.e. if one is not interested in the (sub-)fields of the structure
fields). Therefore it would be an important enhancement to provide a
non-recursive version of read() (e.g. read(boolean recursive)) where the
developer can decide wether the read process has to be called recursively for
each ByReference structure field.
Currently the only workaround for this is to work with pointer arithmetics using
the right offsets of particular fields of the structure. This is not a trivial
issue because the offsets cannot be determined during runtime (as the
StructureField map is package private and cannot be accessed from application
code), those one has to calculate the offsets manually (e.g. from the native C
code). A solution for this would be appreciated very much!