Thanks. Obivious solution. i should be more attentive.

On Wed, Oct 14, 2009 at 11:53,  <[email protected]> wrote:
> Hello Andrey,
>
> Andrey Larionov <[email protected]> schrieb am 14.10.2009 09:40:29:
>
>> Can i inject (via @SessionState) SSO objects into services? I'm try
>> but value of field always null.
>
> @SessionState works only in page and component classes.
>
> You can add the parameter "ApplicationStateManager asm" to the constructor
> of your service.
> Tapestry IOC will then inject the ApplicationStateManager when calling the
> constructor.
> In your constructor, put asm into a (private final) field of your service.
> You can than use asm.get(SsoObject.class) to retrieve the desired SSO
> object by its class. You can also check the existence with
> asm.exists(SsoObject.class), or use asm.getIfExists, or put an object
> asm.set(SsoObject.class, object).
>
> Dirk
> BGS Beratungsgesellschaft
> Software Systemplanung AG         Niederlassung Köln/Bonn
> Grantham-Allee 2-8
> 53757 Sankt Augustin
> Fon: +49 (0) 2241 / 166-500
> Fax: +49 (0) 2241 / 166-680
> www.bgs-ag.de Geschäftssitz Mainz
> Registergericht
> Amtsgericht Mainz
> HRB 62 50
>  Aufsichtsratsvorsitzender
> Klaus Hellwig
> Vorstand
> Hermann Kiefer
> Nils Manegold
> Thomas Reitz
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to