# This file was generated by liblab | https://liblab.com/

from enum import Enum
from typing import List
from .utils.json_map import JsonMap
from .base import BaseModel


class DetailsInputDtoExtras(Enum):
    """An enumeration representing different categories.

    :cvar DESCRIPTION: "DESCRIPTION"
    :vartype DESCRIPTION: str
    :cvar FACILITIES: "FACILITIES"
    :vartype FACILITIES: str
    :cvar PAYMENT: "PAYMENT"
    :vartype PAYMENT: str
    :cvar PHOTOS: "PHOTOS"
    :vartype PHOTOS: str
    :cvar POLICIES: "POLICIES"
    :vartype POLICIES: str
    :cvar ROOMS: "ROOMS"
    :vartype ROOMS: str
    """

    DESCRIPTION = "DESCRIPTION"
    FACILITIES = "FACILITIES"
    PAYMENT = "PAYMENT"
    PHOTOS = "PHOTOS"
    POLICIES = "POLICIES"
    ROOMS = "ROOMS"

    def list():
        """Lists all category values.

        :return: A list of all category values.
        :rtype: list
        """
        return list(map(lambda x: x.value, DetailsInputDtoExtras._member_map_.values()))


class DetailsInputDtoLanguages(Enum):
    """An enumeration representing different categories.

    :cvar AR: "AR"
    :vartype AR: str
    :cvar BG: "BG"
    :vartype BG: str
    :cvar CA: "CA"
    :vartype CA: str
    :cvar CS: "CS"
    :vartype CS: str
    :cvar DA: "DA"
    :vartype DA: str
    :cvar DE: "DE"
    :vartype DE: str
    :cvar EL: "EL"
    :vartype EL: str
    :cvar EN: "EN"
    :vartype EN: str
    :cvar EN_GB: "EN_GB"
    :vartype EN_GB: str
    :cvar EN_US: "EN_US"
    :vartype EN_US: str
    :cvar ES: "ES"
    :vartype ES: str
    :cvar ES_AR: "ES_AR"
    :vartype ES_AR: str
    :cvar ES_MX: "ES_MX"
    :vartype ES_MX: str
    :cvar ET: "ET"
    :vartype ET: str
    :cvar FI: "FI"
    :vartype FI: str
    :cvar FR: "FR"
    :vartype FR: str
    :cvar HE: "HE"
    :vartype HE: str
    :cvar HI: "HI"
    :vartype HI: str
    :cvar HR: "HR"
    :vartype HR: str
    :cvar HU: "HU"
    :vartype HU: str
    :cvar ID: "ID"
    :vartype ID: str
    :cvar IS: "IS"
    :vartype IS: str
    :cvar IT: "IT"
    :vartype IT: str
    :cvar JA: "JA"
    :vartype JA: str
    :cvar KA: "KA"
    :vartype KA: str
    :cvar KO: "KO"
    :vartype KO: str
    :cvar LT: "LT"
    :vartype LT: str
    :cvar LV: "LV"
    :vartype LV: str
    :cvar MS: "MS"
    :vartype MS: str
    :cvar NL: "NL"
    :vartype NL: str
    :cvar NO: "NO"
    :vartype NO: str
    :cvar PL: "PL"
    :vartype PL: str
    :cvar PT_BR: "PT_BR"
    :vartype PT_BR: str
    :cvar PT_PT: "PT_PT"
    :vartype PT_PT: str
    :cvar RO: "RO"
    :vartype RO: str
    :cvar RU: "RU"
    :vartype RU: str
    :cvar SK: "SK"
    :vartype SK: str
    :cvar SL: "SL"
    :vartype SL: str
    :cvar SR: "SR"
    :vartype SR: str
    :cvar SV: "SV"
    :vartype SV: str
    :cvar TH: "TH"
    :vartype TH: str
    :cvar TL: "TL"
    :vartype TL: str
    :cvar TR: "TR"
    :vartype TR: str
    :cvar UK: "UK"
    :vartype UK: str
    :cvar VI: "VI"
    :vartype VI: str
    :cvar ZH_CN: "ZH_CN"
    :vartype ZH_CN: str
    :cvar ZH_TW: "ZH_TW"
    :vartype ZH_TW: str
    """

    AR = "AR"
    BG = "BG"
    CA = "CA"
    CS = "CS"
    DA = "DA"
    DE = "DE"
    EL = "EL"
    EN = "EN"
    EN_GB = "EN_GB"
    EN_US = "EN_US"
    ES = "ES"
    ES_AR = "ES_AR"
    ES_MX = "ES_MX"
    ET = "ET"
    FI = "FI"
    FR = "FR"
    HE = "HE"
    HI = "HI"
    HR = "HR"
    HU = "HU"
    ID = "ID"
    IS = "IS"
    IT = "IT"
    JA = "JA"
    KA = "KA"
    KO = "KO"
    LT = "LT"
    LV = "LV"
    MS = "MS"
    NL = "NL"
    NO = "NO"
    PL = "PL"
    PT_BR = "PT_BR"
    PT_PT = "PT_PT"
    RO = "RO"
    RU = "RU"
    SK = "SK"
    SL = "SL"
    SR = "SR"
    SV = "SV"
    TH = "TH"
    TL = "TL"
    TR = "TR"
    UK = "UK"
    VI = "VI"
    ZH_CN = "ZH_CN"
    ZH_TW = "ZH_TW"

    def list():
        """Lists all category values.

        :return: A list of all category values.
        :rtype: list
        """
        return list(
            map(lambda x: x.value, DetailsInputDtoLanguages._member_map_.values())
        )


