CarlHowarth schrieb: > Hi, > > I have an app that uses the tomahawk savestate component to save the state > of the backing bean. I have just tried bind a selectonemenu component to the > backing bean however as the HtmlSelectOneMenu class is not serializable I > get an error as this can not be saved. > > If I change to session scope, removing the savestate component the app > works, however I do not want the bean to be stored at session level. Has > anyone had this problem/got a work-around? > Savestating is not used for components, sorry to say that, and the classes used by this component have to be serializable due to the inherent nature of the mechanisms used. Your backing bean however is, and you have to use a Serializable on the backing bean to use savestate.
Btw. just another note, saveState in the long run will be replaced by something better, we have a scope component in the sandbox, which is very similar in usage, but way better. I have not used it myself, but the developer of this component uses it heavily so it is pretty well debugged. The benefits of this component, clear begin and end scope definition, some generic bindings into orm layers so that you have an easier handling with orm layers. Savestate is, though very easy to use, somewhat limited.

