File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to import a class in real time?

 
Guilherme Silveira
Greenhorn
Posts: 12
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have got a GUI application which has got GUI objects all extending a common guiClass (or so).
What I need is to make a designer which would read all classes under the gui package so it could allow the user to design an output with all those guiClass inside this package.
But how to get to know all those guiClasses inside this package? How to import them real-time also?
Thanks in advance,

------------------
------------------
TechnoBug
 
Geoffrey Falk
Ranch Hand
Posts: 171
1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Look up the Class Loader and the Reflection API.
Geoffrey

------------------
Sun Certified Programmer for the Java 2 Platform
 
Guilherme Silveira
Greenhorn
Posts: 12
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Geoffrey, but reading it still leaves with the question on how to read a whole package since i do not know the classes name.
I just now i want (i.e.) to read all the classes inside the "java.lang" package. So, if I know the classes names i just use the reflection api, in my case i still do not know the classes names. I have to call something to get to know all the classes under the package and then going to use the reflection api to get their methods/objects/etc...
Thanks in advance once again
Bug
 
Cindy Glass
"The Hood"
Sheriff
Posts: 8521
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
technobug,
Please change your name to be compliant with JavaRanch's naming policy.
Your ID should be 2 separate names with more than 1 letter each. It should not be obviously fictitious. We really want this to be a professional forum and would prefer that you use your REAL name.
Thanks,
Cindy
 
Guilherme Silveira
Greenhorn
Posts: 12
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well Cindy, I did not find where to change my name (I just found a page to change miscellaneous information about myself) therefore I will be creating a new profile...
Sorry for the misunderstanding
Guilherme (TechnoBug)
 
Guilherme Silveira
author
Greenhorn
Posts: 5
5
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Done
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic