Let’s say you have a class that extends RuntimeException, ExtendedRuntimeException.
Then you have a class that extends that, ExtraExtendedRuntimeException.
Then you have a class that extends that, ExtraExtraExtendedRuntimeException.
In your application, this in practical purposes only really has an inheritance depth of 3.
However squid:MaximumInheritanceDepth of max depth = 6 will hit because this exceeds max inheritance depth. Because
Throwable -> Exception -> RuntimeException -> ExtendedRuntimeException -> ExtraExtendedRuntimeException -> ExtraExtraExtendedRuntimeException
We should remove the Throwable, Exception and RuntimeException java.lang classes from the counter.