# coding: utf-8

"""
    Release Manager

    This application generates version for your software.  # noqa: E501

    The version of the OpenAPI document: 0.2.0
    Contact: vitalleshchyk@gmail.com
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six

from client_sdk.configuration import Configuration


class SemverTagSet(object):
    """NOTE: This class is auto generated by OpenAPI Generator.
    Ref: https://openapi-generator.tech

    Do not edit the class manually.
    """

    """
    Attributes:
      openapi_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.
    """
    openapi_types = {
        'all': 'list[str]',
        'full': 'str',
        'minor': 'str',
        'major': 'str',
        'branch': 'str',
        'is_latest': 'bool'
    }

    attribute_map = {
        'all': 'all',
        'full': 'full',
        'minor': 'minor',
        'major': 'major',
        'branch': 'branch',
        'is_latest': 'isLatest'
    }

    def __init__(self, all=None, full=None, minor=None, major=None, branch=None, is_latest=None, local_vars_configuration=None):  # noqa: E501
        """SemverTagSet - a model defined in OpenAPI"""  # noqa: E501
        if local_vars_configuration is None:
            local_vars_configuration = Configuration()
        self.local_vars_configuration = local_vars_configuration

        self._all = None
        self._full = None
        self._minor = None
        self._major = None
        self._branch = None
        self._is_latest = None
        self.discriminator = None

        if all is not None:
            self.all = all
        self.full = full
        if minor is not None:
            self.minor = minor
        if major is not None:
            self.major = major
        if branch is not None:
            self.branch = branch
        self.is_latest = is_latest

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


        :return: The all of this SemverTagSet.  # noqa: E501
        :rtype: list[str]
        """
        return self._all

    @all.setter
    def all(self, all):
        """Sets the all of this SemverTagSet.


        :param all: The all of this SemverTagSet.  # noqa: E501
        :type: list[str]
        """

        self._all = all

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


        :return: The full of this SemverTagSet.  # noqa: E501
        :rtype: str
        """
        return self._full

    @full.setter
    def full(self, full):
        """Sets the full of this SemverTagSet.


        :param full: The full of this SemverTagSet.  # noqa: E501
        :type: str
        """
        if self.local_vars_configuration.client_side_validation and full is None:  # noqa: E501
            raise ValueError("Invalid value for `full`, must not be `None`")  # noqa: E501
        if (self.local_vars_configuration.client_side_validation and
                full is not None and len(full) > 150):
            raise ValueError("Invalid value for `full`, length must be less than or equal to `150`")  # noqa: E501
        if (self.local_vars_configuration.client_side_validation and
                full is not None and len(full) < 3):
            raise ValueError("Invalid value for `full`, length must be greater than or equal to `3`")  # noqa: E501

        self._full = full

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


        :return: The minor of this SemverTagSet.  # noqa: E501
        :rtype: str
        """
        return self._minor

    @minor.setter
    def minor(self, minor):
        """Sets the minor of this SemverTagSet.


        :param minor: The minor of this SemverTagSet.  # noqa: E501
        :type: str
        """
        if (self.local_vars_configuration.client_side_validation and
                minor is not None and len(minor) > 150):
            raise ValueError("Invalid value for `minor`, length must be less than or equal to `150`")  # noqa: E501
        if (self.local_vars_configuration.client_side_validation and
                minor is not None and len(minor) < 3):
            raise ValueError("Invalid value for `minor`, length must be greater than or equal to `3`")  # noqa: E501

        self._minor = minor

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


        :return: The major of this SemverTagSet.  # noqa: E501
        :rtype: str
        """
        return self._major

    @major.setter
    def major(self, major):
        """Sets the major of this SemverTagSet.


        :param major: The major of this SemverTagSet.  # noqa: E501
        :type: str
        """
        if (self.local_vars_configuration.client_side_validation and
                major is not None and len(major) > 150):
            raise ValueError("Invalid value for `major`, length must be less than or equal to `150`")  # noqa: E501
        if (self.local_vars_configuration.client_side_validation and
                major is not None and len(major) < 3):
            raise ValueError("Invalid value for `major`, length must be greater than or equal to `3`")  # noqa: E501

        self._major = major

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


        :return: The branch of this SemverTagSet.  # noqa: E501
        :rtype: str
        """
        return self._branch

    @branch.setter
    def branch(self, branch):
        """Sets the branch of this SemverTagSet.


        :param branch: The branch of this SemverTagSet.  # noqa: E501
        :type: str
        """
        if (self.local_vars_configuration.client_side_validation and
                branch is not None and len(branch) > 150):
            raise ValueError("Invalid value for `branch`, length must be less than or equal to `150`")  # noqa: E501
        if (self.local_vars_configuration.client_side_validation and
                branch is not None and len(branch) < 3):
            raise ValueError("Invalid value for `branch`, length must be greater than or equal to `3`")  # noqa: E501

        self._branch = branch

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


        :return: The is_latest of this SemverTagSet.  # noqa: E501
        :rtype: bool
        """
        return self._is_latest

    @is_latest.setter
    def is_latest(self, is_latest):
        """Sets the is_latest of this SemverTagSet.


        :param is_latest: The is_latest of this SemverTagSet.  # noqa: E501
        :type: bool
        """
        if self.local_vars_configuration.client_side_validation and is_latest is None:  # noqa: E501
            raise ValueError("Invalid value for `is_latest`, must not be `None`")  # noqa: E501

        self._is_latest = is_latest

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

        for attr, _ in six.iteritems(self.openapi_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

        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, SemverTagSet):
            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, SemverTagSet):
            return True

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