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

namespace Google\Cloud\SecurityCenter\V1;

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

/**
 * Kubernetes related attributes.
 *
 * Generated from protobuf message <code>google.cloud.securitycenter.v1.Kubernetes</code>
 */
class Kubernetes extends \Google\Protobuf\Internal\Message
{
    /**
     * Kubernetes Pods associated with the finding. This field will contain Pod
     * records for each container that is owned by a Pod.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Pod pods = 1;</code>
     */
    private $pods;
    /**
     * Provides Kubernetes Node information.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2;</code>
     */
    private $nodes;
    /**
     * GKE Node Pools associated with the finding. This field will
     * contain NodePool information for each Node, when it is available.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.NodePool node_pools = 3;</code>
     */
    private $node_pools;
    /**
     * Provides Kubernetes role information for findings that involve
     * Roles or ClusterRoles.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Role roles = 4;</code>
     */
    private $roles;
    /**
     * Provides Kubernetes role binding information for findings that involve
     * RoleBindings or ClusterRoleBindings.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Binding bindings = 5;</code>
     */
    private $bindings;
    /**
     * Provides information on any Kubernetes access reviews (i.e. privilege
     * checks) relevant to the finding.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.AccessReview access_reviews = 6;</code>
     */
    private $access_reviews;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Pod>|\Google\Protobuf\Internal\RepeatedField $pods
     *           Kubernetes Pods associated with the finding. This field will contain Pod
     *           records for each container that is owned by a Pod.
     *     @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $nodes
     *           Provides Kubernetes Node information.
     *     @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\NodePool>|\Google\Protobuf\Internal\RepeatedField $node_pools
     *           GKE Node Pools associated with the finding. This field will
     *           contain NodePool information for each Node, when it is available.
     *     @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Role>|\Google\Protobuf\Internal\RepeatedField $roles
     *           Provides Kubernetes role information for findings that involve
     *           Roles or ClusterRoles.
     *     @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Binding>|\Google\Protobuf\Internal\RepeatedField $bindings
     *           Provides Kubernetes role binding information for findings that involve
     *           RoleBindings or ClusterRoleBindings.
     *     @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\AccessReview>|\Google\Protobuf\Internal\RepeatedField $access_reviews
     *           Provides information on any Kubernetes access reviews (i.e. privilege
     *           checks) relevant to the finding.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce();
        parent::__construct($data);
    }

    /**
     * Kubernetes Pods associated with the finding. This field will contain Pod
     * records for each container that is owned by a Pod.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Pod pods = 1;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getPods()
    {
        return $this->pods;
    }

    /**
     * Kubernetes Pods associated with the finding. This field will contain Pod
     * records for each container that is owned by a Pod.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Pod pods = 1;</code>
     * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Pod>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setPods($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Pod::class);
        $this->pods = $arr;

        return $this;
    }

    /**
     * Provides Kubernetes Node information.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getNodes()
    {
        return $this->nodes;
    }

    /**
     * Provides Kubernetes Node information.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2;</code>
     * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setNodes($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Node::class);
        $this->nodes = $arr;

        return $this;
    }

    /**
     * GKE Node Pools associated with the finding. This field will
     * contain NodePool information for each Node, when it is available.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.NodePool node_pools = 3;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getNodePools()
    {
        return $this->node_pools;
    }

    /**
     * GKE Node Pools associated with the finding. This field will
     * contain NodePool information for each Node, when it is available.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.NodePool node_pools = 3;</code>
     * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\NodePool>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setNodePools($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\NodePool::class);
        $this->node_pools = $arr;

        return $this;
    }

    /**
     * Provides Kubernetes role information for findings that involve
     * Roles or ClusterRoles.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Role roles = 4;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getRoles()
    {
        return $this->roles;
    }

    /**
     * Provides Kubernetes role information for findings that involve
     * Roles or ClusterRoles.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Role roles = 4;</code>
     * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Role>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setRoles($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Role::class);
        $this->roles = $arr;

        return $this;
    }

    /**
     * Provides Kubernetes role binding information for findings that involve
     * RoleBindings or ClusterRoleBindings.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Binding bindings = 5;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getBindings()
    {
        return $this->bindings;
    }

    /**
     * Provides Kubernetes role binding information for findings that involve
     * RoleBindings or ClusterRoleBindings.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.Binding bindings = 5;</code>
     * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Binding>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setBindings($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Binding::class);
        $this->bindings = $arr;

        return $this;
    }

    /**
     * Provides information on any Kubernetes access reviews (i.e. privilege
     * checks) relevant to the finding.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.AccessReview access_reviews = 6;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getAccessReviews()
    {
        return $this->access_reviews;
    }

    /**
     * Provides information on any Kubernetes access reviews (i.e. privilege
     * checks) relevant to the finding.
     *
     * Generated from protobuf field <code>repeated .google.cloud.securitycenter.v1.Kubernetes.AccessReview access_reviews = 6;</code>
     * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\AccessReview>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setAccessReviews($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\AccessReview::class);
        $this->access_reviews = $arr;

        return $this;
    }

}

