-
- All Implemented Interfaces:
public final class FlyLibBuilder<T extends Object>
A builder that creates Fly Lib.
-
-
Constructor Summary
Constructors Constructor Description FlyLibBuilder(JavaPlugin plugin)
-
Method Summary
Modifier and Type Method Description final FlyLibBuilder<T>
command(Command<T> command)
Add a command. final FlyLibBuilder<T>
defaultPermission(Permission permission)
Specifies the default permissions that will be assigned if the command permissions are not specified. final FlyLibBuilder<T>
config(String baseCommandName, T config)
final <E extends Event> FlyLibBuilder<T>
listen(Class<E> clazz, EventPriority priority, Boolean ignoreCancelled, ListenerAction<E> action)
Listens to the specified event with the specified priority. final <E extends Event> FlyLibBuilder<T>
listen(Class<E> clazz, EventPriority priority, ListenerAction<E> action)
Listens to the specified event with the specified priority. final <E extends Event> FlyLibBuilder<T>
listen(Class<E> clazz, ListenerAction<E> action)
Listens to the specified event with the specified priority. -
-
Method Detail
-
command
final FlyLibBuilder<T> command(Command<T> command)
Add a command.
-
defaultPermission
final FlyLibBuilder<T> defaultPermission(Permission permission)
Specifies the default permissions that will be assigned if the command permissions are not specified.
-
config
final FlyLibBuilder<T> config(String baseCommandName, T config)
-
listen
@JvmOverloads() final <E extends Event> FlyLibBuilder<T> listen(Class<E> clazz, EventPriority priority, Boolean ignoreCancelled, ListenerAction<E> action)
Listens to the specified event with the specified priority. The event Listen is registered when the calling plugin is enabled, not when this method is called, and is unregistered when the calling plugin is disabled.
-
listen
@JvmOverloads() final <E extends Event> FlyLibBuilder<T> listen(Class<E> clazz, EventPriority priority, ListenerAction<E> action)
Listens to the specified event with the specified priority. The event Listen is registered when the calling plugin is enabled, not when this method is called, and is unregistered when the calling plugin is disabled.
-
listen
@JvmOverloads() final <E extends Event> FlyLibBuilder<T> listen(Class<E> clazz, ListenerAction<E> action)
Listens to the specified event with the specified priority. The event Listen is registered when the calling plugin is enabled, not when this method is called, and is unregistered when the calling plugin is disabled.
-
-
-
-