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

"""
   wegene.Models.SportAdvice

   This file was automatically generated by APIMATIC BETA v2.0 on 02/22/2016
"""
from wegene.APIHelper import APIHelper

class SportAdvice(object):

    """Implementation of the 'sport_advice' model.

    Sport advice based on targeting losing weight of 500g/week

    Attributes:
        met (int): TODO: type description here.
        metabolic (int): TODO: type description here.
        sports_speed (int): Suggested speed if jogging
        sports_times (int): Suggested sport times
        sports_type (string): Suggested sport type
        total_consume (int): Suggested kcal to burn every week
        total_intake (int): Suggested kcal to intake every week

    """

    def __init__(self,
                 **kwargs):
        """Constructor for the SportAdvice class

        Args:
            **kwargs: Keyword Arguments in order to initialise the
                object. Any of the attributes in this object are able to
                be set through the **kwargs of the constructor. The values
                that can be supplied and their types are as follows::

                    met -- int -- Sets the attribute met
                    metabolic -- int -- Sets the attribute metabolic
                    sports_speed -- int -- Sets the attribute sports_speed
                    sports_times -- int -- Sets the attribute sports_times
                    sports_type -- string -- Sets the attribute sports_type
                    total_consume -- int -- Sets the attribute total_consume
                    total_intake -- int -- Sets the attribute total_intake

        """
        # Set all of the parameters to their default values
        self.met = None
        self.metabolic = None
        self.sports_speed = None
        self.sports_times = None
        self.sports_type = None
        self.total_consume = None
        self.total_intake = None

        # Create a mapping from API property names to Model property names
        replace_names = {
            "met": "met",
            "metabolic": "metabolic",
            "sports_speed": "sports_speed",
            "sports_times": "sports_times",
            "sports_type": "sports_type",
            "total_consume": "total_consume",
            "total_intake": "total_intake",
        }

        # Parse all of the Key-Value arguments
        if kwargs is not None:
            for key in kwargs:
                # Only add arguments that are actually part of this object
                if key in replace_names:
                    setattr(self, replace_names[key], kwargs[key])

    def resolve_names(self):
        """Creates a dictionary representation of this object.

        This method converts an object to a dictionary that represents the
        format that the model should be in when passed into an API Request.
        Because of this, the generated dictionary may have different
        property names to that of the model itself.

        Returns:
            dict: The dictionary representing the object.

        """
        # Create a mapping from Model property names to API property names
        replace_names = {
            "met": "met",
            "metabolic": "metabolic",
            "sports_speed": "sports_speed",
            "sports_times": "sports_times",
            "sports_type": "sports_type",
            "total_consume": "total_consume",
            "total_intake": "total_intake",
        }

        retval = dict()

        return APIHelper.resolve_names(self, replace_names, retval)
