def METHOD_NAME(self):
    """Returns the model properties as a dict"""
    result = {}
    for attr, _ in six.iteritems(self.openapi_types):
        value = getattr(self, attr)
        if isinstance(value, list):
            result[attr] = list(map(
                lambda x: x.METHOD_NAME() if hasattr(x, "to_dict") else x,
                value
            ))
        elif hasattr(value, "to_dict"):
            result[attr] = value.METHOD_NAME()
        elif isinstance(value, dict):
            result[attr] = dict(map(
                lambda item: (item[0], item[1].METHOD_NAME())
                if hasattr(item[1], "to_dict") else item,
                value.items()
            ))
        else:
            result[attr] = value
    return result