mirror of
https://github.com/AtlasMediaGroup/Scissors-Website.git
synced 2024-09-19 13:48:16 +00:00
931 lines
87 KiB
HTML
931 lines
87 KiB
HTML
|
<!DOCTYPE HTML>
|
||
|
<html lang="en">
|
||
|
<head>
|
||
|
<!-- Generated by javadoc (17) -->
|
||
|
<title>Inventory (Scissors-API 1.18.2-R0.1-SNAPSHOT API)</title>
|
||
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||
|
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||
|
<meta name="description" content="declaration: package: org.bukkit.inventory, interface: Inventory">
|
||
|
<meta name="generator" content="javadoc/ClassWriterImpl">
|
||
|
<link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style">
|
||
|
<link rel="stylesheet" type="text/css" href="../../../script-dir/jquery-ui.min.css" title="Style">
|
||
|
<link rel="stylesheet" type="text/css" href="../../../jquery-ui.overrides.css" title="Style">
|
||
|
<script type="text/javascript" src="../../../script.js"></script>
|
||
|
<script type="text/javascript" src="../../../script-dir/jquery-3.5.1.min.js"></script>
|
||
|
<script type="text/javascript" src="../../../script-dir/jquery-ui.min.js"></script>
|
||
|
</head>
|
||
|
<body class="class-declaration-page">
|
||
|
<script type="text/javascript">var evenRowColor = "even-row-color";
|
||
|
var oddRowColor = "odd-row-color";
|
||
|
var tableTab = "table-tab";
|
||
|
var activeTableTab = "active-table-tab";
|
||
|
var pathtoroot = "../../../";
|
||
|
loadScripts(document, 'script');</script>
|
||
|
<noscript>
|
||
|
<div>JavaScript is disabled on your browser.</div>
|
||
|
</noscript>
|
||
|
<div class="flex-box">
|
||
|
<header role="banner" class="flex-header">
|
||
|
<nav role="navigation">
|
||
|
<!-- ========= START OF TOP NAVBAR ======= -->
|
||
|
<div class="top-nav" id="navbar-top">
|
||
|
<div class="skip-nav"><a href="#skip-navbar-top" title="Skip navigation links">Skip navigation links</a></div>
|
||
|
<ul id="navbar-top-firstrow" class="nav-list" title="Navigation">
|
||
|
<li><a href="../../../index.html">Overview</a></li>
|
||
|
<li><a href="package-summary.html">Package</a></li>
|
||
|
<li class="nav-bar-cell1-rev">Class</li>
|
||
|
<li><a href="package-tree.html">Tree</a></li>
|
||
|
<li><a href="../../../deprecated-list.html">Deprecated</a></li>
|
||
|
<li><a href="../../../index-all.html">Index</a></li>
|
||
|
<li><a href="../../../help-doc.html#class">Help</a></li>
|
||
|
</ul>
|
||
|
</div>
|
||
|
<div class="sub-nav">
|
||
|
<div>
|
||
|
<ul class="sub-nav-list">
|
||
|
<li>Summary: </li>
|
||
|
<li>Nested | </li>
|
||
|
<li>Field | </li>
|
||
|
<li>Constr | </li>
|
||
|
<li><a href="#method-summary">Method</a></li>
|
||
|
</ul>
|
||
|
<ul class="sub-nav-list">
|
||
|
<li>Detail: </li>
|
||
|
<li>Field | </li>
|
||
|
<li>Constr | </li>
|
||
|
<li><a href="#method-detail">Method</a></li>
|
||
|
</ul>
|
||
|
</div>
|
||
|
<div class="nav-list-search"><label for="search-input">SEARCH:</label>
|
||
|
<input type="text" id="search-input" value="search" disabled="disabled">
|
||
|
<input type="reset" id="reset-button" value="reset" disabled="disabled">
|
||
|
</div>
|
||
|
</div>
|
||
|
<!-- ========= END OF TOP NAVBAR ========= -->
|
||
|
<span class="skip-nav" id="skip-navbar-top"></span></nav>
|
||
|
</header>
|
||
|
<div class="flex-content">
|
||
|
<main role="main">
|
||
|
<!-- ======== START OF CLASS DATA ======== -->
|
||
|
<div class="header">
|
||
|
<div class="sub-title"><span class="package-label-in-type">Package</span> <a href="package-summary.html">org.bukkit.inventory</a></div>
|
||
|
<h1 title="Interface Inventory" class="title">Interface Inventory</h1>
|
||
|
</div>
|
||
|
<section class="class-description" id="class-description">
|
||
|
<dl class="notes">
|
||
|
<dt>All Superinterfaces:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Iterable.html" title="class or interface in java.lang" class="external-link">Iterable</a><<a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></code></dd>
|
||
|
</dl>
|
||
|
<dl class="notes">
|
||
|
<dt>All Known Subinterfaces:</dt>
|
||
|
<dd><code><a href="AbstractHorseInventory.html" title="interface in org.bukkit.inventory">AbstractHorseInventory</a></code>, <code><a href="AnvilInventory.html" title="interface in org.bukkit.inventory">AnvilInventory</a></code>, <code><a href="ArmoredHorseInventory.html" title="interface in org.bukkit.inventory">ArmoredHorseInventory</a></code>, <code><a href="BeaconInventory.html" title="interface in org.bukkit.inventory">BeaconInventory</a></code>, <code><a href="BrewerInventory.html" title="interface in org.bukkit.inventory">BrewerInventory</a></code>, <code><a href="CartographyInventory.html" title="interface in org.bukkit.inventory">CartographyInventory</a></code>, <code><a href="CraftingInventory.html" title="interface in org.bukkit.inventory">CraftingInventory</a></code>, <code><a href="DoubleChestInventory.html" title="interface in org.bukkit.inventory">DoubleChestInventory</a></code>, <code><a href="EnchantingInventory.html" title="interface in org.bukkit.inventory">EnchantingInventory</a></code>, <code><a href="FurnaceInventory.html" title="interface in org.bukkit.inventory">FurnaceInventory</a></code>, <code><a href="GrindstoneInventory.html" title="interface in org.bukkit.inventory">GrindstoneInventory</a></code>, <code><a href="HorseInventory.html" title="interface in org.bukkit.inventory">HorseInventory</a></code>, <code><a href="LecternInventory.html" title="interface in org.bukkit.inventory">LecternInventory</a></code>, <code><a href="LlamaInventory.html" title="interface in org.bukkit.inventory">LlamaInventory</a></code>, <code><a href="LoomInventory.html" title="interface in org.bukkit.inventory">LoomInventory</a></code>, <code><a href="MerchantInventory.html" title="interface in org.bukkit.inventory">MerchantInventory</a></code>, <code><a href="PlayerInventory.html" title="interface in org.bukkit.inventory">PlayerInventory</a></code>, <code><a href="SaddledHorseInventory.html" title="interface in org.bukkit.inventory">SaddledHorseInventory</a></code>, <code><a href="SmithingInventory.html" title="interface in org.bukkit.inventory">SmithingInventory</a></code>, <code><a href="StonecutterInventory.html" title="interface in org.bukkit.inventory">StonecutterInventory</a></code></dd>
|
||
|
</dl>
|
||
|
<hr>
|
||
|
<div class="type-signature"><span class="modifiers">public interface </span><span class="element-name type-name-label">Inventory</span><span class="extends-implements">
|
||
|
extends <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Iterable.html" title="class or interface in java.lang" class="external-link">Iterable</a><<a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></span></div>
|
||
|
<div class="block">Interface to the various inventories. Behavior relating to <a href="../Material.html#AIR"><code>Material.AIR</code></a> is unspecified.
|
||
|
|
||
|
<br>
|
||
|
<b>Note that whilst <a href="#iterator()"><code>iterator()</code></a> deals with the entire inventory, add
|
||
|
/ contains / remove methods deal only with the storage contents.</b>
|
||
|
<br>
|
||
|
<b>Consider using <a href="#getContents()"><code>getContents()</code></a> and <a href="#getStorageContents()"><code>getStorageContents()</code></a> for
|
||
|
specific iteration.</b></div>
|
||
|
<dl class="notes">
|
||
|
<dt>See Also:</dt>
|
||
|
<dd>
|
||
|
<ul class="see-list">
|
||
|
<li><a href="#getContents()"><code>getContents()</code></a></li>
|
||
|
<li><a href="#getStorageContents()"><code>getStorageContents()</code></a></li>
|
||
|
</ul>
|
||
|
</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
<section class="summary">
|
||
|
<ul class="summary-list">
|
||
|
<!-- ========== METHOD SUMMARY =========== -->
|
||
|
<li>
|
||
|
<section class="method-summary" id="method-summary">
|
||
|
<h2>Method Summary</h2>
|
||
|
<div id="method-summary-table">
|
||
|
<div class="table-tabs" role="tablist" aria-orientation="horizontal"><button id="method-summary-table-tab0" role="tab" aria-selected="true" aria-controls="method-summary-table.tabpanel" tabindex="0" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table', 3)" class="active-table-tab">All Methods</button><button id="method-summary-table-tab2" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab2', 3)" class="table-tab">Instance Methods</button><button id="method-summary-table-tab3" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab3', 3)" class="table-tab">Abstract Methods</button></div>
|
||
|
<div id="method-summary-table.tabpanel" role="tabpanel">
|
||
|
<div class="summary-table three-column-summary" aria-labelledby="method-summary-table-tab0">
|
||
|
<div class="table-header col-first">Modifier and Type</div>
|
||
|
<div class="table-header col-second">Method</div>
|
||
|
<div class="table-header col-last">Description</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/HashMap.html" title="class or interface in java.util" class="external-link">HashMap</a><<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>,<wbr><a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#addItem(org.bukkit.inventory.ItemStack...)" class="member-name-link">addItem</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>... items)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Stores the given ItemStacks in the inventory.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/HashMap.html" title="class or interface in java.util" class="external-link">HashMap</a><<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>,<wbr>? extends <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#all(org.bukkit.Material)" class="member-name-link">all</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../Material.html" title="enum class in org.bukkit">Material</a> material)</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Returns a HashMap with all slots and ItemStacks in the inventory with
|
||
|
the given Material.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/HashMap.html" title="class or interface in java.util" class="external-link">HashMap</a><<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>,<wbr>? extends <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#all(org.bukkit.inventory.ItemStack)" class="member-name-link">all</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Finds all slots in the inventory containing any ItemStacks with the
|
||
|
given ItemStack.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#clear()" class="member-name-link">clear</a>()</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Clears out the whole Inventory.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#clear(int)" class="member-name-link">clear</a><wbr>(int index)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Clears out a particular slot in the index.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>int</code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#close()" class="member-name-link">close</a>()</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Closes the inventory for all viewers.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>boolean</code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#contains(org.bukkit.Material)" class="member-name-link">contains</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../Material.html" title="enum class in org.bukkit">Material</a> material)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Checks if the inventory contains any ItemStacks with the given
|
||
|
material.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>boolean</code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#contains(org.bukkit.Material,int)" class="member-name-link">contains</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../Material.html" title="enum class in org.bukkit">Material</a> material,
|
||
|
int amount)</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Checks if the inventory contains any ItemStacks with the given
|
||
|
material, adding to at least the minimum amount specified.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>boolean</code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#contains(org.bukkit.inventory.ItemStack)" class="member-name-link">contains</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Checks if the inventory contains any ItemStacks matching the given
|
||
|
ItemStack.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>boolean</code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#contains(org.bukkit.inventory.ItemStack,int)" class="member-name-link">contains</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item,
|
||
|
int amount)</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Checks if the inventory contains at least the minimum amount specified
|
||
|
of exactly matching ItemStacks.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>boolean</code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#containsAtLeast(org.bukkit.inventory.ItemStack,int)" class="member-name-link">containsAtLeast</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item,
|
||
|
int amount)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Checks if the inventory contains ItemStacks matching the given
|
||
|
ItemStack whose amounts sum to at least the minimum amount specified.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>int</code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#first(org.bukkit.inventory.ItemStack)" class="member-name-link">first</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item)</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Returns the first slot in the inventory containing an ItemStack with
|
||
|
the given stack.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>int</code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#first(org.bukkit.Material)" class="member-name-link">first</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../Material.html" title="enum class in org.bukkit">Material</a> material)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Finds the first slot in the inventory containing an ItemStack with the
|
||
|
given material</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>int</code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#firstEmpty()" class="member-name-link">firstEmpty</a>()</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Returns the first empty Slot.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> <a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> []</code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getContents()" class="member-name-link">getContents</a>()</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Returns all ItemStacks from the inventory</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="InventoryHolder.html" title="interface in org.bukkit.inventory">InventoryHolder</a></code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getHolder()" class="member-name-link">getHolder</a>()</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Gets the block or entity belonging to the open inventory</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="InventoryHolder.html" title="interface in org.bukkit.inventory">InventoryHolder</a></code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getHolder(boolean)" class="member-name-link">getHolder</a><wbr>(boolean useSnapshot)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Gets the block or entity belonging to the open inventory</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a></code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getItem(int)" class="member-name-link">getItem</a><wbr>(int index)</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Returns the ItemStack found in the slot at the given index</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="../Location.html" title="class in org.bukkit">Location</a></code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getLocation()" class="member-name-link">getLocation</a>()</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Get the location of the block or entity which corresponds to this inventory.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>int</code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getMaxStackSize()" class="member-name-link">getMaxStackSize</a>()</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Returns the maximum stack size for an ItemStack in this inventory.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>int</code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getSize()" class="member-name-link">getSize</a>()</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Returns the size of the inventory</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> <a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> []</code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getStorageContents()" class="member-name-link">getStorageContents</a>()</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Return the contents from the section of the inventory where items can
|
||
|
reasonably be expected to be stored.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../event/inventory/InventoryType.html" title="enum class in org.bukkit.event.inventory">InventoryType</a></code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getType()" class="member-name-link">getType</a>()</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Returns what type of inventory this is.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/List.html" title="class or interface in java.util" class="external-link">List</a><<a href="../entity/HumanEntity.html" title="interface in org.bukkit.entity">HumanEntity</a>></code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getViewers()" class="member-name-link">getViewers</a>()</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Gets a list of players viewing the inventory.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>boolean</code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#isEmpty()" class="member-name-link">isEmpty</a>()</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Check whether or not this inventory is empty.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/ListIterator.html" title="class or interface in java.util" class="external-link">ListIterator</a><<a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#iterator()" class="member-name-link">iterator</a>()</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"> </div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/ListIterator.html" title="class or interface in java.util" class="external-link">ListIterator</a><<a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#iterator(int)" class="member-name-link">iterator</a><wbr>(int index)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Returns an iterator starting at the given index.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#remove(org.bukkit.inventory.ItemStack)" class="member-name-link">remove</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item)</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Removes all stacks in the inventory matching the given stack.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#remove(org.bukkit.Material)" class="member-name-link">remove</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../Material.html" title="enum class in org.bukkit">Material</a> material)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Removes all stacks in the inventory matching the given material.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/HashMap.html" title="class or interface in java.util" class="external-link">HashMap</a><<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>,<wbr><a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#removeItem(org.bukkit.inventory.ItemStack...)" class="member-name-link">removeItem</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>... items)</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Removes the given ItemStacks from the inventory.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/HashMap.html" title="class or interface in java.util" class="external-link">HashMap</a><<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>,<wbr><a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#removeItemAnySlot(org.bukkit.inventory.ItemStack...)" class="member-name-link">removeItemAnySlot</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>... items)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Searches all possible inventory slots in order to remove the given ItemStacks.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#setContents(org.bukkit.inventory.ItemStack%5B%5D)" class="member-name-link">setContents</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> <a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> [] items)</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Completely replaces the inventory's contents.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#setItem(int,org.bukkit.inventory.ItemStack)" class="member-name-link">setItem</a><wbr>(int index,
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Stores the ItemStack at the given index of the inventory.</div>
|
||
|
</div>
|
||
|
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div>
|
||
|
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#setMaxStackSize(int)" class="member-name-link">setMaxStackSize</a><wbr>(int size)</code></div>
|
||
|
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">This method allows you to change the maximum stack size for an
|
||
|
inventory.</div>
|
||
|
</div>
|
||
|
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div>
|
||
|
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#setStorageContents(org.bukkit.inventory.ItemStack%5B%5D)" class="member-name-link">setStorageContents</a><wbr>(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> <a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> [] items)</code></div>
|
||
|
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
|
||
|
<div class="block">Put the given ItemStacks into the storage slots</div>
|
||
|
</div>
|
||
|
</div>
|
||
|
</div>
|
||
|
</div>
|
||
|
<div class="inherited-list">
|
||
|
<h3 id="methods-inherited-from-class-java.lang.Iterable">Methods inherited from interface java.lang.<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Iterable.html" title="class or interface in java.lang" class="external-link">Iterable</a></h3>
|
||
|
<code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Iterable.html#forEach(java.util.function.Consumer)" title="class or interface in java.lang" class="external-link">forEach</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Iterable.html#spliterator()" title="class or interface in java.lang" class="external-link">spliterator</a></code></div>
|
||
|
</section>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</section>
|
||
|
<section class="details">
|
||
|
<ul class="details-list">
|
||
|
<!-- ============ METHOD DETAIL ========== -->
|
||
|
<li>
|
||
|
<section class="method-details" id="method-detail">
|
||
|
<h2>Method Details</h2>
|
||
|
<ul class="member-list">
|
||
|
<li>
|
||
|
<section class="detail" id="getSize()">
|
||
|
<h3>getSize</h3>
|
||
|
<div class="member-signature"><span class="return-type">int</span> <span class="element-name">getSize</span>()</div>
|
||
|
<div class="block">Returns the size of the inventory</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>The size of the inventory</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="getMaxStackSize()">
|
||
|
<h3>getMaxStackSize</h3>
|
||
|
<div class="member-signature"><span class="return-type">int</span> <span class="element-name">getMaxStackSize</span>()</div>
|
||
|
<div class="block">Returns the maximum stack size for an ItemStack in this inventory.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>The maximum size for an ItemStack in this inventory.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="setMaxStackSize(int)">
|
||
|
<h3>setMaxStackSize</h3>
|
||
|
<div class="member-signature"><span class="return-type">void</span> <span class="element-name">setMaxStackSize</span><wbr><span class="parameters">(int size)</span></div>
|
||
|
<div class="block">This method allows you to change the maximum stack size for an
|
||
|
inventory.
|
||
|
<p>
|
||
|
<b>Caveats:</b>
|
||
|
<ul>
|
||
|
<li>Not all inventories respect this value.
|
||
|
<li>Stacks larger than 127 may be clipped when the world is saved.
|
||
|
<li>This value is not guaranteed to be preserved; be sure to set it
|
||
|
before every time you want to set a slot over the max stack size.
|
||
|
<li>Stacks larger than the default max size for this type of inventory
|
||
|
may not display correctly in the client.
|
||
|
</ul></div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>size</code> - The new maximum stack size for items in this inventory.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="getItem(int)">
|
||
|
<h3>getItem</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a></span> <span class="element-name">getItem</span><wbr><span class="parameters">(int index)</span></div>
|
||
|
<div class="block">Returns the ItemStack found in the slot at the given index</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>index</code> - The index of the Slot's ItemStack to return</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>The ItemStack in the slot</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="setItem(int,org.bukkit.inventory.ItemStack)">
|
||
|
<h3>setItem</h3>
|
||
|
<div class="member-signature"><span class="return-type">void</span> <span class="element-name">setItem</span><wbr><span class="parameters">(int index,
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item)</span></div>
|
||
|
<div class="block">Stores the ItemStack at the given index of the inventory.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>index</code> - The index where to put the ItemStack</dd>
|
||
|
<dd><code>item</code> - The ItemStack to set</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="addItem(org.bukkit.inventory.ItemStack...)">
|
||
|
<h3>addItem</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/HashMap.html" title="class or interface in java.util" class="external-link">HashMap</a><<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>,<wbr><a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></span> <span class="element-name">addItem</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>... items)</span>
|
||
|
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></span></div>
|
||
|
<div class="block">Stores the given ItemStacks in the inventory. This will try to fill
|
||
|
existing stacks and empty slots as well as it can.
|
||
|
<p>
|
||
|
The returned HashMap contains what it couldn't store, where the key is
|
||
|
the index of the parameter, and the value is the ItemStack at that
|
||
|
index of the varargs parameter. If all items are stored, it will return
|
||
|
an empty HashMap.
|
||
|
<p>
|
||
|
If you pass in ItemStacks which exceed the maximum stack size for the
|
||
|
Material, first they will be added to partial stacks where
|
||
|
Material.getMaxStackSize() is not exceeded, up to
|
||
|
Material.getMaxStackSize(). When there are no partial stacks left
|
||
|
stacks will be split on Inventory.getMaxStackSize() allowing you to
|
||
|
exceed the maximum stack size for that material.
|
||
|
<p>
|
||
|
It is known that in some implementations this method will also set
|
||
|
the inputted argument amount to the number of that item not placed in
|
||
|
slots.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>items</code> - The ItemStacks to add</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>A HashMap containing items that didn't fit.</dd>
|
||
|
<dt>Throws:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></code> - if items or any element in it is null</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="removeItem(org.bukkit.inventory.ItemStack...)">
|
||
|
<h3>removeItem</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/HashMap.html" title="class or interface in java.util" class="external-link">HashMap</a><<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>,<wbr><a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></span> <span class="element-name">removeItem</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>... items)</span>
|
||
|
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></span></div>
|
||
|
<div class="block">Removes the given ItemStacks from the inventory.
|
||
|
<p>
|
||
|
It will try to remove 'as much as possible' from the types and amounts
|
||
|
you give as arguments.
|
||
|
<p>
|
||
|
The returned HashMap contains what it couldn't remove, where the key is
|
||
|
the index of the parameter, and the value is the ItemStack at that
|
||
|
index of the varargs parameter. If all the given ItemStacks are
|
||
|
removed, it will return an empty HashMap.
|
||
|
<p>
|
||
|
It is known that in some implementations this method will also set the
|
||
|
inputted argument amount to the number of that item not removed from
|
||
|
slots.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>items</code> - The ItemStacks to remove</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>A HashMap containing items that couldn't be removed.</dd>
|
||
|
<dt>Throws:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></code> - if items is null</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="removeItemAnySlot(org.bukkit.inventory.ItemStack...)">
|
||
|
<h3>removeItemAnySlot</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/HashMap.html" title="class or interface in java.util" class="external-link">HashMap</a><<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>,<wbr><a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></span> <span class="element-name">removeItemAnySlot</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>... items)</span>
|
||
|
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></span></div>
|
||
|
<div class="block">Searches all possible inventory slots in order to remove the given ItemStacks.
|
||
|
<p>
|
||
|
Similar to <a href="#removeItem(org.bukkit.inventory.ItemStack...)"><code>removeItem(ItemStack...)</code></a> in behavior, except this
|
||
|
method will check all possible slots in the inventory, rather than just the main
|
||
|
storage contents.
|
||
|
<p>
|
||
|
It will try to remove 'as much as possible' from the types and amounts
|
||
|
you give as arguments.
|
||
|
<p>
|
||
|
The returned HashMap contains what it couldn't remove, where the key is
|
||
|
the index of the parameter, and the value is the ItemStack at that
|
||
|
index of the varargs parameter. If all the given ItemStacks are
|
||
|
removed, it will return an empty HashMap.
|
||
|
<p>
|
||
|
It is known that in some implementations this method will also set the
|
||
|
inputted argument amount to the number of that item not removed from
|
||
|
slots.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>items</code> - The ItemStacks to remove</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>A HashMap containing items that couldn't be removed.</dd>
|
||
|
<dt>Throws:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></code> - if items is null</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="getContents()">
|
||
|
<h3>getContents</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> <a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> []</span> <span class="element-name">getContents</span>()</div>
|
||
|
<div class="block">Returns all ItemStacks from the inventory</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>An array of ItemStacks from the inventory. Individual items may be null.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="setContents(org.bukkit.inventory.ItemStack[])">
|
||
|
<h3>setContents</h3>
|
||
|
<div class="member-signature"><span class="return-type">void</span> <span class="element-name">setContents</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> <a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> [] items)</span>
|
||
|
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></span></div>
|
||
|
<div class="block">Completely replaces the inventory's contents. Removes all existing
|
||
|
contents and replaces it with the ItemStacks given in the array.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>items</code> - A complete replacement for the contents; the length must
|
||
|
be less than or equal to <a href="#getSize()"><code>getSize()</code></a>.</dd>
|
||
|
<dt>Throws:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></code> - If the array has more items than the
|
||
|
inventory.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="getStorageContents()">
|
||
|
<h3>getStorageContents</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> <a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> []</span> <span class="element-name">getStorageContents</span>()</div>
|
||
|
<div class="block">Return the contents from the section of the inventory where items can
|
||
|
reasonably be expected to be stored. In most cases this will represent
|
||
|
the entire inventory, but in some cases it may exclude armor or result
|
||
|
slots.
|
||
|
<br>
|
||
|
It is these contents which will be used for add / contains / remove
|
||
|
methods which look for a specific stack.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>inventory storage contents. Individual items may be null.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="setStorageContents(org.bukkit.inventory.ItemStack[])">
|
||
|
<h3>setStorageContents</h3>
|
||
|
<div class="member-signature"><span class="return-type">void</span> <span class="element-name">setStorageContents</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> <a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> [] items)</span>
|
||
|
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></span></div>
|
||
|
<div class="block">Put the given ItemStacks into the storage slots</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>items</code> - The ItemStacks to use as storage contents</dd>
|
||
|
<dt>Throws:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></code> - If the array has more items than the
|
||
|
inventory.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="contains(org.bukkit.Material)">
|
||
|
<h3>contains</h3>
|
||
|
<div class="member-signature"><span class="return-type">boolean</span> <span class="element-name">contains</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../Material.html" title="enum class in org.bukkit">Material</a> material)</span>
|
||
|
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></span></div>
|
||
|
<div class="block">Checks if the inventory contains any ItemStacks with the given
|
||
|
material.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>material</code> - The material to check for</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>true if an ItemStack is found with the given Material</dd>
|
||
|
<dt>Throws:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></code> - if material is null</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="contains(org.bukkit.inventory.ItemStack)">
|
||
|
<h3>contains</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Contract.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Contract</a>("null -> false")
|
||
|
</span><span class="return-type">boolean</span> <span class="element-name">contains</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item)</span></div>
|
||
|
<div class="block">Checks if the inventory contains any ItemStacks matching the given
|
||
|
ItemStack.
|
||
|
<p>
|
||
|
This will only return true if both the type and the amount of the stack
|
||
|
match.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>item</code> - The ItemStack to match against</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>false if item is null, true if any exactly matching ItemStacks
|
||
|
were found</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="contains(org.bukkit.Material,int)">
|
||
|
<h3>contains</h3>
|
||
|
<div class="member-signature"><span class="return-type">boolean</span> <span class="element-name">contains</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../Material.html" title="enum class in org.bukkit">Material</a> material,
|
||
|
int amount)</span>
|
||
|
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></span></div>
|
||
|
<div class="block">Checks if the inventory contains any ItemStacks with the given
|
||
|
material, adding to at least the minimum amount specified.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>material</code> - The material to check for</dd>
|
||
|
<dd><code>amount</code> - The minimum amount</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>true if amount is less than 1, true if enough ItemStacks were
|
||
|
found to add to the given amount</dd>
|
||
|
<dt>Throws:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></code> - if material is null</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="contains(org.bukkit.inventory.ItemStack,int)">
|
||
|
<h3>contains</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Contract.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Contract</a>("null, _ -> false")
|
||
|
</span><span class="return-type">boolean</span> <span class="element-name">contains</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item,
|
||
|
int amount)</span></div>
|
||
|
<div class="block">Checks if the inventory contains at least the minimum amount specified
|
||
|
of exactly matching ItemStacks.
|
||
|
<p>
|
||
|
An ItemStack only counts if both the type and the amount of the stack
|
||
|
match.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>item</code> - the ItemStack to match against</dd>
|
||
|
<dd><code>amount</code> - how many identical stacks to check for</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>false if item is null, true if amount less than 1, true if
|
||
|
amount of exactly matching ItemStacks were found</dd>
|
||
|
<dt>See Also:</dt>
|
||
|
<dd>
|
||
|
<ul class="see-list-long">
|
||
|
<li><a href="#containsAtLeast(org.bukkit.inventory.ItemStack,int)"><code>containsAtLeast(ItemStack, int)</code></a></li>
|
||
|
</ul>
|
||
|
</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="containsAtLeast(org.bukkit.inventory.ItemStack,int)">
|
||
|
<h3>containsAtLeast</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Contract.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Contract</a>("null, _ -> false")
|
||
|
</span><span class="return-type">boolean</span> <span class="element-name">containsAtLeast</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item,
|
||
|
int amount)</span></div>
|
||
|
<div class="block">Checks if the inventory contains ItemStacks matching the given
|
||
|
ItemStack whose amounts sum to at least the minimum amount specified.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>item</code> - the ItemStack to match against</dd>
|
||
|
<dd><code>amount</code> - the minimum amount</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>false if item is null, true if amount less than 1, true if
|
||
|
enough ItemStacks were found to add to the given amount</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="all(org.bukkit.Material)">
|
||
|
<h3>all</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/HashMap.html" title="class or interface in java.util" class="external-link">HashMap</a><<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>,<wbr>? extends <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></span> <span class="element-name">all</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../Material.html" title="enum class in org.bukkit">Material</a> material)</span>
|
||
|
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></span></div>
|
||
|
<div class="block">Returns a HashMap with all slots and ItemStacks in the inventory with
|
||
|
the given Material.
|
||
|
<p>
|
||
|
The HashMap contains entries where, the key is the slot index, and the
|
||
|
value is the ItemStack in that slot. If no matching ItemStack with the
|
||
|
given Material is found, an empty map is returned.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>material</code> - The material to look for</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>A HashMap containing the slot index, ItemStack pairs</dd>
|
||
|
<dt>Throws:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></code> - if material is null</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="all(org.bukkit.inventory.ItemStack)">
|
||
|
<h3>all</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/HashMap.html" title="class or interface in java.util" class="external-link">HashMap</a><<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Integer.html" title="class or interface in java.lang" class="external-link">Integer</a>,<wbr>? extends <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></span> <span class="element-name">all</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item)</span></div>
|
||
|
<div class="block">Finds all slots in the inventory containing any ItemStacks with the
|
||
|
given ItemStack. This will only match slots if both the type and the
|
||
|
amount of the stack match
|
||
|
<p>
|
||
|
The HashMap contains entries where, the key is the slot index, and the
|
||
|
value is the ItemStack in that slot. If no matching ItemStack with the
|
||
|
given Material is found, an empty map is returned.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>item</code> - The ItemStack to match against</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>A map from slot indexes to item at index</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="first(org.bukkit.Material)">
|
||
|
<h3>first</h3>
|
||
|
<div class="member-signature"><span class="return-type">int</span> <span class="element-name">first</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../Material.html" title="enum class in org.bukkit">Material</a> material)</span>
|
||
|
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></span></div>
|
||
|
<div class="block">Finds the first slot in the inventory containing an ItemStack with the
|
||
|
given material</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>material</code> - The material to look for</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>The slot index of the given Material or -1 if not found</dd>
|
||
|
<dt>Throws:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></code> - if material is null</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="first(org.bukkit.inventory.ItemStack)">
|
||
|
<h3>first</h3>
|
||
|
<div class="member-signature"><span class="return-type">int</span> <span class="element-name">first</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item)</span></div>
|
||
|
<div class="block">Returns the first slot in the inventory containing an ItemStack with
|
||
|
the given stack. This will only match a slot if both the type and the
|
||
|
amount of the stack match</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>item</code> - The ItemStack to match against</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>The slot index of the given ItemStack or -1 if not found</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="firstEmpty()">
|
||
|
<h3>firstEmpty</h3>
|
||
|
<div class="member-signature"><span class="return-type">int</span> <span class="element-name">firstEmpty</span>()</div>
|
||
|
<div class="block">Returns the first empty Slot.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>The first empty Slot found, or -1 if no empty slots.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="isEmpty()">
|
||
|
<h3>isEmpty</h3>
|
||
|
<div class="member-signature"><span class="return-type">boolean</span> <span class="element-name">isEmpty</span>()</div>
|
||
|
<div class="block">Check whether or not this inventory is empty. An inventory is considered
|
||
|
to be empty if there are no ItemStacks in any slot of this inventory.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>true if empty, false otherwise</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="remove(org.bukkit.Material)">
|
||
|
<h3>remove</h3>
|
||
|
<div class="member-signature"><span class="return-type">void</span> <span class="element-name">remove</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../Material.html" title="enum class in org.bukkit">Material</a> material)</span>
|
||
|
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></span></div>
|
||
|
<div class="block">Removes all stacks in the inventory matching the given material.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>material</code> - The material to remove</dd>
|
||
|
<dt>Throws:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html" title="class or interface in java.lang" class="external-link">IllegalArgumentException</a></code> - if material is null</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="remove(org.bukkit.inventory.ItemStack)">
|
||
|
<h3>remove</h3>
|
||
|
<div class="member-signature"><span class="return-type">void</span> <span class="element-name">remove</span><wbr><span class="parameters">(<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
<a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a> item)</span></div>
|
||
|
<div class="block">Removes all stacks in the inventory matching the given stack.
|
||
|
<p>
|
||
|
This will only match a slot if both the type and the amount of the
|
||
|
stack match</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>item</code> - The ItemStack to match against</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="clear(int)">
|
||
|
<h3>clear</h3>
|
||
|
<div class="member-signature"><span class="return-type">void</span> <span class="element-name">clear</span><wbr><span class="parameters">(int index)</span></div>
|
||
|
<div class="block">Clears out a particular slot in the index.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>index</code> - The index to empty.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="clear()">
|
||
|
<h3>clear</h3>
|
||
|
<div class="member-signature"><span class="return-type">void</span> <span class="element-name">clear</span>()</div>
|
||
|
<div class="block">Clears out the whole Inventory.</div>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="close()">
|
||
|
<h3>close</h3>
|
||
|
<div class="member-signature"><span class="return-type">int</span> <span class="element-name">close</span>()</div>
|
||
|
<div class="block">Closes the inventory for all viewers.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>the number if viewers the inventory was closed for</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="getViewers()">
|
||
|
<h3>getViewers</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/List.html" title="class or interface in java.util" class="external-link">List</a><<a href="../entity/HumanEntity.html" title="interface in org.bukkit.entity">HumanEntity</a>></span> <span class="element-name">getViewers</span>()</div>
|
||
|
<div class="block">Gets a list of players viewing the inventory. Note that a player is
|
||
|
considered to be viewing their own inventory and internal crafting
|
||
|
screen even when said inventory is not open. They will normally be
|
||
|
considered to be viewing their inventory even when they have a
|
||
|
different inventory screen open, but it's possible for customized
|
||
|
inventory screens to exclude the viewer's inventory, so this should
|
||
|
never be assumed to be non-empty.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>A list of HumanEntities who are viewing this Inventory.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="getType()">
|
||
|
<h3>getType</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="../event/inventory/InventoryType.html" title="enum class in org.bukkit.event.inventory">InventoryType</a></span> <span class="element-name">getType</span>()</div>
|
||
|
<div class="block">Returns what type of inventory this is.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>The InventoryType representing the type of inventory.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="getHolder()">
|
||
|
<h3>getHolder</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="InventoryHolder.html" title="interface in org.bukkit.inventory">InventoryHolder</a></span> <span class="element-name">getHolder</span>()</div>
|
||
|
<div class="block">Gets the block or entity belonging to the open inventory</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>The holder of the inventory; null if it has no holder.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="getHolder(boolean)">
|
||
|
<h3>getHolder</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="InventoryHolder.html" title="interface in org.bukkit.inventory">InventoryHolder</a></span> <span class="element-name">getHolder</span><wbr><span class="parameters">(boolean useSnapshot)</span></div>
|
||
|
<div class="block">Gets the block or entity belonging to the open inventory</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>useSnapshot</code> - Create a snapshot if the holder is a tile entity</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>The holder of the inventory; null if it has no holder.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="iterator()">
|
||
|
<h3>iterator</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/ListIterator.html" title="class or interface in java.util" class="external-link">ListIterator</a><<a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></span> <span class="element-name">iterator</span>()</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Specified by:</dt>
|
||
|
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Iterable.html#iterator()" title="class or interface in java.lang" class="external-link">iterator</a></code> in interface <code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Iterable.html" title="class or interface in java.lang" class="external-link">Iterable</a><<a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></code></dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="iterator(int)">
|
||
|
<h3>iterator</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/NotNull.html" title="class or interface in org.jetbrains.annotations" class="external-link">@NotNull</a> <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/ListIterator.html" title="class or interface in java.util" class="external-link">ListIterator</a><<a href="ItemStack.html" title="class in org.bukkit.inventory">ItemStack</a>></span> <span class="element-name">iterator</span><wbr><span class="parameters">(int index)</span></div>
|
||
|
<div class="block">Returns an iterator starting at the given index. If the index is
|
||
|
positive, then the first call to next() will return the item at that
|
||
|
index; if it is negative, the first call to previous will return the
|
||
|
item at index (getSize() + index).</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Parameters:</dt>
|
||
|
<dd><code>index</code> - The index.</dd>
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>An iterator.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
<li>
|
||
|
<section class="detail" id="getLocation()">
|
||
|
<h3>getLocation</h3>
|
||
|
<div class="member-signature"><span class="annotations"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a>
|
||
|
</span><span class="return-type"><a href="https://javadoc.io/doc/org.jetbrains/annotations/23.0.0/org/jetbrains/annotations/Nullable.html" title="class or interface in org.jetbrains.annotations" class="external-link">@Nullable</a> <a href="../Location.html" title="class in org.bukkit">Location</a></span> <span class="element-name">getLocation</span>()</div>
|
||
|
<div class="block">Get the location of the block or entity which corresponds to this inventory. May return null if this container
|
||
|
was custom created or is a virtual / subcontainer.</div>
|
||
|
<dl class="notes">
|
||
|
<dt>Returns:</dt>
|
||
|
<dd>location or null if not applicable.</dd>
|
||
|
</dl>
|
||
|
</section>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</section>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</section>
|
||
|
<!-- ========= END OF CLASS DATA ========= -->
|
||
|
</main>
|
||
|
</div>
|
||
|
</div>
|
||
|
</body>
|
||
|
</html>
|