http://gwt-code-reviews.appspot.com/1450806/diff/3002/dev/core/src/com/google/gwt/core/ext/GeneratorContext.java
File dev/core/src/com/google/gwt/core/ext/GeneratorContext.java (right):

http://gwt-code-reviews.appspot.com/1450806/diff/3002/dev/core/src/com/google/gwt/core/ext/GeneratorContext.java#newcode34
dev/core/src/com/google/gwt/core/ext/GeneratorContext.java:34: * likely
to succeed.
On 2011/05/31 16:27:01, rjrjr wrote:
Why is the argument a string rather than, say, JClassType?


Since this method will be called from within a generator, there may not
be a valid JClassType from type oracle (but we can check for the
availability of a rebind rule, by sourceTypeName, which is how they are
expressed in rebind rules).  The actual type might come into existence
after the current (and other) generators complete.

Wouldn't the second sentence would be more accurate as: "is likely to
succeed
for a type with no default constructor. (Any concrete type with a zero
args
constructor can be instantiated via GWT.create().)"


Can't really check whether a concrete type with a zero args constructor
might be available, since it might only come into being after other
generators run.

Also, it isn't GWT.create(sourceTypeName), the argument is a class
literal.

Good point.  I've removed references to GWT.create() altogether in the
javadoc.

http://gwt-code-reviews.appspot.com/1450806/

--
http://groups.google.com/group/Google-Web-Toolkit-Contributors

Reply via email to