File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

What is class class...

 
kashif hameed
Greenhorn
Posts: 15
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
Dear grat java fellows,I have a problum.What is class class ,I think a polite person in which must be explain thsi!
Kashif Hameed!
 
Michael Morris
Ranch Hand
Posts: 3451
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The Class class (did you hear an echo?) is mainly used for the java reflection API. If you know the Class of an object you can learn practically everything about its class: fields, methods, constructors, etc. It also has a couple of handy methods, getResource() and getResourceAsStream(), which return URL and InputStream respectively. Those are very usefull when you have a resource in the same jar file as the object of the particular Class. You will no doubt eventually see code like:

That static method causes the ClassLoader to dynamically load the class com.mywww.DBDriver, provided of course it can locate it.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic