[
https://issues.apache.org/jira/browse/TAPESTRY-729?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12538337
]
Alejandro Scandroli commented on TAPESTRY-729:
----------------------------------------------
I'm working on something like this for the Trails framework.
Trails callback stack is an ASO persisted by default in the session.
<contribution configuration-id="tapestry.state.ApplicationObjects">
<state-object name="callbackStack" scope="session">
<create-instance
class="org.trails.callback.CallbackStack"/>
</state-object>
</contribution>
To support multiple windows I want the callback stack to be persisted in the
client.
I achieve this using a RequestScopeManager (StateObjectPersistenceManager) in
conjunction with ClientAsoPropertyPersistenceStrategy
(PropertyPersistenceStrategy)
http://svn.trails.codehaus.org/browse/trails/branches/ascandroli-20071009-TRAILS63/modules/trails-core/src/main/java/org/trails/engine/state/RequestScopeManager.java
http://svn.trails.codehaus.org/browse/trails/branches/ascandroli-20071009-TRAILS63/modules/trails-core/src/main/java/org/trails/record/ClientAsoPropertyPersistenceStrategy.java
This way the user can choose between "session" or "client" by only changing
the "scope" attribute, and he doesn't need to change the way he was injecting
the ASO into the components because @InjectState("callbackStack") will work
for both scopes.
Does it sound like what you are looking for?
BTW: this is still a work in progress.
> Enable storage on client side for ASO
> -------------------------------------
>
> Key: TAPESTRY-729
> URL: https://issues.apache.org/jira/browse/TAPESTRY-729
> Project: Tapestry
> Issue Type: Improvement
> Components: Framework
> Affects Versions: 4.0
> Reporter: Henri Dupre
> Fix For: 4.1.4
>
>
> It would be very usefull to be able to set the scope of an ASO as "client"
> where the ASO would be stored as link parameter and hidden field in the forms.
> Otherwise, there is no simple solution with the current persist="client" mode
> to access and update an object from several component + the page itself.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]