<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: lily.proto

namespace Palm\Lily\V1;

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

/**
 * Generated from protobuf message <code>palm.lily.v1.TexToRequest</code>
 */
class TexToRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>string title = 1;</code>
     */
    protected $title = '';
    /**
     * Generated from protobuf field <code>map<string, bytes> files = 2;</code>
     */
    private $files;
    /**
     * Generated from protobuf field <code>optional .google.protobuf.Duration ttl = 7;</code>
     */
    protected $ttl = null;
    /**
     * Generated from protobuf field <code>optional string owner = 8;</code>
     */
    protected $owner = null;
    /**
     * Generated from protobuf field <code>bool published = 9;</code>
     */
    protected $published = false;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $title
     *     @type array|\Google\Protobuf\Internal\MapField $files
     *     @type \Google\Protobuf\Duration $ttl
     *     @type string $owner
     *     @type bool $published
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Lily::initOnce();
        parent::__construct($data);
    }

    /**
     * Generated from protobuf field <code>string title = 1;</code>
     * @return string
     */
    public function getTitle()
    {
        return $this->title;
    }

    /**
     * Generated from protobuf field <code>string title = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setTitle($var)
    {
        GPBUtil::checkString($var, True);
        $this->title = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>map<string, bytes> files = 2;</code>
     * @return \Google\Protobuf\Internal\MapField
     */
    public function getFiles()
    {
        return $this->files;
    }

    /**
     * Generated from protobuf field <code>map<string, bytes> files = 2;</code>
     * @param array|\Google\Protobuf\Internal\MapField $var
     * @return $this
     */
    public function setFiles($var)
    {
        $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::BYTES);
        $this->files = $arr;

        return $this;
    }

    /**
     * Generated from protobuf field <code>optional .google.protobuf.Duration ttl = 7;</code>
     * @return \Google\Protobuf\Duration|null
     */
    public function getTtl()
    {
        return $this->ttl;
    }

    public function hasTtl()
    {
        return isset($this->ttl);
    }

    public function clearTtl()
    {
        unset($this->ttl);
    }

    /**
     * Generated from protobuf field <code>optional .google.protobuf.Duration ttl = 7;</code>
     * @param \Google\Protobuf\Duration $var
     * @return $this
     */
    public function setTtl($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class);
        $this->ttl = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>optional string owner = 8;</code>
     * @return string
     */
    public function getOwner()
    {
        return isset($this->owner) ? $this->owner : '';
    }

    public function hasOwner()
    {
        return isset($this->owner);
    }

    public function clearOwner()
    {
        unset($this->owner);
    }

    /**
     * Generated from protobuf field <code>optional string owner = 8;</code>
     * @param string $var
     * @return $this
     */
    public function setOwner($var)
    {
        GPBUtil::checkString($var, True);
        $this->owner = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>bool published = 9;</code>
     * @return bool
     */
    public function getPublished()
    {
        return $this->published;
    }

    /**
     * Generated from protobuf field <code>bool published = 9;</code>
     * @param bool $var
     * @return $this
     */
    public function setPublished($var)
    {
        GPBUtil::checkBool($var);
        $this->published = $var;

        return $this;
    }

}

