DefaultInventoryRepository
in package
implements
InventoryRepository
FinalYes
Table of Contents
Interfaces
Properties
- $anchorNormalizer : AnchorNormalizer
- $inventories : array<string, Inventory>
- $inventoryLoader : InventoryLoader
Methods
- __construct() : mixed
- addInventory() : void
- getInventory() : Inventory|null
- getLink() : InventoryLink|null
- hasInventory() : bool
Properties
$anchorNormalizer read-only
private
AnchorNormalizer
$anchorNormalizer
$inventories
private
array<string, Inventory>
$inventories
= []
$inventoryLoader read-only
private
InventoryLoader
$inventoryLoader
Methods
__construct()
public
__construct(AnchorNormalizer $anchorNormalizer, InventoryLoader $inventoryLoader, array<int, array<string, string>> $inventoryConfigs) : mixed
Parameters
- $anchorNormalizer : AnchorNormalizer
- $inventoryLoader : InventoryLoader
- $inventoryConfigs : array<int, array<string, string>>
addInventory()
public
addInventory(string $key, Inventory $inventory) : void
Parameters
- $key : string
- $inventory : Inventory
getInventory()
public
getInventory(CrossReferenceNode $node, RenderContext $renderContext, Messages $messages) : Inventory|null
Parameters
- $node : CrossReferenceNode
- $renderContext : RenderContext
- $messages : Messages
Return values
Inventory|nullgetLink()
public
getLink(CrossReferenceNode $node, RenderContext $renderContext, Messages $messages) : InventoryLink|null
Parameters
- $node : CrossReferenceNode
- $renderContext : RenderContext
- $messages : Messages
Return values
InventoryLink|nullhasInventory()
public
hasInventory(string $key) : bool
Parameters
- $key : string