I'm trying to add a unit test for issue 5926 and I don't know how to deal
with the TypeTokenResolver to easily run the test from within Eclipse.
I enabled the requestfactory-apt.jar annotation processor on the gwt-user
project and it generates a Java file that cannot be compiled, because it
uses binary names for classes instead of source names, e.g.
addTypeToken("6GWlio0rpqSic5Nce0g_FPANjqc=",
com.google.web.bindery.requestfactory.server.BoxesAndPrimitivesJreTest$ProxyMismatchedGetterA.class.getName());
addTypeToken("6TPopfzq37rZzVxkFiyvasCck2Q=",
com.google.web.bindery.requestfactory.server.RequestFactoryInterfaceValidatorTest$LocatorEntityProxy.class.getName());
How do you run RF tests in Eclipse? (and are you doing it? or always running
them through Ant?)
Why is it using class literals rather than just strings? to fail early if
one of the classes cannot be found? (rather than failing only when
InProcessRequestContext#createProxy resolves the type token) If that's the
case, then maybe RfApt should .replace('$', '.') when creating the
TypeTokenResolver.Builder-impl?
As we're talking about RfApt, what's the reason for scanning the whole
"classpath" (new
Finder().scan(ElementsFilter.typesIn(roundEnv.getRootElements()), null))
instead of just processing interfaces annotated with @ProxyFor or
@ProxyForName (roundEnv.getElementsAnnotatedWith), given that proxies have
to be annotated to be used with RF?
Am I missing something?
--
http://groups.google.com/group/Google-Web-Toolkit-Contributors