identifier; } public function setLabel(string $label): self { $this->label = $label; return $this; } public function setIcon(?Icon $icon): self { $this->icon = $icon; return $this; } public function setUrl(string $url): self { $this->url = $url; return $this; } public function jsonSerialize(): array { return [ 'identifier' => $this->identifier, 'label' => $this->label, 'icon' => [ 'identifier' => $this->icon?->getIdentifier(), 'overlay' => $this->icon?->getOverlayIcon()?->getIdentifier(), ], 'url' => $this->url, ]; } }