@Test public void testEquals() { File file1 = new File("target/one.txt"); File file2 = new File("target/two.txt"); assertThat(FileLocation.of(file1)).isEqualTo(FileLocation.of(file1)); assertThat(FileLocation.of(file1)).isNotEqualTo(FileLocation.of(file2)); assertThat(FileLocation.of(file2)).isNotEqualTo(FileLocation.of(file1)); }
@Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } FileLocation that = (FileLocation) o; return file.equals(that.file); }
FileLocation implements Location { @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } FileLocation that = (FileLocation) o; return file.equals(that.file); } }
FileLocation implements Location { @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } FileLocation that = (FileLocation) o; return file.equals(that.file); } private  FileLocation(File file); }
FileLocation implements Location { @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } FileLocation that = (FileLocation) o; return file.equals(that.file); } private  FileLocation(File file); static FileLocation of(File file); static FileLocation of(String path); static FileLocation of(URL url); static ResourceLocation ofClasspath(String pathStartingWithSlash); static FileLocation byWildcardFilename(File directory, String wildcardFilename); static FileLocation byWildcardMavenFilename(File directory, String wildcardFilename); @Deprecated static FileLocation ofShared(String relativePath); File getFile(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString(); }
FileLocation implements Location { @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } FileLocation that = (FileLocation) o; return file.equals(that.file); } private  FileLocation(File file); static FileLocation of(File file); static FileLocation of(String path); static FileLocation of(URL url); static ResourceLocation ofClasspath(String pathStartingWithSlash); static FileLocation byWildcardFilename(File directory, String wildcardFilename); static FileLocation byWildcardMavenFilename(File directory, String wildcardFilename); @Deprecated static FileLocation ofShared(String relativePath); File getFile(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString();  }