On Sun, Aug 8, 2010 at 2:16 AM, <[email protected]> wrote:

> Partial review (time for sleep)
>
>
> http://gwt-code-reviews.appspot.com/717801/diff/8003/32002
> File
>
> bikeshed/src/com/google/gwt/sample/expenses/gwt/client/HistoryPlaceIntegration.java
> (right):
>
> http://gwt-code-reviews.appspot.com/717801/diff/8003/32002#newcode91
>
> bikeshed/src/com/google/gwt/sample/expenses/gwt/client/HistoryPlaceIntegration.java:91:
> if ("r".equals(initial)) {
> If we're going with a prefix scheme, maybe there should be a prefix ->
> Tokenizer map. Or perhaps a more flexible scheme would just chain
> tokenizers, so that the first, root, tokenizer installed maps to
> sub-tokenizers.
>

Yes, I plan to do exactly that with a GWT code generator. That will probably
be less work than making Roo generate this thing, so I guess I'll have to do
it today.

There won't be any nesting, at least not yet. The place scheme completely
hinges on there being only one place, so that when someone I don't know sets
a new place I automatically get torn down.

>
> http://gwt-code-reviews.appspot.com/717801/diff/8003/32051
> File user/src/com/google/gwt/app/place/ProxyPlace.java (right):
>
> http://gwt-code-reviews.appspot.com/717801/diff/8003/32051#newcode45
> user/src/com/google/gwt/app/place/ProxyPlace.java:45: return new
> ProxyPlace(requests.getProxy(bits[0]),
> TODO: avoid Enum.valueOf(), prefer ordinal(). This requires every enum
> to carry these string tables around to do the mapping, I'm teaching the
> compiler to prune these with special flags. As an added bonus, the token
> will be shorter.
>

I'll do that now.

>
> http://gwt-code-reviews.appspot.com/717801/diff/8003/32051#newcode50
> user/src/com/google/gwt/app/place/ProxyPlace.java:50: return
> requests.getToken(place.getProxy()) + "@" + place.getOperation();
> TODO: eventually, place.getOperation.ordinal()
>
> http://gwt-code-reviews.appspot.com/717801/diff/8003/32058
> File
> user/src/com/google/gwt/requestfactory/rebind/RequestFactoryGenerator.java
> (right):
>
> http://gwt-code-reviews.appspot.com/717801/diff/8003/32058#newcode324
>
> user/src/com/google/gwt/requestfactory/rebind/RequestFactoryGenerator.java:324:
> // write getToken(Class)
> Am I imagining things, or is this simply the same as doing
> clazz.getName()? getToken(clazz) looks up a RecordSchema in
> recordToTypeMap and then invokes getToken() on RecordSchema, which
> returns the Record clazz again, on which getName() is invoked.


That's exactly what it's doing, but it's intended to be temporary — I'll add
a TODO. Just like the JSON is sending the entire FQ class name down the wire
but shouldn't be. I want to find some kind of lossless compression scheme
for both to use, probably just a base 36 encoding.

>
>
> http://gwt-code-reviews.appspot.com/717801/show
>

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

Reply via email to