I've found a bug describing this issue: http://code.google.com/p/google-web-toolkit/issues/detail?id=2972
I don't like the work around they've justed: it works only if you know that the native method should return an int, it doesn't work for any type. So I guess I'll have to add getters and setters explicitely for primitive types On Jun 5, 12:33 pm, ziglionz <[email protected]> wrote: > I've tried with generic methods, no luck, same exception: > > public final native <T> T get( String property ) /*-{ return this > [property]; }-*/; > public final native <T> void set( String property, T val ) /*-{ this > [property] = val; }-*/; > > Would normal Java perform autoboxing of a returned int to Integer? > I suppose the point of overlay types is really to use the JavaScript > types so autoboxing wouldn't make much sense if JavaScript returns a > primitive type. > I have no idea on whether you can box primitive types in JavaScript. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~----------~----~----~----~------~----~------~--~---
