<?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
{
    /**
     * Optional. The start date of the education.
     *
     * Generated from protobuf field <code>.google.type.Date start_date = 1;</code>
     */
    private $start_date = null;
    /**
     * Optional. The end date of the education.
     *
     * Generated from protobuf field <code>.google.type.Date end_date = 2;</code>
     */
    private $end_date = null;
    /**
     * Optional. 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;
    /**
     * Optional. 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 = '';
    /**
     * Optional. The physical address of the education institution.
     *
     * Generated from protobuf field <code>.google.cloud.talent.v4beta1.Address address = 5;</code>
     */
    private $address = null;
    /**
     * Optional. The description of the education.
     * Number of characters allowed is 100,000.
     *
     * Generated from protobuf field <code>string description = 8;</code>
     */
    private $description = '';
    /**
     * Optional. 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;</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;</code>
     */
    private $degree_snippet = '';
    protected $degree;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Type\Date $start_date
     *           Optional. The start date of the education.
     *     @type \Google\Type\Date $end_date
     *           Optional. The end date of the education.
     *     @type \Google\Type\Date $expected_graduation_date
     *           Optional. The expected graduation date if currently pursuing a degree.
     *     @type string $school_name
     *           Optional. 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
     *           Optional. The physical address of the education institution.
     *     @type string $degree_description
     *           Optional. 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
     *           Optional. The structured notation of the degree.
     *     @type string $description
     *           Optional. The description of the education.
     *           Number of characters allowed is 100,000.
     *     @type \Google\Protobuf\BoolValue $is_current
     *           Optional. 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);
    }

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

    /**
     * Optional. 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;
    }

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

    /**
     * Optional. 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;
    }

    /**
     * Optional. 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
     */
    public function getExpectedGraduationDate()
    {
        return $this->expected_graduation_date;
    }

    /**
     * Optional. 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;
    }

    /**
     * Optional. 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;
    }

    /**
     * Optional. 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;
    }

    /**
     * Optional. 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
     */
    public function getAddress()
    {
        return $this->address;
    }

    /**
     * Optional. 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;
    }

    /**
     * Optional. 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);
    }

    /**
     * Optional. 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;
    }

    /**
     * Optional. 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
     */
    public function getStructuredDegree()
    {
        return $this->readOneof(7);
    }

    /**
     * Optional. 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;
    }

    /**
     * Optional. 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;
    }

    /**
     * Optional. 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;
    }

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

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

     * Optional. If this education is current.
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue is_current = 9;</code>
     * @return bool|null
     */
    public function getIsCurrentValue()
    {
        $wrapper = $this->getIsCurrent();
        return is_null($wrapper) ? null : $wrapper->getValue();
    }

    /**
     * Optional. 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.

     * Optional. 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)
    {
        $wrappedVar = is_null($var) ? null : new \Google\Protobuf\BoolValue(['value' => $var]);
        return $this->setIsCurrent($wrappedVar);
    }

    /**
     * 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;</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;</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;</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;</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");
    }

}

