'Ferienwohnung', self::SportsClub => 'Sportclub', self::Apartment => 'Apartment', self::GuestHouse => 'Gästehaus', self::Pension => 'Pension', }; } public static function fromLabel(string $label): ?self { foreach (self::cases() as $case) { if (0 === strcasecmp($case->label(), trim($label))) { return $case; } } return null; } }