Package org.geysermc.mcprotocollib.auth
Class GameProfile.Property
java.lang.Object
org.geysermc.mcprotocollib.auth.GameProfile.Property
- Enclosing class:
- GameProfile
A property belonging to a profile.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetName()Gets the name of the property.Gets the signature used to verify the property.getValue()Gets the value of the property.booleanGets whether this property has a signature to verify it.booleanGets whether this property's signature is valid.toString()
-
Constructor Details
-
Property
Creates a new Property instance.- Parameters:
name- Name of the property.value- Value of the property.
-
Property
Creates a new Property instance.- Parameters:
name- Name of the property.value- Value of the property.signature- Signature used to verify the property.
-
-
Method Details
-
getName
Gets the name of the property.- Returns:
- The property's name.
-
getValue
Gets the value of the property.- Returns:
- The property's value.
-
hasSignature
public boolean hasSignature()Gets whether this property has a signature to verify it.- Returns:
- Whether this property is signed.
-
getSignature
Gets the signature used to verify the property.- Returns:
- The property's signature.
-
isSignatureValid
Gets whether this property's signature is valid.- Parameters:
key- Public key to validate the signature against.- Returns:
- Whether the signature is valid.
- Throws:
IllegalStateException- If the signature could not be validated.
-
toString
-