# coding: utf-8

"""
    DagsHub API

    The api docs are made with SwaggerUI using the OpenAPI 3 specification.   # noqa: E501

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

import pprint
import re  # noqa: F401

import six

class CreateRepo(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 = {
        'name': 'str',
        'description': 'str',
        'private': 'bool',
        'auto_init': 'bool',
        'gitignores': 'str',
        'license': 'str',
        'readme': 'str'
    }

    attribute_map = {
        'name': 'name',
        'description': 'description',
        'private': 'private',
        'auto_init': 'auto_init',
        'gitignores': 'gitignores',
        'license': 'license',
        'readme': 'readme'
    }

    def __init__(self, name=None, description=None, private=False, auto_init=False, gitignores=None, license=None, readme='Default'):  # noqa: E501
        """CreateRepo - a model defined in Swagger"""  # noqa: E501
        self._name = None
        self._description = None
        self._private = None
        self._auto_init = None
        self._gitignores = None
        self._license = None
        self._readme = None
        self.discriminator = None
        self.name = name
        if description is not None:
            self.description = description
        if private is not None:
            self.private = private
        if auto_init is not None:
            self.auto_init = auto_init
        if gitignores is not None:
            self.gitignores = gitignores
        if license is not None:
            self.license = license
        if readme is not None:
            self.readme = readme

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

        name of the repository  # noqa: E501

        :return: The name of this CreateRepo.  # noqa: E501
        :rtype: str
        """
        return self._name

    @name.setter
    def name(self, name):
        """Sets the name of this CreateRepo.

        name of the repository  # noqa: E501

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

        self._name = name

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

        A short description of the repository  # noqa: E501

        :return: The description of this CreateRepo.  # noqa: E501
        :rtype: str
        """
        return self._description

    @description.setter
    def description(self, description):
        """Sets the description of this CreateRepo.

        A short description of the repository  # noqa: E501

        :param description: The description of this CreateRepo.  # noqa: E501
        :type: str
        """

        self._description = description

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

        Either true to create a private repository, or false to create a public one.  # noqa: E501

        :return: The private of this CreateRepo.  # noqa: E501
        :rtype: bool
        """
        return self._private

    @private.setter
    def private(self, private):
        """Sets the private of this CreateRepo.

        Either true to create a private repository, or false to create a public one.  # noqa: E501

        :param private: The private of this CreateRepo.  # noqa: E501
        :type: bool
        """

        self._private = private

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

        Pass true to create an initial commit with README, .gitignore and LICENSE.  # noqa: E501

        :return: The auto_init of this CreateRepo.  # noqa: E501
        :rtype: bool
        """
        return self._auto_init

    @auto_init.setter
    def auto_init(self, auto_init):
        """Sets the auto_init of this CreateRepo.

        Pass true to create an initial commit with README, .gitignore and LICENSE.  # noqa: E501

        :param auto_init: The auto_init of this CreateRepo.  # noqa: E501
        :type: bool
        """

        self._auto_init = auto_init

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

        Desired language .gitignore templates to apply. Use the name of the templates.  # noqa: E501

        :return: The gitignores of this CreateRepo.  # noqa: E501
        :rtype: str
        """
        return self._gitignores

    @gitignores.setter
    def gitignores(self, gitignores):
        """Sets the gitignores of this CreateRepo.

        Desired language .gitignore templates to apply. Use the name of the templates.  # noqa: E501

        :param gitignores: The gitignores of this CreateRepo.  # noqa: E501
        :type: str
        """

        self._gitignores = gitignores

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

        Desired LICENSE template to apply. Use the name of the template.  # noqa: E501

        :return: The license of this CreateRepo.  # noqa: E501
        :rtype: str
        """
        return self._license

    @license.setter
    def license(self, license):
        """Sets the license of this CreateRepo.

        Desired LICENSE template to apply. Use the name of the template.  # noqa: E501

        :param license: The license of this CreateRepo.  # noqa: E501
        :type: str
        """
        allowed_values = ["Apache License 2.0", "MIT License", "Abstyles License", "Academic Free License v1.1", "Academic Free License v1.2", "Academic Free License v2.0", "Academic Free License v2.1", "Academic Free License v3.0", "Affero General Public License v1.0", "Apache License 1.0", "Apache License 1.1", "Artistic License 1.0", "Artistic License 2.0", "BSD 2-clause License", "BSD 3-clause License", "BSD 4-clause License", "Creative Commons CC0 1.0 Universal", "Eclipse Public License 1.0", "Educational Community License v1.0", "Educational Community License v2.0", "GNU Affero General Public License v3.0", "GNU Free Documentation License v1.1", "GNU Free Documentation License v1.2", "GNU Free Documentation License v1.3", "GNU General Public License v1.0", "GNU General Public License v2.0", "GNU General Public License v3.0", "GNU Lesser General Public License v2.1", "GNU Lesser General Public License v3.0", "GNU Library General Public License v2.0", "ISC license", "Mozilla Public License 1.0", "Mozilla Public License 1.1", "Mozilla Public License 2.03"]  # noqa: E501
        if license not in allowed_values:
            raise ValueError(
                "Invalid value for `license` ({0}), must be one of {1}"  # noqa: E501
                .format(license, allowed_values)
            )

        self._license = license

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

        Desired README template to apply. Use the name of the template.  # noqa: E501

        :return: The readme of this CreateRepo.  # noqa: E501
        :rtype: str
        """
        return self._readme

    @readme.setter
    def readme(self, readme):
        """Sets the readme of this CreateRepo.

        Desired README template to apply. Use the name of the template.  # noqa: E501

        :param readme: The readme of this CreateRepo.  # noqa: E501
        :type: str
        """

        self._readme = readme

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

        return self.__dict__ == other.__dict__

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