diff --git a/docs/en/tutorials/working-with-indexed-associations.rst b/docs/en/tutorials/working-with-indexed-associations.rst index 1b120a2ae40..ac326c4181f 100644 --- a/docs/en/tutorials/working-with-indexed-associations.rst +++ b/docs/en/tutorials/working-with-indexed-associations.rst @@ -32,9 +32,6 @@ The code and mappings for the Market entity looks like this: .. literalinclude:: working-with-indexed-associations/Market.php :language: attribute - .. literalinclude:: working-with-indexed-associations/Market-annotations.php - :language: annotation - .. literalinclude:: working-with-indexed-associations/market.xml :language: xml diff --git a/docs/en/tutorials/working-with-indexed-associations/Market-annotations.php b/docs/en/tutorials/working-with-indexed-associations/Market-annotations.php deleted file mode 100644 index 798b49d1d02..00000000000 --- a/docs/en/tutorials/working-with-indexed-associations/Market-annotations.php +++ /dev/null @@ -1,74 +0,0 @@ - - */ - private Collection $stocks; - - public function __construct($name) - { - $this->name = $name; - $this->stocks = new ArrayCollection(); - } - - public function getId(): int|null - { - return $this->id; - } - - public function getName(): string - { - return $this->name; - } - - public function addStock(Stock $stock): void - { - $this->stocks[$stock->getSymbol()] = $stock; - } - - public function getStock($symbol): Stock - { - if (!isset($this->stocks[$symbol])) { - throw new InvalidArgumentException("Symbol is not traded on this market."); - } - - return $this->stocks[$symbol]; - } - - /** @return array */ - public function getStocks(): array - { - return $this->stocks->toArray(); - } -}