# coding: utf-8

"""
    Pdf4me

    No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)  # noqa: E501

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


import pprint
import re  # noqa: F401

import six

from pdf4me.model.integration_config import IntegrationConfig  # noqa: F401,E501


class Integration(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 = {
        'integration_id': 'str',
        'folder': 'str',
        'integration_alias': 'str',
        'name': 'str',
        'integration_type': 'str',
        'integration_config': 'IntegrationConfig',
        'application_id': 'str',
        'enabled': 'bool',
        'basic_token': 'str',
        'mod_date': 'datetime',
        'mod_name': 'str',
        'url': 'str',
        'request_type': 'str',
        'execution_order': 'int'
    }

    attribute_map = {
        'integration_id': 'integrationId',
        'folder': 'folder',
        'integration_alias': 'integrationAlias',
        'name': 'name',
        'integration_type': 'integrationType',
        'integration_config': 'integrationConfig',
        'application_id': 'applicationId',
        'enabled': 'enabled',
        'basic_token': 'basicToken',
        'mod_date': 'modDate',
        'mod_name': 'modName',
        'url': 'url',
        'request_type': 'requestType',
        'execution_order': 'executionOrder'
    }

    def __init__(self, integration_id=None, folder=None, integration_alias=None, name=None, integration_type=None, integration_config=None, application_id=None, enabled=None, basic_token=None, mod_date=None, mod_name=None, url=None, request_type=None, execution_order=None):  # noqa: E501
        """Integration - a model defined in Swagger"""  # noqa: E501

        self._integration_id = None
        self._folder = None
        self._integration_alias = None
        self._name = None
        self._integration_type = None
        self._integration_config = None
        self._application_id = None
        self._enabled = None
        self._basic_token = None
        self._mod_date = None
        self._mod_name = None
        self._url = None
        self._request_type = None
        self._execution_order = None
        self.discriminator = None

        if integration_id is not None:
            self.integration_id = integration_id
        if folder is not None:
            self.folder = folder
        if integration_alias is not None:
            self.integration_alias = integration_alias
        if name is not None:
            self.name = name
        if integration_type is not None:
            self.integration_type = integration_type
        if integration_config is not None:
            self.integration_config = integration_config
        if application_id is not None:
            self.application_id = application_id
        if enabled is not None:
            self.enabled = enabled
        if basic_token is not None:
            self.basic_token = basic_token
        if mod_date is not None:
            self.mod_date = mod_date
        if mod_name is not None:
            self.mod_name = mod_name
        if url is not None:
            self.url = url
        if request_type is not None:
            self.request_type = request_type
        if execution_order is not None:
            self.execution_order = execution_order

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


        :return: The integration_id of this Integration.  # noqa: E501
        :rtype: str
        """
        return self._integration_id

    @integration_id.setter
    def integration_id(self, integration_id):
        """Sets the integration_id of this Integration.


        :param integration_id: The integration_id of this Integration.  # noqa: E501
        :type: str
        """

        self._integration_id = integration_id

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


        :return: The folder of this Integration.  # noqa: E501
        :rtype: str
        """
        return self._folder

    @folder.setter
    def folder(self, folder):
        """Sets the folder of this Integration.


        :param folder: The folder of this Integration.  # noqa: E501
        :type: str
        """

        self._folder = folder

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


        :return: The integration_alias of this Integration.  # noqa: E501
        :rtype: str
        """
        return self._integration_alias

    @integration_alias.setter
    def integration_alias(self, integration_alias):
        """Sets the integration_alias of this Integration.


        :param integration_alias: The integration_alias of this Integration.  # noqa: E501
        :type: str
        """

        self._integration_alias = integration_alias

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


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

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


        :param name: The name of this Integration.  # noqa: E501
        :type: str
        """

        self._name = name

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


        :return: The integration_type of this Integration.  # noqa: E501
        :rtype: str
        """
        return self._integration_type

    @integration_type.setter
    def integration_type(self, integration_type):
        """Sets the integration_type of this Integration.


        :param integration_type: The integration_type of this Integration.  # noqa: E501
        :type: str
        """
        allowed_values = ["none", "azureStorage", "oneDrive", "sFTP", "fTP", "amazonS3", "amazonGlacier", "googleCloud", "googleDrive", "webHook", "dropbox", "azureBus", "awsSQS", "awsSNS", "azureEventHub", "signingSwissQuoVadisSealsign"]  # noqa: E501
        if integration_type not in allowed_values:
            raise ValueError(
                "Invalid value for `integration_type` ({0}), must be one of {1}"  # noqa: E501
                .format(integration_type, allowed_values)
            )

        self._integration_type = integration_type

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


        :return: The integration_config of this Integration.  # noqa: E501
        :rtype: IntegrationConfig
        """
        return self._integration_config

    @integration_config.setter
    def integration_config(self, integration_config):
        """Sets the integration_config of this Integration.


        :param integration_config: The integration_config of this Integration.  # noqa: E501
        :type: IntegrationConfig
        """

        self._integration_config = integration_config

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


        :return: The application_id of this Integration.  # noqa: E501
        :rtype: str
        """
        return self._application_id

    @application_id.setter
    def application_id(self, application_id):
        """Sets the application_id of this Integration.


        :param application_id: The application_id of this Integration.  # noqa: E501
        :type: str
        """

        self._application_id = application_id

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


        :return: The enabled of this Integration.  # noqa: E501
        :rtype: bool
        """
        return self._enabled

    @enabled.setter
    def enabled(self, enabled):
        """Sets the enabled of this Integration.


        :param enabled: The enabled of this Integration.  # noqa: E501
        :type: bool
        """

        self._enabled = enabled

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


        :return: The basic_token of this Integration.  # noqa: E501
        :rtype: str
        """
        return self._basic_token

    @basic_token.setter
    def basic_token(self, basic_token):
        """Sets the basic_token of this Integration.


        :param basic_token: The basic_token of this Integration.  # noqa: E501
        :type: str
        """

        self._basic_token = basic_token

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


        :return: The mod_date of this Integration.  # noqa: E501
        :rtype: datetime
        """
        return self._mod_date

    @mod_date.setter
    def mod_date(self, mod_date):
        """Sets the mod_date of this Integration.


        :param mod_date: The mod_date of this Integration.  # noqa: E501
        :type: datetime
        """

        self._mod_date = mod_date

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


        :return: The mod_name of this Integration.  # noqa: E501
        :rtype: str
        """
        return self._mod_name

    @mod_name.setter
    def mod_name(self, mod_name):
        """Sets the mod_name of this Integration.


        :param mod_name: The mod_name of this Integration.  # noqa: E501
        :type: str
        """

        self._mod_name = mod_name

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


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

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


        :param url: The url of this Integration.  # noqa: E501
        :type: str
        """

        self._url = url

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


        :return: The request_type of this Integration.  # noqa: E501
        :rtype: str
        """
        return self._request_type

    @request_type.setter
    def request_type(self, request_type):
        """Sets the request_type of this Integration.


        :param request_type: The request_type of this Integration.  # noqa: E501
        :type: str
        """
        allowed_values = ["none", "all", "onRequest"]  # noqa: E501
        if request_type not in allowed_values:
            raise ValueError(
                "Invalid value for `request_type` ({0}), must be one of {1}"  # noqa: E501
                .format(request_type, allowed_values)
            )

        self._request_type = request_type

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


        :return: The execution_order of this Integration.  # noqa: E501
        :rtype: int
        """
        return self._execution_order

    @execution_order.setter
    def execution_order(self, execution_order):
        """Sets the execution_order of this Integration.


        :param execution_order: The execution_order of this Integration.  # noqa: E501
        :type: int
        """

        self._execution_order = execution_order

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

        return self.__dict__ == other.__dict__

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