salve doesnt add a proxy, it removes the field and rewrites any field
read with a lookup.

-igor

On Fri, Feb 6, 2009 at 11:32 AM, francisco treacy
<francisco.tre...@gmail.com> wrote:
> another option is to use salve (http://code.google.com/p/salve/).
> instead of calling guice's injector as a service locator you use
> @Dependency, that will lookup and inject your dependency (behind the
> scenes it adds the class a proxy through bytecode instrumentation).
>
> public class myLDM extends LoadableDetachableModel {
>
>  @Dependency myDAO;
>
>  public Object load() {
>  return myDAO.get(...);
> }
>
> francisco
>
> On Fri, Feb 6, 2009 at 3:06 PM, Martin Grigorov <mcgreg...@e-card.bg> wrote:
>> I have seen such code somewhere:
>>
>>
>> public class myLDM extends LoadableDetachableModel {
>>
>> transient @SpringBean myDAO;
>>
>> public Object load() {
>>  InjectorHolder.getInjector().inject(this);
>>  return myDAO.get(...);
>> }
>>
>> }
>>
>> El vie, 06-02-2009 a las 13:21 +0100, Martijn Dashorst escribió:
>>> How would you inject the dao then?
>>>
>>> Martijn
>>>
>>>
>>> On Fri, Feb 6, 2009 at 12:00 PM, Sergey Didenko
>>> <sergey.dide...@gmail.com> wrote:
>>> > Hi Andreas,
>>> >
>>> > Well, may be my question is silly, but:
>>> >
>>> > What about making "dao" a local variable in your component handlers?
>>> > Then you can get rid of that serializing-deserializing of dao as a
>>> > Component member.
>>> >
>>> > Does this approach have too much overhead? Does it make some things 
>>> > impossible?
>>> >
>>> > Cheers, Sergey.
>>> >
>>> > ---------------------------------------------------------------------
>>> > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>> > For additional commands, e-mail: users-h...@wicket.apache.org
>>> >
>>> >
>>>
>>>
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to