# -*- coding: utf-8 -*-

"""
uexcorpapi

This file was automatically generated by APIMATIC v3.0 (
 https://www.apimatic.io ).
"""
from uexcorpapi.api_helper import APIHelper


class Data29(object):

    """Implementation of the 'Data29' model.

    Attributes:
        city_name (Any): The model property of type Any.
        date_added (str): The model property of type str.
        date_modified (str): The model property of type str.
        id (str): The model property of type str.
        id_city (str): The model property of type str.
        id_moon (str): The model property of type str.
        id_orbit (str): The model property of type str.
        id_outpost (str): The model property of type str.
        id_planet (str): The model property of type str.
        id_poi (str): The model property of type str.
        id_report (str): The model property of type str.
        id_space_station (str): The model property of type str.
        id_star_system (str): The model property of type str.
        id_terminal (str): The model property of type str.
        moon_name (Any): The model property of type Any.
        orbit_name (str): The model property of type str.
        outpost_name (Any): The model property of type Any.
        planet_name (str): The model property of type str.
        poi_name (Any): The model property of type Any.
        space_station_name (str): The model property of type str.
        star_system_name (str): The model property of type str.
        terminal_name (str): The model property of type str.
        value (str): The model property of type str.
        value_month (str): The model property of type str.
        value_week (str): The model property of type str.
        additional_properties (Dict[str, Any]): The additional properties for
            the model.

    """

    # Create a mapping from Model property names to API property names
    _names = {
        "city_name": 'city_name',
        "date_added": 'date_added',
        "date_modified": 'date_modified',
        "id": 'id',
        "id_city": 'id_city',
        "id_moon": 'id_moon',
        "id_orbit": 'id_orbit',
        "id_outpost": 'id_outpost',
        "id_planet": 'id_planet',
        "id_poi": 'id_poi',
        "id_report": 'id_report',
        "id_space_station": 'id_space_station',
        "id_star_system": 'id_star_system',
        "id_terminal": 'id_terminal',
        "moon_name": 'moon_name',
        "orbit_name": 'orbit_name',
        "outpost_name": 'outpost_name',
        "planet_name": 'planet_name',
        "poi_name": 'poi_name',
        "space_station_name": 'space_station_name',
        "star_system_name": 'star_system_name',
        "terminal_name": 'terminal_name',
        "value": 'value',
        "value_month": 'value_month',
        "value_week": 'value_week'
    }

    def __init__(self,
                 city_name=None,
                 date_added=None,
                 date_modified=None,
                 id=None,
                 id_city=None,
                 id_moon=None,
                 id_orbit=None,
                 id_outpost=None,
                 id_planet=None,
                 id_poi=None,
                 id_report=None,
                 id_space_station=None,
                 id_star_system=None,
                 id_terminal=None,
                 moon_name=None,
                 orbit_name=None,
                 outpost_name=None,
                 planet_name=None,
                 poi_name=None,
                 space_station_name=None,
                 star_system_name=None,
                 terminal_name=None,
                 value=None,
                 value_month=None,
                 value_week=None,
                 additional_properties=None):
        """Constructor for the Data29 class"""

        # Initialize members of the class
        self.city_name = city_name 
        self.date_added = date_added 
        self.date_modified = date_modified 
        self.id = id 
        self.id_city = id_city 
        self.id_moon = id_moon 
        self.id_orbit = id_orbit 
        self.id_outpost = id_outpost 
        self.id_planet = id_planet 
        self.id_poi = id_poi 
        self.id_report = id_report 
        self.id_space_station = id_space_station 
        self.id_star_system = id_star_system 
        self.id_terminal = id_terminal 
        self.moon_name = moon_name 
        self.orbit_name = orbit_name 
        self.outpost_name = outpost_name 
        self.planet_name = planet_name 
        self.poi_name = poi_name 
        self.space_station_name = space_station_name 
        self.star_system_name = star_system_name 
        self.terminal_name = terminal_name 
        self.value = value 
        self.value_month = value_month 
        self.value_week = value_week 

        # Add additional model properties to the instance
        if additional_properties is None:
            additional_properties = {}
        self.additional_properties = additional_properties

    @classmethod
    def from_dictionary(cls,
                        dictionary):
        """Creates an instance of this model from a dictionary

        Args:
            dictionary (dictionary): A dictionary representation of the object
            as obtained from the deserialization of the server's response. The
            keys MUST match property names in the API description.

        Returns:
            object: An instance of this structure class.

        """

        if not isinstance(dictionary, dict) or dictionary is None:
            return None

        # Extract variables from the dictionary
        city_name = dictionary.get("city_name") if dictionary.get("city_name") else None
        date_added = dictionary.get("date_added") if dictionary.get("date_added") else None
        date_modified = dictionary.get("date_modified") if dictionary.get("date_modified") else None
        id = dictionary.get("id") if dictionary.get("id") else None
        id_city = dictionary.get("id_city") if dictionary.get("id_city") else None
        id_moon = dictionary.get("id_moon") if dictionary.get("id_moon") else None
        id_orbit = dictionary.get("id_orbit") if dictionary.get("id_orbit") else None
        id_outpost = dictionary.get("id_outpost") if dictionary.get("id_outpost") else None
        id_planet = dictionary.get("id_planet") if dictionary.get("id_planet") else None
        id_poi = dictionary.get("id_poi") if dictionary.get("id_poi") else None
        id_report = dictionary.get("id_report") if dictionary.get("id_report") else None
        id_space_station = dictionary.get("id_space_station") if dictionary.get("id_space_station") else None
        id_star_system = dictionary.get("id_star_system") if dictionary.get("id_star_system") else None
        id_terminal = dictionary.get("id_terminal") if dictionary.get("id_terminal") else None
        moon_name = dictionary.get("moon_name") if dictionary.get("moon_name") else None
        orbit_name = dictionary.get("orbit_name") if dictionary.get("orbit_name") else None
        outpost_name = dictionary.get("outpost_name") if dictionary.get("outpost_name") else None
        planet_name = dictionary.get("planet_name") if dictionary.get("planet_name") else None
        poi_name = dictionary.get("poi_name") if dictionary.get("poi_name") else None
        space_station_name = dictionary.get("space_station_name") if dictionary.get("space_station_name") else None
        star_system_name = dictionary.get("star_system_name") if dictionary.get("star_system_name") else None
        terminal_name = dictionary.get("terminal_name") if dictionary.get("terminal_name") else None
        value = dictionary.get("value") if dictionary.get("value") else None
        value_month = dictionary.get("value_month") if dictionary.get("value_month") else None
        value_week = dictionary.get("value_week") if dictionary.get("value_week") else None
        additional_properties = APIHelper.get_additional_properties(
            dictionary={k: v for k, v in dictionary.items() if k not in cls._names.values()},
            unboxing_function=lambda value: value)
        # Return an object of this model
        return cls(city_name,
                   date_added,
                   date_modified,
                   id,
                   id_city,
                   id_moon,
                   id_orbit,
                   id_outpost,
                   id_planet,
                   id_poi,
                   id_report,
                   id_space_station,
                   id_star_system,
                   id_terminal,
                   moon_name,
                   orbit_name,
                   outpost_name,
                   planet_name,
                   poi_name,
                   space_station_name,
                   star_system_name,
                   terminal_name,
                   value,
                   value_month,
                   value_week,
                   additional_properties)

    def __repr__(self):
        return (f'{self.__class__.__name__}('
                f'city_name={self.city_name!r}, '
                f'date_added={self.date_added!r}, '
                f'date_modified={self.date_modified!r}, '
                f'id={self.id!r}, '
                f'id_city={self.id_city!r}, '
                f'id_moon={self.id_moon!r}, '
                f'id_orbit={self.id_orbit!r}, '
                f'id_outpost={self.id_outpost!r}, '
                f'id_planet={self.id_planet!r}, '
                f'id_poi={self.id_poi!r}, '
                f'id_report={self.id_report!r}, '
                f'id_space_station={self.id_space_station!r}, '
                f'id_star_system={self.id_star_system!r}, '
                f'id_terminal={self.id_terminal!r}, '
                f'moon_name={self.moon_name!r}, '
                f'orbit_name={self.orbit_name!r}, '
                f'outpost_name={self.outpost_name!r}, '
                f'planet_name={self.planet_name!r}, '
                f'poi_name={self.poi_name!r}, '
                f'space_station_name={self.space_station_name!r}, '
                f'star_system_name={self.star_system_name!r}, '
                f'terminal_name={self.terminal_name!r}, '
                f'value={self.value!r}, '
                f'value_month={self.value_month!r}, '
                f'value_week={self.value_week!r}, '
                f'additional_properties={self.additional_properties!r})')

    def __str__(self):
        return (f'{self.__class__.__name__}('
                f'city_name={self.city_name!s}, '
                f'date_added={self.date_added!s}, '
                f'date_modified={self.date_modified!s}, '
                f'id={self.id!s}, '
                f'id_city={self.id_city!s}, '
                f'id_moon={self.id_moon!s}, '
                f'id_orbit={self.id_orbit!s}, '
                f'id_outpost={self.id_outpost!s}, '
                f'id_planet={self.id_planet!s}, '
                f'id_poi={self.id_poi!s}, '
                f'id_report={self.id_report!s}, '
                f'id_space_station={self.id_space_station!s}, '
                f'id_star_system={self.id_star_system!s}, '
                f'id_terminal={self.id_terminal!s}, '
                f'moon_name={self.moon_name!s}, '
                f'orbit_name={self.orbit_name!s}, '
                f'outpost_name={self.outpost_name!s}, '
                f'planet_name={self.planet_name!s}, '
                f'poi_name={self.poi_name!s}, '
                f'space_station_name={self.space_station_name!s}, '
                f'star_system_name={self.star_system_name!s}, '
                f'terminal_name={self.terminal_name!s}, '
                f'value={self.value!s}, '
                f'value_month={self.value_month!s}, '
                f'value_week={self.value_week!s}, '
                f'additional_properties={self.additional_properties!s})')
