<?php

declare (strict_types=1);
namespace idoit\Module\JDisc\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 InterfaceStatus
 * The network interface status.
 */
final class InterfaceStatusEnum implements EnumInterface
{
    public const Up = 'Up';
    public const Down = 'Down';
    public const Testing = 'Testing';
    public const Unknown = 'Unknown';
    public const Dormant = 'Dormant';
    public const NotPresent = 'NotPresent';
    public const LowerLayerDown = 'LowerLayerDown';
    public const NonOperational = 'NonOperational';
    public const Unreachable = 'Unreachable';
    public const Disconnected = 'Disconnected';
    public const Connecting = 'Connecting';
    public const Connected = 'Connected';
    public const Operational = 'Operational';
    public const Initialize = 'Initialize';
    public const Backup = 'Backup';
    public const Bypassed = 'Bypassed';
    public const Diagnostics = 'Diagnostics';
    public const NotConfigured = 'NotConfigured';
    public const Paused = 'Paused';
    public const Failure = 'Failure';
    public string $value;
    private static array $map = [
        self::Up => true,
        self::Down => true,
        self::Testing => true,
        self::Unknown => true,
        self::Dormant => true,
        self::NotPresent => true,
        self::LowerLayerDown => true,
        self::NonOperational => true,
        self::Unreachable => true,
        self::Disconnected => true,
        self::Connecting => true,
        self::Connected => true,
        self::Operational => true,
        self::Initialize => true,
        self::Backup => true,
        self::Bypassed => true,
        self::Diagnostics => true,
        self::NotConfigured => true,
        self::Paused => true,
        self::Failure => 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;
    }
}