Skip to content
Snippets Groups Projects
Commit 04427781 authored by tpylak's avatar tpylak
Browse files

minor: move the method

SVN: 15857
parent db4bf7b9
No related branches found
No related tags found
No related merge requests found
......@@ -37,6 +37,16 @@ public class DBUtils
QueryTool.getTypeMap().put(float[].class, new FloatArrayMapper());
}
/**
* Use this method instead of {@link QueryTool#getQuery(DataSource, Class)}. Only in this way
* you make sure that the rigth query mappers will be registered.
*/
public static <T extends BaseQuery> T getQuery(final DataSource dataSource, final Class<T> query)
throws InvalidDataTypeException, InvalidQueryException
{
return QueryTool.getQuery(dataSource, query);
}
/**
* Rolls backs and closes the given <var>transactionOrNull</var>, if it is not <code>null</code>
* .
......@@ -138,13 +148,4 @@ public class DBUtils
return experiment;
}
/**
* Use this method instead of {@link QueryTool#getQuery(DataSource, Class)} to initialize the
* {@link QueryTool#getTypeMap()}.
*/
public static <T extends BaseQuery> T getQuery(final DataSource dataSource, final Class<T> query)
throws InvalidDataTypeException, InvalidQueryException
{
return QueryTool.getQuery(dataSource, query);
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment