Am 21.01.2010 09:04, Hilco Wijbenga wrote:

So how would you suggest I store data that I only need in a component?

That depends on what you want to do with the data and where you need it.

I'm already using the activation context (not for this component) but
the component has a fair number of fields and this is only the first
component. I'm afraid I would be overloading the activation context.
(It's not a lot of data, just a lot of fields.)

Perhaps you could describe what sort of component this is, what the users does with it and what you do with the data.

I'm not using a database so all data needs to be in either the
session, the URL, or in (the server's) memory (other than the
session).

So you want to store all the data which the user generates in his session?

> What would be the most economical and scalable way to store
up to a few hundred small fields (tiny integers and single characters
only)? I could probably work out a way to compress it all into a
single string which I could store in the activation context.

On one page I use an approach like this. I want the user to be able to undo the settings until he leaves the page, so I store all previous steps in a Java List, convert it to compressed XML and store it in a hidden field. This is rather ugly but the only way I could think of.

- Stephan

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

Reply via email to