- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for getActualElementClassOfSet (0.24 sec)
-
src/test/java/org/codelibs/core/lang/GenericsUtilTest.java
final Map<TypeVariable<?>, Type> map = GenericsUtil.getTypeVariableMap(Hoge.class); final Method method = Hoge.class.getMethod("set"); assertThat(GenericsUtil.getActualElementClassOfSet(method.getGenericReturnType(), map), is(sameClass(String.class))); } /** * @throws Exception */ public void testGetActualKeyClassOfMap() throws Exception {
Registered: Fri Nov 01 20:58:10 UTC 2024 - Last Modified: Thu Mar 07 01:59:08 UTC 2024 - 11.5K bytes - Viewed (0) -
src/main/java/org/codelibs/core/lang/GenericsUtil.java
* パラメータ化された{@link Set} * @param map * パラメータ化された型が持つ型変数をキー、型引数を値とする{@link Map} * @return パラメータ化された{@link Set}の実際の要素型 */ public static Class<?> getActualElementClassOfSet(final Type type, final Map<TypeVariable<?>, Type> map) { if (!isTypeOf(type, Set.class)) { return null; } return getActualClass(getGenericParameter(type, 0), map); }
Registered: Fri Nov 01 20:58:10 UTC 2024 - Last Modified: Thu Mar 07 01:59:08 UTC 2024 - 23.6K bytes - Viewed (0)