diff --git a/base/src/main/java/de/staropensource/engine/base/utility/information/JvmInformation.java b/base/src/main/java/de/staropensource/engine/base/utility/information/JvmInformation.java index 9acdbc9..cda209b 100644 --- a/base/src/main/java/de/staropensource/engine/base/utility/information/JvmInformation.java +++ b/base/src/main/java/de/staropensource/engine/base/utility/information/JvmInformation.java @@ -20,6 +20,7 @@ package de.staropensource.engine.base.utility.information; import de.staropensource.engine.base.logging.Logger; +import de.staropensource.engine.base.type.immutable.ImmutableArrayList; import org.jetbrains.annotations.NotNull; import java.lang.management.ManagementFactory; @@ -109,11 +110,11 @@ public final class JvmInformation { * Returns all arguments passed to the JVM. * This excludes all arguments passed to the application. * - * @return JVM arguments + * @return immutable list with all JVM arguments * @since v1-alpha0 */ public static @NotNull List<@NotNull String> getArguments() { - return ManagementFactory.getRuntimeMXBean().getInputArguments(); + return new ImmutableArrayList<>(ManagementFactory.getRuntimeMXBean().getInputArguments()); } /**