Menu

#31 ViewBuilder.writeState() hassels

open
bug (8)
5
2007-06-11
2007-06-11
Anonymous
No

Hi,

the abstract class ViewBuilder implements the final method writeState() by just calling writeStateInClient() (which calls the underlying ViewHandler.writeState()) when client side state saving is enabled.

This generates some problems when using myfaces with server side state saving, because even then a small client state is inserted into the page (JSF Sequence, etc.) which is ommited when using the ViewBuilder, preventing myfaces from restoring the state.

A simple solution would be to remove "context.getApplication().getStateManager().isSavingStateInClient(context)" from the if condition in ViewBuilder.writeState() and let ViewHandler.writeState() decide to write the state in the client response or not.

Is this a viable solution or is it "too" simple?

Stefan

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.