@Test public void files() throws FileSystemException { List<FileSystem> fileSystems = Arrays.asList( new FileSystem.Fake(Collections.singletonList(new FileSystemPath.Fake())), new FileSystem.Fake(Collections.singletonList(new FileSystemPath.Fake()))); MatcherAssert.assertThat( new FileSystemOfFileSystems(fileSystems).files(), Matchers.hasSize(2)); }
@Override public List<FileSystemPath> files() throws FileSystemException { List<FileSystemPath> files = new ArrayList<>(); for (FileSystem fileSystem : fileSystems) { files.addAll(fileSystem.files()); } return files; }
FileSystemOfFileSystems implements FileSystem { @Override public List<FileSystemPath> files() throws FileSystemException { List<FileSystemPath> files = new ArrayList<>(); for (FileSystem fileSystem : fileSystems) { files.addAll(fileSystem.files()); } return files; } }
FileSystemOfFileSystems implements FileSystem { @Override public List<FileSystemPath> files() throws FileSystemException { List<FileSystemPath> files = new ArrayList<>(); for (FileSystem fileSystem : fileSystems) { files.addAll(fileSystem.files()); } return files; } FileSystemOfFileSystems(List<FileSystem> fileSystems);   FileSystemOfFileSystems(FileSystem... fileSystems); }
FileSystemOfFileSystems implements FileSystem { @Override public List<FileSystemPath> files() throws FileSystemException { List<FileSystemPath> files = new ArrayList<>(); for (FileSystem fileSystem : fileSystems) { files.addAll(fileSystem.files()); } return files; } FileSystemOfFileSystems(List<FileSystem> fileSystems);   FileSystemOfFileSystems(FileSystem... fileSystems); @Override List<FileSystemPath> files(); }
FileSystemOfFileSystems implements FileSystem { @Override public List<FileSystemPath> files() throws FileSystemException { List<FileSystemPath> files = new ArrayList<>(); for (FileSystem fileSystem : fileSystems) { files.addAll(fileSystem.files()); } return files; } FileSystemOfFileSystems(List<FileSystem> fileSystems);   FileSystemOfFileSystems(FileSystem... fileSystems); @Override List<FileSystemPath> files();  }