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

namespace Zaly\Proto\Site;

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

/**
 * Generated from protobuf message <code>site.ApiSiteConfigResponse</code>
 */
class ApiSiteConfigResponse extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>.core.PublicSiteConfig config = 1;</code>
     */
    private $config = null;
    /**
     * randomSignBase64 = rsa(site.privk, request.random)
     *
     * Generated from protobuf field <code>string randomSignBase64 = 2;</code>
     */
    private $randomSignBase64 = '';
    /**
     * Generated from protobuf field <code>bool isSessionValid = 3;</code>
     */
    private $isSessionValid = false;
    /**
     * Generated from protobuf field <code>.core.PluginProfile loginPluginProfile = 4;</code>
     */
    private $loginPluginProfile = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Zaly\Proto\Core\PublicSiteConfig $config
     *     @type string $randomSignBase64
     *           randomSignBase64 = rsa(site.privk, request.random)
     *     @type bool $isSessionValid
     *     @type \Zaly\Proto\Core\PluginProfile $loginPluginProfile
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Site\ApiSiteConfig::initOnce();
        parent::__construct($data);
    }

    /**
     * Generated from protobuf field <code>.core.PublicSiteConfig config = 1;</code>
     * @return \Zaly\Proto\Core\PublicSiteConfig
     */
    public function getConfig()
    {
        return $this->config;
    }

    /**
     * Generated from protobuf field <code>.core.PublicSiteConfig config = 1;</code>
     * @param \Zaly\Proto\Core\PublicSiteConfig $var
     * @return $this
     */
    public function setConfig($var)
    {
        GPBUtil::checkMessage($var, \Zaly\Proto\Core\PublicSiteConfig::class);
        $this->config = $var;

        return $this;
    }

    /**
     * randomSignBase64 = rsa(site.privk, request.random)
     *
     * Generated from protobuf field <code>string randomSignBase64 = 2;</code>
     * @return string
     */
    public function getRandomSignBase64()
    {
        return $this->randomSignBase64;
    }

    /**
     * randomSignBase64 = rsa(site.privk, request.random)
     *
     * Generated from protobuf field <code>string randomSignBase64 = 2;</code>
     * @param string $var
     * @return $this
     */
    public function setRandomSignBase64($var)
    {
        GPBUtil::checkString($var, True);
        $this->randomSignBase64 = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>bool isSessionValid = 3;</code>
     * @return bool
     */
    public function getIsSessionValid()
    {
        return $this->isSessionValid;
    }

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

        return $this;
    }

    /**
     * Generated from protobuf field <code>.core.PluginProfile loginPluginProfile = 4;</code>
     * @return \Zaly\Proto\Core\PluginProfile
     */
    public function getLoginPluginProfile()
    {
        return $this->loginPluginProfile;
    }

    /**
     * Generated from protobuf field <code>.core.PluginProfile loginPluginProfile = 4;</code>
     * @param \Zaly\Proto\Core\PluginProfile $var
     * @return $this
     */
    public function setLoginPluginProfile($var)
    {
        GPBUtil::checkMessage($var, \Zaly\Proto\Core\PluginProfile::class);
        $this->loginPluginProfile = $var;

        return $this;
    }

}

