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

namespace Google\Cloud\Talent\V4beta1;

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

/**
 * Input only.
 * Filter on job compensation type and amount.
 *
 * Generated from protobuf message <code>google.cloud.talent.v4beta1.CompensationFilter</code>
 */
class CompensationFilter extends \Google\Protobuf\Internal\Message
{
    /**
     * Required.
     * Type of filter.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.CompensationFilter.FilterType type = 1;</code>
     */
    private $type = 0;
    /**
     * Required.
     * Specify desired `base compensation entry's`
     * [CompensationInfo.CompensationUnit][google.cloud.talent.v4beta1.CompensationInfo.CompensationUnit].
     *
     * Generated from protobuf field <code>repeated .google.cloud.talent.v4beta1.CompensationInfo.CompensationUnit units = 2;</code>
     */
    private $units;
    /**
     * Optional.
     * Compensation range.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.CompensationInfo.CompensationRange range = 3;</code>
     */
    private $range = null;
    /**
     * Optional.
     * Whether to include jobs whose compensation range is unspecified.
     *
     * Generated from protobuf field <code>bool include_jobs_with_unspecified_compensation_range = 4;</code>
     */
    private $include_jobs_with_unspecified_compensation_range = false;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type int $type
     *           Required.
     *           Type of filter.
     *     @type int[]|\Google\Protobuf\Internal\RepeatedField $units
     *           Required.
     *           Specify desired `base compensation entry's`
     *           [CompensationInfo.CompensationUnit][google.cloud.talent.v4beta1.CompensationInfo.CompensationUnit].
     *     @type \Google\Cloud\Talent\V4beta1\CompensationInfo\CompensationRange $range
     *           Optional.
     *           Compensation range.
     *     @type bool $include_jobs_with_unspecified_compensation_range
     *           Optional.
     *           Whether to include jobs whose compensation range is unspecified.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Talent\V4Beta1\Filters::initOnce();
        parent::__construct($data);
    }

    /**
     * Required.
     * Type of filter.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.CompensationFilter.FilterType type = 1;</code>
     * @return int
     */
    public function getType()
    {
        return $this->type;
    }

    /**
     * Required.
     * Type of filter.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.CompensationFilter.FilterType type = 1;</code>
     * @param int $var
     * @return $this
     */
    public function setType($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\Talent\V4beta1\CompensationFilter_FilterType::class);
        $this->type = $var;

        return $this;
    }

    /**
     * Required.
     * Specify desired `base compensation entry's`
     * [CompensationInfo.CompensationUnit][google.cloud.talent.v4beta1.CompensationInfo.CompensationUnit].
     *
     * Generated from protobuf field <code>repeated .google.cloud.talent.v4beta1.CompensationInfo.CompensationUnit units = 2;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getUnits()
    {
        return $this->units;
    }

    /**
     * Required.
     * Specify desired `base compensation entry's`
     * [CompensationInfo.CompensationUnit][google.cloud.talent.v4beta1.CompensationInfo.CompensationUnit].
     *
     * Generated from protobuf field <code>repeated .google.cloud.talent.v4beta1.CompensationInfo.CompensationUnit units = 2;</code>
     * @param int[]|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setUnits($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Talent\V4beta1\CompensationInfo\CompensationUnit::class);
        $this->units = $arr;

        return $this;
    }

    /**
     * Optional.
     * Compensation range.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.CompensationInfo.CompensationRange range = 3;</code>
     * @return \Google\Cloud\Talent\V4beta1\CompensationInfo\CompensationRange
     */
    public function getRange()
    {
        return $this->range;
    }

    /**
     * Optional.
     * Compensation range.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.CompensationInfo.CompensationRange range = 3;</code>
     * @param \Google\Cloud\Talent\V4beta1\CompensationInfo\CompensationRange $var
     * @return $this
     */
    public function setRange($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Talent\V4beta1\CompensationInfo_CompensationRange::class);
        $this->range = $var;

        return $this;
    }

    /**
     * Optional.
     * Whether to include jobs whose compensation range is unspecified.
     *
     * Generated from protobuf field <code>bool include_jobs_with_unspecified_compensation_range = 4;</code>
     * @return bool
     */
    public function getIncludeJobsWithUnspecifiedCompensationRange()
    {
        return $this->include_jobs_with_unspecified_compensation_range;
    }

    /**
     * Optional.
     * Whether to include jobs whose compensation range is unspecified.
     *
     * Generated from protobuf field <code>bool include_jobs_with_unspecified_compensation_range = 4;</code>
     * @param bool $var
     * @return $this
     */
    public function setIncludeJobsWithUnspecifiedCompensationRange($var)
    {
        GPBUtil::checkBool($var);
        $this->include_jobs_with_unspecified_compensation_range = $var;

        return $this;
    }

}

