<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/policytroubleshooter/iam/v3/troubleshooter.proto

namespace Google\Cloud\PolicyTroubleshooter\Iam\V3;

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

/**
 * Request for
 * [TroubleshootIamPolicy][google.cloud.policytroubleshooter.iam.v3.PolicyTroubleshooter.TroubleshootIamPolicy].
 *
 * Generated from protobuf message <code>google.cloud.policytroubleshooter.iam.v3.TroubleshootIamPolicyRequest</code>
 */
class TroubleshootIamPolicyRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * The information to use for checking whether a principal has a permission
     * for a resource.
     *
     * Generated from protobuf field <code>.google.cloud.policytroubleshooter.iam.v3.AccessTuple access_tuple = 1;</code>
     */
    protected $access_tuple = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\PolicyTroubleshooter\Iam\V3\AccessTuple $access_tuple
     *           The information to use for checking whether a principal has a permission
     *           for a resource.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Policytroubleshooter\Iam\V3\Troubleshooter::initOnce();
        parent::__construct($data);
    }

    /**
     * The information to use for checking whether a principal has a permission
     * for a resource.
     *
     * Generated from protobuf field <code>.google.cloud.policytroubleshooter.iam.v3.AccessTuple access_tuple = 1;</code>
     * @return \Google\Cloud\PolicyTroubleshooter\Iam\V3\AccessTuple|null
     */
    public function getAccessTuple()
    {
        return $this->access_tuple;
    }

    public function hasAccessTuple()
    {
        return isset($this->access_tuple);
    }

    public function clearAccessTuple()
    {
        unset($this->access_tuple);
    }

    /**
     * The information to use for checking whether a principal has a permission
     * for a resource.
     *
     * Generated from protobuf field <code>.google.cloud.policytroubleshooter.iam.v3.AccessTuple access_tuple = 1;</code>
     * @param \Google\Cloud\PolicyTroubleshooter\Iam\V3\AccessTuple $var
     * @return $this
     */
    public function setAccessTuple($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\PolicyTroubleshooter\Iam\V3\AccessTuple::class);
        $this->access_tuple = $var;

        return $this;
    }

}

