Public class testPropertydescription {@ Test public void testcrud () throws Exception {Method [] Methods = IResourceService. class. getMethods (); Method [] declaredMethods = IResourceService. class. getDeclaredMethods (); for (int I = 0; I <Methods. length; I ++) {System. out. println (Methods [I]);} System. out. println ("_______________________________"); for (int I = 0; I <declaredMethods. length; I ++) {System. out. println (declaredMethods [I]) ;}} comparison of results:
Public abstract cn. welcone. pss. page. PageBean cn. welcone. pss. service. IGenericService. queryPageBean (cn. welcone. pss. page. QueryConditions)
Public abstract java. lang. Object cn. welcone. pss. service. IGenericService. get (java. io. Serializable)
Public abstract java. util. List cn. welcone. pss. service. IGenericService. list ()
Public abstract void cn. welcone. pss. service. IGenericService. save (java. lang. Object)
Public abstract void cn. welcone. pss. service. IGenericService. delete (java. io. Serializable) throws java. lang. Exception
Public abstract void cn. welcone. pss. service. IGenericService. update (java. lang. Object)
_______________________________
Note: getMethod () obtains the inherited method.
GetDeclaredMethod () obtains the method defined in this class.
This article is from "welcone !" Blog, please be sure to keep this source http://welcone.blog.51cto.com/5430968/1293996