This commit adds a `PriorityQueue` constructor that takes both a custom comparator and an existing collection.
See previous discussion in https://github.com/openjdk/jdk/pull/17045. --------- - [x] I confirm that I make this contribution in accordance with the [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai). ------------- Commit messages: - since 23 -> 28 - fix style - updated javadoc, added tests - updated the javadoc - add since tag - updated the javadoc - fix styling - Introduce constructor for PriorityQueue with existing collection and custom comparator Changes: https://git.openjdk.org/jdk/pull/31452/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=31452&range=00 Issue: https://bugs.openjdk.org/browse/JDK-6356745 Stats: 52 lines in 2 files changed: 51 ins; 0 del; 1 mod Patch: https://git.openjdk.org/jdk/pull/31452.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/31452/head:pull/31452 PR: https://git.openjdk.org/jdk/pull/31452
