Exemplo n.º 1
0
 @Override
 public void update(Person newInstance) {
   newInstance.setUsername(newInstance.getUsername().toLowerCase());
   getHibernateTemplate().update(newInstance);
 }
Exemplo n.º 2
0
 @Override
 public Integer create(Person newInstance) {
   newInstance.setUsername(newInstance.getUsername().toLowerCase());
   return (Integer) getHibernateTemplate().save(newInstance);
 }