@JsonMap({})
class DetailsInputDto(BaseModel):
    """DetailsInputDto

    :param accommodations: A signed integer number that uniquely identifies an accommodation property., defaults to None
    :type accommodations: List[int], optional
    :param accommodation_facilities: A signed integer number that uniquely identifies an accommodation property facility. Examples of facilities are: Parking, Restaurant, Room service etc. , defaults to None
    :type accommodation_facilities: List[int], optional
    :param accommodation_types: A signed integer number that uniquely identifies an accommodation property type. Examples of accommodation types are: Apartment, Hostel, Hotel etc., defaults to None
    :type accommodation_types: List[int], optional
    :param airport: A three-letter code that uniquely identifies an airport as defined by the International Air Transport Association (IATA)., defaults to None
    :type airport: str, optional
    :param brands: A signed integer number that uniquely identifies an accommodation brand. Examples of brands are: Radisson Blu, WestCord Hotels, Westin etc. , defaults to None
    :type brands: List[int], optional
    :param city: A signed integer number that uniquely identifies a city., defaults to None
    :type city: int, optional
    :param country: A two-letter code that uniquely identifies a country. This code is defined by the ISO 3166-1 alpha-2 standard (ISO2) as described here: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2. , defaults to None
    :type country: str, optional
    :param region: A signed integer number that uniquely identifies a geographical region. Regions usually define official administrative areas within a country, but may also include multiple countries and in some cases un-official but popular designations for geographical areas. An example of a region that crosses multiple countries is the Alps in Europe. , defaults to None
    :type region: int, optional
    :param extras: Input parameter to request for additional information about the accommodation property. It should be passed as a JSON array with one or more items. , defaults to None
    :type extras: List[DetailsInputDtoExtras], optional
    :param languages: An IETF language tag code that uniquely identifies a supported human language or dialect as described here: https://en.wikipedia.org/wiki/IETF_language_tag. Note that in in demand-api-v3-compatible the whole tag is always lowercase. Examples: "nl" for Dutch/Nederlands or "en-us" for English (US). , defaults to None
    :type languages: List[DetailsInputDtoLanguages], optional
    :param rows: The maximum number of results to return., defaults to None
    :type rows: int, optional
    :param page: Pagination token used to retrieve the next page of results. Obtained from `next_page`., defaults to None
    :type page: str, optional
    """

    def __init__(
        self,
        accommodations: List[int] = None,
        accommodation_facilities: List[int] = None,
        accommodation_types: List[int] = None,
        airport: str = None,
        brands: List[int] = None,
        city: int = None,
        country: str = None,
        region: int = None,
        extras: List[DetailsInputDtoExtras] = None,
        languages: List[DetailsInputDtoLanguages] = None,
        rows: int = None,
        page: str = None,
    ):
        if accommodations is not None:
            self.accommodations = accommodations
        if accommodation_facilities is not None:
            self.accommodation_facilities = accommodation_facilities
        if accommodation_types is not None:
            self.accommodation_types = accommodation_types
        if airport is not None:
            self.airport = self._pattern_matching(airport, "^[A-Z]{3}$", "airport")
        if brands is not None:
            self.brands = brands
        if city is not None:
            self.city = city
        if country is not None:
            self.country = self._pattern_matching(country, "^[a-z]{2}$", "country")
        if region is not None:
            self.region = region
        if extras is not None:
            self.extras = self._define_list(extras, DetailsInputDtoExtras)
        if languages is not None:
            self.languages = self._define_list(languages, DetailsInputDtoLanguages)
        if rows is not None:
            self.rows = rows
        if page is not None:
            self.page = page
