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

namespace Couchbase\Protostellar\Generated\Internal\Hooks\V1\HookAction;

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

/**
 * Generated from protobuf message <code>couchbase.internal.hooks.v1.HookAction.Counter</code>
 */
class Counter extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>string counter_id = 1;</code>
     */
    protected $counter_id = '';
    /**
     * Generated from protobuf field <code>int64 delta = 2;</code>
     */
    protected $delta = 0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $counter_id
     *     @type int|string $delta
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Couchbase\Internal\Hooks\V1\Hooks::initOnce();
        parent::__construct($data);
    }

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

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

        return $this;
    }

    /**
     * Generated from protobuf field <code>int64 delta = 2;</code>
     * @return int|string
     */
    public function getDelta()
    {
        return $this->delta;
    }

    /**
     * Generated from protobuf field <code>int64 delta = 2;</code>
     * @param int|string $var
     * @return $this
     */
    public function setDelta($var)
    {
        GPBUtil::checkInt64($var);
        $this->delta = $var;

        return $this;
    }

}

// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Counter::class, \Couchbase\Protostellar\Generated\Internal\Hooks\V1\HookAction_Counter::class);

