Not currently, GenericRecord is internally an Object[]. It won't create an extra object on read, it creates the boxed object during deserialization.
On 5/20/11 2:32 AM, "[email protected]" <[email protected]> wrote: >Hi, >just a short question. Is there any way to retrieve a native java int >from a Generic Record (without creating an additional object). >This seems kind of trivial question, but I haven't seen yet how to do it. >Thanks >JS > > GenericRecord rec = null; > ... > try { > rec = r1.read(null, decoder); > sourceIP[i] = rec.get("sourceIP").toString(); > //same with int????
