![]() |
| 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 |
![]() Related Questions 1. Can You catch the Error? 2. Difference between compiletime exception and runtime exception?3. How 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 ? Latest Answer : " Throwable " is a class(it's default super class is Object) in java API. The Throwable class is the superclass of all errors and exceptions in the Java language. Only objects that are instances of this class (or one of its subclasses) are thrown by ... Read Answers (1) | Asked by : veera Can we catch an Error occurred in a class by extending that class with Throwable Since, Exception and error is the sub class of throwable.If yes/no- why? Latest Answer : we can handle the exception but we cabt handle error super call of both is throwable ... We usually extend Exception instead of Throwable. Why? In what situations we extend Throwable.Could anybody give the answer in detail. Thanks in advance. Latest Answer : Extending the Exception class (a descendant of Throwable) instead of extending Throwable itself is a programming convention, not a requirement.Like most conventions, following the convention lends consistency to the end result. ...
Sponsored Links
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||