Package io.github.apfelcreme.Pipes.Pipe
Class PipeOutput
java.lang.Object
io.github.apfelcreme.Pipes.Pipe.AbstractPipePart
io.github.apfelcreme.Pipes.Pipe.PipeOutput
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
static class
static enum
Nested classes/interfaces inherited from class io.github.apfelcreme.Pipes.Pipe.AbstractPipePart
AbstractPipePart.Option<T>, AbstractPipePart.OptionsList, AbstractPipePart.Value<T>
-
Field Summary
Fields inherited from class io.github.apfelcreme.Pipes.Pipe.AbstractPipePart
OPTIONS_KEY, STORED_TYPE_KEY, TYPE_KEY
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionCheck whether or not this output can accept that item stackboolean
protected AbstractPipePart.Option<?>
getAvailableOption
(String name) Returns the enum constant of this type with the specified name.org.bukkit.block.BlockFace
List<org.bukkit.inventory.ItemStack>
returns the list of items in the dropperString[]
Get the setup of the GUI with the character 'i' for the block's inventory, 's' and 'z' for settings, 'c' for the copy bookprotected AbstractPipePart.Option<?>[]
Get all possible optionsorg.bukkit.inventory.InventoryHolder
returns the InventoryHolderboolean
matchesFilter
(org.bukkit.inventory.ItemStack filter, org.bukkit.inventory.ItemStack item) Check whether or not an item stack matches the filter of this outputtoString()
Methods inherited from class io.github.apfelcreme.Pipes.Pipe.AbstractPipePart
applyBook, getHolder, getLocation, getOption, getOption, getOptionsString, getType, getValue, getValue, hashCode, setOption, setOption, showGui
-
Field Details
-
GUI_SETUP
-
-
Constructor Details
-
PipeOutput
public PipeOutput(org.bukkit.block.BlockState state)
-
-
Method Details
-
getTargetHolder
public org.bukkit.inventory.InventoryHolder getTargetHolder()returns the InventoryHolder- Returns:
- the InventoryHolder
-
getTargetLocation
-
getFacing
public org.bukkit.block.BlockFace getFacing() -
getFilterItems
returns the list of items in the dropper- Returns:
- the list of items in the dropper
-
accepts
Check whether or not this output can accept that item stack- Parameters:
input
- The input that tries to move the itemitemStack
- The item to check- Returns:
- A result that represents why or why not the item is accepted by this output
-
matchesFilter
public boolean matchesFilter(org.bukkit.inventory.ItemStack filter, org.bukkit.inventory.ItemStack item) Check whether or not an item stack matches the filter of this output- Parameters:
filter
- The filter item to match againstitem
- The item stack to check- Returns:
true
if the filter is similar;false
if not
-
getGuiSetup
Description copied from class:AbstractPipePart
Get the setup of the GUI with the character 'i' for the block's inventory, 's' and 'z' for settings, 'c' for the copy book- Specified by:
getGuiSetup
in classAbstractPipePart
- Returns:
- The setup for the GUI
-
getOptions
Description copied from class:AbstractPipePart
Get all possible options- Specified by:
getOptions
in classAbstractPipePart
- Returns:
- All possible options of this part
-
getAvailableOption
Description copied from class:AbstractPipePart
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Overrides:
getAvailableOption
in classAbstractPipePart
- Parameters:
name
- The name of the option to get- Returns:
- the enum constant with the specified name
-
equals
- Overrides:
equals
in classAbstractPipePart
-
toString
- Overrides:
toString
in classAbstractPipePart
-