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

namespace Google\Cloud\Talent\V4beta1;

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

/**
 * Resource that represents an education record of a candidate.
 *
 * Generated from protobuf message <code>google.cloud.talent.v4beta1.EducationRecord</code>
 */
class EducationRecord extends \Google\Protobuf\Internal\Message
{
    /**
     * The start date of the education.
     *
     * Generated from protobuf field <code>.google.type.Date start_date = 1;</code>
     */
    private $start_date = null;
    /**
     * The end date of the education.
     *
     * Generated from protobuf field <code>.google.type.Date end_date = 2;</code>
     */
    private $end_date = null;
    /**
     * The expected graduation date if currently pursuing a degree.
     *
     * Generated from protobuf field <code>.google.type.Date expected_graduation_date = 3;</code>
     */
    private $expected_graduation_date = null;
    /**
     * The name of the school or institution.
     * For example, "Stanford University", "UC Berkeley", and so on.
     * Number of characters allowed is 250.
     *
     * Generated from protobuf field <code>string school_name = 4;</code>
     */
    private $school_name = '';
    /**
     * The physical address of the education institution.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.Address address = 5;</code>
     */
    private $address = null;
    /**
     * The description of the education.
     * Number of characters allowed is 100,000.
     *
     * Generated from protobuf field <code>string description = 8;</code>
     */
    private $description = '';
    /**
     * If this education is current.
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue is_current = 9;</code>
     */
    private $is_current = null;
    /**
     * Output only. The school name snippet shows how the [school_name][google.cloud.talent.v4beta1.EducationRecord.school_name] is related to a
     * search query in search result. It's empty if the [school_name][google.cloud.talent.v4beta1.EducationRecord.school_name] isn't
     * related to the search query.
     *
     * Generated from protobuf field <code>string school_name_snippet = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    private $school_name_snippet = '';
    /**
     * Output only. The job description snippet shows how the [Degree][google.cloud.talent.v4beta1.Degree] is related to a search
     * query in search result. It's empty if the [Degree][google.cloud.talent.v4beta1.Degree] isn't related to the
     * search query.
     *
     * Generated from protobuf field <code>string degree_snippet = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    private $degree_snippet = '';
    protected $degree;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Type\Date $start_date
     *           The start date of the education.
     *     @type \Google\Type\Date $end_date
     *           The end date of the education.
     *     @type \Google\Type\Date $expected_graduation_date
     *           The expected graduation date if currently pursuing a degree.
     *     @type string $school_name
     *           The name of the school or institution.
     *           For example, "Stanford University", "UC Berkeley", and so on.
     *           Number of characters allowed is 250.
     *     @type \Google\Cloud\Talent\V4beta1\Address $address
     *           The physical address of the education institution.
     *     @type string $degree_description
     *           The full description of the degree.
     *           For example, "Master of Science in Computer Science", "B.S in Math".
     *           Number of characters allowed is 100.
     *     @type \Google\Cloud\Talent\V4beta1\Degree $structured_degree
     *           The structured notation of the degree.
     *     @type string $description
     *           The description of the education.
     *           Number of characters allowed is 100,000.
     *     @type \Google\Protobuf\BoolValue $is_current
     *           If this education is current.
     *     @type string $school_name_snippet
     *           Output only. The school name snippet shows how the [school_name][google.cloud.talent.v4beta1.EducationRecord.school_name] is related to a
     *           search query in search result. It's empty if the [school_name][google.cloud.talent.v4beta1.EducationRecord.school_name] isn't
     *           related to the search query.
     *     @type string $degree_snippet
     *           Output only. The job description snippet shows how the [Degree][google.cloud.talent.v4beta1.Degree] is related to a search
     *           query in search result. It's empty if the [Degree][google.cloud.talent.v4beta1.Degree] isn't related to the
     *           search query.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Talent\V4Beta1\Profile::initOnce();
        parent::__construct($data);
    }

    /**
     * The start date of the education.
     *
     * Generated from protobuf field <code>.google.type.Date start_date = 1;</code>
     * @return \Google\Type\Date|null
     */
    public function getStartDate()
    {
        return isset($this->start_date) ? $this->start_date : null;
    }

    public function hasStartDate()
    {
        return isset($this->start_date);
    }

