This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 149893

Summary: [introduce method] Too many return values although there is only 1 return value.
Product: java Reporter: giorgio42 <giorgio42>
Component: HintsAssignee: Max Sauer <msauer>
Status: RESOLVED WONTFIX    
Severity: blocker    
Priority: P3    
Version: 6.x   
Hardware: All   
OS: Windows XP   
Issue Type: DEFECT Exception Reporter:
Attachments: Screenshot

Description giorgio42 2008-10-12 22:29:52 UTC
NB6.5 daily from 20081010 refuses to convert the following code snippet from a J2SE project into a separate method:

    final File[] directoryEntries =
            entry.listFiles( new FileFilter() {
      public boolean accept( File pathname )
      {
        // Keep directories.
        if (pathname.isDirectory()) {
          return true;
        }
        
        final int position =
                pathname.getName().lastIndexOf(  File.separator );
        String fileName = pathname.getName();
        if (position >=0) {
          fileName = pathname.getName().substring( position + 1 );
        }
        getLog().debug( "Checking file name " + fileName );
        return fileName.matches( pattern );
      }
    });

Regards,
Georg
Comment 1 giorgio42 2008-10-12 22:30:52 UTC
Created attachment 71625 [details]
Screenshot
Comment 2 Jan Becicka 2008-11-13 10:47:15 UTC
Will resolve later
Comment 3 Quality Engineering 2009-11-02 11:03:23 UTC
NetBeans.org Migration: changing resolution from LATER to WONTFIX