summaryrefslogtreecommitdiffstats
path: root/java/MyMyBatis/src/ModelMapper.java
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2017-04-25 10:49:07 +0200
committerJérémy Zurcher <jeremy@asynk.ch>2017-04-25 10:49:07 +0200
commit609c5d6d7a228f027c01dd203f78fe64ed641641 (patch)
tree615480127b3db4a41d0558246f79e7c688e0c666 /java/MyMyBatis/src/ModelMapper.java
parent4eaaddb6813b0f563c9022e67f7a4d4a2fc8bae1 (diff)
downloadshare-609c5d6d7a228f027c01dd203f78fe64ed641641.zip
share-609c5d6d7a228f027c01dd203f78fe64ed641641.tar.gz
java : MyMyBatis : add selectSelf(TObject) -> reload() for free
Diffstat (limited to 'java/MyMyBatis/src/ModelMapper.java')
-rw-r--r--java/MyMyBatis/src/ModelMapper.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/java/MyMyBatis/src/ModelMapper.java b/java/MyMyBatis/src/ModelMapper.java
index e71f851..901af2c 100644
--- a/java/MyMyBatis/src/ModelMapper.java
+++ b/java/MyMyBatis/src/ModelMapper.java
@@ -36,4 +36,8 @@ public interface ModelMapper extends AbstractMapper<Integer, Model>
final static String SELECT_ONE = SELECT + where;
@Select(SELECT_ONE)
Model selectOne(Integer id);
+
+ final static String SELECT_SELF = SELECT + where;
+ @Select(SELECT_SELF)
+ Model selectSelf(Model obj);
}