diff options
Diffstat (limited to 'src/main/java/moe/nea/modernjava/launch/util/WellKnownBlackboard.java')
-rw-r--r-- | src/main/java/moe/nea/modernjava/launch/util/WellKnownBlackboard.java | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/src/main/java/moe/nea/modernjava/launch/util/WellKnownBlackboard.java b/src/main/java/moe/nea/modernjava/launch/util/WellKnownBlackboard.java new file mode 100644 index 0000000..967f531 --- /dev/null +++ b/src/main/java/moe/nea/modernjava/launch/util/WellKnownBlackboard.java @@ -0,0 +1,27 @@ +package moe.nea.modernjava.launch.util; + +import net.minecraft.launchwrapper.Launch; + +import java.util.List; +import java.util.Map; + +/** + * Contains references to the {@link Launch#blackboard black board} in one central spot to avoid misspelling. + */ +@SuppressWarnings("unchecked") +public class WellKnownBlackboard { + /** + * A list of tweaker class names yet to be executed. This does not include tweaker class names present in the current + * round of tweaking. + */ + public static List<String> tweakerNames() { + return (List<String>) Launch.blackboard.get("TweakClasses"); + } + + /** + * A map of arguments in the form of --prefixedKey to value. + */ + public static Map<String, String> launchArgs() { + return (Map<String, String>) Launch.blackboard.get("launchArgs"); + } +} |