From fc5d43e14b6497dc1bc1e13af8f96a402a70d92c Mon Sep 17 00:00:00 2001 From: Speiger Date: Thu, 14 Apr 2022 06:06:35 +0200 Subject: [PATCH] Updated Changelog. --- Changelog.md | 7 ++++++- .../collections/templates/utils/AsyncBuilder.template | 10 ++++++++++ 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/Changelog.md b/Changelog.md index 8092eeb..c2e2d92 100644 --- a/Changelog.md +++ b/Changelog.md @@ -3,7 +3,12 @@ ### Version 0.6.0 - Added: addOrGet for sets. - Added: Async API which allows to easily execute Iterables/Collections offthread without the complexity. -- Added: ConcurrentArrayLists and tests for it +- Added: CopyOnWriteArrayList and tests for it +- Added: Support up to Java17. +- Added: Build System now adds module-info if the Running JVM is 9 or higher +- Added: ArrayList.of(Class, size) that allows you to allocate a size right at the creation of the List without having to create a wrapper array. +- Added: A ConcurrentHashMap implementation. +- Fixed: containsValue in the HashMap wouldn't check the nullKey ### Version 0.5.3 - Added: OrderedMap/Set diff --git a/src/builder/resources/speiger/assets/collections/templates/utils/AsyncBuilder.template b/src/builder/resources/speiger/assets/collections/templates/utils/AsyncBuilder.template index e74a60e..2614807 100644 --- a/src/builder/resources/speiger/assets/collections/templates/utils/AsyncBuilder.template +++ b/src/builder/resources/speiger/assets/collections/templates/utils/AsyncBuilder.template @@ -102,6 +102,16 @@ public class ASYNC_BUILDER KEY_GENERIC_TYPE this.task = task; } + /** + * Helper function that automatically wraps a Iterable into a AsyncBuilder since it forces this collections Iterable. + * @param iterable that should be wrapped + * @Type(T) + * @return a AsyncBuilder with the iterable wrapped + */ + public static GENERIC_KEY_BRACES ASYNC_BUILDER KEY_GENERIC_TYPE of(Iterable iterable) { + return new ASYNC_BUILDERBRACES(ITERABLES.wrap(iterable)); + } + /** * Maps the elements to something else * @param mapper the mapping function