register

Registers a BasePermissionsBuilder for a a given type of Permission. Only one builder can be registered per type of Permission. Make sure to call unregister before calling this if a permission has been registered before. This method is thread-safe.

Return

the registered Builder

Parameters

builder

the Builder to register for the permission.

Type Parameters

P

the type of Permission for which to register the builder.

Builder

the type of BasePermissionsBuilder to register for this permission

Throws

if the permission was already registered.


Registers a BasePermissionsBuilder for a a given type of Permission. Only one builder can be registered per type of Permission. Make sure to call unregister before calling this if a permission has been registered before. This method is thread-safe.

Return

the registered Builder

Parameters

permission

the KClass of the P to register

builder

the Builder to register for the permission.

Type Parameters

P

the type of Permission for which to register the builder.

Builder

the type of BasePermissionsBuilder to register for this permission

Throws

if the permission was already registered.