Examples of IncorrectResultSizeDataAccessException


Examples of org.springframework.dao.IncorrectResultSizeDataAccessException

    }
    if (ex instanceof NoResultException) {
      return new EmptyResultDataAccessException(ex.getMessage(), 1);
    }
    if (ex instanceof NonUniqueResultException) {
      return new IncorrectResultSizeDataAccessException(ex.getMessage(), 1);
    }
    if (ex instanceof OptimisticLockException) {
      return new JpaOptimisticLockingFailureException((OptimisticLockException) ex);
    }
    if (ex instanceof EntityExistsException) {
View Full Code Here

Examples of org.springframework.dao.IncorrectResultSizeDataAccessException

    }
    if (ex instanceof WrongClassException) {
      return new HibernateObjectRetrievalFailureException((WrongClassException) ex);
    }
    if (ex instanceof NonUniqueResultException) {
      return new IncorrectResultSizeDataAccessException(ex.getMessage(), 1);
    }
    if (ex instanceof StaleObjectStateException) {
      return new HibernateOptimisticLockingFailureException((StaleObjectStateException) ex);
    }
    if (ex instanceof StaleStateException) {
View Full Code Here

Examples of org.springframework.dao.IncorrectResultSizeDataAccessException

    int size = (results != null ? results.size() : 0);
    if (size == 0) {
      return null;
    }
    if (results.size() > 1) {
      throw new IncorrectResultSizeDataAccessException(1, size);
    }
    return results.iterator().next();
  }
View Full Code Here

Examples of org.springframework.dao.IncorrectResultSizeDataAccessException

    int size = (results != null ? results.size() : 0);
    if (size == 0) {
      throw new EmptyResultDataAccessException(1);
    }
    if (results.size() > 1) {
      throw new IncorrectResultSizeDataAccessException(1, size);
    }
    return results.iterator().next();
  }
View Full Code Here

Examples of org.springframework.dao.IncorrectResultSizeDataAccessException

    int size = (results != null ? results.size() : 0);
    if (size == 0) {
      return null;
    }
    if (!CollectionUtils.hasUniqueObject(results)) {
      throw new IncorrectResultSizeDataAccessException(1, size);
    }
    return results.iterator().next();
  }
View Full Code Here

Examples of org.springframework.dao.IncorrectResultSizeDataAccessException

    int size = (results != null ? results.size() : 0);
    if (size == 0) {
      throw new EmptyResultDataAccessException(1);
    }
    if (!CollectionUtils.hasUniqueObject(results)) {
      throw new IncorrectResultSizeDataAccessException(1, size);
    }
    return results.iterator().next();
  }
View Full Code Here

Examples of org.springframework.dao.IncorrectResultSizeDataAccessException

    }
    if (ex instanceof WrongClassException) {
      return new HibernateObjectRetrievalFailureException((WrongClassException) ex);
    }
    if (ex instanceof NonUniqueResultException) {
      return new IncorrectResultSizeDataAccessException(ex.getMessage(), 1);
    }
    if (ex instanceof StaleObjectStateException) {
      return new HibernateOptimisticLockingFailureException((StaleObjectStateException) ex);
    }
    if (ex instanceof StaleStateException) {
View Full Code Here

Examples of org.springframework.dao.IncorrectResultSizeDataAccessException

   * @throws DataAccessException a corresponding exception,
   * by default an IncorrectResultSizeDataAccessException
   * @see org.springframework.dao.IncorrectResultSizeDataAccessException
   */
  protected void handleMultipleRowsFound() throws DataAccessException {
    throw new IncorrectResultSizeDataAccessException(
        "LobStreamingResultSetExtractor found multiple rows in database", 1);
  }
View Full Code Here

Examples of org.springframework.dao.IncorrectResultSizeDataAccessException

    }
    if (ex instanceof WrongClassException) {
      return new HibernateObjectRetrievalFailureException((WrongClassException) ex);
    }
    if (ex instanceof NonUniqueResultException) {
      return new IncorrectResultSizeDataAccessException(ex.getMessage(), 1);
    }
    if (ex instanceof StaleObjectStateException) {
      return new HibernateOptimisticLockingFailureException((StaleObjectStateException) ex);
    }
    if (ex instanceof StaleStateException) {
View Full Code Here

Examples of org.springframework.dao.IncorrectResultSizeDataAccessException

    }
    if (ex instanceof NoResultException) {
      return new EmptyResultDataAccessException(ex.getMessage(), 1);
    }
    if (ex instanceof NonUniqueResultException) {
      return new IncorrectResultSizeDataAccessException(ex.getMessage(), 1);
    }
    if (ex instanceof OptimisticLockException) {
      return new JpaOptimisticLockingFailureException((OptimisticLockException) ex);
    }
    if (ex instanceof EntityExistsException) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.