On Wed, Aug 18, 2010 at 2:24 PM, Ray Ryan <[email protected]> wrote:
> This is nothing to do with Roo. And while we want to be Gin friendly, we
> can't count on people using Gin.
> It's a constructor argument because the activity is intended to be single
> use, and it is not viable without something to edit. I'm really not inclined
> to change the api around the current state of Gin's feature set.
> If I were trying to get Gin to cooperate with this kind of situation I'd
> make myself a factory that takes the edited record as an input and returns
> an activity, and put Gin in charge of instantiating the factories. Is that
> not practical?

That's what we are doing now.  It's a surprising amount of code.  For
a large application, it's quite an amount of injected factory classes.

I wasn't trying to say that the assisted injection feature coming to
Gin would solve it.  It would cut down on the amount of boiler plate
code but it would still be quite a bit of code.  The comment was more
than until the activity is started, it has no need of a record.

I wish I had a better argument but this is only about the quantity of
code we need to supply to make use of this class.

Considering the scenario, I think the best way to cut down on code is
to proxy the editing activity and only instantiate the inner
AnstractRecordEditActivity on start.  This would cut down on code much
more than all these factories.

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

Reply via email to