aspose file tools*
The moose likes Beginning Java and the fly likes Can the main() method throw Exceptions ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Can the main() method throw Exceptions ?" Watch "Can the main() method throw Exceptions ?" New topic
Author

Can the main() method throw Exceptions ?

Parag Kale
Greenhorn

Joined: Apr 08, 2001
Posts: 25
Can the main() method throw any exceptions ?
In general, is there any restriction on static methods for throwing Exceptions ?
Bosun Bello
Ranch Hand

Joined: Nov 06, 2000
Posts: 1510
Yes, main can throw exceptions and can be declared to throw exceptions.

Bosun (SCJP, SCWCD)
So much trouble in the world -- Bob Marley
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Can the main() method throw Exceptions ?