Home
last modified time | relevance | path

Searched refs:getMethod (Results 1 – 25 of 99) sorted by relevance

1234

/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 …]
/libcore/luni/src/test/java/libcore/java/lang/reflect/
DMethodTest.java33 Method method = MethodTestHelper.class.getMethod("m1", new Class[0]); in test_getExceptionTypes()
46 Method method = MethodTestHelper.class.getMethod("m1", expectedParameters); in test_getParameterTypes()
50 method = MethodTestHelper.class.getMethod("m2", expectedParameters); in test_getParameterTypes()
63 Method method = MethodTestHelper.class.getMethod("m1", expectedParameters); in test_getParameterCount()
67 method = MethodTestHelper.class.getMethod("m2", expectedParameters); in test_getParameterCount()
74 Method method = MethodTestHelper.class.getMethod("m1", expectedParameters); in test_getParameters()
78 method = MethodTestHelper.class.getMethod("m2", expectedParameters); in test_getParameters()
94 assertEquals(InterfaceA.class, Sub.class.getMethod("a").getDeclaringClass()); in testGetMethodWithPrivateMethodAndInterfaceMethod()
98 assertEquals(InterfaceA.class, ImplementsC.class.getMethod("a").getDeclaringClass()); in testGetMethodReturnsIndirectlyImplementedInterface()
99 assertEquals(InterfaceA.class, ExtendsImplementsC.class.getMethod("a").getDeclaringClass()); in testGetMethodReturnsIndirectlyImplementedInterface()
[all …]
DMethodOverridesTest.java30 Method method = StringBuilder.class.getMethod("append", char.class); in testName()
35 Method method = StringBuilder.class.getMethod("append", char.class); in testParameterTypes()
41 Method method = StringBuilder.class.getMethod("append", char.class); in testDeclaringClass()
46 Method method = StringBuilder.class.getMethod("append", char.class); in testReturnType()
51 Method method = StringBuilder.class.getMethod("append", char.class); in testThrownExceptions()
66 assertEquals(Sub.class, Sub.class.getMethod("unchanged").getDeclaringClass()); in testGetDeclaringClassReturnsOverridingClass()
74 assertEquals(Sub.class, Sub.class.getMethod("thrower").getDeclaringClass()); in testGetMethodsDoesNotIncludeExceptionChanges()
82 Method method = Sub.class.getMethod("returner"); in testGetMethodsIncludesSyntheticMethods()
92 Method method = Sub.class.getMethod("returner"); in testGetDeclaredMethodsIncludesSyntheticMethods()
109 Method method = Sub.class.getMethod("visibility"); in testSubclassChangesVisibility()
[all …]
DGenericExceptionsTest.java31 Method method = Thrower.class.getMethod("parameterizedMethod"); in testGenericExceptionsOfMethodsWithTypeParameters()
37 Method method = Thrower.class.getMethod("genericParameters", List.class); in testGenericExceptionsOfMethodsWithGenericParameters()
63 Method method = ThrowerT.class.getMethod("throwsTypeVariable"); in testMethodThrowingTypeVariable()
71 Method method = ThrowerT.class.getMethod("throwsMethodTypeParameter"); in testThrowingMethodTypeParameter()
79 Method method = ThrowerT.class.getMethod("throwsEverything"); in testThrowingMethodThrowsEverything()
/libcore/ojluni/src/test/java/lang/StackWalker/
DReflectionFrames.java91 .getMethod("create", How.class) in testNewStackInspector()
113 .getMethod("reflect", How.class) in testNewStackInspector()
137 .getMethod("handle", How.class) in testNewStackInspector()
165 .getMethod("create", How.class) in testNewStackInspector()
192 .getMethod("reflect", How.class) in testNewStackInspector()
223 .getMethod("handle", How.class) in testNewStackInspector()
267 .getMethod("create", How.class) in testConstructor()
289 .getMethod("reflect", How.class) in testConstructor()
313 .getMethod("handle", How.class) in testConstructor()
341 .getMethod("create", How.class) in testConstructor()
[all …]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/org/xml/sax/helpers/
DXMLFilterImplTest.java195 assertEquals("parse", logger.getMethod()); in testParseInputSource()
221 assertEquals("parse", logger.getMethod()); in testParseString()
279 assertEquals("notationDecl", logger.getMethod()); in testNotationDecl()
292 assertEquals("unparsedEntityDecl", logger.getMethod()); in testUnparsedEntityDecl()
303 assertEquals("setDocumentLocator", logger.getMethod()); in testSetDocumentLocator()
309 assertEquals("setDocumentLocator", logger.getMethod()); in testSetDocumentLocator()
321 assertEquals("startDocument", logger.getMethod()); in testStartDocument()
333 assertEquals("endDocument", logger.getMethod()); in testEndDocument()
345 assertEquals("startPrefixMapping", logger.getMethod()); in testStartPrefixMapping()
358 assertEquals("endPrefixMapping", logger.getMethod()); in testEndPrefixMapping()
[all …]
DXMLReaderAdapterTest.java140 assertEquals("startDocument", logger.getMethod()); in testSetDocumentHandler()
167 assertEquals("parse", logger.getMethod(0)); in testParseString()
182 assertEquals("parse", logger.getMethod()); in testParseInputSource()
191 assertEquals("setDocumentLocator", logger.getMethod()); in testSetDocumentLocator()
207 assertEquals("startDocument", logger.getMethod()); in testStartDocument()
219 assertEquals("endDocument", logger.getMethod()); in testEndDocument()
245 assertEquals("startElement", logger.getMethod()); in testStartElement()
259 assertEquals("endElement", logger.getMethod()); in testEndElement()
273 assertEquals("characters", logger.getMethod()); in testCharacters()
287 assertEquals("ignorableWhitespace", logger.getMethod()); in testIgnorableWhitespace()
[all …]
DParserAdapterTest.java201 assertEquals("parse", logger.getMethod()); in testParseString()
216 assertEquals("parse", logger.getMethod()); in testParseInputSource()
226 assertEquals("setDocumentLocator", logger.getMethod()); in testSetDocumentLocator()
232 assertEquals("setDocumentLocator", logger.getMethod()); in testSetDocumentLocator()
244 assertEquals("startDocument", logger.getMethod()); in testStartDocument()
256 assertEquals("endDocument", logger.getMethod()); in testEndDocument()
271 assertEquals("startElement", logger.getMethod()); in testStartElement()
290 assertEquals("endElement", logger.getMethod()); in testEndElement()
304 assertEquals("characters", logger.getMethod()); in testCharacters()
318 assertEquals("ignorableWhitespace", logger.getMethod()); in testIgnorableWhitespace()
[all …]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/lang/reflect/
DGenericMethodsTests.java87 Method method = clazz.getMethod("noParamNoReturn"); in testNoParamNoReturn()
92 Method method = clazz.getMethod("paramNoReturn", Object.class); in testParamNoReturn()
98 Method method = clazz.getMethod("noParamReturn"); in testNoParamReturn()
104 Method method = clazz.getMethod("paramReturn", Object.class); in testParamReturn()
110 Method method0 = clazz.getMethod("paramNoReturn", Object.class); in testIndependencyOfMethodTypeParameters()
113 Method method1 = clazz.getMethod("noParamNoReturn"); in testIndependencyOfMethodTypeParameters()
DMethodTest.java201 m1 = TestMethod.class.getMethod("invokeInstanceTest", new Class[0]); in test_equalsLjava_lang_Object()
202 m2 = TestMethodSub.class.getMethod("invokeInstanceTest", in test_equalsLjava_lang_Object()
210 m1 = TestMethod.class.getMethod("invokeStaticTest", new Class[0]); in test_equalsLjava_lang_Object()
212 .getMethod("invokeStaticTest", new Class[0]); in test_equalsLjava_lang_Object()
224 Method m1 = TestMethod.class.getMethod("invokeInstanceTest", new Class[0]); in test_getMethod()
225 Method m2 = TestMethod.class.getMethod("invokeInstanceTest", (Class[]) null); in test_getMethod()
267 Method mth = TestMethod.class.getMethod("voidMethod", new Class[0]); in test_getExceptionTypes()
273 mth = TestMethod.class.getMethod("intMethod", new Class[0]); in test_getExceptionTypes()
294 mth = cl.getMethod("pustatic", new Class[0]); in test_getModifiers()
344 mth = TestMethod.class.getMethod("voidMethod", new Class[0]); in test_getName()
[all …]
DBoundedGenericMethodsTests.java108 Method method = clazz.getMethod("noParamNoReturn"); in testNoParamNoReturn()
112 Method method = clazz.getMethod("paramNoReturn", BoundedGenericMethods.class); in testUnboundedParamNoReturn()
117 Method method = clazz.getMethod("noParamReturn"); in testNoParamReturn()
123 Method method = clazz.getMethod("paramReturn", BoundedGenericMethods.class); in testUnboundedParamReturn()
DWildcardTypeTest.java129 …Method method = clazz.getMethod("upperBoundedParamNoReturn", BoundedWildcardsGenericMethods.class); in testUpperBoundedParamNoReturn()
135 … Method method = clazz.getMethod("lowerBoundedParamReturn", BoundedWildcardsGenericMethods.class); in testLowerBoundedParamReturn()
142 … Method method = clazz.getMethod("upperBoundedParamReturn", BoundedWildcardsGenericMethods.class); in testUpperBoundedParamReturn()
149 …Method method = clazz.getMethod("lowerBoundedParamNoReturn", BoundedWildcardsGenericMethods.class); in testLowerBoundedParamNoReturn()
DAccessibleObjectTest.java135 AccessibleObject ao = SubTestClass.class.getMethod("annotatedMethod"); in test_getAnnotation()
156 AccessibleObject ao = SubTestClass.class.getMethod("annotatedMethod"); in test_getAnnotations()
171 AccessibleObject ao = SubTestClass.class.getMethod("annotatedMethod"); in test_getDeclaredAnnotations()
186 AccessibleObject ao = SubTestClass.class.getMethod("annotatedMethod"); in test_isAnnotationPresent()
/libcore/dom/src/test/java/org/w3c/domts/
DLSDocumentBuilderFactory.java136 Method domConfigMethod = parser.getClass().getMethod("getDomConfig", in setParameter()
139 Method setParameterMethod = domConfig.getClass().getMethod( in setParameter()
154 Method domConfigMethod = parser.getClass().getMethod("getDomConfig", in getParameter()
157 Method getParameterMethod = domConfig.getClass().getMethod("getParameter", in getParameter()
275 Method newInstanceMethod = domImplRegistryClass.getMethod("newInstance", (Class<?>) null); in LSDocumentBuilderFactory()
277 Method getDOMImplementationMethod = domImplRegistryClass.getMethod( in LSDocumentBuilderFactory()
281 Method createLSParserMethod = impl.getClass().getMethod("createLSParser", in LSDocumentBuilderFactory()
285 parseURIMethod = parser.getClass().getMethod("parseURI", in LSDocumentBuilderFactory()
DDOM4JTestDocumentBuilderFactory.java71 Method getInstance = domFactoryClass.getMethod("getInstance", new Class[] {}); in DOM4JTestDocumentBuilderFactory()
79 Method getReaderMethod = saxReaderClass.getMethod("getXMLReader", in DOM4JTestDocumentBuilderFactory()
83 readMethod = saxReaderClass.getMethod("read", new Class[] {java.net.URL.class}); in DOM4JTestDocumentBuilderFactory()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/org/xml/sax/support/
DMethodLogger.java59 public String getMethod(int index) { in getMethod() method in MethodLogger
67 public String getMethod() { in getMethod() method in MethodLogger
68 return (size() == 0 ? null : getMethod(size() - 1)); in getMethod()
/libcore/luni/src/test/java/libcore/java/math/
DRunCSVTestsStrict.java27 Method m = mathClass.getMethod(func, new Class[] { Double.TYPE }); in runTest()
49 m = mathClass.getMethod(func, new Class[] { Double.TYPE, Integer.TYPE }); in run2InputTest()
52 m = mathClass.getMethod(func, new Class[] { Double.TYPE, Double.TYPE }); in run2InputTest()
DRunCSVTests.java57 Method m = mathClass.getMethod(func, new Class[] { Double.TYPE }); in runTest()
87 m = mathClass.getMethod(func, new Class[] { Double.TYPE, Integer.TYPE }); in run2InputTest()
90 m = mathClass.getMethod(func, new Class[] { Double.TYPE, Double.TYPE }); in run2InputTest()
/libcore/test-rules/src/main/java/libcore/junit/util/
DSwitchTargetSdkVersionRule.java126 this.runtimeInstanceGetter = runtimeClass.getMethod("getRuntime"); in SwitchVMRuntimeUsingReflection()
127 this.targetSdkVersionGetter = runtimeClass.getMethod("getTargetSdkVersion"); in SwitchVMRuntimeUsingReflection()
128 this.targetSdkVersionSetter = runtimeClass.getMethod("setTargetSdkVersion", int.class); in SwitchVMRuntimeUsingReflection()
DResourceLeakageDetector.java65 Method method = closeGuardSupportClass.getMethod("getRule");
94 Method method = closeGuardSupportClass.getMethod("getFinalizerChecker"); in getFinalizerChecker()
/libcore/luni/src/test/java/libcore/javax/crypto/
DCipherOutputStreamTest.java96 keyParamsBuilderClass.getMethod("setBlockModes", new Class[]{String[].class}) in getAndroidKeyStoreSecretKey()
98 keyParamsBuilderClass.getMethod("setEncryptionPaddings", new Class[]{String[].class}) in getAndroidKeyStoreSecretKey()
101 keyParamsBuilderClass.getMethod("build", new Class[]{}).invoke(keyParamsBuilder); in getAndroidKeyStoreSecretKey()
/libcore/ojluni/src/test/java/io/Writer/
DAppend.java58 test(c.getMethod("append", cparams), io); in test()
60 test(c.getMethod("append", csparams), io); in test()
/libcore/ojluni/src/test/java/lang/invoke/VarHandles/
DVarHandleTestReflection.java63 Method vhm = VarHandle.class.getMethod(accessMode.methodName(), Object[].class); in methodInvocation()
74 VarHandle.class.getMethod(accessMode.methodName(), Object[].class)); in methodHandleInvoke()
88 VarHandle.class.getMethod(accessMode.methodName(), Object[].class)); in methodInvocationFromMethodInfo()
/libcore/ojluni/src/main/java/sun/net/
DProgressMonitor.java129 …ProgressEvent pe = new ProgressEvent(pi, pi.getURL(), pi.getMethod(), pi.getContentType(), pi.getS… in registerSource()
166 …ProgressEvent pe = new ProgressEvent(pi, pi.getURL(), pi.getMethod(), pi.getContentType(), pi.getS… in unregisterSource()
198 …ProgressEvent pe = new ProgressEvent(pi, pi.getURL(), pi.getMethod(), pi.getContentType(), pi.getS… in updateProgress()
/libcore/luni/src/test/java/libcore/libcore/io/
DFdsanTest.java73 Method pfdMethodDup = pfdClass.getMethod("dup", FileDescriptor.class); in testParcelFileDescriptor()
74 Method pfdMethodClose = pfdClass.getMethod("close"); in testParcelFileDescriptor()
75 Method pfdMethodGetFileDescriptor = pfdClass.getMethod("getFileDescriptor"); in testParcelFileDescriptor()

1234