<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: couchbase/kv/v1/kv.proto

namespace Couchbase\Protostellar\Generated\KV\V1;

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

/**
 * Generated from protobuf message <code>couchbase.kv.v1.LookupInRequest</code>
 */
class LookupInRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>string bucket_name = 1;</code>
     */
    protected $bucket_name = '';
    /**
     * Generated from protobuf field <code>string scope_name = 2;</code>
     */
    protected $scope_name = '';
    /**
     * Generated from protobuf field <code>string collection_name = 3;</code>
     */
    protected $collection_name = '';
    /**
     * Generated from protobuf field <code>string key = 4;</code>
     */
    protected $key = '';
    /**
     * Generated from protobuf field <code>repeated .couchbase.kv.v1.LookupInRequest.Spec specs = 5;</code>
     */
    private $specs;
    /**
     * Generated from protobuf field <code>optional .couchbase.kv.v1.LookupInRequest.Flags flags = 6;</code>
     */
    protected $flags = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $bucket_name
     *     @type string $scope_name
     *     @type string $collection_name
     *     @type string $key
     *     @type array<\Couchbase\Protostellar\Generated\KV\V1\LookupInRequest\Spec>|\Google\Protobuf\Internal\RepeatedField $specs
     *     @type \Couchbase\Protostellar\Generated\KV\V1\LookupInRequest\Flags $flags
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Couchbase\Kv\V1\Kv::initOnce();
        parent::__construct($data);
    }

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

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

        return $this;
    }

    /**
     * Generated from protobuf field <code>string scope_name = 2;</code>
     * @return string
     */
    public function getScopeName()
    {
        return $this->scope_name;
    }

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

        return $this;
    }

    /**
     * Generated from protobuf field <code>string collection_name = 3;</code>
     * @return string
     */
    public function getCollectionName()
    {
        return $this->collection_name;
    }

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

        return $this;
    }

    /**
     * Generated from protobuf field <code>string key = 4;</code>
     * @return string
     */
    public function getKey()
    {
        return $this->key;
    }

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

        return $this;
    }

    /**
     * Generated from protobuf field <code>repeated .couchbase.kv.v1.LookupInRequest.Spec specs = 5;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getSpecs()
    {
        return $this->specs;
    }

    /**
     * Generated from protobuf field <code>repeated .couchbase.kv.v1.LookupInRequest.Spec specs = 5;</code>
     * @param array<\Couchbase\Protostellar\Generated\KV\V1\LookupInRequest\Spec>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setSpecs($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Couchbase\Protostellar\Generated\KV\V1\LookupInRequest\Spec::class);
        $this->specs = $arr;

        return $this;
    }

    /**
     * Generated from protobuf field <code>optional .couchbase.kv.v1.LookupInRequest.Flags flags = 6;</code>
     * @return \Couchbase\Protostellar\Generated\KV\V1\LookupInRequest\Flags|null
     */
    public function getFlags()
    {
        return $this->flags;
    }

    public function hasFlags()
    {
        return isset($this->flags);
    }

    public function clearFlags()
    {
        unset($this->flags);
    }

    /**
     * Generated from protobuf field <code>optional .couchbase.kv.v1.LookupInRequest.Flags flags = 6;</code>
     * @param \Couchbase\Protostellar\Generated\KV\V1\LookupInRequest\Flags $var
     * @return $this
     */
    public function setFlags($var)
    {
        GPBUtil::checkMessage($var, \Couchbase\Protostellar\Generated\KV\V1\LookupInRequest\Flags::class);
        $this->flags = $var;

        return $this;
    }

}

