# coding: utf-8

"""
    Internal API

    SmartDiagnostics REST API for internal users only  # noqa: E501

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

import pprint
import re  # noqa: F401

import six

class DashboardWidgetChild(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 = {
        'dashboard_widget_id': 'str',
        'dashboard_widget_name': 'str',
        'dashboard_widget_refresh_interval': 'int',
        'dashboard_widget_layout': 'LayoutChild',
        'widget': 'WidgetChild'
    }

    attribute_map = {
        'dashboard_widget_id': 'DashboardWidgetId',
        'dashboard_widget_name': 'DashboardWidgetName',
        'dashboard_widget_refresh_interval': 'DashboardWidgetRefreshInterval',
        'dashboard_widget_layout': 'DashboardWidgetLayout',
        'widget': 'Widget'
    }

    def __init__(self, dashboard_widget_id=None, dashboard_widget_name=None, dashboard_widget_refresh_interval=None, dashboard_widget_layout=None, widget=None):  # noqa: E501
        """DashboardWidgetChild - a model defined in Swagger"""  # noqa: E501
        self._dashboard_widget_id = None
        self._dashboard_widget_name = None
        self._dashboard_widget_refresh_interval = None
        self._dashboard_widget_layout = None
        self._widget = None
        self.discriminator = None
        self.dashboard_widget_id = dashboard_widget_id
        self.dashboard_widget_name = dashboard_widget_name
        if dashboard_widget_refresh_interval is not None:
            self.dashboard_widget_refresh_interval = dashboard_widget_refresh_interval
        self.dashboard_widget_layout = dashboard_widget_layout
        self.widget = widget

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


        :return: The dashboard_widget_id of this DashboardWidgetChild.  # noqa: E501
        :rtype: str
        """
        return self._dashboard_widget_id

    @dashboard_widget_id.setter
    def dashboard_widget_id(self, dashboard_widget_id):
        """Sets the dashboard_widget_id of this DashboardWidgetChild.


        :param dashboard_widget_id: The dashboard_widget_id of this DashboardWidgetChild.  # noqa: E501
        :type: str
        """
        if dashboard_widget_id is None:
            raise ValueError("Invalid value for `dashboard_widget_id`, must not be `None`")  # noqa: E501

        self._dashboard_widget_id = dashboard_widget_id

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


        :return: The dashboard_widget_name of this DashboardWidgetChild.  # noqa: E501
        :rtype: str
        """
        return self._dashboard_widget_name

    @dashboard_widget_name.setter
    def dashboard_widget_name(self, dashboard_widget_name):
        """Sets the dashboard_widget_name of this DashboardWidgetChild.


        :param dashboard_widget_name: The dashboard_widget_name of this DashboardWidgetChild.  # noqa: E501
        :type: str
        """
        if dashboard_widget_name is None:
            raise ValueError("Invalid value for `dashboard_widget_name`, must not be `None`")  # noqa: E501

        self._dashboard_widget_name = dashboard_widget_name

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


        :return: The dashboard_widget_refresh_interval of this DashboardWidgetChild.  # noqa: E501
        :rtype: int
        """
        return self._dashboard_widget_refresh_interval

    @dashboard_widget_refresh_interval.setter
    def dashboard_widget_refresh_interval(self, dashboard_widget_refresh_interval):
        """Sets the dashboard_widget_refresh_interval of this DashboardWidgetChild.


        :param dashboard_widget_refresh_interval: The dashboard_widget_refresh_interval of this DashboardWidgetChild.  # noqa: E501
        :type: int
        """

        self._dashboard_widget_refresh_interval = dashboard_widget_refresh_interval

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


        :return: The dashboard_widget_layout of this DashboardWidgetChild.  # noqa: E501
        :rtype: LayoutChild
        """
        return self._dashboard_widget_layout

    @dashboard_widget_layout.setter
    def dashboard_widget_layout(self, dashboard_widget_layout):
        """Sets the dashboard_widget_layout of this DashboardWidgetChild.


        :param dashboard_widget_layout: The dashboard_widget_layout of this DashboardWidgetChild.  # noqa: E501
        :type: LayoutChild
        """
        if dashboard_widget_layout is None:
            raise ValueError("Invalid value for `dashboard_widget_layout`, must not be `None`")  # noqa: E501

        self._dashboard_widget_layout = dashboard_widget_layout

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


        :return: The widget of this DashboardWidgetChild.  # noqa: E501
        :rtype: WidgetChild
        """
        return self._widget

    @widget.setter
    def widget(self, widget):
        """Sets the widget of this DashboardWidgetChild.


        :param widget: The widget of this DashboardWidgetChild.  # noqa: E501
        :type: WidgetChild
        """
        if widget is None:
            raise ValueError("Invalid value for `widget`, must not be `None`")  # noqa: E501

        self._widget = widget

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

        return self.__dict__ == other.__dict__

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