pocketmine\inventory\InventoryType::get PHP Method

get() public static method

public static get ( $index ) : InventoryType
$index
return InventoryType
    public static function get($index)
    {
        return isset(static::$default[$index]) ? static::$default[$index] : null;
    }

Usage Example

 public function __construct(Chest $left, Chest $right)
 {
     $this->left = $left->getRealInventory();
     $this->right = $right->getRealInventory();
     $items = array_merge($this->left->getContents(), $this->right->getContents());
     BaseInventory::__construct($this, InventoryType::get(InventoryType::DOUBLE_CHEST), $items);
 }
All Usage Examples Of pocketmine\inventory\InventoryType::get