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

namespace Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature;

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

/**
 * Memory hash detection contributing to the binary family match.
 *
 * Generated from protobuf message <code>google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature.Detection</code>
 */
class Detection extends \Google\Protobuf\Internal\Message
{
    /**
     * The name of the binary associated with the memory hash
     * signature detection.
     *
     * Generated from protobuf field <code>string binary = 2;</code>
     */
    private $binary = '';
    /**
     * The percentage of memory page hashes in the signature
     * that were matched.
     *
     * Generated from protobuf field <code>double percent_pages_matched = 3;</code>
     */
    private $percent_pages_matched = 0.0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $binary
     *           The name of the binary associated with the memory hash
     *           signature detection.
     *     @type float $percent_pages_matched
     *           The percentage of memory page hashes in the signature
     *           that were matched.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Securitycenter\V1\Indicator::initOnce();
        parent::__construct($data);
    }

    /**
     * The name of the binary associated with the memory hash
     * signature detection.
     *
     * Generated from protobuf field <code>string binary = 2;</code>
     * @return string
     */
    public function getBinary()
    {
        return $this->binary;
    }

    /**
     * The name of the binary associated with the memory hash
     * signature detection.
     *
     * Generated from protobuf field <code>string binary = 2;</code>
     * @param string $var
     * @return $this
     */
    public function setBinary($var)
    {
        GPBUtil::checkString($var, True);
        $this->binary = $var;

        return $this;
    }

    /**
     * The percentage of memory page hashes in the signature
     * that were matched.
     *
     * Generated from protobuf field <code>double percent_pages_matched = 3;</code>
     * @return float
     */
    public function getPercentPagesMatched()
    {
        return $this->percent_pages_matched;
    }

    /**
     * The percentage of memory page hashes in the signature
     * that were matched.
     *
     * Generated from protobuf field <code>double percent_pages_matched = 3;</code>
     * @param float $var
     * @return $this
     */
    public function setPercentPagesMatched($var)
    {
        GPBUtil::checkDouble($var);
        $this->percent_pages_matched = $var;

        return $this;
    }

}

// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Detection::class, \Google\Cloud\SecurityCenter\V1\Indicator_ProcessSignature_MemoryHashSignature_Detection::class);

