Solved

Show the class that is loading

Posted on 2004-04-29
16
185 Views
Last Modified: 2012-03-15
Hi i have an applet that take a lot of classes to load and i have a splash screen that display the user a little image with a JProgressBar with the setIndeterminate() to true. For this i don't care, but what i want is to do like acrobat software that display all plugin that is loading. So when the splashscreen start i want it to display all classes that is loading at the moment the jre load it.

Is there a dynamic way? Cause i know i can use
Class thatClass = Class.forName("TheClassToLoad");
  theObject = thatClass.newInstance();

but each time i will have to add a new class i will add to add these line... so i want  something that will know which classes the java runtime is loading and display the name to the user

thx
0
Comment
Question by:bumpert
  • 8
  • 4
  • 2
  • +1
16 Comments
 
LVL 35

Expert Comment

by:TimYates
ID: 10949124
That's the only way of doing it, unless you want to write your own classloader and sign your applet...

0
 
LVL 35

Expert Comment

by:TimYates
ID: 10949157
0
 

Author Comment

by:bumpert
ID: 10949298
my applet is already signed, and what do you mean when you said "write your own classloader"? Will i have to load EACH class manually with the code i post in my question???

cause if i'm not wrong, if i load my applet class the jre will automatically load all the class contain in this class... so all the class will load automatically without i have to load it by myself

i'll give a check to your url

thx
0
 

Author Comment

by:bumpert
ID: 10949827
humm i'm a little bit lost in all these links... i'll try continue reading on the subject but don't really know how and where to start to do what i want. I don't want people to make code for me, but just a little hint :)

thx
0
 

Author Comment

by:bumpert
ID: 10990142
nobody???
0
 
LVL 30

Expert Comment

by:mayankeagle
ID: 10992951
What seems to be the problem now?
0
 

Author Comment

by:bumpert
ID: 10995419
i'm still not able to do something for my problem... someone posted me links but that didn't help me (maybe i'm not good enough to do this)
i'm still searching on google and java forums to find solution

thx for help
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 
LVL 35

Expert Comment

by:TimYates
ID: 10995467
what you are trying to do is not an easy thing...

either you have to do it the way you said (with Class.forName) or you will need to write your own ClassLoader

To write your own ClassLoader, you will need to understand those links I gave you, and then you will need to digitally sign your applet, as applets are not normally allowed to define their own classloaders...

http://java.sun.com/developer/onlineTraining/Security/Fundamentals/magercises/ClassLoader/help.html

is another classloader tutorial
0
 

Author Comment

by:bumpert
ID: 10995559
ok i have something more urgent to do, and ill come back on this later... at least tomorrow and give you feedback

my applet is already sign so it would be more easy...

thx
0
 

Author Comment

by:bumpert
ID: 11164855
somoen answer me an another forum
sorry
0
 
LVL 35

Expert Comment

by:TimYates
ID: 11166122
> somoen answer me an another forum

what was the answer then?
0
 

Author Comment

by:bumpert
ID: 11168031
maybe not the best, but simple and working:
http://forum.java.sun.com/thread.jsp?forum=31&thread=518176
0
 
LVL 30

Expert Comment

by:mayankeagle
ID: 11168139
If I'm not mistaken, I think that even that one is not solved, and the last comment there is from you:

>> i give 1 more duke for somebody that could give ma solution that will help me do what i want
>> thx

What was the answer, BTW?
0
 

Author Comment

by:bumpert
ID: 11172346
heu!?!?

i give the duke on reply 16 of 18
the solution is on reply 16 of 18 (answer here)
the answer you writed here is on reply 14 of 18
on the reply 17 of 18 and said that the answer looks good
and at the last reply, 18 of 18, i'm leaving the topic

you didn't read all the thread...
0
 

Accepted Solution

by:
modulo earned 0 total points
ID: 11190377
Closed, 250 points refunded.

modulo
Community Support Moderator
Experts Exchange
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
triangle challenge 4 79
word0 challenge 3 59
java set up 1 48
eclipse java  build path 6 25
An old method to applying the Singleton pattern in your Java code is to check if a static instance, defined in the same class that needs to be instantiated once and only once, is null and then create a new instance; otherwise, the pre-existing insta…
Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
Viewers learn about the “for” loop and how it works in Java. By comparing it to the while loop learned before, viewers can make the transition easily. You will learn about the formatting of the for loop as we write a program that prints even numbers…
Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now