<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/compute/v1/compute.proto

namespace Google\Cloud\Compute\V1\TargetHttpsProxy;

use UnexpectedValueException;

/**
 * Specifies the QUIC override policy for this TargetHttpsProxy resource. This setting determines whether the load balancer attempts to negotiate QUIC with clients. You can specify NONE, ENABLE, or DISABLE. - When quic-override is set to NONE, Google manages whether QUIC is used. - When quic-override is set to ENABLE, the load balancer uses QUIC when possible. - When quic-override is set to DISABLE, the load balancer doesn't use QUIC. - If the quic-override flag is not specified, NONE is implied. 
 *
 * Protobuf type <code>google.cloud.compute.v1.TargetHttpsProxy.QuicOverride</code>
 */
class QuicOverride
{
    /**
     * A value indicating that the enum field is not set.
     *
     * Generated from protobuf enum <code>UNDEFINED_QUIC_OVERRIDE = 0;</code>
     */
    const UNDEFINED_QUIC_OVERRIDE = 0;
    /**
     * The load balancer will not attempt to negotiate QUIC with clients.
     *
     * Generated from protobuf enum <code>DISABLE = 241807048;</code>
     */
    const DISABLE = 241807048;
    /**
     * The load balancer will attempt to negotiate QUIC with clients.
     *
     * Generated from protobuf enum <code>ENABLE = 438835587;</code>
     */
    const ENABLE = 438835587;
    /**
     * No overrides to the default QUIC policy. This option is implicit if no QUIC override has been specified in the request.
     *
     * Generated from protobuf enum <code>NONE = 2402104;</code>
     */
    const NONE = 2402104;

    private static $valueToName = [
        self::UNDEFINED_QUIC_OVERRIDE => 'UNDEFINED_QUIC_OVERRIDE',
        self::DISABLE => 'DISABLE',
        self::ENABLE => 'ENABLE',
        self::NONE => 'NONE',
    ];

    public static function name($value)
    {
        if (!isset(self::$valueToName[$value])) {
            throw new UnexpectedValueException(sprintf(
                    'Enum %s has no name defined for value %s', __CLASS__, $value));
        }
        return self::$valueToName[$value];
    }


    public static function value($name)
    {
        $const = __CLASS__ . '::' . strtoupper($name);
        if (!defined($const)) {
            throw new UnexpectedValueException(sprintf(
                    'Enum %s has no value defined for name %s', __CLASS__, $name));
        }
        return constant($const);
    }
}


