Results 1 to 2 of 2
  1. #1
    deeevo is offline Member
    Join Date
    Apr 2013
    Rep Power

    Default Checked Exception

    Hi, I was wondering if someone could help me with this question, please?

    Question 3)
    Write a class named ConnectionException that is a checked Exception. The constructor should receive an error message call the parent class passing details of the error that caused the Exception.

    So far I have...

    Java Code:
    public class ConnectionException() throws Exception
    	public ConnectionException(String message)
    Any help would be appreciated :)

  2. #2
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Voorschoten, the Netherlands
    Blog Entries
    Rep Power

    Default Re: Checked Exception

    A class doesn't 'throws' anything, methods do. Your class should 'extend' something explicitly to be marked as a checked exception.

    kind regards,

    The only person who got everything done by Friday was Robinson Crusoe.

Similar Threads

  1. why we need checked exceptions
    By akiravelmont in forum New To Java
    Replies: 2
    Last Post: 12-03-2011, 08:51 PM
  2. Replies: 1
    Last Post: 12-16-2010, 03:39 PM
  3. Replies: 1
    Last Post: 02-08-2010, 02:57 PM
  4. radio button checked by default
    By whiteasshweta in forum JavaServer Pages (JSP) and JSTL
    Replies: 3
    Last Post: 07-06-2009, 01:11 PM
  5. Checked Exception
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 11-18-2007, 07:59 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts