File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Exception

 
naresh babu
Greenhorn
Posts: 16
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I had a question in exception:
public class exception1 extends Exception{}

public class exception2 extends exception1{}
I want client to catch only exception2, but
not exception1.Any ideas?

Thanks
 
Roy Ben Ami
Ranch Hand
Posts: 732
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
catch(Exception2 e){} ???
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic