# coding: utf-8

"""
    KubeVirt API

    This is KubeVirt API an add-on for Kubernetes.  # noqa: E501

    OpenAPI spec version: 1.0.0
    Contact: kubevirt-dev@googlegroups.com
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""


import pprint
import re  # noqa: F401

import six

from kubevirt.configuration import Configuration


class V1beta1FeaturePreferences(object):
    """NOTE: This class is auto generated by the swagger code generator program.

    Do not edit the class manually.
    """

    """
    Attributes:
      swagger_types (dict): The key is attribute name
                            and the value is attribute type.
      attribute_map (dict): The key is attribute name
                            and the value is json key in definition.
    """
    swagger_types = {
        'preferred_acpi': 'V1FeatureState',
        'preferred_apic': 'V1FeatureAPIC',
        'preferred_hyperv': 'V1FeatureHyperv',
        'preferred_kvm': 'V1FeatureKVM',
        'preferred_pvspinlock': 'V1FeatureState',
        'preferred_smm': 'V1FeatureState'
    }

    attribute_map = {
        'preferred_acpi': 'preferredAcpi',
        'preferred_apic': 'preferredApic',
        'preferred_hyperv': 'preferredHyperv',
        'preferred_kvm': 'preferredKvm',
        'preferred_pvspinlock': 'preferredPvspinlock',
        'preferred_smm': 'preferredSmm'
    }

    def __init__(self, preferred_acpi=None, preferred_apic=None, preferred_hyperv=None, preferred_kvm=None, preferred_pvspinlock=None, preferred_smm=None, _configuration=None):  # noqa: E501
        """V1beta1FeaturePreferences - a model defined in Swagger"""  # noqa: E501
        if _configuration is None:
            _configuration = Configuration()
        self._configuration = _configuration

        self._preferred_acpi = None
        self._preferred_apic = None
        self._preferred_hyperv = None
        self._preferred_kvm = None
        self._preferred_pvspinlock = None
        self._preferred_smm = None
        self.discriminator = None

        if preferred_acpi is not None:
            self.preferred_acpi = preferred_acpi
        if preferred_apic is not None:
            self.preferred_apic = preferred_apic
        if preferred_hyperv is not None:
            self.preferred_hyperv = preferred_hyperv
        if preferred_kvm is not None:
            self.preferred_kvm = preferred_kvm
        if preferred_pvspinlock is not None:
            self.preferred_pvspinlock = preferred_pvspinlock
        if preferred_smm is not None:
            self.preferred_smm = preferred_smm

    @property
    def preferred_acpi(self):
        """Gets the preferred_acpi of this V1beta1FeaturePreferences.  # noqa: E501

        PreferredAcpi optionally enables the ACPI feature  # noqa: E501

        :return: The preferred_acpi of this V1beta1FeaturePreferences.  # noqa: E501
        :rtype: V1FeatureState
        """
        return self._preferred_acpi

    @preferred_acpi.setter
    def preferred_acpi(self, preferred_acpi):
        """Sets the preferred_acpi of this V1beta1FeaturePreferences.

        PreferredAcpi optionally enables the ACPI feature  # noqa: E501

        :param preferred_acpi: The preferred_acpi of this V1beta1FeaturePreferences.  # noqa: E501
        :type: V1FeatureState
        """

        self._preferred_acpi = preferred_acpi

    @property
    def preferred_apic(self):
        """Gets the preferred_apic of this V1beta1FeaturePreferences.  # noqa: E501

        PreferredApic optionally enables and configures the APIC feature  # noqa: E501

        :return: The preferred_apic of this V1beta1FeaturePreferences.  # noqa: E501
        :rtype: V1FeatureAPIC
        """
        return self._preferred_apic

    @preferred_apic.setter
    def preferred_apic(self, preferred_apic):
        """Sets the preferred_apic of this V1beta1FeaturePreferences.

        PreferredApic optionally enables and configures the APIC feature  # noqa: E501

        :param preferred_apic: The preferred_apic of this V1beta1FeaturePreferences.  # noqa: E501
        :type: V1FeatureAPIC
        """

        self._preferred_apic = preferred_apic

    @property
    def preferred_hyperv(self):
        """Gets the preferred_hyperv of this V1beta1FeaturePreferences.  # noqa: E501

        PreferredHyperv optionally enables and configures HyperV features  # noqa: E501

        :return: The preferred_hyperv of this V1beta1FeaturePreferences.  # noqa: E501
        :rtype: V1FeatureHyperv
        """
        return self._preferred_hyperv

    @preferred_hyperv.setter
    def preferred_hyperv(self, preferred_hyperv):
        """Sets the preferred_hyperv of this V1beta1FeaturePreferences.

        PreferredHyperv optionally enables and configures HyperV features  # noqa: E501

        :param preferred_hyperv: The preferred_hyperv of this V1beta1FeaturePreferences.  # noqa: E501
        :type: V1FeatureHyperv
        """

        self._preferred_hyperv = preferred_hyperv

    @property
    def preferred_kvm(self):
        """Gets the preferred_kvm of this V1beta1FeaturePreferences.  # noqa: E501

        PreferredKvm optionally enables and configures KVM features  # noqa: E501

        :return: The preferred_kvm of this V1beta1FeaturePreferences.  # noqa: E501
        :rtype: V1FeatureKVM
        """
        return self._preferred_kvm

    @preferred_kvm.setter
    def preferred_kvm(self, preferred_kvm):
        """Sets the preferred_kvm of this V1beta1FeaturePreferences.

        PreferredKvm optionally enables and configures KVM features  # noqa: E501

        :param preferred_kvm: The preferred_kvm of this V1beta1FeaturePreferences.  # noqa: E501
        :type: V1FeatureKVM
        """

        self._preferred_kvm = preferred_kvm

    @property
    def preferred_pvspinlock(self):
        """Gets the preferred_pvspinlock of this V1beta1FeaturePreferences.  # noqa: E501

        PreferredPvspinlock optionally enables the Pvspinlock feature  # noqa: E501

        :return: The preferred_pvspinlock of this V1beta1FeaturePreferences.  # noqa: E501
        :rtype: V1FeatureState
        """
        return self._preferred_pvspinlock

    @preferred_pvspinlock.setter
    def preferred_pvspinlock(self, preferred_pvspinlock):
        """Sets the preferred_pvspinlock of this V1beta1FeaturePreferences.

        PreferredPvspinlock optionally enables the Pvspinlock feature  # noqa: E501

        :param preferred_pvspinlock: The preferred_pvspinlock of this V1beta1FeaturePreferences.  # noqa: E501
        :type: V1FeatureState
        """

        self._preferred_pvspinlock = preferred_pvspinlock

    @property
    def preferred_smm(self):
        """Gets the preferred_smm of this V1beta1FeaturePreferences.  # noqa: E501

        PreferredSmm optionally enables the SMM feature  # noqa: E501

        :return: The preferred_smm of this V1beta1FeaturePreferences.  # noqa: E501
        :rtype: V1FeatureState
        """
        return self._preferred_smm

    @preferred_smm.setter
    def preferred_smm(self, preferred_smm):
        """Sets the preferred_smm of this V1beta1FeaturePreferences.

        PreferredSmm optionally enables the SMM feature  # noqa: E501

        :param preferred_smm: The preferred_smm of this V1beta1FeaturePreferences.  # noqa: E501
        :type: V1FeatureState
        """

        self._preferred_smm = preferred_smm

    def to_dict(self):
        """Returns the model properties as a dict"""
        result = {}

        for attr, _ in six.iteritems(self.swagger_types):
            value = getattr(self, attr)
            if isinstance(value, list):
                result[attr] = list(map(
                    lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
                    value
                ))
            elif hasattr(value, "to_dict"):
                result[attr] = value.to_dict()
            elif isinstance(value, dict):
                result[attr] = dict(map(
                    lambda item: (item[0], item[1].to_dict())
                    if hasattr(item[1], "to_dict") else item,
                    value.items()
                ))
            else:
                result[attr] = value
        if issubclass(V1beta1FeaturePreferences, dict):
            for key, value in self.items():
                result[key] = value

        return result

    def to_str(self):
        """Returns the string representation of the model"""
        return pprint.pformat(self.to_dict())

    def __repr__(self):
        """For `print` and `pprint`"""
        return self.to_str()

    def __eq__(self, other):
        """Returns true if both objects are equal"""
        if not isinstance(other, V1beta1FeaturePreferences):
            return False

        return self.to_dict() == other.to_dict()

    def __ne__(self, other):
        """Returns true if both objects are not equal"""
        if not isinstance(other, V1beta1FeaturePreferences):
            return True

        return self.to_dict() != other.to_dict()
