Package net.luckperms.api.model
Interface PlayerSaveResult
-
public interface PlayerSaveResultEncapsulates the result of an operation to save uuid data about a player.The corresponding method can be found at
UserManager.savePlayerData(UUID, String).
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classPlayerSaveResult.OutcomeThe various states the result can take
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description @Nullable @Unmodifiable Set<UUID>getOtherUniqueIds()Gets the other uuids involved in the result.@NonNull @Unmodifiable Set<PlayerSaveResult.Outcome>getOutcomes()Gets the status returned by the operation@Nullable StringgetPreviousUsername()Gets the previous username involved in the result.default booleanincludes(@NonNull PlayerSaveResult.Outcome outcome)Gets if the result includes a certain outcome.
-
-
-
Method Detail
-
getOutcomes
@NonNull @Unmodifiable Set<PlayerSaveResult.Outcome> getOutcomes()
Gets the status returned by the operation- Returns:
- the status
-
includes
default boolean includes(@NonNull PlayerSaveResult.Outcome outcome)
Gets if the result includes a certain outcome.- Parameters:
outcome- the outcome to check for- Returns:
- if the result includes the outcome
-
getPreviousUsername
@Nullable String getPreviousUsername()
Gets the previous username involved in the result.Returns null when the result doesn't
includethePlayerSaveResult.Outcome.USERNAME_UPDATEDstatus.- Returns:
- the previous username
- See Also:
PlayerSaveResult.Outcome.USERNAME_UPDATED
-
getOtherUniqueIds
@Nullable @Unmodifiable Set<UUID> getOtherUniqueIds()
Gets the other uuids involved in the result.Returns null when the result doesn't
includethePlayerSaveResult.Outcome.OTHER_UNIQUE_IDS_PRESENT_FOR_USERNAMEstatus.- Returns:
- the other uuids
- See Also:
PlayerSaveResult.Outcome.OTHER_UNIQUE_IDS_PRESENT_FOR_USERNAME
-
-