http://code.google.com/p/google-web-toolkit/issues/detail?id=7414
Dne pátek, 8. června 2012 16:48:47 UTC+2 Thomas Broyer napsal(a): > > > > On Friday, June 8, 2012 4:14:44 PM UTC+2, zorro wrote: >> >> Well, I have the requestFactory-apt set as annotation processor. But >> maybe problem is that the type that I wanted to create on server is an >> interface! And this is not covered by compiler at all! > > > Would you mind filing an issue on the tracker? > (DomainChecker should check that the type is instantiable, i.e. neither an > interface or an abstract class –or an enum!) > > >> Can I say to this magical RequestFactory stuff say what type to >> instantiate on the server, if interface is allowed (apparently) in the >> ProxyFor annotation? >> > > You can use a Locator (on server-side, responsible for "instantiating your > interface") and link to it from the ProxyFor annotation. > > https://developers.google.com/web-toolkit/doc/latest/DevGuideRequestFactory#locators > > >> I woudl really appreciate that because I am using interfaces to get rid >> of tuns of necessary copying among proxy objects and real gwt objects. My >> original intention was to use gwt so I can move functionality execution >> easily from server to client. Therefore RF proxies in my case should be the >> same as the domain objects. Therefore interfaces. >> > > In your case, I'd make sure to reference the real domain object (that > implements the same interface that the proxy extends). > I suppose that's what you were willing to do, but somehow forgot to change > the ProxyFor value during the refactoring, and the bug in ValidationTool > didn't tell you you were wrong, right? > -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To view this discussion on the web visit https://groups.google.com/d/msg/google-web-toolkit/-/citl4FAtRTcJ. 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.
