how to call one program .class file in another program
Answer Posted / jason
for the above class "Hello" ...
creating its '.class' file in another class is..
class DemoHello
{ p s v m(...)
{
Hello h=new Hello();
Class c=h.getClass();
sop(c);
}
}
=================
o/p:
class Hello
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
What is meant by JVM? Is JVM platform independent or not?
Java openings 3 - 5 years, Lnt Infotech. requirements - core java, J2ee, struts, hibernate Interview Date:- 19 March 2011 Time:- 9:00 AM to 12:00 Pm Interview Location - L & T Infotech, Manapakkam, Chennai Refererral PS NO:- 291649 (Please mention this when u fill the form only then u will be considered for interview) Documents Required:- Latest Resume, Photograph and last 3 payslips Mail me on vasan2211@gmail.com once u appear for interview
What is difference between path and classpath?
Can we have 2 main methods in java class?
What are the 5 types of research methods?
Which class is used by server applications to obtain a port and listen for client requests?
Name the components that are termed to be Heavy-weight component but available in Light-weight components?
What is the difference between hashmap and hashtable in java?
Explain when we should make an instance variable private.
Java Compiler is stored in JDK, JRE or JVM?
How to sort a collection of custom Objects in Java?
Can you call a method in a method?
Write java program to reverse string without using api?
What is passing parameters in java?
Is object a data type in java?