Package com.griefdefender.api.data
Interface ClaimData
- All Superinterfaces:
ClaimDataGetter
- All Known Subinterfaces:
TownData
Represents the persisted data of a claim.
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic ClaimData.Builderbuilder()Gets a new claim data builder instance forClaimData.Builder.voidsave()Saves all changes to storage.voidsetAccessorGroups(Set<String> accessorGroups) Sets the trusted accessor group set ofUUID's.voidsetAccessors(Set<UUID> accessors) Sets the trusted accessor set ofUUID's.voidsetAllowExpiration(boolean allowExpire) Toggles whether this claim can expire due to no player activity.voidsetAttributes(Set<ClaimAttribute> attributes) Sets theClaimAttribute's.voidsetBuilderGroups(Set<String> builderGroups) Sets the trusted builder group set ofUUID's.voidsetBuilders(Set<UUID> builders) Sets the trusted builder set ofUUID's.booleansetClaimGroupUniqueId(UUID uuid) Sets the claim group uuid this claim should be part of.voidsetClanData(ClanData clanData) Sets theClanData.voidsetContainerGroups(Set<String> containerGroups) Sets the trusted container group set ofUUID's.voidsetContainers(Set<UUID> containers) Sets the trusted container set ofUUID's.voidsetCuboid(boolean cuboid) Toggles whether this claim is a cuboid.voidsetDateLastActive(Instant date) Sets last active date of claim.voidsetDenyMessages(boolean allowDenyMessages) Toggles whether this claim allows deny messages to be sent to players.voidsetDisplayName(net.kyori.adventure.text.Component name) Sets the display name of claim.voidsetEconomyData(EconomyData economyData) Sets the @{link EconomyData}.voidsetEnterActionBar(net.kyori.adventure.text.Component message) Sets the action bar when player enters the claim.voidsetEnterTitle(net.kyori.adventure.title.Title title) Sets theTitlewhen a player enters the claim.voidsetExitActionBar(net.kyori.adventure.text.Component message) Sets the action bar when player exits the claim.voidsetExitTitle(net.kyori.adventure.title.Title title) Sets theTitlewhen a player exits the claim.voidsetExpired(boolean expired) Toggles whether this claim is expired.voidsetFarewell(net.kyori.adventure.text.Component farewell) Sets the farewell message when a player exits the claim.voidsetGreaterBoundaryCorner(int x, int y, int z) Sets the greater boundary corner position.voidsetGreaterBoundaryCorner(com.flowpowered.math.vector.Vector3i pos) Sets the greater boundary corner position.voidsetGreeting(net.kyori.adventure.text.Component greeting) Sets the greeting message when a player enters the claim.voidsetInheritParent(boolean inherit) Toggles whether this claim is inheriting from parent claim.voidsetLesserBoundaryCorner(int x, int y, int z) Sets the lesser boundary corner position.voidsetLesserBoundaryCorner(com.flowpowered.math.vector.Vector3i pos) Sets the lesser boundary corner position.voidsetManagerGroups(Set<String> managerGroups) Sets the trusted manager group set ofUUID's.voidsetManagers(Set<UUID> managers) Sets the trusted manager set ofUUID's.voidsetOwnerUniqueId(UUID ownerUniqueId) Sets the ownerUUIDof claim.voidsetParentUniqueId(UUID uniqueId) Sets the parentUUID.voidsetRequiresClaimBlocks(boolean requiresClaimBlocks) Sets if this claim requires claim blocks from players.voidsetResidentGroups(Set<String> residentGroups) Sets the trusted resident group set ofUUID's.voidsetResidents(Set<UUID> residents) Sets the trusted resident set ofUUID's.voidsetResizable(boolean allowResize) Toggles whether this claim is resizable.voidsetSizeRestrictions(boolean sizeRestrictions) Sets if this claim checks for min/max size restrictions.voidsetSpawnPos(int x, int y, int z) Sets the spawn position of claim.voidsetSpawnPos(@Nullable com.flowpowered.math.vector.Vector3i pos) Sets the spawn position of claim.voidSets theClaimType.voidsetWorldUniqueId(UUID worldUniqueId) Sets the worldUUIDof claim.Methods inherited from interface com.griefdefender.api.data.ClaimDataGetter
allowDenyMessages, allowExpiration, doesInheritParent, getAccessorGroups, getAccessors, getAttributes, getBuilderGroups, getBuilders, getClaimGroupUniqueId, getClanData, getContainerGroups, getContainers, getDateCreated, getDateLastActive, getDisplayName, getDisplayNameComponent, getEconomyData, getEnterActionBar, getEnterTitle, getExitActionBar, getExitTitle, getFarewell, getGreaterBoundaryCorner, getGreeting, getLesserBoundaryCorner, getManagerGroups, getManagers, getOwnerUniqueId, getParentUniqueId, getResidentGroups, getResidents, getSpawnPos, getType, getWorldUniqueId, hasSizeRestrictions, isCuboid, isExpired, isResizable, requiresClaimBlocks
-
Method Details
-
setClaimGroupUniqueId
Sets the claim group uuid this claim should be part of.
Note: If joined to a group, all permissions and options will be taken from group instead of claim.- Parameters:
uuid- The claim group uuid- Returns:
- true if the group was set, false if the group does not exist
-
setLesserBoundaryCorner
void setLesserBoundaryCorner(com.flowpowered.math.vector.Vector3i pos) Sets the lesser boundary corner position.- Parameters:
pos- The lesser boundary
-
setLesserBoundaryCorner
void setLesserBoundaryCorner(int x, int y, int z) Sets the lesser boundary corner position.- Parameters:
x- X coordinatey- Y coordinatez- Z coordinate
-
setGreaterBoundaryCorner
void setGreaterBoundaryCorner(com.flowpowered.math.vector.Vector3i pos) Sets the greater boundary corner position.- Parameters:
pos- The greater boundary
-
setGreaterBoundaryCorner
void setGreaterBoundaryCorner(int x, int y, int z) Sets the greater boundary corner position.- Parameters:
x- X coordinatey- Y coordinatez- Z coordinate
-
setSpawnPos
void setSpawnPos(@Nullable com.flowpowered.math.vector.Vector3i pos) Sets the spawn position of claim.- Parameters:
pos- The new spawn position
-
setSpawnPos
void setSpawnPos(int x, int y, int z) Sets the spawn position of claim.- Parameters:
x- X coordinatey- Y coordinatez- Z coordinate
-
setWorldUniqueId
Sets the worldUUIDof claim.- Parameters:
worldUniqueId- The world uuid
-
setDisplayName
void setDisplayName(net.kyori.adventure.text.Component name) Sets the display name of claim.- Parameters:
name- The claim display name
-
setOwnerUniqueId
Sets the ownerUUIDof claim.- Parameters:
ownerUniqueId- The owner uuid
-
setType
Sets theClaimType.- Parameters:
type- The claim type
-
setAttributes
Sets theClaimAttribute's.- Parameters:
attributes- The set of claim attributes
-
setFarewell
void setFarewell(net.kyori.adventure.text.Component farewell) Sets the farewell message when a player exits the claim.- Parameters:
farewell- The farewell message
-
setGreeting
void setGreeting(net.kyori.adventure.text.Component greeting) Sets the greeting message when a player enters the claim.- Parameters:
greeting- The greeting message
-
setEnterActionBar
void setEnterActionBar(net.kyori.adventure.text.Component message) Sets the action bar when player enters the claim.- Parameters:
message- The enter action bar message
-
setExitActionBar
void setExitActionBar(net.kyori.adventure.text.Component message) Sets the action bar when player exits the claim.- Parameters:
message- The exit action bar message
-
setEnterTitle
void setEnterTitle(net.kyori.adventure.title.Title title) Sets theTitlewhen a player enters the claim.- Parameters:
title- The enter title
-
setExitTitle
void setExitTitle(net.kyori.adventure.title.Title title) Sets theTitlewhen a player exits the claim.- Parameters:
title- The exit title
-
setExpired
void setExpired(boolean expired) Toggles whether this claim is expired.- Parameters:
expired- true if expired, false if not
-
setDateLastActive
Sets last active date of claim. Note: The date is used to determine whether the claim expires based on expiration settings.- Parameters:
date- The last active date
-
setInheritParent
void setInheritParent(boolean inherit) Toggles whether this claim is inheriting from parent claim.- Parameters:
inherit- Whether claim inherits from parent
-
setResizable
void setResizable(boolean allowResize) Toggles whether this claim is resizable.- Parameters:
allowResize- Whether claim can be resized.
-
setCuboid
void setCuboid(boolean cuboid) Toggles whether this claim is a cuboid.- Parameters:
cuboid- Whether claim is a cuboid
-
setDenyMessages
void setDenyMessages(boolean allowDenyMessages) Toggles whether this claim allows deny messages to be sent to players. If false, no deny messages will be sent.- Parameters:
allowDenyMessages- Whether to allow sending deny messages to players
-
setAllowExpiration
void setAllowExpiration(boolean allowExpire) Toggles whether this claim can expire due to no player activity.- Parameters:
allowExpire- Whether this claim allows expirations
-
setParentUniqueId
Sets the parentUUID.- Parameters:
uniqueId- The parent uuid
-
setRequiresClaimBlocks
void setRequiresClaimBlocks(boolean requiresClaimBlocks) Sets if this claim requires claim blocks from players. Note: This is true by default.- Parameters:
requiresClaimBlocks- Whether this claim requires claim blocks
-
setSizeRestrictions
void setSizeRestrictions(boolean sizeRestrictions) Sets if this claim checks for min/max size restrictions. Note:andinvalid reference
ClaimType#ADMINcan not have restrictions.invalid reference
ClaimType#WILDERNESS- Parameters:
sizeRestrictions- Whether this claim checks size restrictions.
-
setAccessors
Sets the trusted accessor set ofUUID's.- Parameters:
The- set of accessor uuid's
-
setBuilders
Sets the trusted builder set ofUUID's.- Parameters:
The- set of builder uuid's
-
setContainers
Sets the trusted container set ofUUID's.- Parameters:
The- set of container uuid's
-
setManagers
Sets the trusted manager set ofUUID's.- Parameters:
The- set of manager uuid's
-
setResidents
Sets the trusted resident set ofUUID's.- Parameters:
The- set of resident uuid's
-
setAccessorGroups
Sets the trusted accessor group set ofUUID's.- Parameters:
The- set of accessor group uuid's
-
setBuilderGroups
Sets the trusted builder group set ofUUID's.- Parameters:
The- set of builder group uuid's
-
setContainerGroups
Sets the trusted container group set ofUUID's.- Parameters:
The- set of container group uuid's
-
setManagerGroups
Sets the trusted manager group set ofUUID's.- Parameters:
The- set of manager group uuid's
-
setResidentGroups
Sets the trusted resident group set ofUUID's.- Parameters:
The- set of resident group uuid's
-
setClanData
Sets theClanData.- Parameters:
clanData- The clan data
-
setEconomyData
Sets the @{link EconomyData}.- Parameters:
economyData- The economy data
-
save
void save()Saves all changes to storage. -
builder
Gets a new claim data builder instance forClaimData.Builder.- Returns:
- A new claim data builder instance
-