Class PermissionProvider

java.lang.Object
de.simonsator.partyandfriends.api.PermissionProvider
Direct Known Subclasses:
StandardPermissionProvider

public abstract class PermissionProvider extends Object
This class provides information about if a player has a permission or not. It is also thought to work as communication between the permission plugin and this plugin for more things then just the permissions. Like in a custom version for a special permission plugin as provider for the display name.
  • Constructor Details

    • PermissionProvider

      public PermissionProvider()
      Sets the new instance of this class to the instance which is returned if getInstance() is called.
  • Method Details

    • getInstance

      public static PermissionProvider getInstance()
      Returns:
      Returns the instance of the PermissionProvider. There can always only be one PermissionProvider
    • hasPermission

      public abstract boolean hasPermission(PAFPlayer pPlayer, String pPermission)
      Parameters:
      pPlayer - The player for whom the permission is asked
      pPermission - The permission which is asked for
      Returns:
      Returns true if the given player has the given permission and returns false if he has not.