Class Attribute
- java.lang.Object
-
- com.runemate.game.api.hybrid.entities.attributes.Attribute
-
public final class Attribute extends java.lang.Object
An attribute representing a characteristic.
-
-
Constructor Summary
Constructors Constructor Description Attribute(long id, java.lang.Object value)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Integer
getAsInteger()
Gets the value of this attribute and casts it to an Integer@NonNull java.lang.Object
getAsObject()
Gets the value of this characteristicjava.lang.String
getAsString()
AttributeDefinition
getDefinition()
long
getId()
Gets the identifier of the attributeboolean
isInteger()
Checks whether the attributes value is an Integerboolean
isString()
java.lang.String
toString()
-
-
-
Method Detail
-
getId
public long getId()
Gets the identifier of the attribute
-
getAsObject
@NonNull public @NonNull java.lang.Object getAsObject()
Gets the value of this characteristic
-
getAsInteger
@Nullable public java.lang.Integer getAsInteger()
Gets the value of this attribute and casts it to an Integer
-
isInteger
public boolean isInteger()
Checks whether the attributes value is an Integer
-
getAsString
@Nullable public java.lang.String getAsString()
-
isString
public boolean isString()
-
getDefinition
@Nullable public AttributeDefinition getDefinition()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-