jikan-rest/app/Enums/GenderEnum.php
pushrbx 0211fc4128 multiple fixes
- updated api docs
- fixed top reviews endpoint
- fixed reviews parsing
- added "contextual" boolean query string parameters, so params without value can be interpreted as "boolean". E.g. ?sfw or ?kid in the url would add "true" value to their corresponding field in the DTO
- fixed typesense issues
2023-05-21 11:18:02 +01:00

32 lines
803 B
PHP

<?php
namespace App\Enums;
use Jikan\Helper\Constants as JikanConstants;
use Spatie\Enum\Laravel\Enum;
/**
* @method static self any()
* @method static self male()
* @method static self female()
* @method static self nonbinary()
* @OA\Schema(
* schema="users_search_query_gender",
* description="Users Search Query Gender.",
* type="string",
* enum={"any","male","female","nonbinary"}
* )
*/
final class GenderEnum extends Enum
{
protected static function labels(): array
{
return [
'any' => JikanConstants::SEARCH_USER_GENDER_ANY,
'male' => JikanConstants::SEARCH_USER_GENDER_MALE,
'female' => JikanConstants::SEARCH_USER_GENDER_FEMALE,
'nonbinary' => JikanConstants::SEARCH_USER_GENDER_NONBINARY
];
}
}