Equality of attributes of two files
Rajendra.Gutupalli at Sun.COM
Sun Jul 20 02:16:39 PDT 2008
I am looking for a method in BasicFileAttributes such as 'equals() or
compareTo' which compares basic file attributes of two files.
It would be helpful code such as below works:
BasicFileAttributes ba1 = Attributes.readBasicFileAttributes(file1,false);
BasicFileAttributes ba2 = Attributes.readBasicFileAttributes(file2,false);
S.O.P("Basic File Attributes of two files are same");
As of now BasicFileAttribute implementation does not seem to override
If the implementation has equals or compareTo methods then it is handy
for users to compare file attributes of two files without comparing each
attribute (like ba1.isDirectory()==ba2.isDirectory() etc.).
More information about the nio-dev