Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

The 'Class' and 'Method' classes

 
Chandra Kaye
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
I dont know whether this has to go in the beginners/indermediate/advanced. I would like to know when and why anyone would need to use the above two classes?? Method class objects represents methods of an object. We can use the invoke() method of the Method class object to invoke the method represnted by the Method object on some other object. Since the same functions can be performed by just creating objects and calling their methods through the object_name.method() format, why do we really need these classes??
Thanks in advance.
Regards
Chandra
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Chandra KKKK,
Welcome to JavaRanch!
We ain't got many rules 'round these parts, but we do got one. Please change your display name to comply with The JavaRanch Naming Policy.
Thanks Pardner! Hope to see you 'round the Ranch!
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Take a look at The Reflection Trail of Sun's Java Tutorial.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic