wood burning stoves 2.0*
The moose likes Spring and the fly likes suppress checked compile time exception Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Frameworks » Spring
Bookmark "suppress checked compile time exception" Watch "suppress checked compile time exception" New topic
Author

suppress checked compile time exception

vik ar
Ranch Hand

Joined: Jul 31, 2009
Posts: 104
I want to handle checked exception via spring aop. At compile time a try catch is required otherwise compile time error results? Is there any way to suppress these errors?
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17250
    
    6

Have your method throw the Exception instead of catching it.

Mark


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: suppress checked compile time exception