From a3942c5c1bb914ddbeca9b3ef50a1cb2e984872e Mon Sep 17 00:00:00 2001 From: Thomas Risberg Date: Thu, 12 Mar 2009 21:30:42 +0000 Subject: [PATCH] changed exception class thrown for problems configuring GenericSqlQuery class (SPR-3986) --- .../org/springframework/jdbc/object/GenericSqlQuery.java | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/org.springframework.jdbc/src/main/java/org/springframework/jdbc/object/GenericSqlQuery.java b/org.springframework.jdbc/src/main/java/org/springframework/jdbc/object/GenericSqlQuery.java index a9848a884a..b2d09d28d2 100644 --- a/org.springframework.jdbc/src/main/java/org/springframework/jdbc/object/GenericSqlQuery.java +++ b/org.springframework.jdbc/src/main/java/org/springframework/jdbc/object/GenericSqlQuery.java @@ -16,13 +16,11 @@ package org.springframework.jdbc.object; -import java.sql.ResultSet; -import java.sql.SQLException; import java.util.Map; import org.springframework.jdbc.core.RowMapper; import org.springframework.util.Assert; -import org.springframework.dao.InvalidDataAccessApiUsageException; +import org.springframework.dao.InvalidDataAccessResourceUsageException; public class GenericSqlQuery extends SqlQuery { @@ -49,10 +47,10 @@ public class GenericSqlQuery extends SqlQuery { return (RowMapper) rowMapperClass.newInstance(); } catch (InstantiationException e) { - throw new InvalidDataAccessApiUsageException("Unable to instantiate RowMapper", e); + throw new InvalidDataAccessResourceUsageException("Unable to instantiate RowMapper", e); } catch (IllegalAccessException e) { - throw new InvalidDataAccessApiUsageException("Unable to instantiate RowMapper", e); + throw new InvalidDataAccessResourceUsageException("Unable to instantiate RowMapper", e); } } }