public static boolean containsFile(@NotNull SourceProvider provider,@NotNull File file){
  Collection<File> srcDirectories=getAllSourceFolders(provider);
  if (filesEqual(provider.getManifestFile(),file)) {
    return true;
  }
  for (  File container : srcDirectories) {
    File parent=container.getParentFile();
    if (parent != null && parent.isDirectory() && filesEqual(parent,file)) {
      return true;
    }
    if (!container.exists()) {
      continue;
    }
    if (isAncestor(container,file,false)) {
      return true;
    }
  }
  return false;
}

public static boolean containsFile ( @ NotNull SourceProvider provider , @ NotNull File file ) { Collection < File > srcDirectories = getAllSourceFolders ( provider ) ; if ( filesEqual ( provider . getManifestFile ( ) , file ) ) { return true ; } for ( File container : srcDirectories ) { File parent = container . getParentFile ( ) ; if ( parent != null && parent . isDirectory ( ) && filesEqual ( parent , file ) ) { return true ; } if ( ! container . exists ( ) ) { continue ; } if ( isAncestor ( container , file , false ) ) { return true ; } } return false ; }
returns true iff this sourceprovider provides the source folder that contains the given file .
