Home
last modified time | relevance | path

Searched refs:invoke (Results 1 – 25 of 141) sorted by relevance

123456

/libcore/luni/src/test/java/libcore/java/lang/
DIntrinsicTest.java27 String.class.getMethod("charAt", int.class).invoke("hello", 0); in testString_charAt()
32 String.class.getMethod("compareTo", String.class).invoke("hello", "world"); in testString_compareTo()
37 String.class.getMethod("equals", Object.class).invoke("hello", "world"); in testString_equals()
42 String.class.getMethod("indexOf", int.class).invoke("hello", 'l'); in testString_fastIndexOf_II()
47 String.class.getMethod("isEmpty").invoke("hello"); in testString_isEmpty()
52 String.class.getMethod("length").invoke("hello"); in testString_length()
57 Math.class.getMethod("abs", int.class).invoke(null, 1); in testMath_abs()
59 Math.class.getMethod("abs", long.class).invoke(null, 1L); in testMath_abs()
61 Math.class.getMethod("abs", float.class).invoke(null, 1.0f); in testMath_abs()
63 Math.class.getMethod("abs", double.class).invoke(null, 1.0); in testMath_abs()
[all …]
DCharacterTest.java200 assertEquals(m.invoke(null, i), Character.isDigit(i)); in test_isDigit_against_icu4c()
209 assertEquals(m.invoke(null, i), Character.isIdentifierIgnorable(i)); in test_isIdentifierIgnorable_against_icu4c()
218 assertEquals(m.invoke(null, i), Character.isLetter(i)); in test_isLetter_against_icu4c()
227 assertEquals(m.invoke(null, i), Character.isLetterOrDigit(i)); in test_isLetterOrDigit_against_icu4c()
236 assertEquals(m.invoke(null, i), Character.isLowerCase(i)); in test_isLowerCase_against_icu4c()
249 assertFalse((Boolean) m.invoke(null, i)); in test_isSpaceChar_against_icu4c()
251 assertEquals("Failed for character " + i, m.invoke(null, i), Character.isSpaceChar(i)); in test_isSpaceChar_against_icu4c()
261 assertEquals(m.invoke(null, i), Character.isUpperCase(i)); in test_isUpperCase_against_icu4c()
274 assertFalse((Boolean) m.invoke(null, i)); in test_isWhitespace_against_icu4c()
276 assertEquals("Failed for character " + i, m.invoke(null, i), Character.isWhitespace(i)); in test_isWhitespace_against_icu4c()
DClassTest.java183 return (Class) method.invoke(null, name); in getPrimitiveType()
238 assertEquals("packageMethod2", m.invoke(instance)); in test_getVirtualMethod()
241 assertEquals("packageMethod", m.invoke(instance)); in test_getVirtualMethod()
247 assertEquals("protectedMethod2", m.invoke(instance)); in test_getVirtualMethod()
250 assertEquals("protectedMethod", m.invoke(instance)); in test_getVirtualMethod()
256 assertEquals("publicMethod2", m.invoke(instance)); in test_getVirtualMethod()
259 assertEquals("publicMethod", m.invoke(instance)); in test_getVirtualMethod()
/libcore/ojluni/annotations/hiddenapi/java/lang/invoke/
DMethodHandles.java26 package java.lang.invoke;
37 public static java.lang.invoke.MethodHandles.Lookup lookup() { in lookup()
41 public static java.lang.invoke.MethodHandles.Lookup publicLookup() { in publicLookup()
46 java.lang.Class<T> expected, java.lang.invoke.MethodHandle target) { in reflectAs()
50 private static java.lang.invoke.MethodHandleImpl getMethodHandleImpl( in getMethodHandleImpl()
51 java.lang.invoke.MethodHandle target) { in getMethodHandleImpl()
63 public static java.lang.invoke.MethodHandle arrayElementGetter(java.lang.Class<?> arrayClass) in arrayElementGetter()
100 public static java.lang.invoke.MethodHandle arrayElementSetter(java.lang.Class<?> arrayClass) in arrayElementSetter()
137 public static java.lang.invoke.VarHandle arrayElementVarHandle(java.lang.Class<?> arrayClass) in arrayElementVarHandle()
142 public static java.lang.invoke.VarHandle byteArrayViewVarHandle( in byteArrayViewVarHandle()
[all …]
/libcore/luni/src/test/java/libcore/java/lang/invoke/
DMethodHandleCombinersTest.java17 package libcore.java.lang.invoke;
20 import java.lang.invoke.MethodHandle;
21 import java.lang.invoke.MethodHandles;
22 import java.lang.invoke.MethodType;
23 import java.lang.invoke.WrongMethodTypeException;
44 handle.invoke(iae); in testThrowException()
74 transform.invoke(45, new Object(), "foo", 42l); in testDropArguments()
79 transform.invoke("foo", 45, new Object(), 42l); in testDropArguments()
84 transform.invoke("foo", 42l, 45, new Object()); in testDropArguments()
89 transform.invoke("foo", 42l, 45l, new Object()); in testDropArguments()
[all …]
DMethodHandlesTest.java17 package libcore.java.lang.invoke;
21 import java.lang.invoke.MethodHandle;
22 import java.lang.invoke.MethodHandleInfo;
23 import java.lang.invoke.MethodHandles;
24 import java.lang.invoke.MethodHandles.Lookup;
25 import java.lang.invoke.MethodType;
26 import java.lang.invoke.WrongMethodTypeException;
37 import static java.lang.invoke.MethodHandles.Lookup.*;
314 mh1.invoke(bInstance); in testfindSpecial_invokeSuperBehaviour()
320 mh1.invoke(new A()); in testfindSpecial_invokeSuperBehaviour()
[all …]
DCallSitesTest.java17 package libcore.java.lang.invoke;
21 import java.lang.invoke.CallSite;
22 import java.lang.invoke.ConstantCallSite;
23 import java.lang.invoke.MethodHandle;
24 import java.lang.invoke.MethodHandles;
25 import java.lang.invoke.MethodHandles.Lookup;
26 import java.lang.invoke.MethodType;
27 import java.lang.invoke.MutableCallSite;
28 import java.lang.invoke.VolatileCallSite;
29 import java.lang.invoke.WrongMethodTypeException;
[all …]
DMethodHandleAccessorsTest.java17 package libcore.java.lang.invoke;
21 import java.lang.invoke.MethodHandle;
22 import java.lang.invoke.MethodHandles;
23 import java.lang.invoke.WrongMethodTypeException;
761 h0.invoke(); in testStaticGetter()
762 Number t = (Number)h0.invoke(); in testStaticGetter()
763 int u = (int)h0.invoke(); in testStaticGetter()
764 Integer v = (Integer)h0.invoke(); in testStaticGetter()
765 long w = (long)h0.invoke(); in testStaticGetter()
767 byte x = (byte)h0.invoke(); in testStaticGetter()
[all …]
DMethodHandleInfoTest.java17 package libcore.java.lang.invoke;
21 import java.lang.invoke.MethodHandleInfo;
22 import java.lang.invoke.MethodType;
24 import static java.lang.invoke.MethodHandleInfo.*;
/libcore/luni/src/test/java/libcore/sun/invoke/util/
DVerifyAccessTest.java17 package libcore.sun.invoke.util;
21 import sun.invoke.util.VerifyAccess;
23 import java.lang.invoke.MethodHandle;
24 import java.lang.invoke.MethodHandles;
/libcore/ojluni/src/main/java/java/lang/invoke/
DMethodHandleInfo.java26 package java.lang.invoke;
30 import java.lang.invoke.MethodHandleNatives.Constants;
31 import java.lang.invoke.MethodHandles.Lookup;
32 import static java.lang.invoke.MethodHandleStatics.*;
DMethodHandleNatives.java26 package java.lang.invoke;
28 import static java.lang.invoke.MethodHandleNatives.Constants.*;
DCallSite.java26 package java.lang.invoke;
30 import static java.lang.invoke.MethodHandleStatics.*;
31 import static java.lang.invoke.MethodHandles.Lookup.IMPL_LOOKUP;
/libcore/dom/src/test/java/org/w3c/domts/
DLSDocumentBuilderFactory.java138 Object domConfig = domConfigMethod.invoke(parser, new Object[0]); in setParameter()
141 setParameterMethod.invoke(domConfig, new Object[] {parameter, value}); in setParameter()
156 Object domConfig = domConfigMethod.invoke(parser, new Object[0]); in getParameter()
159 return getParameterMethod.invoke(domConfig, new Object[] {parameter}); in getParameter()
276 Object domRegistry = newInstanceMethod.invoke(null, (Class<?>) null); in LSDocumentBuilderFactory()
279 impl = (DOMImplementation) getDOMImplementationMethod.invoke(domRegistry, in LSDocumentBuilderFactory()
283 parser = createLSParserMethod.invoke(impl, in LSDocumentBuilderFactory()
333 return (Document) parseURIMethod.invoke(parser, in load()
DDOM4JTestDocumentBuilderFactory.java72 domFactory = getInstance.invoke(null, new Object[] {}); in DOM4JTestDocumentBuilderFactory()
81 xmlReader = (XMLReader) getReaderMethod.invoke(saxReader, new Object[0]); in DOM4JTestDocumentBuilderFactory()
113 return (org.w3c.dom.Document) readMethod.invoke(saxReader, in load()
/libcore/test-rules/src/main/java/libcore/junit/util/
DSwitchTargetSdkVersionRule.java136 Object runtime = runtimeInstanceGetter.invoke(null); in createStatement()
137 int oldTargetSdkVersion = (int) targetSdkVersionGetter.invoke(runtime); in createStatement()
139 targetSdkVersionSetter.invoke(runtime, targetSdkVersion); in createStatement()
142 targetSdkVersionSetter.invoke(runtime, oldTargetSdkVersion); in createStatement()
/libcore/luni/src/test/java/libcore/java/math/
DRunCSVTestsStrict.java28 Object returnValue = m.invoke(null, input); in runTest()
50 returnValue = m.invoke(null, input1, (int) input2); in run2InputTest()
53 returnValue = m.invoke(null, input1, input2); in run2InputTest()
/libcore/luni/src/test/java/libcore/java/lang/reflect/
DMethodTest.java375 assertEquals(interfaceWithStaticClassName, method.invoke(null)); in testStaticInterfaceMethod_invoke()
376 assertEquals(interfaceWithStaticClassName, method.invoke(new InterfaceWithStatic() {})); in testStaticInterfaceMethod_invoke()
384 assertEquals(interfaceWithStaticClassName, method.invoke(null)); in testStaticInterfaceMethod_setAccessible()
416 assertEquals(interfaceWithDefaultClassName, defaultMethod.invoke(anon)); in testDefaultMethod_inheritance()
417 assertEquals(interfaceWithDefaultClassName, inheritedDefaultMethod.invoke(anon)); in testDefaultMethod_inheritance()
446 assertEquals(anonymousClassName, defaultMethod.invoke(anon)); in testDefaultMethod_override()
447 assertEquals(anonymousClassName, overriddenDefaultMethod.invoke(anon)); in testDefaultMethod_override()
461 assertEquals(InterfaceWithDefault.class.getName(), defaultMethod.invoke(anon)); in testDefaultMethod_setAccessible()
473 assertEquals(anon2Class.getName(), overriddenDefaultMethod.invoke(anon2)); in testDefaultMethod_setAccessible()
505 assertEquals(implClassName, implClassDefaultMethod.invoke(impl)); in testDefaultMethod_reimplementedInClass()
[all …]
DProxyTest.java34 public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {
66 assertEquals("foo", proxy.getClass().getMethod("echo", String.class).invoke(proxy, "foo")); in testClassLoaderDoesNotNeedToSeeInvocationHandlerLoader()
249 @Override public Object invoke(Object proxy, Method method, Object[] args) { in testEquals()
262 @Override public Object invoke(Object proxy, Method method, Object[] args) { in testHashCode()
272 @Override public Object invoke(Object proxy, Method method, Object[] args) { in testToString()
282 @Override public Object invoke(Object proxy, Method method, Object[] args) { in testReturnTypeDoesNotSatisfyAllConstraintsWithLenientCaller()
294 @Override public Object invoke(Object proxy, Method method, Object[] args) { in testReturnTypeDoesNotSatisfyAllConstraintsWithStrictCaller()
395 public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { in invoke() method in ProxyTest.TestInvocationHandler
405 public Object invoke(Object proxy, Method method, Object[] args) throws Throwable { in test24846()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/lang/reflect/
DProxyTest.java55 public Object invoke(Object proxy, Method method, Object[] args) in invoke() method in ProxyTest.Broken1Invoke
104 public Object invoke(Object proxy, Method method, Object[] args) in test_ProxyLjava_lang_reflect_InvocationHandler()
122 public Object invoke(Object proxy, Method method, Object[] args) in test_newProxyInstanceLjava_lang_ClassLoader$Ljava_lang_ClassLjava_lang_reflect_InvocationHandler()
196 public Object invoke(Object proxy, Method method, Object[] args) in test_isProxyClassLjava_lang_Class()
221 public Object invoke(Object proxy, Method method, Object[] args) in test_getInvocationHandlerLjava_lang_Object()
303 public Object invoke(Object object, Method method, Object[] args) in invoke() method in ProxyTest.TestProxyHandler
306 return method.invoke(proxied, args); in invoke()
/libcore/benchmarks/src/benchmarks/regression/
DReflectionBenchmark.java97 m.invoke(instance); in timeMethod_invokeV()
105 m.invoke(null); in timeMethod_invokeStaticV()
114 m.invoke(instance, 1); in timeMethod_invokeI()
124 m.invoke(instance, one); in timeMethod_invokePreBoxedI()
132 m.invoke(null, 1); in timeMethod_invokeStaticI()
141 m.invoke(null, one); in timeMethod_invokeStaticPreBoxedI()
/libcore/luni/src/main/java/javax/xml/datatype/
DDatatypeConfigurationException.java145 m.invoke(this, new Object[] {cause}); in initCauseByReflection()
157 Throwable cause = (Throwable) m1.invoke(this, new Object[] {}); in readObject()
163 m2.invoke(this, new Object[] {causeOnJDK13OrBelow}); in readObject()
/libcore/ojluni/src/lambda/java/java/lang/invoke/
DMethodHandle.java26 package java.lang.invoke;
34 public final Object invoke(Object... args) throws Throwable { return null; } in invoke() method in MethodHandle
/libcore/ojluni/src/test/java/util/stream/test/org/openjdk/tests/java/lang/invoke/
DDeserializeMethodTest.java23 package org.openjdk.tests.java.lang.invoke;
28 import java.lang.invoke.SerializedLambda;
/libcore/luni/src/test/java/libcore/javax/crypto/
DCipherOutputStreamTest.java97 .invoke(keyParamsBuilder, new Object[]{new String[]{"GCM"}}); in getAndroidKeyStoreSecretKey()
99 .invoke(keyParamsBuilder, new Object[]{new String[]{"NoPadding"}}); in getAndroidKeyStoreSecretKey()
101 keyParamsBuilderClass.getMethod("build", new Class[]{}).invoke(keyParamsBuilder); in getAndroidKeyStoreSecretKey()

123456