GeekInterview.com
   Home |  Tech FAQ  |   Interview Questions |  Placement Papers |  Tech Articles |  Learn |  Freelance Projects |  Online Testing |  Geeks Talk |  Job Postings |  Knowledge Base | Site Search |  Add/Ask Question

GeekInterview.com  >  Interview Questions  >  J2EE  >  Core Java
Go To First  |  Previous Question  |  Next Question 
 Core Java  |  Question 432 of 493    Print  
how can we call a class in directory by a class in another directory by writing class paths

  
Total Answers and Comments: 2 Last Update: November 26, 2007     Asked by: loki 
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
November 17, 2007 19:35:20   #1  
kohina Member Since: May 2006   Contribution: 1    

RE: how can we call a class in directory by a class in...
Suppose 'A' directory has 'class x'  and ' B '  directory  has ' class y '  then while compling the x class give the classpath of class y . Even while running the class x the class path of y should be specified.(hope that 'y' is not dependent on x. compile y before 'x')

../ex>javac  x.java  -classpath = ../B

 
Is this answer useful? Yes | No
November 26, 2007 05:01:49   #2  
sreenivas reddy        

RE: how can we call a class in directory by a class in...
We should set the class path otherwise we can't compile the java program.
 
Is this answer useful? Yes | No

 Related Questions

Latest Answer : The intention behind this question is not clear here. Can u elaborate the question??????????? ...

Latest Answer : yes they are represented as wrapper classes ...

Latest Answer : A static member class or a static member interface comprises the same declarations as those allowed in an ordinary top-level class or interface. A static member class must be declared as a static member of an enclosing class or interface. Nested ...

Can we declare multiple main() methods in multiple classes.ie can we have each main method in its class in our program?

br />1.what is oracle.2.what is major differenece oracle8i and oracle9i.4.tell me some thing ur self.5.please tell me about oops.6.what is single inheritance.7.what is multiple inheritance.8.can java support 
Latest Answer : how do u prove that abstrace class cannot instantiate directly?    ofcourse abstract class can have constructor,but the keyword "abstract" denotes that the class or method is not yet constructed fully.So if we use abstract keyword ...
Read Answers (10) | Asked by : rajjava

Latest Answer : No a Class, Method cannot be Garbage collected simply because a class or Method does not have physical exestence in memory and garbage collector is only used for freeing up the memory which only applies to objects not classes or methods.So only objects ...
Read Answers (5) | Asked by : chandu

I want to create two instances of a class ,But when trying for creating third instance it should not allow me to create . what i have to do for making this?
Read Answers (4) | Asked by : chandu

Latest Answer : To provide multiple inheretance we needed interface ...
Read Answers (9) | Asked by : prakash

I need some more information about interface. For Example there is no any functionality inside the method which is declared in any interface. Then why i want to implement that interface to my class. 2. Statement is an interface. When i say stmt.executeQuery(). I am getting the records in my ResultSet. How it is possible?.. since there is no functionality insid the methods which is declared in Statement Interface. What is happning here?
An idea 

What is the difference between putting a class as abstract or if any of method in class is declared as abstract diference of these two while extending these two types of classes
Read Answers (1) | Asked by : karunakar
Tags : Abstract


 Sponsored Links

 
Related Articles

Service Oriented Java Business Integration Review

Service Oriented Java Business Integration Review Introduction If you ve read through the texts which give you an introduction to SOA or Web Services you will often find them to be quite frustrating and the reason for this is because they spend too much time referencing business processes which are
 

C++ Pure Virtual Function and Base Class

C Pure Virtual Function and Virtual Base Class In this C tutorial you will learn about pure virtual function declaration of pure virtual function and virtual base class virtual base class and how to implement a virtual base class explained with examples mosgoogle center What is Pure Virtual Function
 

Java and Client Server Models

Java and Client Server Models The Role of Client Servers on the Web Client server models provide the essential mechanisms for working with the Internet In fact most of the World Wide Web is built according to this paradigm In client server models the web browsers run by millions of users are the cli
 

How to Access C++ Class Members

How to Access C Class Members In this C tutorial you will learn how to access Class members dot operator or class member access operator difference between struct and class and  scope resolution operator mosgoogle center It is possible to access the class members after a class is defined an
 

How does the function call within function get evaluated?

Whenever we have more than one function which is called for a finite number of times then such a function gets evaluated from inside out. Let us understand this concept with an example. For instance consider a function sample called within it 4 times as given in program below: main() { int a=50;
 

How to call C header that is not provided generally by system in C++?

Headers can be called by using extern C Syntax of extern C is: extern "C" <function declaration> for example to call C functions from C++ we can write extern "C" { <function declaration> <function declaration> ...
 

What is difference between call by value and call by reference in function?

The arguments passed to function can be of two types 1. Values passed 2. Address passed The first type refers to call by value and the second type refers to call by reference. For instance consider program1 main() { int x=50, y=70; interchange(x,y); printf(“x=%d y=%d”,x,
 

Professional Resume Writing Services

A good resume will be a ticket to a great career while a badly written one will diminish your chances of getting hired. Your resume needs to have a great impact since you have less than 10 seconds to impress. Without any good information as well as presentation of your resume, you won’t ev
 

The Interview Snafu

How to turn someone else’s mistake to your advantage Your dream job is about to become reality. A recruiter gave you the heads up about the perfect position at Humungous Conglomerate, Inc. You went through five interviews as well as a battery of psychological tests mandated by their HR de
 

Winning a Job Interview with a Winning Resume

Does your resume unlock your potential, take your skills to the highest level and win you the interview and the job you want now? The job market today is highly competitive and even if you think you have what it takes to get an interview you won’t get over the line without a polished, prof
 





About Us  |   Privacy Policy  |   Terms and Conditions  |   Contact  |   Site Map  |   Add Question  |   Propose Category  |   RSS Feeds  |   Articles Sitemap  |   Site Updates  |   Add Resource

Copyright © 2005 - 2008 GeekInterview.com. All Rights Reserved
Page copy protected against web site content infringement by Copyscape