Package org.jeecgframework.core.common.exception

Examples of org.jeecgframework.core.common.exception.BusinessException


    try{
      for(String id:ids){
        delete(table, id);
      }
    }catch (Exception e) {
      throw new BusinessException(e.getMessage());
    }
    return true;
  }
View Full Code Here


      // 循环标题所有的列
      while (cellTitle.hasNext()) {
        Cell cell = cellTitle.next();
        String value = cell.getStringCellValue();
        if (fieldMap.get(value)==null) {
          throw new BusinessException("导入数据excel列名有不能识别的列");
        }
        titlemap.put(i, value);
        i = i + 1;
      }
      // 用来格式化日期的DateFormat
View Full Code Here

        } catch (IOException e) {

        }
      }
    } else {
      throw new BusinessException("参数错误");
    }
  }
View Full Code Here

    List<T> list = queryObject.list();
    if (list.size() == 1) {
      getSession().flush();
      t = list.get(0);
    } else if (list.size() > 0) {
      throw new BusinessException("查询结果数:" + list.size() + "大于1");
    }
    return t;
  }
View Full Code Here

   * @param target
   * @param errorMessage
   */
  public static void throwIfNull(Object target,String errorMessage){
    if(target==null){
      throw new BusinessException(errorMessage);
    }
  }
View Full Code Here

   * @param errorMessage
   */
  public static void throwIfEmpty(String target,String errorMessage)
  {
    if(target==null || target.equals("")){
      throw new BusinessException(errorMessage);
    }
  }
View Full Code Here

TOP

Related Classes of org.jeecgframework.core.common.exception.BusinessException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.