# coding: utf-8

"""
    farm API

    farm API documentation  # noqa: E501

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

import pprint
import re  # noqa: F401

import six

class PreferencesDto(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 = {
        'area_units': 'str',
        'currency': 'str',
        'data': 'dict(str, object)',
        'id': 'int',
        'language': 'str',
        'locations': 'list[LocationDto]',
        'time_zone': 'str'
    }

    attribute_map = {
        'area_units': 'areaUnits',
        'currency': 'currency',
        'data': 'data',
        'id': 'id',
        'language': 'language',
        'locations': 'locations',
        'time_zone': 'timeZone'
    }

    def __init__(self, area_units=None, currency=None, data=None, id=None, language=None, locations=None, time_zone=None):  # noqa: E501
        """PreferencesDto - a model defined in Swagger"""  # noqa: E501
        self._area_units = None
        self._currency = None
        self._data = None
        self._id = None
        self._language = None
        self._locations = None
        self._time_zone = None
        self.discriminator = None
        if area_units is not None:
            self.area_units = area_units
        if currency is not None:
            self.currency = currency
        if data is not None:
            self.data = data
        if id is not None:
            self.id = id
        if language is not None:
            self.language = language
        if locations is not None:
            self.locations = locations
        if time_zone is not None:
            self.time_zone = time_zone

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


        :return: The area_units of this PreferencesDto.  # noqa: E501
        :rtype: str
        """
        return self._area_units

    @area_units.setter
    def area_units(self, area_units):
        """Sets the area_units of this PreferencesDto.


        :param area_units: The area_units of this PreferencesDto.  # noqa: E501
        :type: str
        """
        allowed_values = ["HECTARE", "ACRE", "SQUARE_METER", "SQUARE_FOOT", "SQUARE_KILOMETER", "SQUARE_MILE", "SQUARE_YARD", "BIGHA", "GUNTA", "RAI", "DECIMAL_UNIT"]  # noqa: E501
        if area_units not in allowed_values:
            raise ValueError(
                "Invalid value for `area_units` ({0}), must be one of {1}"  # noqa: E501
                .format(area_units, allowed_values)
            )

        self._area_units = area_units

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


        :return: The currency of this PreferencesDto.  # noqa: E501
        :rtype: str
        """
        return self._currency

    @currency.setter
    def currency(self, currency):
        """Sets the currency of this PreferencesDto.


        :param currency: The currency of this PreferencesDto.  # noqa: E501
        :type: str
        """
        allowed_values = ["DOLLAR", "INR", "YEN", "GBP", "UKRAINIAN_HRYNVIA", "AFGHAN_AFGHANI", "EUROPEAN_EURO", "ALBANIAN_LEK", "ALGERIAN_DINAR", "UNITED_STATES_DOLLAR", "ANGOLAN_KWANZA", "EAST_CARIBBEAN_DOLLAR", "ARGENTINE_PESO", "ARMENIAN_DRAM", "ARUBAN_FLORIN", "SAINT_HELENA_POUND", "AUSTRALIAN_DOLLAR", "AZERBAIJAN_MANAT", "BAHAMIAN_DOLLAR", "BAHRAINI_DINAR", "BANGLADESHI_TAKA", "BARBADIAN_DOLLAR", "BELARUSIAN_RUBLE", "BELIZE_DOLLAR", "WEST_AFRICAN_CFA_FRANC", "BERMUDIAN_DOLLAR", "BHUTANESE_NGULTRUM", "BOLIVIAN_BOLIVIANO", "BOSNIA_AND_HERZEGOVINA_CONVERTIBLE_MARK", "BOTSWANA_PULA", "BRAZILIAN_REAL", "BRUNEI_DOLLAR", "BULGARIAN_LEV", "BURUNDI_FRANC", "CAPE_VERDEAN_ESCUDO", "CAMBODIAN_RIEL", "CENTRAL_AFRICAN_CFA_FRANC", "CANADIAN_DOLLAR", "CAYMAN_ISLANDS_DOLLAR", "NEW_ZEALAND_DOLLAR", "CHILEAN_PESO", "CHINESE_YUAN_RENMINBI", "COLOMBIAN_PESO", "COMORIAN_FRANC", "CONGOLESE_FRANC", "COOK_ISLANDS_DOLLAR", "COSTA_RICAN_COLON", "CROATIAN_KUNA", "CUBAN_PESO", "NETHERLANDS_ANTILLEAN_GUILDER", "CZECH_KORUNA", "DANISH_KRONE", "DJIBOUTIAN_FRANC", "DOMINICAN_PESO", "EGYPTIAN_POUND", "ERITREAN_NAKFA", "SWAZI_LILANGENI", "ETHIOPIAN_BIRR", "FALKLAND_ISLANDS_POUND", "FAROESE_KRONA", "FIJIAN_DOLLAR", "CFP_FRANC", "GAMBIAN_DALASI", "GEORGIAN_LARI", "GHANAIAN_CEDI", "GIBRALTAR_POUND", "GUATEMALAN_QUETZAL", "GUERNSEY_POUND", "GUINEAN_FRANC", "GUYANESE_DOLLAR", "HAITIAN_GOURDE", "HONDURAN_LEMPIRA", "HONG_KONG_DOLLAR", "HUNGARIAN_FORINT", "ICELANDIC_KRONA", "INDIAN_RUPEE", "INDONESIAN_RUPIAH", "IRANIAN_RIAL", "IRAQI_DINAR", "MANX_POUND", "ISRAELI_NEW_SHEKEL", "JAMAICAN_DOLLAR", "JAPANESE_YEN", "JERSEY_POUND", "JORDANIAN_DINAR", "KAZAKHSTANI_TENGE", "KENYAN_SHILLING", "KUWAITI_DINAR", "KYRGYZSTANI_SOM", "LAO_KIP", "LEBANESE_POUND", "LESOTHO_LOTI", "LIBERIAN_DOLLAR", "LIBYAN_DINAR", "SWISS_FRANC", "MACANESE_PATACA", "MALAGASY_ARIARY", "MALAWIAN_KWACHA", "MALAYSIAN_RINGGIT", "MALDIVIAN_RUFIYAA", "MAURITANIAN_OUGUIYA", "MAURITIAN_RUPEE", "MEXICAN_PESO", "MOLDOVAN_LEU", "MONGOLIAN_TUGRIK", "MOROCCAN_DIRHAM", "MOZAMBICAN_METICAL", "MYANMAR_KYAT", "NAMIBIAN_DOLLAR", "NEPALESE_RUPEE", "NICARAGUAN_CORDOBA", "NIGERIAN_NAIRA", "NORTH_KOREAN_WON", "MACEDONIAN_DENAR", "NORWEGIAN_KRONE", "OMANI_RIAL", "PAKISTANI_RUPEE", "PAPUA_NEW_GUINEAN_KINA", "PARAGUAYAN_GUARANI", "PERUVIAN_SOL", "PHILIPPINE_PESO", "POLISH_ZLOTY", "QATARI_RIYAL", "ROMANIAN_LEU", "RUSSIAN_RUBLE", "RWANDAN_FRANC", "SAMOAN_TALA", "SAO_TOME_AND_PRINCIPE_DOBRA", "SAUDI_ARABIAN_RIYAL", "SERBIAN_DINAR", "SEYCHELLOIS_RUPEE", "SIERRA_LEONEAN_LEONE", "SINGAPORE_DOLLAR", "SOLOMON_ISLANDS_DOLLAR", "SOMALI_SHILLING", "SOUTH_AFRICAN_RAND", "POUND_STERLING", "SOUTH_KOREAN_WON", "SOUTH_SUDANESE_POUND", "SRI_LANKAN_RUPEE", "SUDANESE_POUND", "SURINAMESE_DOLLAR", "SWEDISH_KRONA", "SYRIAN_POUND", "NEW_TAIWAN_DOLLAR", "TAJIKISTANI_SOMONI", "TANZANIAN_SHILLING", "THAI_BAHT", "TONGAN_PA_ANGA", "TRINIDAD_AND_TOBAGO_DOLLAR", "TUNISIAN_DINAR", "TURKISH_LIRA", "TURKMEN_MANAT", "UGANDAN_SHILLING", "UKRAINIAN_HRYVNIA", "UAE_DIRHAM", "URUGUAYAN_PESO", "UZBEKISTANI_SOM", "VANUATU_VATU", "VENEZUELAN_BOLIVAR", "VIETNAMESE_DONG", "YEMENI_RIAL", "ZAMBIAN_KWACHA"]  # noqa: E501
        if currency not in allowed_values:
            raise ValueError(
                "Invalid value for `currency` ({0}), must be one of {1}"  # noqa: E501
                .format(currency, allowed_values)
            )

        self._currency = currency

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


        :return: The data of this PreferencesDto.  # noqa: E501
        :rtype: dict(str, object)
        """
        return self._data

    @data.setter
    def data(self, data):
        """Sets the data of this PreferencesDto.


        :param data: The data of this PreferencesDto.  # noqa: E501
        :type: dict(str, object)
        """

        self._data = data

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


        :return: The id of this PreferencesDto.  # noqa: E501
        :rtype: int
        """
        return self._id

    @id.setter
    def id(self, id):
        """Sets the id of this PreferencesDto.


        :param id: The id of this PreferencesDto.  # noqa: E501
        :type: int
        """

        self._id = id

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


        :return: The language of this PreferencesDto.  # noqa: E501
        :rtype: str
        """
        return self._language

    @language.setter
    def language(self, language):
        """Sets the language of this PreferencesDto.


        :param language: The language of this PreferencesDto.  # noqa: E501
        :type: str
        """

        self._language = language

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


        :return: The locations of this PreferencesDto.  # noqa: E501
        :rtype: list[LocationDto]
        """
        return self._locations

    @locations.setter
    def locations(self, locations):
        """Sets the locations of this PreferencesDto.


        :param locations: The locations of this PreferencesDto.  # noqa: E501
        :type: list[LocationDto]
        """

        self._locations = locations

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


        :return: The time_zone of this PreferencesDto.  # noqa: E501
        :rtype: str
        """
        return self._time_zone

    @time_zone.setter
    def time_zone(self, time_zone):
        """Sets the time_zone of this PreferencesDto.


        :param time_zone: The time_zone of this PreferencesDto.  # noqa: E501
        :type: str
        """
        allowed_values = ["ACDT", "ACST", "ADT", "BKK", "BRT", "BTT", "CAT", "CST", "EST", "IST", "IRST", "ICT", "WITA", "WIB", "WIT", "PST", "EET", "A", "ACT", "ACWST", "AEDT", "AEST", "AET", "AFT", "AKDT", "AKST", "ALMT", "AMST", "AMT", "ANAST", "ANAT", "AQTT", "ART", "AST", "AT", "AWDT", "AWST", "AZOST", "AZOT", "AZST", "AZT", "AoE", "B", "BNT", "BOT", "BRST", "BST", "C", "CAST", "CCT", "CDT", "CEST", "CET", "CHADT", "CHAST", "CHOST", "CHOT", "CHUT", "CIDST", "CIST", "CKT", "CLST", "CLT", "COT", "CT", "CVT", "CXT", "CHST", "D", "DAVT", "DDUT", "E", "EASST", "EAST", "EAT", "ECT", "EDT", "EEST", "EGST", "EGT", "ET", "F", "FET", "FJST", "FJT", "FKST", "FKT", "FNT", "G", "GALT", "GAMT", "GET", "GFT", "GILT", "GMT", "GST", "GYT", "H", "HDT", "HKT", "HOVST", "HOVT", "HST", "I", "IDT", "IOT", "IRDT", "IRKST", "IRKT", "JST", "K", "KGT", "KOST", "KRAST", "KRAT", "KST", "KUYT", "L", "LHDT", "LHST", "LINT", "M", "MAGST", "MAGT", "MART", "MAWT", "MDT", "MHT", "MMT", "MSD", "MSK", "MST", "MT", "MUT", "MVT", "MYT", "N", "NCT", "NDT", "NFDT", "NFT", "NOVST", "NOVT", "NPT", "NRT", "NST", "NUT", "NZDT", "NZST", "O", "OMSST", "OMST", "ORAT", "P", "PDT", "PET", "PETST", "PETT", "PGT", "PHOT", "PHT", "PKT", "PMDT", "PMST", "PONT", "PT", "PWT", "PYST", "PYT", "Q", "QYZT", "R", "RET", "ROTT", "S", "SAKT", "SAMT", "SAST", "SBT", "SCT", "SGT", "SRET", "SRT", "SST", "SYOT", "T", "TAHT", "TFT", "TJT", "TKT", "TLT", "TMT", "TOST", "TOT", "TRT", "TVT", "U", "ULAST", "ULAT", "UTC", "UYST", "UYT", "UZT", "V", "VET", "VLAST", "VLAT", "VOST", "VUT", "W", "WAKT", "WARST", "WAST", "WAT", "WEST", "WET", "WFT", "WGST", "WGT", "WST", "WT", "X", "Y", "YAKST", "YAKT", "YAPT", "YEKST", "YEKT", "Z"]  # noqa: E501
        if time_zone not in allowed_values:
            raise ValueError(
                "Invalid value for `time_zone` ({0}), must be one of {1}"  # noqa: E501
                .format(time_zone, allowed_values)
            )

        self._time_zone = time_zone

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

        return self.__dict__ == other.__dict__

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