<?php
 
 
 

namespace Google\Protobuf\Internal;

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




class FieldOptions extends \Google\Protobuf\Internal\Message
{
    










    protected $ctype = null;
    










    protected $packed = null;
    













    protected $jstype = null;
    






















    protected $lazy = null;
    






    protected $unverified_lazy = null;
    







    protected $deprecated = null;
    




    protected $weak = null;
    





    protected $debug_redact = null;
    


    protected $retention = null;
    


    private $targets;
    


    private $edition_defaults;
    







    protected $features = null;
    


    protected $feature_support = null;
    




    private $uninterpreted_option;

    















































































    public function __construct($data = NULL) {
        \GPBMetadata\Google\Protobuf\Internal\Descriptor::initOnce();
        parent::__construct($data);
    }

    











    public function getCtype()
    {
        return isset($this->ctype) ? $this->ctype : 0;
    }

    public function hasCtype()
    {
        return isset($this->ctype);
    }

    public function clearCtype()
    {
        unset($this->ctype);
    }

    












    public function setCtype($var)
    {
        GPBUtil::checkEnum($var, \Google\Protobuf\Internal\FieldOptions\CType::class);
        $this->ctype = $var;

        return $this;
    }

    











    public function getPacked()
    {
        return isset($this->packed) ? $this->packed : false;
    }

    public function hasPacked()
    {
        return isset($this->packed);
    }

    public function clearPacked()
    {
        unset($this->packed);
    }

    












    public function setPacked($var)
    {
        GPBUtil::checkBool($var);
        $this->packed = $var;

        return $this;
    }

    














    public function getJstype()
    {
        return isset($this->jstype) ? $this->jstype : 0;
    }

    public function hasJstype()
    {
        return isset($this->jstype);
    }

    public function clearJstype()
    {
        unset($this->jstype);
    }

    















    public function setJstype($var)
    {
        GPBUtil::checkEnum($var, \Google\Protobuf\Internal\FieldOptions\JSType::class);
        $this->jstype = $var;

        return $this;
    }

    























    public function getLazy()
    {
        return isset($this->lazy) ? $this->lazy : false;
    }

    public function hasLazy()
    {
        return isset($this->lazy);
    }

    public function clearLazy()
    {
        unset($this->lazy);
    }

    
























    public function setLazy($var)
    {
        GPBUtil::checkBool($var);
        $this->lazy = $var;

        return $this;
    }

    







    public function getUnverifiedLazy()
    {
        return isset($this->unverified_lazy) ? $this->unverified_lazy : false;
    }

    public function hasUnverifiedLazy()
    {
        return isset($this->unverified_lazy);
    }

    public function clearUnverifiedLazy()
    {
        unset($this->unverified_lazy);
    }

    








    public function setUnverifiedLazy($var)
    {
        GPBUtil::checkBool($var);
        $this->unverified_lazy = $var;

        return $this;
    }

    








    public function getDeprecated()
    {
        return isset($this->deprecated) ? $this->deprecated : false;
    }

    public function hasDeprecated()
    {
        return isset($this->deprecated);
    }

    public function clearDeprecated()
    {
        unset($this->deprecated);
    }

    









    public function setDeprecated($var)
    {
        GPBUtil::checkBool($var);
        $this->deprecated = $var;

        return $this;
    }

    





    public function getWeak()
    {
        return isset($this->weak) ? $this->weak : false;
    }

    public function hasWeak()
    {
        return isset($this->weak);
    }

    public function clearWeak()
    {
        unset($this->weak);
    }

    






    public function setWeak($var)
    {
        GPBUtil::checkBool($var);
        $this->weak = $var;

        return $this;
    }

    






    public function getDebugRedact()
    {
        return isset($this->debug_redact) ? $this->debug_redact : false;
    }

    public function hasDebugRedact()
    {
        return isset($this->debug_redact);
    }

    public function clearDebugRedact()
    {
        unset($this->debug_redact);
    }

    







    public function setDebugRedact($var)
    {
        GPBUtil::checkBool($var);
        $this->debug_redact = $var;

        return $this;
    }

    



    public function getRetention()
    {
        return isset($this->retention) ? $this->retention : 0;
    }

    public function hasRetention()
    {
        return isset($this->retention);
    }

    public function clearRetention()
    {
        unset($this->retention);
    }

    




    public function setRetention($var)
    {
        GPBUtil::checkEnum($var, \Google\Protobuf\Internal\FieldOptions\OptionRetention::class);
        $this->retention = $var;

        return $this;
    }

    



    public function getTargets()
    {
        return $this->targets;
    }

    




    public function setTargets($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Protobuf\Internal\FieldOptions\OptionTargetType::class);
        $this->targets = $arr;

        return $this;
    }

    



    public function getEditionDefaults()
    {
        return $this->edition_defaults;
    }

    




    public function setEditionDefaults($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\FieldOptions\EditionDefault::class);
        $this->edition_defaults = $arr;

        return $this;
    }

    








    public function getFeatures()
    {
        return $this->features;
    }

    public function hasFeatures()
    {
        return isset($this->features);
    }

    public function clearFeatures()
    {
        unset($this->features);
    }

    









    public function setFeatures($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Internal\FeatureSet::class);
        $this->features = $var;

        return $this;
    }

    



    public function getFeatureSupport()
    {
        return $this->feature_support;
    }

    public function hasFeatureSupport()
    {
        return isset($this->feature_support);
    }

    public function clearFeatureSupport()
    {
        unset($this->feature_support);
    }

    




    public function setFeatureSupport($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Internal\FieldOptions\FeatureSupport::class);
        $this->feature_support = $var;

        return $this;
    }

    





    public function getUninterpretedOption()
    {
        return $this->uninterpreted_option;
    }

    






    public function setUninterpretedOption($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Internal\UninterpretedOption::class);
        $this->uninterpreted_option = $arr;

        return $this;
    }

}

