Package xyz.xenondevs.invui.item.builder
Class PotionBuilder
java.lang.Object
xyz.xenondevs.invui.item.builder.AbstractItemBuilder<PotionBuilder>
xyz.xenondevs.invui.item.builder.PotionBuilder
- All Implemented Interfaces:
Cloneable
,Supplier<@NotNull org.bukkit.inventory.ItemStack>
,ItemProvider
-
Nested Class Summary
-
Field Summary
Fields inherited from class xyz.xenondevs.invui.item.builder.AbstractItemBuilder
amount, base, customModelData, damage, displayName, enchantments, itemFlags, lore, material, modifiers, unbreakable
Fields inherited from interface xyz.xenondevs.invui.item.ItemProvider
EMPTY
-
Constructor Summary
ConstructorDescriptionPotionBuilder
(@NotNull org.bukkit.inventory.ItemStack base) PotionBuilder
(@NotNull PotionBuilder.PotionType type) -
Method Summary
Modifier and TypeMethodDescription@NotNull PotionBuilder
addEffect
(@NotNull org.bukkit.potion.PotionEffect effect) @NotNull PotionBuilder
clone()
Clones this builder.@NotNull org.bukkit.inventory.ItemStack
Builds theItemStack
@NotNull PotionBuilder
setBasePotionData
(@NotNull org.bukkit.potion.PotionData basePotionData) @NotNull PotionBuilder
@NotNull PotionBuilder
setColor
(@NotNull org.bukkit.Color color) Methods inherited from class xyz.xenondevs.invui.item.builder.AbstractItemBuilder
addAllItemFlags, addEnchantment, addItemFlags, addLegacyLoreLines, addLoreLines, addLoreLines, addLoreLines, addLoreLines, addModifier, clearEnchantments, clearItemFlags, clearLore, clearModifiers, getAmount, getBase, getCustomModelData, getDamage, getDisplayName, getEnchantments, getItemFlags, getLore, getMaterial, getModifiers, isUnbreakable, removeEnchantment, removeItemFlags, removeLoreLine, setAmount, setCustomModelData, setDamage, setDisplayName, setDisplayName, setDisplayName, setEnchantments, setItemFlags, setLegacyLore, setLore, setMaterial, setUnbreakable
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface xyz.xenondevs.invui.item.ItemProvider
get
-
Constructor Details
-
PotionBuilder
-
PotionBuilder
public PotionBuilder(@NotNull @NotNull org.bukkit.inventory.ItemStack base)
-
-
Method Details
-
setColor
@Contract("_ -> this") @NotNull public @NotNull PotionBuilder setColor(@NotNull @NotNull org.bukkit.Color color) -
setColor
-
setBasePotionData
@Contract("_ -> this") @NotNull public @NotNull PotionBuilder setBasePotionData(@NotNull @NotNull org.bukkit.potion.PotionData basePotionData) -
addEffect
@Contract("_ -> this") @NotNull public @NotNull PotionBuilder addEffect(@NotNull @NotNull org.bukkit.potion.PotionEffect effect) -
get
@Contract(value="_ -> new", pure=true) @NotNull public @NotNull org.bukkit.inventory.ItemStack get(@Nullable @Nullable String lang) Description copied from class:AbstractItemBuilder
Builds theItemStack
- Specified by:
get
in interfaceItemProvider
- Overrides:
get
in classAbstractItemBuilder<PotionBuilder>
- Parameters:
lang
- The language to translate the item in.- Returns:
- The
ItemStack
-
clone
Description copied from class:AbstractItemBuilder
Clones this builder.- Overrides:
clone
in classAbstractItemBuilder<PotionBuilder>
- Returns:
- The cloned builder
-