public class Attributes
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
Attributes.Attribute |
static class |
Attributes.AttributeType |
static class |
Attributes.Operation |
Modifier and Type | Field and Description |
---|---|
org.bukkit.inventory.ItemStack |
stack |
Constructor and Description |
---|
Attributes(org.bukkit.inventory.ItemStack stack) |
Modifier and Type | Method and Description |
---|---|
Attributes |
add(Attributes.Attribute attribute)
Add a new attribute to the list.
|
Attributes |
clear()
Remove every attribute.
|
Attributes.Attribute |
get(int index)
Retrieve the attribute at a given index.
|
org.bukkit.inventory.ItemStack |
getStack()
Retrieve the modified item stack.
|
boolean |
remove(Attributes.Attribute attribute)
Remove the first instance of the given attribute.
|
int |
size()
Retrieve the number of attributes.
|
java.lang.Iterable<Attributes.Attribute> |
values() |
public org.bukkit.inventory.ItemStack getStack()
public int size()
public Attributes add(Attributes.Attribute attribute)
attribute
- - the new attribute.public boolean remove(Attributes.Attribute attribute)
The attribute will be removed using its UUID.
attribute
- - the attribute to remove.public Attributes clear()
public Attributes.Attribute get(int index)
index
- - the index to look up.public java.lang.Iterable<Attributes.Attribute> values()