APISonar


com.google.common.io.Files.equal

> com > google > common > io > Files > equal
com APIs google APIs common APIs io APIs Files APIs equal APIs

Example 1
private static boolean filesEqual(File file1, File file2)
    {
        try {
            return Files.equal(file1, file2);
        }
        catch (IOException e) {
            throw new UncheckedIOException(e);
        }
    }
Example 2
public List<String> diff() throws IOException {
    if (Files.equal(left.toFile(), right.toFile())) {
      return Collections.emptyList();
    }

    List<String> leftDump = jarDumper.dump(left);
    List<String> rightDump = jarDumper.dump(right);

    Patch<String> diff = DiffUtils.diff(leftDump, rightDump);
    return DiffUtils.generateUnifiedDiff(left.toString(), right.toString(), leftDump, diff, 4);
  }