<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/privacy/dlp/v2/dlp.proto

namespace Google\Cloud\Dlp\V2\OutputStorageConfig;

use UnexpectedValueException;

/**
 * Predefined schemas for storing findings.
 *
 * Protobuf type <code>google.privacy.dlp.v2.OutputStorageConfig.OutputSchema</code>
 */
class OutputSchema
{
    /**
     * Generated from protobuf enum <code>OUTPUT_SCHEMA_UNSPECIFIED = 0;</code>
     */
    const OUTPUT_SCHEMA_UNSPECIFIED = 0;
    /**
     * Basic schema including only `info_type`, `quote`, `certainty`, and
     * `timestamp`.
     *
     * Generated from protobuf enum <code>BASIC_COLUMNS = 1;</code>
     */
    const BASIC_COLUMNS = 1;
    /**
     * Schema tailored to findings from scanning Google Cloud Storage.
     *
     * Generated from protobuf enum <code>GCS_COLUMNS = 2;</code>
     */
    const GCS_COLUMNS = 2;
    /**
     * Schema tailored to findings from scanning Google Datastore.
     *
     * Generated from protobuf enum <code>DATASTORE_COLUMNS = 3;</code>
     */
    const DATASTORE_COLUMNS = 3;
    /**
     * Schema tailored to findings from scanning Google BigQuery.
     *
     * Generated from protobuf enum <code>BIG_QUERY_COLUMNS = 4;</code>
     */
    const BIG_QUERY_COLUMNS = 4;
    /**
     * Schema containing all columns.
     *
     * Generated from protobuf enum <code>ALL_COLUMNS = 5;</code>
     */
    const ALL_COLUMNS = 5;

    private static $valueToName = [
        self::OUTPUT_SCHEMA_UNSPECIFIED => 'OUTPUT_SCHEMA_UNSPECIFIED',
        self::BASIC_COLUMNS => 'BASIC_COLUMNS',
        self::GCS_COLUMNS => 'GCS_COLUMNS',
        self::DATASTORE_COLUMNS => 'DATASTORE_COLUMNS',
        self::BIG_QUERY_COLUMNS => 'BIG_QUERY_COLUMNS',
        self::ALL_COLUMNS => 'ALL_COLUMNS',
    ];

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

// Adding a class alias for backwards compatibility with the previous class name.
class_alias(OutputSchema::class, \Google\Cloud\Dlp\V2\OutputStorageConfig_OutputSchema::class);

