# coding: utf-8

"""
    Harmony Connect

    An easy to use API that helps you access the Factom blockchain.  # noqa: E501

    OpenAPI spec version: 1.0.17
    Contact: harmony-support@factom.com
    Generated by: https://openapi-generator.tech
"""


import pprint
import re  # noqa: F401

import six


class ChainCreate(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 = {
        'external_ids': 'list[str]',
        'content': 'str',
        'callback_url': 'str',
        'callback_stages': 'list[str]'
    }

    attribute_map = {
        'external_ids': 'external_ids',
        'content': 'content',
        'callback_url': 'callback_url',
        'callback_stages': 'callback_stages'
    }

    def __init__(self, external_ids=None, content=None, callback_url=None, callback_stages=None):  # noqa: E501
        """ChainCreate - a model defined in OpenAPI"""  # noqa: E501

        self._external_ids = None
        self._content = None
        self._callback_url = None
        self._callback_stages = None
        self.discriminator = None

        self.external_ids = external_ids
        self.content = content
        if callback_url is not None:
            self.callback_url = callback_url
        if callback_stages is not None:
            self.callback_stages = callback_stages

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

        Tags that can be used to identify your chain. You can search for records that contain a particular external_id using Connect. You must send External IDs in Base64 format.  # noqa: E501

        :return: The external_ids of this ChainCreate.  # noqa: E501
        :rtype: list[str]
        """
        return self._external_ids

    @external_ids.setter
    def external_ids(self, external_ids):
        """Sets the external_ids of this ChainCreate.

        Tags that can be used to identify your chain. You can search for records that contain a particular external_id using Connect. You must send External IDs in Base64 format.  # noqa: E501

        :param external_ids: The external_ids of this ChainCreate.  # noqa: E501
        :type: list[str]
        """
        if external_ids is None:
            raise ValueError("Invalid value for `external_ids`, must not be `None`")  # noqa: E501

        self._external_ids = external_ids

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

        This is the data that will make up the first entry in your new chain. It is customary to use this space to describe the entries that are to follow in the chain. You must send the content field in Base64 format.  # noqa: E501

        :return: The content of this ChainCreate.  # noqa: E501
        :rtype: str
        """
        return self._content

    @content.setter
    def content(self, content):
        """Sets the content of this ChainCreate.

        This is the data that will make up the first entry in your new chain. It is customary to use this space to describe the entries that are to follow in the chain. You must send the content field in Base64 format.  # noqa: E501

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

        self._content = content

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

        The URL where you would like to receive the callback from Connect. If this is not specified, callbacks will not activate.  # noqa: E501

        :return: The callback_url of this ChainCreate.  # noqa: E501
        :rtype: str
        """
        return self._callback_url

    @callback_url.setter
    def callback_url(self, callback_url):
        """Sets the callback_url of this ChainCreate.

        The URL where you would like to receive the callback from Connect. If this is not specified, callbacks will not activate.  # noqa: E501

        :param callback_url: The callback_url of this ChainCreate.  # noqa: E501
        :type: str
        """

        self._callback_url = callback_url

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

        The stages that you would like to trigger a callback from Connect. This list can include any or all of the three stages: `replicated`, `factom`, and `anchored`. If callbacks are activated and this field is not sent, it will default to `factom` and `anchored`  # noqa: E501

        :return: The callback_stages of this ChainCreate.  # noqa: E501
        :rtype: list[str]
        """
        return self._callback_stages

    @callback_stages.setter
    def callback_stages(self, callback_stages):
        """Sets the callback_stages of this ChainCreate.

        The stages that you would like to trigger a callback from Connect. This list can include any or all of the three stages: `replicated`, `factom`, and `anchored`. If callbacks are activated and this field is not sent, it will default to `factom` and `anchored`  # noqa: E501

        :param callback_stages: The callback_stages of this ChainCreate.  # noqa: E501
        :type: list[str]
        """

        self._callback_stages = callback_stages

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

        return self.__dict__ == other.__dict__

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