<?php

declare (strict_types=1);
namespace idoit\Module\SyneticsJdisc\Graphql\Schema\Model;

use Axtiva\FlexibleGraphql\Generator\Exception\UnknownEnumValue;
use Axtiva\FlexibleGraphql\Type\EnumInterface;

/**
 * This code is @generated by axtiva/flexible-graphql-php
 * and will be regenerated. Do not edit it manually
 * PHP representation of graphql enum FieldWidthEnum
 * Enumeration for field widths in the UI
 */
final class FieldWidthEnumEnum implements EnumInterface
{
    public const checkbox = 'checkbox';
    public const ip4Address = 'ip4Address';
    public const timestamp = 'timestamp';
    public const tiny = 'tiny';
    public const verySmall = 'verySmall';
    public const small = 'small';
    public const deviceType = 'deviceType';
    public const medium = 'medium';
    public const large = 'large';
    public const veryLarge = 'veryLarge';
    public const incrediblyLarge = 'incrediblyLarge';
    public const ipAddress = 'ipAddress';
    public const ip6Address = 'ip6Address';
    public const ip6NetworkPrefix = 'ip6NetworkPrefix';
    public string $value;
    private static array $map = [
        self::checkbox => true,
        self::ip4Address => true,
        self::timestamp => true,
        self::tiny => true,
        self::verySmall => true,
        self::small => true,
        self::deviceType => true,
        self::medium => true,
        self::large => true,
        self::veryLarge => true,
        self::incrediblyLarge => true,
        self::ipAddress => true,
        self::ip6Address => true,
        self::ip6NetworkPrefix => true,
    ];

    public function __construct($value)
    {
        if (!isset(self::$map[$value])) {
            throw new UnknownEnumValue(__CLASS__, $value);
        }
        $this->value = $value;
    }

    public function __toString(): string
    {
        return $this->value;
    }
}