    public function clearStartDate()
    {
        unset($this->start_date);
    }

    /**
     * The start date of the education.
     *
     * Generated from protobuf field <code>.google.type.Date start_date = 1;</code>
     * @param \Google\Type\Date $var
     * @return $this
     */
    public function setStartDate($var)
    {
        GPBUtil::checkMessage($var, \Google\Type\Date::class);
        $this->start_date = $var;

        return $this;
    }

    /**
     * The end date of the education.
     *
     * Generated from protobuf field <code>.google.type.Date end_date = 2;</code>
     * @return \Google\Type\Date|null
     */
    public function getEndDate()
    {
        return isset($this->end_date) ? $this->end_date : null;
    }

    public function hasEndDate()
    {
        return isset($this->end_date);
    }

    public function clearEndDate()
    {
        unset($this->end_date);
    }

    /**
     * The end date of the education.
     *
     * Generated from protobuf field <code>.google.type.Date end_date = 2;</code>
     * @param \Google\Type\Date $var
     * @return $this
     */
    public function setEndDate($var)
    {
        GPBUtil::checkMessage($var, \Google\Type\Date::class);
        $this->end_date = $var;

        return $this;
    }

    /**
     * The expected graduation date if currently pursuing a degree.
     *
     * Generated from protobuf field <code>.google.type.Date expected_graduation_date = 3;</code>
     * @return \Google\Type\Date|null
     */
    public function getExpectedGraduationDate()
    {
        return isset($this->expected_graduation_date) ? $this->expected_graduation_date : null;
    }

    public function hasExpectedGraduationDate()
    {
        return isset($this->expected_graduation_date);
    }

    public function clearExpectedGraduationDate()
    {
        unset($this->expected_graduation_date);
    }

    /**
     * The expected graduation date if currently pursuing a degree.
     *
     * Generated from protobuf field <code>.google.type.Date expected_graduation_date = 3;</code>
     * @param \Google\Type\Date $var
     * @return $this
     */
    public function setExpectedGraduationDate($var)
    {
        GPBUtil::checkMessage($var, \Google\Type\Date::class);
        $this->expected_graduation_date = $var;

        return $this;
    }

    /**
     * The name of the school or institution.
     * For example, "Stanford University", "UC Berkeley", and so on.
     * Number of characters allowed is 250.
     *
     * Generated from protobuf field <code>string school_name = 4;</code>
     * @return string
     */
    public function getSchoolName()
    {
        return $this->school_name;
    }

    /**
     * The name of the school or institution.
     * For example, "Stanford University", "UC Berkeley", and so on.
     * Number of characters allowed is 250.
     *
     * Generated from protobuf field <code>string school_name = 4;</code>
     * @param string $var
     * @return $this
     */
    public function setSchoolName($var)
    {
        GPBUtil::checkString($var, True);
        $this->school_name = $var;

        return $this;
    }

    /**
     * The physical address of the education institution.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.Address address = 5;</code>
     * @return \Google\Cloud\Talent\V4beta1\Address|null
     */
    public function getAddress()
    {
        return isset($this->address) ? $this->address : null;
    }

    public function hasAddress()
    {
        return isset($this->address);
    }

    public function clearAddress()
    {
        unset($this->address);
    }

    /**
     * The physical address of the education institution.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.Address address = 5;</code>
     * @param \Google\Cloud\Talent\V4beta1\Address $var
     * @return $this
     */
    public function setAddress($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Talent\V4beta1\Address::class);
        $this->address = $var;

