aboutsummaryrefslogtreecommitdiffhomepage
path: root/patches/api/0008-Paper-Plugins.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patches/api/0008-Paper-Plugins.patch')
-rw-r--r--patches/api/0008-Paper-Plugins.patch28
1 files changed, 24 insertions, 4 deletions
diff --git a/patches/api/0008-Paper-Plugins.patch b/patches/api/0008-Paper-Plugins.patch
index c09fbcb044..42a3f68bc8 100644
--- a/patches/api/0008-Paper-Plugins.patch
+++ b/patches/api/0008-Paper-Plugins.patch
@@ -194,9 +194,29 @@ index 0000000000000000000000000000000000000000..cdbc93b317b3bab47bf6552c29cfbb2c
+ void clearPermissions();
+
+}
+diff --git a/src/main/java/io/papermc/paper/plugin/bootstrap/BootstrapContext.java b/src/main/java/io/papermc/paper/plugin/bootstrap/BootstrapContext.java
+new file mode 100644
+index 0000000000000000000000000000000000000000..08f2050356acaf74e3210416760e3873c2dafd2c
+--- /dev/null
++++ b/src/main/java/io/papermc/paper/plugin/bootstrap/BootstrapContext.java
+@@ -0,0 +1,14 @@
++package io.papermc.paper.plugin.bootstrap;
++
++import org.jetbrains.annotations.ApiStatus;
++
++/**
++ * Represents the context provided to a {@link PluginBootstrap} during both the bootstrapping and plugin
++ * instantiation logic.
++ * A boostrap context may be used to access data or logic usually provided to {@link org.bukkit.plugin.Plugin} instances
++ * like the plugin's configuration or logger during the plugins bootstrap.
++ */
++public interface BootstrapContext extends PluginProviderContext {
++}
diff --git a/src/main/java/io/papermc/paper/plugin/bootstrap/PluginBootstrap.java b/src/main/java/io/papermc/paper/plugin/bootstrap/PluginBootstrap.java
new file mode 100644
-index 0000000000000000000000000000000000000000..ea84b11e8682e73fcd563fec65e76b707546a99e
+index 0000000000000000000000000000000000000000..288c078da3d3ca78d02caa4e3565ac7cf89f9f9f
--- /dev/null
+++ b/src/main/java/io/papermc/paper/plugin/bootstrap/PluginBootstrap.java
@@ -0,0 +1,41 @@
@@ -226,7 +246,7 @@ index 0000000000000000000000000000000000000000..ea84b11e8682e73fcd563fec65e76b70
+ *
+ * @param context the server provided context
+ */
-+ void bootstrap(@NotNull PluginProviderContext context);
++ void bootstrap(@NotNull BootstrapContext context);
+
+ /**
+ * Called by the server to instantiate your main class.
@@ -243,7 +263,7 @@ index 0000000000000000000000000000000000000000..ea84b11e8682e73fcd563fec65e76b70
+}
diff --git a/src/main/java/io/papermc/paper/plugin/bootstrap/PluginProviderContext.java b/src/main/java/io/papermc/paper/plugin/bootstrap/PluginProviderContext.java
new file mode 100644
-index 0000000000000000000000000000000000000000..a9208254142d270da7bd4815a01b9627c7918c11
+index 0000000000000000000000000000000000000000..2c14693155de3654d5ca011c63e13e4a1abf2080
--- /dev/null
+++ b/src/main/java/io/papermc/paper/plugin/bootstrap/PluginProviderContext.java
@@ -0,0 +1,52 @@
@@ -258,7 +278,7 @@ index 0000000000000000000000000000000000000000..a9208254142d270da7bd4815a01b9627
+
+/**
+ * Represents the context provided to a {@link PluginBootstrap} during both the bootstrapping and plugin
-+ * instanciation logic.
++ * instantiation logic.
+ * A boostrap context may be used to access data or logic usually provided to {@link org.bukkit.plugin.Plugin} instances
+ * like the plugin's configuration or logger during the plugins bootstrap.
+ */