Skip to content

Commit ed13366

Browse files
committed
slight adjustment to signature of EntityManager.createNativeQuery()
preparing the way for jakartaee#52
1 parent c0753aa commit ed13366

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

api/src/main/java/jakarta/persistence/EntityManager.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1071,11 +1071,14 @@ void refresh(Object entity,
10711071
/**
10721072
* Create an instance of {@link Query} for executing a native
10731073
* SQL query.
1074+
*
1075+
* <p><em>In the next release of this API, the return type of this
1076+
* method will change to {@code TypedQuery<T>}.</em>
10741077
* @param sqlString a native SQL query string
1075-
* @param resultClass the class of the resulting instance(s)
1078+
* @param resultClass the type of the query result
10761079
* @return the new query instance
10771080
*/
1078-
Query createNativeQuery(String sqlString, Class<?> resultClass);
1081+
<T> Query createNativeQuery(String sqlString, Class<T> resultClass);
10791082

10801083
/**
10811084
* Create an instance of {@link Query} for executing

0 commit comments

Comments
 (0)