Class UUIDUtils

java.lang.Object
net.paulem.arcana.utils.UUIDUtils

public class UUIDUtils extends Object
Utility methods for comparing the unique identifiers of entities and UUIDs.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static boolean
    areEquals(@Nullable UUID uuid, @Nullable UUID uuid1)
    Checks whether two UUIDs are equal.
    static boolean
    areEquals(@Nullable UUID uuid, @Nullable org.bukkit.entity.Entity entity1)
    Checks whether a UUID matches an entity's unique identifier.
    static boolean
    areEquals(@Nullable org.bukkit.entity.Entity entity, @Nullable UUID uuid1)
    Checks whether an entity's unique identifier matches the given UUID.
    static boolean
    areEquals(@Nullable org.bukkit.entity.Entity entity, @Nullable org.bukkit.entity.Entity entity1)
    Checks whether two entities share the same unique identifier.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • UUIDUtils

      public UUIDUtils()
  • Method Details

    • areEquals

      public static boolean areEquals(@Nullable @Nullable org.bukkit.entity.Entity entity, @Nullable @Nullable org.bukkit.entity.Entity entity1)
      Checks whether two entities share the same unique identifier.
      Parameters:
      entity - the first entity, may be null
      entity1 - the second entity, may be null
      Returns:
      true if both entities are non-null and have the same UUID, false otherwise
    • areEquals

      public static boolean areEquals(@Nullable @Nullable org.bukkit.entity.Entity entity, @Nullable @Nullable UUID uuid1)
      Checks whether an entity's unique identifier matches the given UUID.
      Parameters:
      entity - the entity, may be null
      uuid1 - the UUID to compare against, may be null
      Returns:
      true if both are non-null and the entity's UUID equals uuid1, false otherwise
    • areEquals

      public static boolean areEquals(@Nullable @Nullable UUID uuid, @Nullable @Nullable org.bukkit.entity.Entity entity1)
      Checks whether a UUID matches an entity's unique identifier.
      Parameters:
      uuid - the UUID to compare against, may be null
      entity1 - the entity, may be null
      Returns:
      true if both are non-null and uuid equals the entity's UUID, false otherwise
    • areEquals

      public static boolean areEquals(@Nullable @Nullable UUID uuid, @Nullable @Nullable UUID uuid1)
      Checks whether two UUIDs are equal.
      Parameters:
      uuid - the first UUID, may be null
      uuid1 - the second UUID, may be null
      Returns:
      true if both UUIDs are non-null and equal, false otherwise