首页 > 代码库 > java学习指南

java学习指南

@Override
    public BaseResponse selectListPage(PageData page, Object obj) {
        BaseResponse response = new BaseResponse();
        PageHelper.startPage(page.getPage(), page.getNumber(), true);
        List<Object> list =  getSqlSession().selectList(getStatement(BasicExecuteEnum.SELECT_LIST.id), obj);
        response.setObj(list);
        response.setPageInfo(new PageInfo<Object>(list));
        return response;
    }

    @Override
    public BaseResponse selectListPage(PageData page, String statement,
            Object obj) {
        BaseResponse response = new BaseResponse();
        PageHelper.startPage(page.getPage(), page.getNumber(), true);
        List<Object> list =  getSqlSession().selectList(getStatement(statement), obj);
        response.setObj(list);
        response.setPageInfo(new PageInfo<Object>(list));
        return response;
    }

java学习指南