Interface Permission

All Known Implementing Classes:
PermissionProvider

public sealed interface Permission permits PermissionProvider
Permission interface to manage permissions.
  • Method Summary

    Modifier and Type
    Method
    Description
    getPermissions(int userId)
    Obtains the permissions of a user.
    boolean
    hasPermission(UUID uuid, String permission)
    Checks if a user has a permission.
  • Method Details

    • getPermissions

      List<String> getPermissions(int userId)
      Obtains the permissions of a user.
      Parameters:
      userId - The id of the user.
      Returns:
      The permissions of the user.
    • hasPermission

      boolean hasPermission(UUID uuid, String permission)
      Checks if a user has a permission.
      Parameters:
      uuid - The id of the player.
      permission - The permission.
      Returns:
      True if the user has the permission, otherwise false.