- Sort Score
- Num 10 results
- Language All
Results 11 - 20 of 35 for setAccessible (0.14 seconds)
-
android/guava-testlib/src/com/google/common/testing/ArbitraryInstances.java
} Constructor<T> constructor; try { constructor = type.getConstructor(); } catch (NoSuchMethodException e) { return arbitraryConstantInstanceOrNull(type); } constructor.setAccessible(true); // accessibility check is too slow try { return constructor.newInstance(); } catch (InstantiationException | IllegalAccessException impossible) { throw new AssertionError(impossible);Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue Sep 23 17:50:58 GMT 2025 - 20.9K bytes - Click Count (0) -
guava-testlib/src/com/google/common/testing/ArbitraryInstances.java
} Constructor<T> constructor; try { constructor = type.getConstructor(); } catch (NoSuchMethodException e) { return arbitraryConstantInstanceOrNull(type); } constructor.setAccessible(true); // accessibility check is too slow try { return constructor.newInstance(); } catch (InstantiationException | IllegalAccessException impossible) { throw new AssertionError(impossible);Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue Sep 23 17:50:58 GMT 2025 - 21.4K bytes - Click Count (0) -
android/guava-tests/test/com/google/common/reflect/SubtypeTester.java
Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue Nov 25 23:29:58 GMT 2025 - 6.2K bytes - Click Count (0) -
guava-tests/test/com/google/common/util/concurrent/AggregateFutureStateFallbackAtomicHelperTest.java
Class<?> aggregateFutureStateClass = classLoader.loadClass(AggregateFutureState.class.getName()); Field helperField = aggregateFutureStateClass.getDeclaredField("ATOMIC_HELPER"); helperField.setAccessible(true); assertEquals(expectedHelperClassName, helperField.get(null).getClass().getSimpleName()); } private static ClassLoader getClassLoader(Set<String> blocklist) {
Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue May 13 18:46:00 GMT 2025 - 6.5K bytes - Click Count (0) -
android/guava-testlib/src/com/google/common/testing/ForwardingWrapperTester.java
checkNotNull(wrapperFunction); checkArgument(interfaceType.isInterface(), "%s isn't an interface", interfaceType); Method[] methods = getMostConcreteMethods(interfaceType); AccessibleObject.setAccessible(methods, true); for (Method method : methods) { // Interfaces can have default methods that aren't abstract. // No need to verify them. // Can't check isDefault() for Android compatibility.
Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue May 13 17:27:14 GMT 2025 - 9.1K bytes - Click Count (0) -
guava-tests/test/com/google/common/util/concurrent/AbstractFutureFallbackAtomicHelperTest.java
Class<?> abstractFutureStateClass = classLoader.loadClass(AbstractFutureState.class.getName()); Method helperMethod = abstractFutureStateClass.getDeclaredMethod("atomicHelperTypeForTest"); helperMethod.setAccessible(true); assertThat(helperMethod.invoke(null)).isEqualTo(expectedHelperClassName); } private static ClassLoader getClassLoader(Set<String> disallowedClassNames) {
Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue May 13 18:46:00 GMT 2025 - 7.3K bytes - Click Count (0) -
guava/src/com/google/common/reflect/Types.java
if (method.getDeclaringClass().equals(TypeVariableImpl.class)) { try { method.setAccessible(true); } catch (AccessControlException e) { // OK: the method is accessible to us anyway. The setAccessible call is only for // unusual execution environments where that might not be true. } builder.put(method.getName(), method);
Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Fri Oct 31 19:34:24 GMT 2025 - 24.3K bytes - Click Count (0) -
compat/maven-compat/src/test/java/org/apache/maven/project/ProjectClasspathTestType.java
(DefaultArtifactDescriptorReader) getContainer().lookup(ArtifactDescriptorReader.class); Field field = DefaultArtifactDescriptorReader.class.getDeclaredField("artifactResolver"); field.setAccessible(true); field.set(pomReader, resolver); projectBuilder = getContainer().lookup(ProjectBuilder.class, "classpath"); } @Test void testProjectClasspath() throws Exception {
Created: Sun Dec 28 03:35:09 GMT 2025 - Last Modified: Fri Mar 21 04:56:21 GMT 2025 - 6.4K bytes - Click Count (0) -
guava-tests/test/com/google/common/reflect/SubtypeTester.java
Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue Nov 25 23:29:58 GMT 2025 - 6.2K bytes - Click Count (0) -
guava-tests/test/com/google/common/base/FinalizableReferenceQueueClassLoaderUnloadingTest.java
Class<?> sepFrqSystemLoaderC = sepLoader.loadClass(FinalizableReferenceQueue.SystemLoader.class.getName()); Field disabled = sepFrqSystemLoaderC.getDeclaredField("disabled"); disabled.setAccessible(true); disabled.set(null, true); // Now make a parallel FRQ and an associated FinalizableWeakReference to an object, in order to // exercise some classes from the parallel ClassLoader.
Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue May 13 18:46:00 GMT 2025 - 7.6K bytes - Click Count (0)