<?php

# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/analytics/data/v1beta/data.proto
namespace Matomo\Dependencies\GoogleAnalyticsImporter\Google\Analytics\Data\V1beta;

use Matomo\Dependencies\GoogleAnalyticsImporter\Google\Protobuf\Internal\GPBType;
use Matomo\Dependencies\GoogleAnalyticsImporter\Google\Protobuf\Internal\RepeatedField;
use Matomo\Dependencies\GoogleAnalyticsImporter\Google\Protobuf\Internal\GPBUtil;
/**
 * Used to express a dimension which is the result of a formula of multiple
 * dimensions. Example usages:
 * 1) lower_case(dimension)
 * 2) concatenate(dimension1, symbol, dimension2).
 *
 * Generated from protobuf message <code>google.analytics.data.v1beta.DimensionExpression</code>
 */
class DimensionExpression extends \Matomo\Dependencies\GoogleAnalyticsImporter\Google\Protobuf\Internal\Message
{
    protected $one_expression;
    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $lower_case
     *           Used to convert a dimension value to lower case.
     *     @type \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $upper_case
     *           Used to convert a dimension value to upper case.
     *     @type \Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression $concatenate
     *           Used to combine dimension values to a single dimension.
     *           For example, dimension "country, city": concatenate(country, ", ", city).
     * }
     */
    public function __construct($data = NULL)
    {
        \Matomo\Dependencies\GoogleAnalyticsImporter\GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce();
        parent::__construct($data);
    }
    /**
     * Used to convert a dimension value to lower case.
     *
     * Generated from protobuf field <code>.google.analytics.data.v1beta.DimensionExpression.CaseExpression lower_case = 4;</code>
     * @return \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression|null
     */
    public function getLowerCase()
    {
        return $this->readOneof(4);
    }
    public function hasLowerCase()
    {
        return $this->hasOneof(4);
    }
    /**
     * Used to convert a dimension value to lower case.
     *
     * Generated from protobuf field <code>.google.analytics.data.v1beta.DimensionExpression.CaseExpression lower_case = 4;</code>
     * @param \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $var
     * @return $this
     */
    public function setLowerCase($var)
    {
        GPBUtil::checkMessage($var, \Matomo\Dependencies\GoogleAnalyticsImporter\Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression::class);
        $this->writeOneof(4, $var);
        return $this;
    }
    /**
     * Used to convert a dimension value to upper case.
     *
     * Generated from protobuf field <code>.google.analytics.data.v1beta.DimensionExpression.CaseExpression upper_case = 5;</code>
     * @return \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression|null
     */
    public function getUpperCase()
    {
        return $this->readOneof(5);
    }
    public function hasUpperCase()
    {
        return $this->hasOneof(5);
    }
    /**
     * Used to convert a dimension value to upper case.
     *
     * Generated from protobuf field <code>.google.analytics.data.v1beta.DimensionExpression.CaseExpression upper_case = 5;</code>
     * @param \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $var
     * @return $this
     */
    public function setUpperCase($var)
    {
        GPBUtil::checkMessage($var, \Matomo\Dependencies\GoogleAnalyticsImporter\Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression::class);
        $this->writeOneof(5, $var);
        return $this;
    }
    /**
     * Used to combine dimension values to a single dimension.
     * For example, dimension "country, city": concatenate(country, ", ", city).
     *
     * Generated from protobuf field <code>.google.analytics.data.v1beta.DimensionExpression.ConcatenateExpression concatenate = 6;</code>
     * @return \Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression|null
     */
    public function getConcatenate()
    {
        return $this->readOneof(6);
    }
    public function hasConcatenate()
    {
        return $this->hasOneof(6);
    }
    /**
     * Used to combine dimension values to a single dimension.
     * For example, dimension "country, city": concatenate(country, ", ", city).
     *
     * Generated from protobuf field <code>.google.analytics.data.v1beta.DimensionExpression.ConcatenateExpression concatenate = 6;</code>
     * @param \Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression $var
     * @return $this
     */
    public function setConcatenate($var)
    {
        GPBUtil::checkMessage($var, \Matomo\Dependencies\GoogleAnalyticsImporter\Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression::class);
        $this->writeOneof(6, $var);
        return $this;
    }
    /**
     * @return string
     */
    public function getOneExpression()
    {
        return $this->whichOneof("one_expression");
    }
}
