Is java Exception class checked type?
<p>Here is an example that shows contrary behavior of java 'Exception' class.</p>

<pre><code>Try
{
}
catch(Exception ex)
{
}
</code></pre>

<p>In case of checked type of exception, if we keep a catch block without any error provoking statement to that particular checked exception in try block then, compiler will raise an error like “This exception is never thrown from the try statement body”. But in above case compiler will not give any error.</p>

<p>On the other hand, if we raise an exception of type 'Exception' class by using throw key word, the exception will not be automatically ducked to a caller, like below</p>

<pre><code>throw new Exception();
</code></pre>

<p>In above case compiler gives error like “Unhandled exception type Exception”.</p>

<p>So, is java Exception class is checked type or unchecked type?</p>

<p>Thanks
Raj.</p>
