Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

how and when compiler knows that the Java code throws the
checked Exception.

Answer Posted / aruna

Checked or caught exceptions are those exceptions that the
application programmer created a catch block to handle them.
while compiling, the java compiler make sure that all the
checked exceptions must be caught by the applicaion
programmer.Those exceptions are called the application or
business logic exceptions.

Inside the method body, there are calls to other methods;
the compiler looks at each of their method signature, what
exceptions they declared to throw. There are two
possibilities, either exceptions are caught inside the
caller-method by a try-catch block, or the caller declares
to throw the exception to its caller.

Is This Answer Correct ?    18 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is final?

1003


What is the purpose of stub and skeleton?

954


What are thread safe functions?

896


Does java have a compiler?

976


What is the purpose of main function in java?

969


How we can execute any code even before main method?

1074


Why array is used in java?

908


What do you understand by classes in java?

945


Can we have multiple classes in a single file?

912


What is hash code collision?

1002


What is the difference between a break statement and a continue statement?

988


What is jvm? Why is java called the platform independent programming language?

945


Is nan false?

915


What is meant by class and object in java?

968


What is object of class in java?

1067