打开APP
userphoto
未登录

开通VIP,畅享免费电子书等14项超值服

开通VIP
Class.getDeclaredMethods

Returns an array containing Method objects reflecting all the declared methods of the class or interface represented by this Class object, including public, protected, default (package) access, and private methods, but excluding inherited methods.

返回一个数组,包含类或接口声明的方法对象: 包含 public、protected、package(缺省的),以及 private 方法,但不包含继承的方法


If this Class object represents a type that has multiple declared methods with the same name and parameter types, but different return types, then the returned array has a Method object for each such method.

如果这个对象中有同名方法, 有同名同类型的参数但返回不同的类型, 则返回的数组中,每个方法对应一个Method对象;


If this Class object represents a type that has a class initialization method <clinit>, then the returned array does not have a corresponding Method object.

如果这个对象有类的初始化方法<cinit>,则返回的数组中不包含此方法;


If this Class object represents a class or interface with no declared methods, then the returned array has length 0.

如果这个类对象表示没有声明方法的类或接口,返回数组的程度为0;


If this Class object represents an array type, a primitive type, or void, then the returned array has length 0.

如果这个类对象表示数组类型、基本类型或void,则返回的数组长度为0。


The elements in the returned array are not sorted and are not in any particular order.

返回的数组中的元素没有排序,也没有任何特定的顺序。

本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请点击举报
打开APP,阅读全文并永久保存 查看更多类似文章
猜你喜欢
类似文章
【热】打开小程序,算一算2024你的财运
Objective-C 编程语言官网文档(三)-协议
java 反射常用方法
JAVA语言中的反射机制
js如何判断一个对象是不是Array?
历史上的 Collection 类 ― 数组
关于一些前端js框架的源码研究
更多类似文章 >>
生活服务
热点新闻
分享 收藏 导长图 关注 下载文章
绑定账号成功
后续可登录账号畅享VIP特权!
如果VIP功能使用有故障,
可点击这里联系客服!

联系客服