[lworld] RFR: 8372038: [lworld] Update ExplodedImage to use preview mode correctly [v2]

Roger Riggs rriggs at openjdk.org
Wed Nov 26 15:39:27 UTC 2025


On Wed, 26 Nov 2025 13:10:18 GMT, David Beaumont <duke at openjdk.org> wrote:

>> Adds preview mode support for ExplodedImage.
>> 
>> Adds tests so both ExplodedImage and ImageReader implementations of SystemImage are tested with exactly the same test data and assertions.
>
> David Beaumont has updated the pull request incrementally with one additional commit since the last revision:
> 
>   fixing duplicate elements

src/java.base/share/classes/jdk/internal/jrtfs/ExplodedImage.java line 112:

> 110:         private PathNode(String name, List<PathNode> children) {    // dir
> 111:             super(name, modulesDirAttrs);
> 112:             this.childNames = children.stream().map(Node::getName).collect(toList());

How is this different than using `Stream.toList()`?  
It makes the static import of `toList` unnecessary; (Static imports are hard to follow/read if not using an IDE).

-------------

PR Review Comment: https://git.openjdk.org/valhalla/pull/1743#discussion_r2565430616


More information about the valhalla-dev mailing list