- Sort Score
- Result 10 results
- Languages All
Results 21 - 28 of 28 for getDeclaredField (0.12 sec)
-
android/guava/src/com/google/common/collect/Serialization.java
} } } // Secret sauce for setting final fields; don't make it public. static <T> FieldSetter<T> getFieldSetter(Class<T> clazz, String fieldName) { try { Field field = clazz.getDeclaredField(fieldName); return new FieldSetter<>(field); } catch (NoSuchFieldException e) { throw new AssertionError(e); // programmer error } }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Mar 06 16:06:58 UTC 2023 - 8.5K bytes - Viewed (0) -
src/main/java/org/codelibs/core/lang/ClassUtil.java
* 指定された名前のフィールドが見つからない場合 * @see Class#getDeclaredField(String) */ public static Field getDeclaredField(final Class<?> clazz, final String name) throws NoSuchFieldRuntimeException { assertArgumentNotNull("clazz", clazz); assertArgumentNotEmpty("name", name); try { return clazz.getDeclaredField(name); } catch (final NoSuchFieldException e) {
Registered: Fri Nov 01 20:58:10 UTC 2024 - Last Modified: Thu Mar 07 01:59:08 UTC 2024 - 27.5K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/-UtilJvm.kt
internal fun <T> readFieldOrNull( instance: Any, fieldType: Class<T>, fieldName: String, ): T? { var c: Class<*> = instance.javaClass while (c != Any::class.java) { try { val field = c.getDeclaredField(fieldName) field.isAccessible = true val value = field.get(instance) return if (!fieldType.isInstance(value)) null else fieldType.cast(value) } catch (_: NoSuchFieldException) { }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon May 13 13:42:37 UTC 2024 - 10.7K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/reflect/TypeTokenTest.java
Bar<T> delegate; TypeToken<SubBar<T>> fieldTypeAsSubBar() { return new TypeToken<SubBar<T>>() {}; } } Field delegateField = SubBar.class.getDeclaredField("delegate"); // barType is Bar<T>, a ParameterizedType with no generic arguments specified TypeToken<?> barType = TypeToken.of(delegateField.getGenericType());
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Oct 21 21:13:09 UTC 2024 - 89.1K bytes - Viewed (0) -
guava-tests/test/com/google/common/reflect/TypeTokenTest.java
Bar<T> delegate; TypeToken<SubBar<T>> fieldTypeAsSubBar() { return new TypeToken<SubBar<T>>() {}; } } Field delegateField = SubBar.class.getDeclaredField("delegate"); // barType is Bar<T>, a ParameterizedType with no generic arguments specified TypeToken<?> barType = TypeToken.of(delegateField.getGenericType());
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Oct 21 21:13:09 UTC 2024 - 89.1K bytes - Viewed (0) -
android/guava-tests/benchmark/com/google/common/util/concurrent/ExecutionListBenchmark.java
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 22:10:29 UTC 2024 - 20.5K bytes - Viewed (0) -
src/test/java/org/codelibs/fess/crawler/transformer/FessXpathTransformerTest.java
} private void setValueToObject(Object obj, String name, Object value) { Field field = ClassUtil.getDeclaredField(obj.getClass(), name); field.setAccessible(true); FieldUtil.set(field, obj, value); } public void test_pruneNode() throws Exception {
Registered: Thu Oct 31 13:40:30 UTC 2024 - Last Modified: Thu Oct 24 13:01:38 UTC 2024 - 41.3K bytes - Viewed (0) -
compat/maven-model-builder/src/main/java/org/apache/maven/model/building/DefaultModelBuilder.java
Registered: Sun Nov 03 03:35:11 UTC 2024 - Last Modified: Fri Oct 25 12:31:46 UTC 2024 - 83.6K bytes - Viewed (0)