<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: deviceapis/device/v1/deviceapis_device_capability_v1.proto

namespace Deviceapis\Device\V1;

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

/**
 * Возможность устройства
 *
 * Generated from protobuf message <code>deviceapis.device.v1.Capability</code>
 */
class Capability extends \Google\Protobuf\Internal\Message
{
    protected $kind;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Deviceapis\Device\V1\Capability\EncryptionProfile $encryption_profile
     *           Профиль шифрования
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Deviceapis\Device\V1\DeviceapisDeviceCapabilityV1::initOnce();
        parent::__construct($data);
    }

    /**
     * Профиль шифрования
     *
     * Generated from protobuf field <code>.deviceapis.device.v1.Capability.EncryptionProfile encryption_profile = 1;</code>
     * @return \Deviceapis\Device\V1\Capability\EncryptionProfile|null
     */
    public function getEncryptionProfile()
    {
        return $this->readOneof(1);
    }

    public function hasEncryptionProfile()
    {
        return $this->hasOneof(1);
    }

    /**
     * Профиль шифрования
     *
     * Generated from protobuf field <code>.deviceapis.device.v1.Capability.EncryptionProfile encryption_profile = 1;</code>
     * @param \Deviceapis\Device\V1\Capability\EncryptionProfile $var
     * @return $this
     */
    public function setEncryptionProfile($var)
    {
        GPBUtil::checkMessage($var, \Deviceapis\Device\V1\Capability\EncryptionProfile::class);
        $this->writeOneof(1, $var);

        return $this;
    }

    /**
     * @return string
     */
    public function getKind()
    {
        return $this->whichOneof("kind");
    }

}

