Skip to content

Commit d78c537

Browse files
Treiblesschorlectrueden
authored andcommitted
Expose getExactParameterTypes & getExactReturnType
1 parent aeb82b4 commit d78c537

1 file changed

Lines changed: 23 additions & 0 deletions

File tree

src/main/java/org/scijava/util/Types.java

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1297,6 +1297,29 @@ public static Type parameterizeRaw(Class<?> rawType) {
12971297
return Types.parameterize(rawType, typeParams);
12981298
}
12991299

1300+
/**
1301+
* See {@link GenericTypeReflector#getExactParameterTypes(Method, Type)}
1302+
*
1303+
* @param m
1304+
* @param type
1305+
* @return
1306+
*/
1307+
public static Type[] getExactParameterTypes(final Method m,
1308+
final Type type){
1309+
return GenericTypeReflector.getExactParameterTypes(m, type);
1310+
}
1311+
1312+
/**
1313+
* See {@link GenericTypeReflector#getExactReturnType(Method, Type)}
1314+
*
1315+
* @param m
1316+
* @param type
1317+
* @return
1318+
*/
1319+
public static Type getExactReturnType(final Method m, final Type type) {
1320+
return GenericTypeReflector.getExactReturnType(m, type);
1321+
}
1322+
13001323
// -- Helper methods --
13011324

13021325
private static Type[] filterIndices(Type[] types, List<Integer> indices) {

0 commit comments

Comments
 (0)