<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/iap/v1/service.proto

namespace Google\Cloud\Iap\V1;

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

/**
 * Custom content configuration for access denied page.
 * IAP allows customers to define a custom URI to use as the error page when
 * access is denied to users. If IAP prevents access to this page, the default
 * IAP error page will be displayed instead.
 *
 * Generated from protobuf message <code>google.cloud.iap.v1.AccessDeniedPageSettings</code>
 */
class AccessDeniedPageSettings extends \Google\Protobuf\Internal\Message
{
    /**
     * The URI to be redirected to when access is denied.
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue access_denied_page_uri = 1;</code>
     */
    protected $access_denied_page_uri = null;
    /**
     * Whether to generate a troubleshooting URL on access denied events to this
     * application.
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue generate_troubleshooting_uri = 2;</code>
     */
    protected $generate_troubleshooting_uri = null;
    /**
     * Whether to generate remediation token on access denied events to this
     * application.
     *
     * Generated from protobuf field <code>optional .google.protobuf.BoolValue remediation_token_generation_enabled = 3;</code>
     */
    protected $remediation_token_generation_enabled = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Protobuf\StringValue $access_denied_page_uri
     *           The URI to be redirected to when access is denied.
     *     @type \Google\Protobuf\BoolValue $generate_troubleshooting_uri
     *           Whether to generate a troubleshooting URL on access denied events to this
     *           application.
     *     @type \Google\Protobuf\BoolValue $remediation_token_generation_enabled
     *           Whether to generate remediation token on access denied events to this
     *           application.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Iap\V1\Service::initOnce();
        parent::__construct($data);
    }

    /**
     * The URI to be redirected to when access is denied.
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue access_denied_page_uri = 1;</code>
     * @return \Google\Protobuf\StringValue|null
     */
    public function getAccessDeniedPageUri()
    {
        return $this->access_denied_page_uri;
    }

    public function hasAccessDeniedPageUri()
    {
        return isset($this->access_denied_page_uri);
    }

    public function clearAccessDeniedPageUri()
    {
        unset($this->access_denied_page_uri);
    }

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

     * The URI to be redirected to when access is denied.
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue access_denied_page_uri = 1;</code>
     * @return string|null
     */
    public function getAccessDeniedPageUriUnwrapped()
    {
        return $this->readWrapperValue("access_denied_page_uri");
    }

    /**
     * The URI to be redirected to when access is denied.
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue access_denied_page_uri = 1;</code>
     * @param \Google\Protobuf\StringValue $var
     * @return $this
     */
    public function setAccessDeniedPageUri($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\StringValue::class);
        $this->access_denied_page_uri = $var;

        return $this;
    }

    /**
     * Sets the field by wrapping a primitive type in a Google\Protobuf\StringValue object.

     * The URI to be redirected to when access is denied.
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue access_denied_page_uri = 1;</code>
     * @param string|null $var
     * @return $this
     */
    public function setAccessDeniedPageUriUnwrapped($var)
    {
        $this->writeWrapperValue("access_denied_page_uri", $var);
        return $this;}

    /**
     * Whether to generate a troubleshooting URL on access denied events to this
     * application.
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue generate_troubleshooting_uri = 2;</code>
     * @return \Google\Protobuf\BoolValue|null
     */
    public function getGenerateTroubleshootingUri()
    {
        return $this->generate_troubleshooting_uri;
    }

    public function hasGenerateTroubleshootingUri()
    {
        return isset($this->generate_troubleshooting_uri);
    }

    public function clearGenerateTroubleshootingUri()
    {
        unset($this->generate_troubleshooting_uri);
    }

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

     * Whether to generate a troubleshooting URL on access denied events to this
     * application.
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue generate_troubleshooting_uri = 2;</code>
     * @return bool|null
     */
    public function getGenerateTroubleshootingUriUnwrapped()
    {
        return $this->readWrapperValue("generate_troubleshooting_uri");
    }

    /**
     * Whether to generate a troubleshooting URL on access denied events to this
     * application.
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue generate_troubleshooting_uri = 2;</code>
     * @param \Google\Protobuf\BoolValue $var
     * @return $this
     */
    public function setGenerateTroubleshootingUri($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\BoolValue::class);
        $this->generate_troubleshooting_uri = $var;

        return $this;
    }

    /**
     * Sets the field by wrapping a primitive type in a Google\Protobuf\BoolValue object.

     * Whether to generate a troubleshooting URL on access denied events to this
     * application.
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue generate_troubleshooting_uri = 2;</code>
     * @param bool|null $var
     * @return $this
     */
    public function setGenerateTroubleshootingUriUnwrapped($var)
    {
        $this->writeWrapperValue("generate_troubleshooting_uri", $var);
        return $this;}

    /**
     * Whether to generate remediation token on access denied events to this
     * application.
     *
     * Generated from protobuf field <code>optional .google.protobuf.BoolValue remediation_token_generation_enabled = 3;</code>
     * @return \Google\Protobuf\BoolValue|null
     */
    public function getRemediationTokenGenerationEnabled()
    {
        return $this->remediation_token_generation_enabled;
    }

    public function hasRemediationTokenGenerationEnabled()
    {
        return isset($this->remediation_token_generation_enabled);
    }

    public function clearRemediationTokenGenerationEnabled()
    {
        unset($this->remediation_token_generation_enabled);
    }

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

     * Whether to generate remediation token on access denied events to this
     * application.
     *
     * Generated from protobuf field <code>optional .google.protobuf.BoolValue remediation_token_generation_enabled = 3;</code>
     * @return bool|null
     */
    public function getRemediationTokenGenerationEnabledUnwrapped()
    {
        return $this->readWrapperValue("remediation_token_generation_enabled");
    }

    /**
     * Whether to generate remediation token on access denied events to this
     * application.
     *
     * Generated from protobuf field <code>optional .google.protobuf.BoolValue remediation_token_generation_enabled = 3;</code>
     * @param \Google\Protobuf\BoolValue $var
     * @return $this
     */
    public function setRemediationTokenGenerationEnabled($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\BoolValue::class);
        $this->remediation_token_generation_enabled = $var;

        return $this;
    }

    /**
     * Sets the field by wrapping a primitive type in a Google\Protobuf\BoolValue object.

     * Whether to generate remediation token on access denied events to this
     * application.
     *
     * Generated from protobuf field <code>optional .google.protobuf.BoolValue remediation_token_generation_enabled = 3;</code>
     * @param bool|null $var
     * @return $this
     */
    public function setRemediationTokenGenerationEnabledUnwrapped($var)
    {
        $this->writeWrapperValue("remediation_token_generation_enabled", $var);
        return $this;}

}

