<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# NO CHECKED-IN PROTOBUF GENCODE
# source: configsync.proto

namespace OS\PB;

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

/**
 * Generated from protobuf message <code>OS.PB.ConfigSyncEvent</code>
 */
class ConfigSyncEvent extends \Google\Protobuf\Internal\Message
{
    /**
     * A friendly user interface message if anything went wrong
     *
     * Generated from protobuf field <code>string Message = 6;</code>
     */
    protected $Message = '';
    /**
     * Only applicable on SyncEnd, how many configs were received
     *
     * Generated from protobuf field <code>uint32 TotalReceived = 8;</code>
     */
    protected $TotalReceived = 0;
    /**
     * If ProgressTotal was set to something greater than zero, it will send a SyncProgress event with this percentage point set
     *
     * Generated from protobuf field <code>uint32 ProgressPercent = 9;</code>
     */
    protected $ProgressPercent = 0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $Message
     *           A friendly user interface message if anything went wrong
     *     @type int $TotalReceived
     *           Only applicable on SyncEnd, how many configs were received
     *     @type int $ProgressPercent
     *           If ProgressTotal was set to something greater than zero, it will send a SyncProgress event with this percentage point set
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Configsync::initOnce();
        parent::__construct($data);
    }

    /**
     * A friendly user interface message if anything went wrong
     *
     * Generated from protobuf field <code>string Message = 6;</code>
     * @return string
     */
    public function getMessage()
    {
        return $this->Message;
    }

    /**
     * A friendly user interface message if anything went wrong
     *
     * Generated from protobuf field <code>string Message = 6;</code>
     * @param string $var
     * @return $this
     */
    public function setMessage($var)
    {
        GPBUtil::checkString($var, True);
        $this->Message = $var;

        return $this;
    }

    /**
     * Only applicable on SyncEnd, how many configs were received
     *
     * Generated from protobuf field <code>uint32 TotalReceived = 8;</code>
     * @return int
     */
    public function getTotalReceived()
    {
        return $this->TotalReceived;
    }

    /**
     * Only applicable on SyncEnd, how many configs were received
     *
     * Generated from protobuf field <code>uint32 TotalReceived = 8;</code>
     * @param int $var
     * @return $this
     */
    public function setTotalReceived($var)
    {
        GPBUtil::checkUint32($var);
        $this->TotalReceived = $var;

        return $this;
    }

    /**
     * If ProgressTotal was set to something greater than zero, it will send a SyncProgress event with this percentage point set
     *
     * Generated from protobuf field <code>uint32 ProgressPercent = 9;</code>
     * @return int
     */
    public function getProgressPercent()
    {
        return $this->ProgressPercent;
    }

    /**
     * If ProgressTotal was set to something greater than zero, it will send a SyncProgress event with this percentage point set
     *
     * Generated from protobuf field <code>uint32 ProgressPercent = 9;</code>
     * @param int $var
     * @return $this
     */
    public function setProgressPercent($var)
    {
        GPBUtil::checkUint32($var);
        $this->ProgressPercent = $var;

        return $this;
    }

}

