RFR(JDK 12/NIO) 8202285: (fs) Add a method to Files for comparing file contents
Joe Wang
huizhe.wang at oracle.com
Wed Oct 17 19:33:57 UTC 2018
On 10/17/18, 7:16 AM, Roger Riggs wrote:
> Hi Joe,
>
> Looks good, straightforward and easy to understand.
Glad to hear that, while it's been back and forth a couple of times, it
seems "straightforward and easy" won :-)
>
> The spec text in the CSR need to be updated to match. (At least the
> paragraph about reflexive and atomic).
CSR: update the text and attachment
https://bugs.openjdk.java.net/browse/JDK-8202302
Also added coverage to spec case 5 - reflexive (no new test cases),
spec case 6 - symmetric with tests selected from case 3.
webrevs: http://cr.openjdk.java.net/~joehw/jdk12/8202285/webrev_v05/
Thanks,
Joe
>
> Thanks, Roger
>
> On 10/16/2018 02:10 PM, Joe Wang wrote:
>> Hi Daniel,
>>
>> @linkplain it is! Thanks! And yes, int totalRead was fixed in the
>> previous webrevs.
>>
>> Current version:
>> specdiff:
>> http://cr.openjdk.java.net/~joehw/jdk12/8202285/specdiff_v04/java/nio/file/Files.html
>>
>> webrevs: http://cr.openjdk.java.net/~joehw/jdk12/8202285/webrev_v04/
>>
>> Previous version:
>> specdiff:
>> http://cr.openjdk.java.net/~joehw/jdk12/8202285/specdiff_v03/java/nio/file/Files.html
>>
>> webrevs: http://cr.openjdk.java.net/~joehw/jdk12/8202285/webrev_v03/
>>
>> Best regards,
>> Joe
>>
>> On 10/16/18, 2:11 AM, Daniel Fuchs wrote:
>>> Hi Joe,
>>>
>>> There are a few places where {@linkplain } should be used instead
>>> of {@link }. For instance:
>>>
>>> 1545 * <li> The two paths locate the {@link #isSameFile(Path,
>>> Path) same file},
>>>
>>> This should be {@linkplain } - for the record {@link } will format the
>>> text as code, {@linkplain } will format it as regular text. Since the
>>> text of the link is "same file" then it should be formatted as regular
>>> text - not as code.
>>>
>>> The link on the next line should probably be {@linkplain } as well.
>>>
>>> Otherwise looks good to me (except for the declaration of
>>> int totalRead that should be long but Alan already mentioned it).
>>>
>>> best regards,
>>>
>>> -- daniel
>>>
>>>
>>> On 12/10/2018 20:16, Joe Wang wrote:
>>>> Here's an update based on all of the great reviews and comments
>>>> (thanks all!):
>>>>
>>>> JBS: https://bugs.openjdk.java.net/browse/JDK-8202285
>>>> CSR: https://bugs.openjdk.java.net/browse/JDK-8202302
>>>>
>>>> Current version:
>>>> specdiff:
>>>> http://cr.openjdk.java.net/~joehw/jdk12/8202285/specdiff_02/java/nio/file/Files.html
>>>>
>>>> webrevs: http://cr.openjdk.java.net/~joehw/jdk12/8202285/webrev_v02/
>>>>
>>>> Previous version:
>>>> specdiff:
>>>> http://cr.openjdk.java.net/~joehw/jdk12/8202285/specdiff_v01/java/nio/file/Files.html
>>>>
>>>> webrevs: http://cr.openjdk.java.net/~joehw/jdk12/8202285/webrev_v01/
>>>>
>>>> It's been a while, so here's a summary of what's changed:
>>>>
>>>> Spec: Alan's patch to fix inconsistencies in wording/terminology
>>>> Impl: s/mismatchByAttrs and etc/isSameFile;
>>>> Stick with the simple implementation (InputStream/Buffer)
>>>> for now. Further improvement may be done if there's a need;
>>>> The impl is smaller than the previous version, merged the
>>>> code into Files, removed FilesMismatch.java;
>>>>
>>>> Test: more readable variables instead of the array of test files
>>>> more comments on the testcases
>>>> improved the private methods used for generating the test
>>>> files
>>>>
>>>> Thanks,
>>>> Joe
>>>
>
More information about the core-libs-dev
mailing list