# coding: utf-8

"""
    Spotii Billing API

    API for Billing  # noqa: E501

    OpenAPI spec version: v1.0
    Contact: hello@nuclearo.com
    Generated by: https://github.com/swagger-api/swagger-codegen.git
"""

import pprint
import re  # noqa: F401

import six


class BillingAddress(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 = {
        'billing_address_id': 'str',
        'external_key': 'str',
        'name': 'str',
        'first_name_len': 'int',
        'email': 'str',
        'phone': 'str',
        'country': 'str',
        'city': 'str',
        'state': 'str',
        'address1': 'str',
        'address2': 'str',
        'address3': 'str',
        'postal_code': 'str',
        'company': 'str',
        'notes': 'str',
        'is_default': 'bool',
        'created_at': 'datetime',
        'updated_at': 'datetime',
        'deleted_at': 'datetime'
    }

    attribute_map = {
        'billing_address_id': 'billing_address_id',
        'external_key': 'external_key',
        'name': 'name',
        'first_name_len': 'first_name_len',
        'email': 'email',
        'phone': 'phone',
        'country': 'country',
        'city': 'city',
        'state': 'state',
        'address1': 'address1',
        'address2': 'address2',
        'address3': 'address3',
        'postal_code': 'postal_code',
        'company': 'company',
        'notes': 'notes',
        'is_default': 'is_default',
        'created_at': 'created_at',
        'updated_at': 'updated_at',
        'deleted_at': 'deleted_at'
    }

    def __init__(self, billing_address_id=None, external_key=None, name=None, first_name_len=None, email=None, phone=None, country=None, city=None, state=None, address1=None, address2=None, address3=None, postal_code=None, company=None, notes=None, is_default=None, created_at=None, updated_at=None, deleted_at=None):  # noqa: E501
        """BillingAddress - a model defined in Swagger"""  # noqa: E501
        self._billing_address_id = None
        self._external_key = None
        self._name = None
        self._first_name_len = None
        self._email = None
        self._phone = None
        self._country = None
        self._city = None
        self._state = None
        self._address1 = None
        self._address2 = None
        self._address3 = None
        self._postal_code = None
        self._company = None
        self._notes = None
        self._is_default = None
        self._created_at = None
        self._updated_at = None
        self._deleted_at = None
        self.discriminator = None
        if billing_address_id is not None:
            self.billing_address_id = billing_address_id
        if external_key is not None:
            self.external_key = external_key
        if name is not None:
            self.name = name
        if first_name_len is not None:
            self.first_name_len = first_name_len
        if email is not None:
            self.email = email
        if phone is not None:
            self.phone = phone
        if country is not None:
            self.country = country
        if city is not None:
            self.city = city
        if state is not None:
            self.state = state
        if address1 is not None:
            self.address1 = address1
        if address2 is not None:
            self.address2 = address2
        if address3 is not None:
            self.address3 = address3
        if postal_code is not None:
            self.postal_code = postal_code
        if company is not None:
            self.company = company
        if notes is not None:
            self.notes = notes
        if is_default is not None:
            self.is_default = is_default
        if created_at is not None:
            self.created_at = created_at
        if updated_at is not None:
            self.updated_at = updated_at
        if deleted_at is not None:
            self.deleted_at = deleted_at

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


        :return: The billing_address_id of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._billing_address_id

    @billing_address_id.setter
    def billing_address_id(self, billing_address_id):
        """Sets the billing_address_id of this BillingAddress.


        :param billing_address_id: The billing_address_id of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._billing_address_id = billing_address_id

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


        :return: The external_key of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._external_key

    @external_key.setter
    def external_key(self, external_key):
        """Sets the external_key of this BillingAddress.


        :param external_key: The external_key of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._external_key = external_key

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


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

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


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

        self._name = name

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


        :return: The first_name_len of this BillingAddress.  # noqa: E501
        :rtype: int
        """
        return self._first_name_len

    @first_name_len.setter
    def first_name_len(self, first_name_len):
        """Sets the first_name_len of this BillingAddress.


        :param first_name_len: The first_name_len of this BillingAddress.  # noqa: E501
        :type: int
        """

        self._first_name_len = first_name_len

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


        :return: The email of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._email

    @email.setter
    def email(self, email):
        """Sets the email of this BillingAddress.


        :param email: The email of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._email = email

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


        :return: The phone of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._phone

    @phone.setter
    def phone(self, phone):
        """Sets the phone of this BillingAddress.


        :param phone: The phone of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._phone = phone

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


        :return: The country of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._country

    @country.setter
    def country(self, country):
        """Sets the country of this BillingAddress.


        :param country: The country of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._country = country

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


        :return: The city of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._city

    @city.setter
    def city(self, city):
        """Sets the city of this BillingAddress.


        :param city: The city of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._city = city

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


        :return: The state of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._state

    @state.setter
    def state(self, state):
        """Sets the state of this BillingAddress.


        :param state: The state of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._state = state

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


        :return: The address1 of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._address1

    @address1.setter
    def address1(self, address1):
        """Sets the address1 of this BillingAddress.


        :param address1: The address1 of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._address1 = address1

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


        :return: The address2 of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._address2

    @address2.setter
    def address2(self, address2):
        """Sets the address2 of this BillingAddress.


        :param address2: The address2 of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._address2 = address2

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


        :return: The address3 of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._address3

    @address3.setter
    def address3(self, address3):
        """Sets the address3 of this BillingAddress.


        :param address3: The address3 of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._address3 = address3

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


        :return: The postal_code of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._postal_code

    @postal_code.setter
    def postal_code(self, postal_code):
        """Sets the postal_code of this BillingAddress.


        :param postal_code: The postal_code of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._postal_code = postal_code

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


        :return: The company of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._company

    @company.setter
    def company(self, company):
        """Sets the company of this BillingAddress.


        :param company: The company of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._company = company

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


        :return: The notes of this BillingAddress.  # noqa: E501
        :rtype: str
        """
        return self._notes

    @notes.setter
    def notes(self, notes):
        """Sets the notes of this BillingAddress.


        :param notes: The notes of this BillingAddress.  # noqa: E501
        :type: str
        """

        self._notes = notes

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


        :return: The is_default of this BillingAddress.  # noqa: E501
        :rtype: bool
        """
        return self._is_default

    @is_default.setter
    def is_default(self, is_default):
        """Sets the is_default of this BillingAddress.


        :param is_default: The is_default of this BillingAddress.  # noqa: E501
        :type: bool
        """

        self._is_default = is_default

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


        :return: The created_at of this BillingAddress.  # noqa: E501
        :rtype: datetime
        """
        return self._created_at

    @created_at.setter
    def created_at(self, created_at):
        """Sets the created_at of this BillingAddress.


        :param created_at: The created_at of this BillingAddress.  # noqa: E501
        :type: datetime
        """

        self._created_at = created_at

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


        :return: The updated_at of this BillingAddress.  # noqa: E501
        :rtype: datetime
        """
        return self._updated_at

    @updated_at.setter
    def updated_at(self, updated_at):
        """Sets the updated_at of this BillingAddress.


        :param updated_at: The updated_at of this BillingAddress.  # noqa: E501
        :type: datetime
        """

        self._updated_at = updated_at

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


        :return: The deleted_at of this BillingAddress.  # noqa: E501
        :rtype: datetime
        """
        return self._deleted_at

    @deleted_at.setter
    def deleted_at(self, deleted_at):
        """Sets the deleted_at of this BillingAddress.


        :param deleted_at: The deleted_at of this BillingAddress.  # noqa: E501
        :type: datetime
        """

        self._deleted_at = deleted_at

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

        return self.__dict__ == other.__dict__

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