carloc wrote:
>
> public CCTIDetachableModel extends Loadable DetachableModel {
>
> private String id;
> private Integer version;
> private Dao dao;
>
> public Object load() {
> MyObject myobj = dao.get(id);
> if (version == null) {
> version = myobj.getVersion();
> }
> else if (!myobject.getVersion().equals(version)) {
> throw new MyVersionMismatchException(MyObject.class, id, version);
> }
>
> return myobj;
> }
> }
>
The code shouldn't compile as "myobject" is undefined:
... if (!myobject.getVersion().equals(version)) {
--
View this message in context:
http://www.nabble.com/Versioning-Problems-With-DataTable%2C-Spring-Hibernate-tf4484198.html#a12833349
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]