# coding: utf-8

"""
    AssistedInstall

    Assisted installation  # noqa: E501

    OpenAPI spec version: 1.0.0
    
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""


import pprint
import re  # noqa: F401

import six


class ReleaseImage(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 = {
        'openshift_version': 'str',
        'cpu_architecture': 'str',
        'cpu_architectures': 'list[str]',
        'url': 'str',
        'version': 'str',
        'default': 'bool',
        'support_level': 'str'
    }

    attribute_map = {
        'openshift_version': 'openshift_version',
        'cpu_architecture': 'cpu_architecture',
        'cpu_architectures': 'cpu_architectures',
        'url': 'url',
        'version': 'version',
        'default': 'default',
        'support_level': 'support_level'
    }

    def __init__(self, openshift_version=None, cpu_architecture='x86_64', cpu_architectures=None, url=None, version=None, default=None, support_level=None):  # noqa: E501
        """ReleaseImage - a model defined in Swagger"""  # noqa: E501

        self._openshift_version = None
        self._cpu_architecture = None
        self._cpu_architectures = None
        self._url = None
        self._version = None
        self._default = None
        self._support_level = None
        self.discriminator = None

        self.openshift_version = openshift_version
        self.cpu_architecture = cpu_architecture
        if cpu_architectures is not None:
            self.cpu_architectures = cpu_architectures
        self.url = url
        self.version = version
        if default is not None:
            self.default = default
        if support_level is not None:
            self.support_level = support_level

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

        Version of the OpenShift cluster.  # noqa: E501

        :return: The openshift_version of this ReleaseImage.  # noqa: E501
        :rtype: str
        """
        return self._openshift_version

    @openshift_version.setter
    def openshift_version(self, openshift_version):
        """Sets the openshift_version of this ReleaseImage.

        Version of the OpenShift cluster.  # noqa: E501

        :param openshift_version: The openshift_version of this ReleaseImage.  # noqa: E501
        :type: str
        """
        if openshift_version is None:
            raise ValueError("Invalid value for `openshift_version`, must not be `None`")  # noqa: E501

        self._openshift_version = openshift_version

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

        (DEPRECATED) The CPU architecture of the image (x86_64/arm64/etc).  # noqa: E501

        :return: The cpu_architecture of this ReleaseImage.  # noqa: E501
        :rtype: str
        """
        return self._cpu_architecture

    @cpu_architecture.setter
    def cpu_architecture(self, cpu_architecture):
        """Sets the cpu_architecture of this ReleaseImage.

        (DEPRECATED) The CPU architecture of the image (x86_64/arm64/etc).  # noqa: E501

        :param cpu_architecture: The cpu_architecture of this ReleaseImage.  # noqa: E501
        :type: str
        """
        if cpu_architecture is None:
            raise ValueError("Invalid value for `cpu_architecture`, must not be `None`")  # noqa: E501
        allowed_values = ["x86_64", "aarch64", "arm64", "ppc64le", "s390x", "multi"]  # noqa: E501
        if cpu_architecture not in allowed_values:
            raise ValueError(
                "Invalid value for `cpu_architecture` ({0}), must be one of {1}"  # noqa: E501
                .format(cpu_architecture, allowed_values)
            )

        self._cpu_architecture = cpu_architecture

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

        List of CPU architectures provided by the image.  # noqa: E501

        :return: The cpu_architectures of this ReleaseImage.  # noqa: E501
        :rtype: list[str]
        """
        return self._cpu_architectures

    @cpu_architectures.setter
    def cpu_architectures(self, cpu_architectures):
        """Sets the cpu_architectures of this ReleaseImage.

        List of CPU architectures provided by the image.  # noqa: E501

        :param cpu_architectures: The cpu_architectures of this ReleaseImage.  # noqa: E501
        :type: list[str]
        """

        self._cpu_architectures = cpu_architectures

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

        The installation image of the OpenShift cluster.  # noqa: E501

        :return: The url of this ReleaseImage.  # noqa: E501
        :rtype: str
        """
        return self._url

    @url.setter
    def url(self, url):
        """Sets the url of this ReleaseImage.

        The installation image of the OpenShift cluster.  # noqa: E501

        :param url: The url of this ReleaseImage.  # noqa: E501
        :type: str
        """
        if url is None:
            raise ValueError("Invalid value for `url`, must not be `None`")  # noqa: E501

        self._url = url

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

        OCP version from the release metadata.  # noqa: E501

        :return: The version of this ReleaseImage.  # noqa: E501
        :rtype: str
        """
        return self._version

    @version.setter
    def version(self, version):
        """Sets the version of this ReleaseImage.

        OCP version from the release metadata.  # noqa: E501

        :param version: The version of this ReleaseImage.  # noqa: E501
        :type: str
        """
        if version is None:
            raise ValueError("Invalid value for `version`, must not be `None`")  # noqa: E501

        self._version = version

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

        Indication that the version is the recommended one.  # noqa: E501

        :return: The default of this ReleaseImage.  # noqa: E501
        :rtype: bool
        """
        return self._default

    @default.setter
    def default(self, default):
        """Sets the default of this ReleaseImage.

        Indication that the version is the recommended one.  # noqa: E501

        :param default: The default of this ReleaseImage.  # noqa: E501
        :type: bool
        """

        self._default = default

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

        Level of support of the version.  # noqa: E501

        :return: The support_level of this ReleaseImage.  # noqa: E501
        :rtype: str
        """
        return self._support_level

    @support_level.setter
    def support_level(self, support_level):
        """Sets the support_level of this ReleaseImage.

        Level of support of the version.  # noqa: E501

        :param support_level: The support_level of this ReleaseImage.  # noqa: E501
        :type: str
        """
        allowed_values = ["beta", "production", "maintenance", "end-of-life"]  # noqa: E501
        if support_level not in allowed_values:
            raise ValueError(
                "Invalid value for `support_level` ({0}), must be one of {1}"  # noqa: E501
                .format(support_level, allowed_values)
            )

        self._support_level = support_level

    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(ReleaseImage, 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, ReleaseImage):
            return False

        return self.__dict__ == other.__dict__

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