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...

what is difference between throw and throws in exception?

Answer Posted / chandrakala

throw and throws are clauses.
throws: if we are not interested to catch the exception then we have to use throws. if any exception arises then internally JVM handles that exception.
throw: If we want to throw an exception explicitly we have to use throw.It comes under user defined exception.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are adapter classes?

1047


What do you understand by classes in java?

1005


Why does my function print none?

951


v-model life cycle

2042


What is the difference between length and size in java?

988


What is static class

1112


What is integer valueof?

1103


What is a “stateless” protocol ?

988


Why java is considered as platform independent?

1001


How objects of a class are created if no constructor is defined in the class?

1068


Give us a program to check for parenthesis matching using stack.

1001


Is there any tag in htm to upload and download files?

1045


Write a program to reverse a number in java?

1087


Does list allow duplicates in java?

928


Is void a data type?

954