private void reportBugs ( ) { for ( Map . Entry < QMethod , String > attEntry : attributes . entrySet ( ) ) { QMethod methodInfo = attEntry . getKey ( ) ; String attType = attEntry . getValue ( ) ; Map < Map . Entry < String , String > , SourceLineAnnotation > fields = methodWrites . get ( methodInfo ) ; if ( ( fields == null ) || ( fields . size ( ) != 1 ) ) { continue ; } Map . Entry < String , String > fieldInfo = fields . keySet ( ) . iterator ( ) . next ( ) ; String fieldType = fieldInfo . getValue ( ) ; if ( ! attType . equals ( fieldType ) ) { continue ; } String fieldName = fieldInfo . getKey ( ) ; for ( Map . Entry < QMethod , Map < Map . Entry < String , String > , SourceLineAnnotation > > fwEntry : methodWrites . entrySet ( ) ) { if ( fwEntry . getKey ( ) . equals ( methodInfo ) ) { continue ; } SourceLineAnnotation sla = fwEntry . getValue ( ) . get ( fieldInfo ) ; if ( sla != null ) { bugReporter . reportBug ( new BugInstance ( this , BugType . NRTL_NON_RECYCLEABLE_TAG_LIB . name ( ) , NORMAL_PRIORITY ) . addClass ( this ) . addField ( fieldAnnotations . get ( fieldName ) ) . addSourceLine ( sla ) ) ; break ; } } } }
generates all the bug reports for attributes that are not recycleable