| Modifier and Type | Field and Description |
|---|---|
boolean |
enableAfterDownload
Whether to attempt to enable the dependency after it has been downloaded
|
@NotNull java.io.File |
file
The new file of the dependency (
name.jar) |
@NotNull java.lang.String |
name
The name of the dependency (from it's
plugin.yml) |
PluginPlatform.Multi |
platforms
The platforms the dependency can be downloaded from
|
boolean |
required
Whether the dependency is required to be installed.
|
| Constructor and Description |
|---|
AnnoyingDependency(@NotNull java.lang.String name,
PluginPlatform.Multi platforms,
boolean required,
boolean enableAfterDownload)
Creates a new dependency instance
|
| Modifier and Type | Method and Description |
|---|---|
@NotNull org.bukkit.configuration.ConfigurationSection |
dump(@NotNull org.bukkit.configuration.ConfigurationSection section)
Dumps the object to an object
|
boolean |
isNotInstalled()
This uses
Bukkit.getPluginManager() to check if the dependency isn't installed. |
static @NotNull AnnoyingDependency |
load(@NotNull org.bukkit.configuration.ConfigurationSection section)
Loads a dependency from a
ConfigurationSection |
@NotNull public final @NotNull java.lang.String name
plugin.yml)@NotNull public final PluginPlatform.Multi platforms
public final boolean required
This does NOT stop the dependency from being downloaded/installed
public final boolean enableAfterDownload
@NotNull public final @NotNull java.io.File file
name.jar)public AnnoyingDependency(@NotNull
@NotNull java.lang.String name,
@NotNull
PluginPlatform.Multi platforms,
boolean required,
boolean enableAfterDownload)
name - nameplatforms - platformsrequired - requiredenableAfterDownload - enableAfterDownload@NotNull public static @NotNull AnnoyingDependency load(@NotNull @NotNull org.bukkit.configuration.ConfigurationSection section)
ConfigurationSectionsection - the section to load from@NotNull
public @NotNull org.bukkit.configuration.ConfigurationSection dump(@NotNull
@NotNull org.bukkit.configuration.ConfigurationSection section)
Dumpablepublic boolean isNotInstalled()
Bukkit.getPluginManager() to check if the dependency isn't installed. So it's vital that name is from the plugin's plugin.yml