posted 16 years ago
hi,please resolve the problem of exception for overriding.Actually ,if super class declares a checked exception,then the overriding method cannot declare a new exception,or a cheked exception of broader type.
But the following gives error;
class A
{
void method() throws Exception
{
}
}
class B extends A
{
void method()
{
}
}
In the above scenario,the overriding method cannot declare a new exception or a checked exception of broader type ,But it is showing the error.Please solve this problem.