garydgregory commented on PR #378: URL: https://github.com/apache/commons-compress/pull/378#issuecomment-4951001929
> We already have a way to retrieve the first entry: `getEntry`. > > I don’t think `getEntries` would be particularly useful, because most code expects each name to map to a unique entry rather than being designed to handle entries with conflicting names. The main value of `getEntries` would probably be to detect duplicate entries and report an error. In my view, optimizing for that path would not justify sacrificing memory usage, the performance of other methods, or thread safety. > > By comparison, I think it would be more useful to introduce a new option for opening ZIP files. When this option is enabled, the operation would fail immediately if conflicting entries are detected. I like that idea 💡! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
