...
Code Block |
---|
public class ExampleAction extends ActionSupport {
@In(scope = ScopeType.SESSION, value = ModelRepo.DOMAIN_MODEL)
@Out(scope = ScopeType.SESSION, value = ModelRepo.DOMAIN_MODEL)
private ExampleBean exampleBean;
...
public String edit() {
...
return SUCCESS;
}
public String save() {
...
return SUCCESS;
}
}
|
That's all. After the edit, the domain model will be stored in the session. On the save, the model will be restored before the new values are applied.