return;
}
for ( Iterator ii = catches.iterator(); ii.hasNext(); )
{
AnnotationInstance catchAnnotation = ( AnnotationInstance ) ii.next();
//
// Find the method referred to in this annotation. If we can't find it, do nothing -- this
// will get caught elsewhere in the checking.
//
String methodName = CompilerUtils.getString( catchAnnotation, METHOD_ATTR, false );
if ( methodName.length() > 0 && ! methodName.equals( methodBeingChecked.getSimpleName() ) )
{
MethodDeclaration otherMethod = findMethod( methodName, outerType );
if ( otherMethod != null )
{
//
// Look through this other method's forwards. None may have the same name (and different path)
// as the current one.
//
Collection otherForwards =
CompilerUtils.getAnnotationArrayValue( otherMethod, EXCEPTION_HANDLER_TAG_NAME,
FORWARDS_ATTR, false );
for ( Iterator i2 = otherForwards.iterator(); i2.hasNext(); )
{
AnnotationInstance otherForward = ( AnnotationInstance ) i2.next();
String otherForwardName = CompilerUtils.getString( otherForward, NAME_ATTR, true );
String otherForwardPath = CompilerUtils.getString( otherForward, PATH_ATTR, true );
String otherFwdNavigateTo =
CompilerUtils.getEnumFieldName( otherForward, NAVIGATE_TO_ATTR, true );
Collection forwards =
CompilerUtils.getAnnotationArrayValue( methodBeingChecked,
EXCEPTION_HANDLER_TAG_NAME,
FORWARDS_ATTR, false );
for ( Iterator i3 = forwards.iterator(); i3.hasNext(); )
{
AnnotationInstance forward = ( AnnotationInstance ) i3.next();
String forwardName = CompilerUtils.getString( forward, NAME_ATTR, true );
String forwardPath = CompilerUtils.getString( forward, PATH_ATTR, true );
String fwdNavigateTo = CompilerUtils.getEnumFieldName( forward, NAVIGATE_TO_ATTR, true );
if ( forwardName != null && forwardName.equals( otherForwardName ) )