        return $this;
    }

    /**
     * The full description of the degree.
     * For example, "Master of Science in Computer Science", "B.S in Math".
     * Number of characters allowed is 100.
     *
     * Generated from protobuf field <code>string degree_description = 6;</code>
     * @return string
     */
    public function getDegreeDescription()
    {
        return $this->readOneof(6);
    }

    public function hasDegreeDescription()
    {
        return $this->hasOneof(6);
    }

    /**
     * The full description of the degree.
     * For example, "Master of Science in Computer Science", "B.S in Math".
     * Number of characters allowed is 100.
     *
     * Generated from protobuf field <code>string degree_description = 6;</code>
     * @param string $var
     * @return $this
     */
    public function setDegreeDescription($var)
    {
        GPBUtil::checkString($var, True);
        $this->writeOneof(6, $var);

        return $this;
    }

    /**
     * The structured notation of the degree.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.Degree structured_degree = 7;</code>
     * @return \Google\Cloud\Talent\V4beta1\Degree|null
     */
    public function getStructuredDegree()
    {
        return $this->readOneof(7);
    }

    public function hasStructuredDegree()
    {
        return $this->hasOneof(7);
    }

    /**
     * The structured notation of the degree.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.Degree structured_degree = 7;</code>
     * @param \Google\Cloud\Talent\V4beta1\Degree $var
     * @return $this
     */
    public function setStructuredDegree($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Talent\V4beta1\Degree::class);
        $this->writeOneof(7, $var);

        return $this;
    }

    /**
     * The description of the education.
     * Number of characters allowed is 100,000.
     *
     * Generated from protobuf field <code>string description = 8;</code>
     * @return string
     */
    public function getDescription()
    {
        return $this->description;
    }

    /**
     * The description of the education.
     * Number of characters allowed is 100,000.
     *
     * Generated from protobuf field <code>string description = 8;</code>
     * @param string $var
     * @return $this
     */
    public function setDescription($var)
    {
        GPBUtil::checkString($var, True);
        $this->description = $var;

        return $this;
    }

    /**
     * If this education is current.
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue is_current = 9;</code>
     * @return \Google\Protobuf\BoolValue|null
     */
    public function getIsCurrent()
    {
        return isset($this->is_current) ? $this->is_current : null;
    }

    public function hasIsCurrent()
    {
        return isset($this->is_current);
    }

    public function clearIsCurrent()
    {
        unset($this->is_current);
    }

    /**
     * Returns the unboxed value from <code>getIsCurrent()</code>

     * If this education is current.
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue is_current = 9;</code>
     * @return bool|null
     */
    public function getIsCurrentValue()
    {
        return $this->readWrapperValue("is_current");
    }

    /**
     * If this education is current.
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue is_current = 9;</code>
     * @param \Google\Protobuf\BoolValue $var
     * @return $this
     */
    public function setIsCurrent($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\BoolValue::class);
        $this->is_current = $var;

        return $this;
    }

    /**
     * Sets the field by wrapping a primitive type in a Google\Protobuf\BoolValue object.

     * If this education is current.
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue is_current = 9;</code>
     * @param bool|null $var
     * @return $this
     */
    public function setIsCurrentValue($var)
    {
        $this->writeWrapperValue("is_current", $var);
        return $this;}

    /**
     * Output only. The school name snippet shows how the [school_name][google.cloud.talent.v4beta1.EducationRecord.school_name] is related to a
     * search query in search result. It's empty if the [school_name][google.cloud.talent.v4beta1.EducationRecord.school_name] isn't
     * related to the search query.
     *
     * Generated from protobuf field <code>string school_name_snippet = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getSchoolNameSnippet()
    {
        return $this->school_name_snippet;
    }

    /**
     * Output only. The school name snippet shows how the [school_name][google.cloud.talent.v4beta1.EducationRecord.school_name] is related to a
     * search query in search result. It's empty if the [school_name][google.cloud.talent.v4beta1.EducationRecord.school_name] isn't
     * related to the search query.
     *
     * Generated from protobuf field <code>string school_name_snippet = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setSchoolNameSnippet($var)
    {
        GPBUtil::checkString($var, True);
        $this->school_name_snippet = $var;

        return $this;
    }

    /**
     * Output only. The job description snippet shows how the [Degree][google.cloud.talent.v4beta1.Degree] is related to a search
     * query in search result. It's empty if the [Degree][google.cloud.talent.v4beta1.Degree] isn't related to the
     * search query.
     *
     * Generated from protobuf field <code>string degree_snippet = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getDegreeSnippet()
    {
        return $this->degree_snippet;
    }

    /**
     * Output only. The job description snippet shows how the [Degree][google.cloud.talent.v4beta1.Degree] is related to a search
     * query in search result. It's empty if the [Degree][google.cloud.talent.v4beta1.Degree] isn't related to the
     * search query.
     *
     * Generated from protobuf field <code>string degree_snippet = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setDegreeSnippet($var)
    {
        GPBUtil::checkString($var, True);
        $this->degree_snippet = $var;

        return $this;
    }

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

}

