DelegateInventory
Extends BaseInventory
An inventory which is backed by another inventory, and acts as a proxy to that inventory.
Methods
__construct()
php
public function __construct(\pocketmine\inventory\Inventory $backingInventory)__destruct()
php
public function __destruct()getContents()
php
public function getContents(bool $includeEmpty = false) : arraygetItem()
php
public function getItem(int $index) : \pocketmine\item\ItemgetSize()
php
public function getSize() : intinternalSetContents() protected
php
protected function internalSetContents(array $items) : voidinternalSetItem() protected
php
protected function internalSetItem(int $index, \pocketmine\item\Item $item) : voidisSlotEmpty()
php
public function isSlotEmpty(int $index) : boolonContentChange() protected
php
protected function onContentChange(array $itemsBefore) : voidonSlotChange() protected
php
protected function onSlotChange(int $index, \pocketmine\item\Item $before) : void