Interface LuckPermsPlugin
- All Known Implementing Classes:
AbstractLuckPermsPlugin
public interface LuckPermsPlugin
Main internal interface for LuckPerms plugins, providing the base for
abstraction throughout the project.
All plugin platforms implement this interface.
-
Method Summary
Modifier and TypeMethodDescriptionReturns the class implementing the LuckPermsAPI on this platform.Gets the bootstrap plugin instanceGets the bytebin instance in use by platform.Gets the bytesocks instance in use by platform.Gets the class responsible for constructing PermissionCalculators on this platform.Gets the command managerGets the plugin's configurationGets the connection listener.Gets the console.ContextManager<?, ?> Gets the context manager.Gets the dependency manager for the pluginGets the event dispatcherGets the extension manager.Gets the file watcher running on the platformGroupManager<? extends Group> Gets the group manager instance for the platformGets the inheritance handlerGets the log dispatcher running on the platformGets a wrapped logger instance for the platform.Gets the messaging service.Gets a list of online Senders on the platformGets the permission registry for the platform.Optional<net.luckperms.api.query.QueryOptions> getQueryOptionsForUser(User user) Gets a calculated context instance for the user using the rules of the platform.Gets the primary data storage instance.Gets the sync task buffer of the platform, used for scheduling and running sync tasks.TrackManager<? extends Track> Gets the track manager instance for the platformGets the instance providing locale translations for the pluginGets the translation repositoryUserManager<? extends User> Gets the user manager instance for the platformGets the verbose debug handler instance.Gets the web editor storelookupUniqueId(String username) Lookup a uuid from a username.lookupUsername(UUID uniqueId) Lookup a username from a uuid.default voidCalled at the end of the sync task.net.luckperms.api.platform.HealthRuns a health check for the plugin.voidSets the messaging service.booleantestUsernameValidity(String username) Tests whether the given username is valid.
-
Method Details
-
getBootstrap
-
getUserManager
UserManager<? extends User> getUserManager()Gets the user manager instance for the platform- Returns:
- the user manager
-
getGroupManager
GroupManager<? extends Group> getGroupManager()Gets the group manager instance for the platform- Returns:
- the group manager
-
getTrackManager
TrackManager<? extends Track> getTrackManager()Gets the track manager instance for the platform- Returns:
- the track manager
-
getConfiguration
LuckPermsConfiguration getConfiguration()Gets the plugin's configuration- Returns:
- the plugin config
-
getStorage
Storage getStorage()Gets the primary data storage instance. This is likely to be wrapped with extra layers for caching, etc.- Returns:
- the storage handler instance
-
getMessagingService
Optional<InternalMessagingService> getMessagingService()Gets the messaging service.- Returns:
- the messaging service
-
setMessagingService
Sets the messaging service.- Parameters:
service- the service
-
getLogger
PluginLogger getLogger()Gets a wrapped logger instance for the platform.- Returns:
- the plugin's logger
-
getEventDispatcher
-
getApiProvider
LuckPermsApiProvider getApiProvider()Returns the class implementing the LuckPermsAPI on this platform.- Returns:
- the api
-
getExtensionManager
SimpleExtensionManager getExtensionManager()Gets the extension manager.- Returns:
- the extension manager
-
getCommandManager
-
getConnectionListener
AbstractConnectionListener getConnectionListener()Gets the connection listener.- Returns:
- the connection listener
-
getTranslationManager
TranslationManager getTranslationManager()Gets the instance providing locale translations for the plugin- Returns:
- the translation manager
-
getTranslationRepository
TranslationRepository getTranslationRepository()Gets the translation repository- Returns:
- the translation repository
-
getDependencyManager
DependencyManager getDependencyManager()Gets the dependency manager for the plugin- Returns:
- the dependency manager
-
getContextManager
ContextManager<?,?> getContextManager()Gets the context manager. This object handles context accumulation for all players on the platform.- Returns:
- the context manager
-
getInheritanceGraphFactory
InheritanceGraphFactory getInheritanceGraphFactory()Gets the inheritance handler- Returns:
- the inheritance handler
-
getCalculatorFactory
CalculatorFactory getCalculatorFactory()Gets the class responsible for constructing PermissionCalculators on this platform.- Returns:
- the permission calculator factory
-
getVerboseHandler
VerboseHandler getVerboseHandler()Gets the verbose debug handler instance.- Returns:
- the debug handler instance
-
getPermissionRegistry
PermissionRegistry getPermissionRegistry()Gets the permission registry for the platform.- Returns:
- the permission registry
-
getLogDispatcher
LogDispatcher getLogDispatcher()Gets the log dispatcher running on the platform- Returns:
- the log dispatcher
-
getFileWatcher
Optional<FileWatcher> getFileWatcher()Gets the file watcher running on the platform- Returns:
- the file watcher
-
getBytebin
BytebinClient getBytebin()Gets the bytebin instance in use by platform.- Returns:
- the bytebin instance
-
getBytesocks
BytesocksClient getBytesocks()Gets the bytesocks instance in use by platform.- Returns:
- the bytesocks instance
-
getWebEditorStore
-
runHealthCheck
net.luckperms.api.platform.Health runHealthCheck()Runs a health check for the plugin.- Returns:
- the result of the healthcheck
-
getQueryOptionsForUser
-
lookupUniqueId
-
lookupUsername
-
testUsernameValidity
Tests whether the given username is valid.- Parameters:
username- the username- Returns:
- true if valid
-
getOnlineSenders
-
getConsoleSender
-
getExtraCommands
-
getSyncTaskBuffer
SyncTask.Buffer getSyncTaskBuffer()Gets the sync task buffer of the platform, used for scheduling and running sync tasks.- Returns:
- the sync task buffer instance
-
performPlatformDataSync
default void performPlatformDataSync()Called at the end of the sync task.
-