コード例 #1
0
 @Override
 public SystemAdminTO toTO(GenericUserBO bo) {
   SystemAdminTO converted = new SystemAdminTO();
   if (bo.getKey() != null) {
     converted.setKey(KeyFactory.stringToKey(bo.getKey()));
   }
   converted.setUsername(bo.getUsername());
   converted.setPassword(bo.getPassword());
   return converted;
 }
コード例 #2
0
 @Override
 public GenericUserBO toBO(SystemAdminTO to) {
   GenericUserBO converted = new GenericUserBO();
   converted.setKey(KeyFactory.keyToString(to.getKey()));
   converted.setUsername(to.getUsername());
   converted.setPassword(to.getPassword());
   converted.setActive(true);
   converted.setRank(new UserType(UserType.eTypes.SYSADMIN));
   return converted;
 }