Package de.Keyle.MyPet.api.plugin
Interface MyPetPlugin
- All Superinterfaces:
CommandExecutor,LifecycleEventOwner,Namespaced,Plugin,TabCompleter,TabExecutor
API-facing contract for the MyPet plugin instance. Provides access to
all top-level managers and services without depending on the concrete
plugin-module class. Obtained globally via
MyPetApi.getPlugin().
Extends Bukkit Plugin so callers can register listeners, schedule
tasks, and access the data folder without a separate plugin reference.
-
Method Summary
Modifier and TypeMethodDescriptionReturns the error reporter (Sentry in non-release builds, no-op otherwise).getFile()Returns the plugin JAR file on disk.Returns the utility for querying third-party hook state.Returns the shared MiniMessage instance used for all text serialization.Returns the per-type metadata registry (HP, speed, food, leash flags).Returns the manager for active and inactive pet instances.Returns the manager forMyPetPlayerinstances.Returns the central service registry for lifecycle-managed services.booleanReturnstrueduringonDisable()execution.Methods inherited from interface org.bukkit.command.CommandExecutor
onCommandMethods inherited from interface net.kyori.adventure.key.Namespaced
namespaceMethods inherited from interface org.bukkit.plugin.Plugin
getComponentLogger, getConfig, getDataFolder, getDataPath, getDefaultBiomeProvider, getDefaultWorldGenerator, getDescription, getLifecycleManager, getLog4JLogger, getLogger, getName, getPluginLoader, getPluginMeta, getResource, getServer, getSLF4JLogger, isEnabled, isNaggable, onDisable, onEnable, onLoad, reloadConfig, saveConfig, saveDefaultConfig, saveResource, setNaggableMethods inherited from interface org.bukkit.command.TabCompleter
onTabComplete
-
Method Details
-
getFile
File getFile()Returns the plugin JAR file on disk.- Returns:
- the plugin's own jar on disk
-
getPetInfo
PetInfo getPetInfo()Returns the per-type metadata registry (HP, speed, food, leash flags).- Returns:
- the per-type metadata registry
-
getPlayerManager
PlayerManager getPlayerManager()Returns the manager forMyPetPlayerinstances.- Returns:
- the player manager
-
getPetManager
PetManager getPetManager()Returns the manager for active and inactive pet instances.- Returns:
- the pet manager
-
getHookHelper
HookHelper getHookHelper()Returns the utility for querying third-party hook state.- Returns:
- the hook helper
-
getServiceManager
ServiceManager getServiceManager()Returns the central service registry for lifecycle-managed services.- Returns:
- the service manager
-
getErrorReporter
ErrorReporter getErrorReporter()Returns the error reporter (Sentry in non-release builds, no-op otherwise).- Returns:
- the error reporter
-
isDisabling
boolean isDisabling()ReturnstrueduringonDisable()execution. Used to suppress async operations that would race against shutdown.- Returns:
truewhile the plugin is shutting down
-
getMiniMessage
MiniMessage getMiniMessage()Returns the shared MiniMessage instance used for all text serialization.- Returns:
- the shared MiniMessage instance
-