Class NameKey
java.lang.Object
eu.endercentral.crazy_advancements.NameKey
Represents a Unique Name
- Author:
- Axel
-
Constructor Details
-
NameKey
Constructor for creating a NameKey- Parameters:
namespace
- The namespace, choose something representing your plugin/project/subprojectkey
- The Unique key inside your namespace
-
NameKey
Constructor for creating a NameKey- Parameters:
key
- The key inside the default namespace "minecraft" or a NameSpacedKey seperated by a colon
-
NameKey
public NameKey(net.minecraft.resources.MinecraftKey from) Generates aNameKey
- Parameters:
from
- The MinecraftKey to generate from
-
-
Method Details
-
getNamespace
Gets the namespace- Returns:
- The namespace
-
getKey
Gets the key- Returns:
- The key
-
isSimilar
Compares to another key- Parameters:
anotherNameKey
- NameKey to compare to- Returns:
- true if both NameKeys match each other
-
getMinecraftKey
public net.minecraft.resources.MinecraftKey getMinecraftKey()Gets the MinecraftKey equivalent of this NameKey- Returns:
- A
MinecraftKey
representation of this NameKey
-
equals
-
toString
-
hashCode
public int hashCode()
-