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

namespace Google\Cloud\NetworkManagement\V1\DeliverInfo;

use UnexpectedValueException;

/**
 * Deliver target types:
 *
 * Protobuf type <code>google.cloud.networkmanagement.v1.DeliverInfo.Target</code>
 */
class Target
{
    /**
     * Target not specified.
     *
     * Generated from protobuf enum <code>TARGET_UNSPECIFIED = 0;</code>
     */
    const TARGET_UNSPECIFIED = 0;
    /**
     * Target is a Compute Engine instance.
     *
     * Generated from protobuf enum <code>INSTANCE = 1;</code>
     */
    const INSTANCE = 1;
    /**
     * Target is the internet.
     *
     * Generated from protobuf enum <code>INTERNET = 2;</code>
     */
    const INTERNET = 2;
    /**
     * Target is a Google API.
     *
     * Generated from protobuf enum <code>GOOGLE_API = 3;</code>
     */
    const GOOGLE_API = 3;
    /**
     * Target is a Google Kubernetes Engine cluster master.
     *
     * Generated from protobuf enum <code>GKE_MASTER = 4;</code>
     */
    const GKE_MASTER = 4;
    /**
     * Target is a Cloud SQL instance.
     *
     * Generated from protobuf enum <code>CLOUD_SQL_INSTANCE = 5;</code>
     */
    const CLOUD_SQL_INSTANCE = 5;
    /**
     * Target is a published service that uses [Private Service
     * Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-services).
     *
     * Generated from protobuf enum <code>PSC_PUBLISHED_SERVICE = 6;</code>
     */
    const PSC_PUBLISHED_SERVICE = 6;
    /**
     * Target is all Google APIs that use [Private Service
     * Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-apis).
     *
     * Generated from protobuf enum <code>PSC_GOOGLE_API = 7;</code>
     */
    const PSC_GOOGLE_API = 7;
    /**
     * Target is a VPC-SC that uses [Private Service
     * Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-apis).
     *
     * Generated from protobuf enum <code>PSC_VPC_SC = 8;</code>
     */
    const PSC_VPC_SC = 8;
    /**
     * Target is a serverless network endpoint group.
     *
     * Generated from protobuf enum <code>SERVERLESS_NEG = 9;</code>
     */
    const SERVERLESS_NEG = 9;
    /**
     * Target is a Cloud Storage bucket.
     *
     * Generated from protobuf enum <code>STORAGE_BUCKET = 10;</code>
     */
    const STORAGE_BUCKET = 10;
    /**
     * Target is a private network. Used only for return traces.
     *
     * Generated from protobuf enum <code>PRIVATE_NETWORK = 11;</code>
     */
    const PRIVATE_NETWORK = 11;
    /**
     * Target is a Cloud Function. Used only for return traces.
     *
     * Generated from protobuf enum <code>CLOUD_FUNCTION = 12;</code>
     */
    const CLOUD_FUNCTION = 12;
    /**
     * Target is a App Engine service version. Used only for return traces.
     *
     * Generated from protobuf enum <code>APP_ENGINE_VERSION = 13;</code>
     */
    const APP_ENGINE_VERSION = 13;
    /**
     * Target is a Cloud Run revision. Used only for return traces.
     *
     * Generated from protobuf enum <code>CLOUD_RUN_REVISION = 14;</code>
     */
    const CLOUD_RUN_REVISION = 14;

    private static $valueToName = [
        self::TARGET_UNSPECIFIED => 'TARGET_UNSPECIFIED',
        self::INSTANCE => 'INSTANCE',
        self::INTERNET => 'INTERNET',
        self::GOOGLE_API => 'GOOGLE_API',
        self::GKE_MASTER => 'GKE_MASTER',
        self::CLOUD_SQL_INSTANCE => 'CLOUD_SQL_INSTANCE',
        self::PSC_PUBLISHED_SERVICE => 'PSC_PUBLISHED_SERVICE',
        self::PSC_GOOGLE_API => 'PSC_GOOGLE_API',
        self::PSC_VPC_SC => 'PSC_VPC_SC',
        self::SERVERLESS_NEG => 'SERVERLESS_NEG',
        self::STORAGE_BUCKET => 'STORAGE_BUCKET',
        self::PRIVATE_NETWORK => 'PRIVATE_NETWORK',
        self::CLOUD_FUNCTION => 'CLOUD_FUNCTION',
        self::APP_ENGINE_VERSION => 'APP_ENGINE_VERSION',
        self::CLOUD_RUN_REVISION => 'CLOUD_RUN_REVISION',
    ];

    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);
    }
}


