Sorry to barge in, several things here:
I love the JDK. At the very least, you could say, that
'IllegalStateException' is the appropriate name in this case, as it
purveys the fact, that the results might fail to fulfill the contract.
UncheckedIoException doesn't do that. Pretty subtle! ;-) I
On Sat, Dec 2, 2023 at 12:01 AM Miguel Muñoz wrote:
>
> @Elliotte Rusty Harold,
> I'd like to make two unrelated points.
> 1. I wasn't suggesting the missingFilesFirst() or missingFilesLast() methods
> as a solution to the issues raised in IO-813 LastModifiedFileComparator
> should not throw exc
@Elliotte Rusty Harold,
I'd like to make two unrelated points.
1. I wasn't suggesting the missingFilesFirst() or missingFilesLast() methods
as a solution to the issues raised in IO-813 LastModifiedFileComparator
should not throw exceptions, period. I just thought these met
I'm not sure we need two methods here, or even one. We simply need to
detect a missing file and assign it a time like Integer.MIN_INT. Make
the behavior as reproducible as reasonable for the case where the file
doesn't exist and never existed.
For cases where the last modified time changes or a fi
Good question. Since the missingFilesFirst/Last() methods would most likely be
used for sorting, I'm going to assume your "ls -type" command sorts the
files at
some point. I'll assume it's by last-modified, to put more recent files first.
Without calling the missingFile
Hi Miguel,
I like the idea but I think we need a use case, even if it's one we can
only write about here, otherwise we are making everything more complicated.
For example, if implementing an "ls"-type, command, a UI, or an app
configuration, what would be best for a user?
Let's say some files di
In my comments about issue IO-813 LastModifiedFileComparator should not throw
exceptions, period, I made a suggestion that I thought I'd repeat here. I was
thinking of adding these two methods to AbstractFileComparator.
public static Comparator missingFilesFirst(Compa