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

namespace Google\Cloud\OsConfig\V1\Inventory;

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

/**
 * Software package information of the operating system.
 *
 * Generated from protobuf message <code>google.cloud.osconfig.v1.Inventory.SoftwarePackage</code>
 */
class SoftwarePackage extends \Google\Protobuf\Internal\Message
{
    protected $details;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage $yum_package
     *           Yum package info.
     *           For details about the yum package manager, see
     *           https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/6/html/deployment_guide/ch-yum.
     *     @type \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage $apt_package
     *           Details of an APT package.
     *           For details about the apt package manager, see
     *           https://wiki.debian.org/Apt.
     *     @type \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage $zypper_package
     *           Details of a Zypper package.
     *           For details about the Zypper package manager, see
     *           https://en.opensuse.org/SDB:Zypper_manual.
     *     @type \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage $googet_package
     *           Details of a Googet package.
     *            For details about the googet package manager, see
     *            https://github.com/google/googet.
     *     @type \Google\Cloud\OsConfig\V1\Inventory\ZypperPatch $zypper_patch
     *           Details of a Zypper patch.
     *           For details about the Zypper package manager, see
     *           https://en.opensuse.org/SDB:Zypper_manual.
     *     @type \Google\Cloud\OsConfig\V1\Inventory\WindowsUpdatePackage $wua_package
     *           Details of a Windows Update package.
     *           See https://docs.microsoft.com/en-us/windows/win32/api/_wua/ for
     *           information about Windows Update.
     *     @type \Google\Cloud\OsConfig\V1\Inventory\WindowsQuickFixEngineeringPackage $qfe_package
     *           Details of a Windows Quick Fix engineering package.
     *           See
     *           https://docs.microsoft.com/en-us/windows/win32/cimwin32prov/win32-quickfixengineering
     *           for info in Windows Quick Fix Engineering.
     *     @type \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage $cos_package
     *           Details of a COS package.
     *     @type \Google\Cloud\OsConfig\V1\Inventory\WindowsApplication $windows_application
     *           Details of Windows Application.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Osconfig\V1\Inventory::initOnce();
        parent::__construct($data);
    }

    /**
     * Yum package info.
     * For details about the yum package manager, see
     * https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/6/html/deployment_guide/ch-yum.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.VersionedPackage yum_package = 1;</code>
     * @return \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage|null
     */
    public function getYumPackage()
    {
        return $this->readOneof(1);
    }

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

    /**
     * Yum package info.
     * For details about the yum package manager, see
     * https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/6/html/deployment_guide/ch-yum.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.VersionedPackage yum_package = 1;</code>
     * @param \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage $var
     * @return $this
     */
    public function setYumPackage($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage::class);
        $this->writeOneof(1, $var);

        return $this;
    }

    /**
     * Details of an APT package.
     * For details about the apt package manager, see
     * https://wiki.debian.org/Apt.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.VersionedPackage apt_package = 2;</code>
     * @return \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage|null
     */
    public function getAptPackage()
    {
        return $this->readOneof(2);
    }

    public function hasAptPackage()
    {
        return $this->hasOneof(2);
    }

    /**
     * Details of an APT package.
     * For details about the apt package manager, see
     * https://wiki.debian.org/Apt.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.VersionedPackage apt_package = 2;</code>
     * @param \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage $var
     * @return $this
     */
    public function setAptPackage($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage::class);
        $this->writeOneof(2, $var);

        return $this;
    }

    /**
     * Details of a Zypper package.
     * For details about the Zypper package manager, see
     * https://en.opensuse.org/SDB:Zypper_manual.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.VersionedPackage zypper_package = 3;</code>
     * @return \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage|null
     */
    public function getZypperPackage()
    {
        return $this->readOneof(3);
    }

    public function hasZypperPackage()
    {
        return $this->hasOneof(3);
    }

    /**
     * Details of a Zypper package.
     * For details about the Zypper package manager, see
     * https://en.opensuse.org/SDB:Zypper_manual.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.VersionedPackage zypper_package = 3;</code>
     * @param \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage $var
     * @return $this
     */
    public function setZypperPackage($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage::class);
        $this->writeOneof(3, $var);

        return $this;
    }

    /**
     * Details of a Googet package.
     *  For details about the googet package manager, see
     *  https://github.com/google/googet.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.VersionedPackage googet_package = 4;</code>
     * @return \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage|null
     */
    public function getGoogetPackage()
    {
        return $this->readOneof(4);
    }

    public function hasGoogetPackage()
    {
        return $this->hasOneof(4);
    }

    /**
     * Details of a Googet package.
     *  For details about the googet package manager, see
     *  https://github.com/google/googet.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.VersionedPackage googet_package = 4;</code>
     * @param \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage $var
     * @return $this
     */
    public function setGoogetPackage($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage::class);
        $this->writeOneof(4, $var);

        return $this;
    }

    /**
     * Details of a Zypper patch.
     * For details about the Zypper package manager, see
     * https://en.opensuse.org/SDB:Zypper_manual.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.ZypperPatch zypper_patch = 5;</code>
     * @return \Google\Cloud\OsConfig\V1\Inventory\ZypperPatch|null
     */
    public function getZypperPatch()
    {
        return $this->readOneof(5);
    }

    public function hasZypperPatch()
    {
        return $this->hasOneof(5);
    }

    /**
     * Details of a Zypper patch.
     * For details about the Zypper package manager, see
     * https://en.opensuse.org/SDB:Zypper_manual.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.ZypperPatch zypper_patch = 5;</code>
     * @param \Google\Cloud\OsConfig\V1\Inventory\ZypperPatch $var
     * @return $this
     */
    public function setZypperPatch($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\OsConfig\V1\Inventory\ZypperPatch::class);
        $this->writeOneof(5, $var);

        return $this;
    }

    /**
     * Details of a Windows Update package.
     * See https://docs.microsoft.com/en-us/windows/win32/api/_wua/ for
     * information about Windows Update.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.WindowsUpdatePackage wua_package = 6;</code>
     * @return \Google\Cloud\OsConfig\V1\Inventory\WindowsUpdatePackage|null
     */
    public function getWuaPackage()
    {
        return $this->readOneof(6);
    }

    public function hasWuaPackage()
    {
        return $this->hasOneof(6);
    }

    /**
     * Details of a Windows Update package.
     * See https://docs.microsoft.com/en-us/windows/win32/api/_wua/ for
     * information about Windows Update.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.WindowsUpdatePackage wua_package = 6;</code>
     * @param \Google\Cloud\OsConfig\V1\Inventory\WindowsUpdatePackage $var
     * @return $this
     */
    public function setWuaPackage($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\OsConfig\V1\Inventory\WindowsUpdatePackage::class);
        $this->writeOneof(6, $var);

        return $this;
    }

    /**
     * Details of a Windows Quick Fix engineering package.
     * See
     * https://docs.microsoft.com/en-us/windows/win32/cimwin32prov/win32-quickfixengineering
     * for info in Windows Quick Fix Engineering.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.WindowsQuickFixEngineeringPackage qfe_package = 7;</code>
     * @return \Google\Cloud\OsConfig\V1\Inventory\WindowsQuickFixEngineeringPackage|null
     */
    public function getQfePackage()
    {
        return $this->readOneof(7);
    }

    public function hasQfePackage()
    {
        return $this->hasOneof(7);
    }

    /**
     * Details of a Windows Quick Fix engineering package.
     * See
     * https://docs.microsoft.com/en-us/windows/win32/cimwin32prov/win32-quickfixengineering
     * for info in Windows Quick Fix Engineering.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.WindowsQuickFixEngineeringPackage qfe_package = 7;</code>
     * @param \Google\Cloud\OsConfig\V1\Inventory\WindowsQuickFixEngineeringPackage $var
     * @return $this
     */
    public function setQfePackage($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\OsConfig\V1\Inventory\WindowsQuickFixEngineeringPackage::class);
        $this->writeOneof(7, $var);

        return $this;
    }

    /**
     * Details of a COS package.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.VersionedPackage cos_package = 8;</code>
     * @return \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage|null
     */
    public function getCosPackage()
    {
        return $this->readOneof(8);
    }

    public function hasCosPackage()
    {
        return $this->hasOneof(8);
    }

    /**
     * Details of a COS package.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.VersionedPackage cos_package = 8;</code>
     * @param \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage $var
     * @return $this
     */
    public function setCosPackage($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\OsConfig\V1\Inventory\VersionedPackage::class);
        $this->writeOneof(8, $var);

        return $this;
    }

    /**
     * Details of Windows Application.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.WindowsApplication windows_application = 9;</code>
     * @return \Google\Cloud\OsConfig\V1\Inventory\WindowsApplication|null
     */
    public function getWindowsApplication()
    {
        return $this->readOneof(9);
    }

    public function hasWindowsApplication()
    {
        return $this->hasOneof(9);
    }

    /**
     * Details of Windows Application.
     *
     * Generated from protobuf field <code>.google.cloud.osconfig.v1.Inventory.WindowsApplication windows_application = 9;</code>
     * @param \Google\Cloud\OsConfig\V1\Inventory\WindowsApplication $var
     * @return $this
     */
    public function setWindowsApplication($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\OsConfig\V1\Inventory\WindowsApplication::class);
        $this->writeOneof(9, $var);

        return $this;
    }

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

}


