Answering my own question:
The class field that was supposed to use the ASO was annotated with
@Inject. After carefully re-reading the docs, it seems that using
@ApplicationState is the right thing to do...
Once the ASO field is accessed,  contributeApplicationStateManager()
gets magically invoked.


On Tue, 2007-03-27 at 18:45 +0200, Arnon Klein wrote:

> Hi! Following the user guide about ASO, I've written a method to define
> an ASO creator. After getting it compiled (found the typo...), it still
> doesn't get called at runtime.
> what's missing?
> 
> 
>    public void contributeApplicationStateManager(MappedConfiguration<Class, 
> ApplicationStateContribution> configuration)
>     {
>       ApplicationStateCreator<IProvider> creator = new 
> ApplicationStateCreator<IProvider>()
>       {
>         public IProvider create()
>         {
>           return Application.provider();
>         }
>       };
>     
>       configuration.add(IProvider.class, new 
> ApplicationStateContribution("session", creator));
>     }


________________________________________________________________________

Information in this e-mail and its attachments is confidential and may
be privileged. This e-mail is for the exclusive use of the intended
recipient(s). If you are not one of the intended recipients, you are
hereby informed that any use, disclosure, distribution, and/or copying
of this information is strictly prohibited. If you have received this
information in error, please inform the sender and then delete it from
your system immediately. Thank you.

Reply via email to