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

namespace Google\Cloud\Dlp\V2;

use Google\Protobuf\Internal\GPBType;
use Google\Protobuf\Internal\RepeatedField;
use Google\Protobuf\Internal\GPBUtil;

/**
 * Privacy metric to compute for reidentification risk analysis.
 *
 * Generated from protobuf message <code>google.privacy.dlp.v2.PrivacyMetric</code>
 */
class PrivacyMetric extends \Google\Protobuf\Internal\Message
{
    protected $type;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\Dlp\V2\PrivacyMetric\NumericalStatsConfig $numerical_stats_config
     *     @type \Google\Cloud\Dlp\V2\PrivacyMetric\CategoricalStatsConfig $categorical_stats_config
     *     @type \Google\Cloud\Dlp\V2\PrivacyMetric\KAnonymityConfig $k_anonymity_config
     *     @type \Google\Cloud\Dlp\V2\PrivacyMetric\LDiversityConfig $l_diversity_config
     *     @type \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig $k_map_estimation_config
     *     @type \Google\Cloud\Dlp\V2\PrivacyMetric\DeltaPresenceEstimationConfig $delta_presence_estimation_config
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Privacy\Dlp\V2\Dlp::initOnce();
        parent::__construct($data);
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
     * @return \Google\Cloud\Dlp\V2\PrivacyMetric\NumericalStatsConfig
     */
    public function getNumericalStatsConfig()
    {
        return $this->readOneof(1);
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
     * @param \Google\Cloud\Dlp\V2\PrivacyMetric\NumericalStatsConfig $var
     * @return $this
     */
    public function setNumericalStatsConfig($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric_NumericalStatsConfig::class);
        $this->writeOneof(1, $var);

        return $this;
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
     * @return \Google\Cloud\Dlp\V2\PrivacyMetric\CategoricalStatsConfig
     */
    public function getCategoricalStatsConfig()
    {
        return $this->readOneof(2);
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
     * @param \Google\Cloud\Dlp\V2\PrivacyMetric\CategoricalStatsConfig $var
     * @return $this
     */
    public function setCategoricalStatsConfig($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric_CategoricalStatsConfig::class);
        $this->writeOneof(2, $var);

        return $this;
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
     * @return \Google\Cloud\Dlp\V2\PrivacyMetric\KAnonymityConfig
     */
    public function getKAnonymityConfig()
    {
        return $this->readOneof(3);
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
     * @param \Google\Cloud\Dlp\V2\PrivacyMetric\KAnonymityConfig $var
     * @return $this
     */
    public function setKAnonymityConfig($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric_KAnonymityConfig::class);
        $this->writeOneof(3, $var);

        return $this;
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
     * @return \Google\Cloud\Dlp\V2\PrivacyMetric\LDiversityConfig
     */
    public function getLDiversityConfig()
    {
        return $this->readOneof(4);
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
     * @param \Google\Cloud\Dlp\V2\PrivacyMetric\LDiversityConfig $var
     * @return $this
     */
    public function setLDiversityConfig($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric_LDiversityConfig::class);
        $this->writeOneof(4, $var);

        return $this;
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig k_map_estimation_config = 5;</code>
     * @return \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig
     */
    public function getKMapEstimationConfig()
    {
        return $this->readOneof(5);
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.KMapEstimationConfig k_map_estimation_config = 5;</code>
     * @param \Google\Cloud\Dlp\V2\PrivacyMetric\KMapEstimationConfig $var
     * @return $this
     */
    public function setKMapEstimationConfig($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric_KMapEstimationConfig::class);
        $this->writeOneof(5, $var);

        return $this;
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.DeltaPresenceEstimationConfig delta_presence_estimation_config = 6;</code>
     * @return \Google\Cloud\Dlp\V2\PrivacyMetric\DeltaPresenceEstimationConfig
     */
    public function getDeltaPresenceEstimationConfig()
    {
        return $this->readOneof(6);
    }

    /**
     * Generated from protobuf field <code>.google.privacy.dlp.v2.PrivacyMetric.DeltaPresenceEstimationConfig delta_presence_estimation_config = 6;</code>
     * @param \Google\Cloud\Dlp\V2\PrivacyMetric\DeltaPresenceEstimationConfig $var
     * @return $this
     */
    public function setDeltaPresenceEstimationConfig($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dlp\V2\PrivacyMetric_DeltaPresenceEstimationConfig::class);
        $this->writeOneof(6, $var);

        return $this;
    }

    /**
     * @return string
     */
    public function getType()
    {
        return $this->whichOneof("type");
    }

}

