コード例 #1
0
 public void deleteIMEI(String _imei) throws MSMApplicationException {
   try {
     ImeiVO imeiVO = getImei(_imei);
     if (imeiVO.getRealImei() == 'N') {
       deleteJadDir(imeiVO.getMsisdn());
     }
     imeiManager.deleteIMEI(_imei);
   } catch (RuntimeException e) {
     Throwable cause = e.getCause();
     for (int i = 0; i < 3 && cause != null; i++) {
       cause = cause.getCause();
       if (cause instanceof ConstraintViolationException) {
         throw new ImeiHasRelationshipException();
       }
     }
     throw e;
   }
 }
コード例 #2
0
 public void registerIMEI(String msisdn, String newImei) throws MSMApplicationException {
   System.out.println(
       "[MSMBusinessDelegate.registerIMEI] Msisdn " + msisdn + "; Imei: " + newImei);
   imeiManager.registerIMEI(msisdn, newImei);
   deleteJadDir(msisdn);
 }