Package br.jus.tjrn.arq.exception

Examples of br.jus.tjrn.arq.exception.ServiceDataAccessException


  @Override
    public void delete(T entity) {
    try {
      dao.delete(entity);
    } catch (DataAccessException e) {
      throw new ServiceDataAccessException(e.getMessage(), e);
    }
  }
View Full Code Here


         *
         * Ex:
         * ServiceDataAccessException(e.getMessage(), e) = "O registro não pode ser removido por haver registros dependentes"
         * ServiceDataAccessException(e) = "br.jus.tjrn.arq.exception.DataAccessException: O registro não pode ser removido por haver registros dependentes"
         */
      throw new ServiceDataAccessException(e.getMessage(), e);
    }
  }
View Full Code Here

  @Override
    public List<T> findAll() {
      try {
          return dao.findAll();
        } catch (DataAccessException e) {
            throw new ServiceDataAccessException(e);
        }
  }
View Full Code Here

    @Override
    public List<T> findAll(String sortField, Boolean sortOrder) {
        try {
            return dao.findAll(sortField, sortOrder);
        } catch (DataAccessException e) {
            throw new ServiceDataAccessException(e);
        }
    }
View Full Code Here

  @Override
    public List<T> findAll(final int firstResult, final int maxResult) {
        try {
            return dao.findAll(firstResult, maxResult);
        } catch (DataAccessException e) {
            throw new ServiceDataAccessException(e);
        }
  }
View Full Code Here

  public List<T> findAll(int firstResult, int maxResult, String sortField,
          Boolean sortOrder) {
        try {
            return dao.findAll(firstResult, maxResult, sortField, sortOrder);
        } catch (DataAccessException e) {
            throw new ServiceDataAccessException(e);
        }
  }
View Full Code Here

  @Override
    public Integer countAll() {
        try {
            return dao.countAll();
        } catch (DataAccessException e) {
            throw new ServiceDataAccessException(e);
        }

  }
View Full Code Here

  @Override
    public List<T> findByAttributes(T entity, final int firstResult, final int maxResult) {
      try {
          return dao.findByAttributes(entity, firstResult, maxResult);
        } catch (DataAccessException e) {
            throw new ServiceDataAccessException(e);
        }
  }
View Full Code Here

    public List<T> findByAttributes(T entity, final int firstResult,
            final int maxResult, final String sortField, final Boolean sortOrder) {
        try {
            return dao.findByAttributes(entity, firstResult, maxResult, sortField, sortOrder);
        } catch (DataAccessException e) {
            throw new ServiceDataAccessException(e);
        }
    }
View Full Code Here

  @Override
    public Integer countByAttributes(T entity) {
      try {
          return dao.countByAttributes(entity);
        } catch (DataAccessException e) {
            throw new ServiceDataAccessException(e);
        }
  }
View Full Code Here

TOP

Related Classes of br.jus.tjrn.arq.exception.ServiceDataAccessException

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.