Class DiscoveredExtension

java.lang.Object
net.minestom.server.extensions.DiscoveredExtension

public final class DiscoveredExtension extends Object
Represents an extension from an `extension.json` that is capable of powering an Extension object. This has no constructor as its properties are set via GSON.
  • Field Details

    • LOGGER

      public static final org.slf4j.Logger LOGGER
      Static logger for this class.
    • NAME_REGEX

      public static final String NAME_REGEX
      The regex that this name must pass. If it doesn't, it will not be accepted.
      See Also:
  • Constructor Details

    • DiscoveredExtension

      public DiscoveredExtension()
  • Method Details

    • getName

      @NotNull public @NotNull String getName()
    • getEntrypoint

      @NotNull public @NotNull String getEntrypoint()
    • getVersion

      @NotNull public @NotNull String getVersion()
    • getAuthors

      @NotNull public @NotNull String[] getAuthors()
    • getDependencies

      @NotNull public @NotNull String[] getDependencies()
    • getExternalDependencies

      @NotNull public @NotNull DiscoveredExtension.ExternalDependencies getExternalDependencies()
    • setOriginalJar

      public void setOriginalJar(@Nullable @Nullable File file)
    • getOriginalJar

      @Nullable public @Nullable File getOriginalJar()
    • getDataDirectory

      @NotNull public @NotNull Path getDataDirectory()
    • setDataDirectory

      public void setDataDirectory(@NotNull @NotNull Path dataDirectory)
    • getClassLoader

      @NotNull public @NotNull ExtensionClassLoader getClassLoader()
    • verifyIntegrity

      public static void verifyIntegrity(@NotNull @NotNull DiscoveredExtension extension)
      Ensures that all properties of this extension are properly set if they aren't
      Parameters:
      extension - The extension to verify
    • getMeta

      @NotNull public @NotNull com.google.gson.JsonObject getMeta()