Class GPClaim
java.lang.Object
me.EtienneDx.RealEstate.ClaimAPI.GriefPrevention.GPClaim
-
Constructor Summary
ConstructorsConstructorDescriptionGPClaim(me.ryanhamshire.GriefPrevention.Claim claim) Constructs a new GPClaim that wraps the given GriefPrevention claim. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddManager(UUID player) Adds the specified player as a manager for this claim.voidaddPlayerPermissions(UUID player, ClaimPermission permission) Adds player permissions to this claim based on the specifiedClaimPermission.voidClears all managers from this claim.voidClears all player permissions for this claim.voiddropPlayerPermissions(UUID player) Removes all player permissions for the specified player from this claim.intgetArea()Returns the area of this claim.Returns anIterableover the child claims of this claim.me.ryanhamshire.GriefPrevention.ClaimgetClaim()Returns the underlying GriefPrevention claim.getId()Returns the unique identifier of this claim.getOwner()Returns the UUID of the owner of this claim.Returns the name of the owner of this claim.Returns the parent claim of this claim.org.bukkit.WorldgetWorld()Returns the world in which this claim is located.intgetX()Returns the X-coordinate of the claim's lesser boundary corner.intgetY()Returns the Y-coordinate of the claim's lesser boundary corner.intgetZ()Returns the Z-coordinate of the claim's lesser boundary corner.booleanDetermines if this claim is an admin claim.booleanDetermines if this claim is a parent claim.booleanDetermines if this claim is a subclaim.booleanIndicates whether this claim represents wilderness.voidremoveManager(UUID player) Removes the specified player from the list of managers for this claim.voidsetInheritPermissions(boolean inherit) Sets whether this claim should inherit permissions from its parent.
-
Constructor Details
-
GPClaim
public GPClaim(me.ryanhamshire.GriefPrevention.Claim claim) Constructs a new GPClaim that wraps the given GriefPrevention claim.- Parameters:
claim- the GriefPrevention claim to wrap
-
-
Method Details
-
getClaim
public me.ryanhamshire.GriefPrevention.Claim getClaim()Returns the underlying GriefPrevention claim.- Returns:
- the GriefPrevention
Claimobject
-
getId
-
getArea
-
getWorld
-
getX
-
getY
-
getZ
-
isAdminClaim
public boolean isAdminClaim()Determines if this claim is an admin claim.- Specified by:
isAdminClaimin interfaceIClaim- Returns:
- true if the claim is an admin claim, false otherwise
-
getChildren
-
isWilderness
public boolean isWilderness()Indicates whether this claim represents wilderness. For GriefPrevention claims, this always returns false.- Specified by:
isWildernessin interfaceIClaim- Returns:
- false
-
isSubClaim
public boolean isSubClaim()Determines if this claim is a subclaim.- Specified by:
isSubClaimin interfaceIClaim- Returns:
- true if the claim has a parent claim, false otherwise
-
isParentClaim
public boolean isParentClaim()Determines if this claim is a parent claim.- Specified by:
isParentClaimin interfaceIClaim- Returns:
- true if the claim does not have a parent, false otherwise
-
getParent
-
dropPlayerPermissions
Removes all player permissions for the specified player from this claim.- Specified by:
dropPlayerPermissionsin interfaceIClaim- Parameters:
player- the UUID of the player whose permissions will be removed
-
addPlayerPermissions
Adds player permissions to this claim based on the specifiedClaimPermission.- Specified by:
addPlayerPermissionsin interfaceIClaim- Parameters:
player- the UUID of the player to add permissions forpermission- theClaimPermissionto add
-
removeManager
Removes the specified player from the list of managers for this claim.- Specified by:
removeManagerin interfaceIClaim- Parameters:
player- the UUID of the player to remove as a manager
-
getOwner
-
getOwnerName
Returns the name of the owner of this claim. If the owner is not available, a default server keyword is returned.- Specified by:
getOwnerNamein interfaceIClaim- Returns:
- the owner's name, or a default value if not available
-
setInheritPermissions
public void setInheritPermissions(boolean inherit) Sets whether this claim should inherit permissions from its parent.- Specified by:
setInheritPermissionsin interfaceIClaim- Parameters:
inherit- true if the claim should inherit permissions, false otherwise
-
clearPlayerPermissions
public void clearPlayerPermissions()Clears all player permissions for this claim.- Specified by:
clearPlayerPermissionsin interfaceIClaim
-
addManager
Adds the specified player as a manager for this claim.- Specified by:
addManagerin interfaceIClaim- Parameters:
player- the UUID of the player to add as a manager
-
clearManagers
public void clearManagers()Clears all managers from this claim.- Specified by:
clearManagersin interfaceIClaim
-