one thing that immediately strikes me is that it might be that the model is really the thing which is either a value model or a reference model (although you could imagine an app where the same model was used both ways, you could trivially extend the model to provide both usages).
if we had
public boolean IModel.isValue()
then the model itself could give us information about whether it should be cloned via Objects.clone() (serialization) or just referenced. for someone working with hibernate, your base class for your detachable models could implement this by returning false. this would mean that undo information for any components referencing the model would be references and not copies. but then someone who is trying to edit a non-persistent model by value could return true.
not sure what the picture is yet for how all this interacts with staleness...
Jonathan Locke wrote:
i don't think you understood. read the post i just posted.
you would never want to get back to a bunch of components that don't match the rendering. there's no need for that "flexibility" because all you could do is botch it.
what /is/ needed is a way for users to guide the way that models are copied or referenced. that's a much more controlled kind of flexibility that targets the real problem.
Gili wrote:
Based on the feedback I just got I would recommend having the automatic behavior on by default and allowing developments to override it and provide their own UndoableEdit. I think everyone will be happy with that.
Gili
On Wed, 02 Mar 2005 14:08:59 -0800, Jonathan Locke wrote:
i think this is all completely automatic.
each page has a bunch of versioning information in Page that gets modified as components call replace/add/remove (after the first rendering).
then we can essentially setVersion(int renderingCount) to get the earlier page back. the user would have no control over any of this. it just happens.
Gili wrote:
I'm looking for a good anti-pattern to my suggestion. Is there a reasonable use-case where using UndoableEdits would not yield the correct/expected behavior?
My hope is that there is none and we can all agree to move
forward on this issue. Remember, if no UndoableEdit is registered for a
rendering operation then hitting Back yields a "page is stale" message.
It seems quite intuitive to me. :|
Gili
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Wicket-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-develop
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Wicket-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-develop
------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click _______________________________________________ Wicket-develop mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/wicket-develop
------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click _______________________________________________ Wicket-develop mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/wicket-develop
------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click _______________________________________________ Wicket-develop mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/wicket-develop
