feature = $feature; return $this; } /** * Get the feature that is to be enabled or disabled * * @return string */ public function getFeature(): string { if ($this->feature === null) { throw new \LogicException( 'You are accessing an unset property. Please make sure to set it beforehand.' ); } return $this->feature; } /** * Set whether the feature should be enabled or disabled * * @param bool $enabled * * @return $this */ public function setEnabled(bool $enabled = true): self { $this->enabled = $enabled; return $this; } /** * Get whether the feature should be enabled or disabled * * @return ?bool */ public function getEnabled() { return $this->enabled; } }