RequestFactory: Enabling support for interfaces in @ProxyFor.

Patch moved from rietveld (http://gwt-code-reviews.appspot.com/1764804/)

RequestFactory should allow that client-proxies point to interfaces in
server side instead of classes, facilitating different implementations.

This feature allows as well that we could reuse proxy interfaces in both
sides, what reduces the code.

@ProxyFor(value = A.class, locator = ALocator.class)
public interface A {
  String getSomething();
  void setSomething(String s);
}

public class ALocator extends Locator<A, String>  {
  @Override
  public A create(Class<? extends A> clazz) {
    return new AImpl();
  }
  ....
}

public class AImpl implements A {
  String getSomething(){return null}
  void setSomething(String s){}
}

Change-Id: I273ed2c403b275f4c9bec2b7e7ba72a3d05930b9
Bugs: issue 5762.
6 files changed