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 241 of 493    Print  
1. Can You catch the Error?

2. Difference between compiletime exception and runtime exception?

3. How you throw user defined exception?

4. How you handle throwable while using exceptions ?

5. What are the methods available in Object ?

6. Is there any methods available in serialization ?

7. How you seralize an Object ?

8.How you get the serialized object ?

9. Any methods available in deseralization ?

  
Total Answers and Comments: 7 Last Update: June 28, 2007     Asked by: sudhakar_bvr 
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
June 01, 2006 11:53:51   #1  
Rohit Sachan        

RE: 1. Can You catch the Error? 2. Differe...
1. No U can not catch the error.2. Error like stack over flow at run time which is diffrent from Exceptions exception are like the will come every time as in general there is sth wrong in your code, this kinda error will happen at run time depends on that perticular situation.
 
Is this answer useful? Yes | No
June 02, 2006 00:39:21   #2  
sudhakar_bvr Member Since: March 2006   Contribution: 10    

RE: 1. Can You catch the Error? 2. Differe...
Thank You
 
Is this answer useful? Yes | No
June 12, 2006 02:56:32   #3  
Klasseic        

RE: 1. Can You catch the Error? 2. Differe...

Error exceptions indicate a very serious problems that are usually unrecoverable and should never be caught. Its not a good idea to catch Error exceptions by 'try-catch' blocks.

But 'finally' clause will always be executed when any exception-including 'Error' exceptions- comes up in the call stack, so you can always clean up after any exception.


 
Is this answer useful? Yes | No
June 12, 2006 03:31:36   #4  
Klasseic        

RE: 1. Can You catch the Error? 2. Differe...

2. Runtime exceptions are  exceptions that extends the RuntimeException class and are called unchecked exceptions.

Compiler checks only the checked exceptions meaning, that your method throws only those exceptions that they have declared themselves to throw.Unchecked exceptions are thrown during runtime and are not checked by compiler, which extends the 'Exception' class but not 'RuntimeException' class.


 
Is this answer useful? Yes | No
August 24, 2006 13:58:43   #5  
kripa        

RE: 1. Can You catch the Error? 2. Differe...
it would be better to use a 'try-catch' block.
 
Is this answer useful? Yes | No
February 01, 2007 00:11:39   #6  
santosh dash        

RE: 1. Can You catch the Error? 2. Differe...
who tells no? we can catch errros by try/catch block.but it is advisible not to handle errors.every subclass of Throwable can be handled.
 
Is this answer useful? Yes | No
June 28, 2007 01:37:21   #7  
ambuj        

RE: 1. Can You catch the Error? 2. Differe...
No, because error is not related to ur progamming envirnment through which we can apply our exception handling mecanism. It occurs only due to operating system failure, System virus affected etc.
 
Is this answer useful? Yes | No


 
Go To Top


 Sponsored Links

 
Sponsored Links

 




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