# coding=utf-8
# --------------------------------------------------------------------------
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class CloudToDeviceMethod(Model):
    """The parameters to execute a direct method on the device.

    :param method_name: The name of the method to execute.
    :type method_name: str
    :param payload: The JSON-formatted direct method payload, up to 128kb in
     size.
    :type payload: object
    :param response_timeout_in_seconds:
    :type response_timeout_in_seconds: int
    :param connect_timeout_in_seconds:
    :type connect_timeout_in_seconds: int
    """

    _attribute_map = {
        "method_name": {"key": "methodName", "type": "str"},
        "payload": {"key": "payload", "type": "object"},
        "response_timeout_in_seconds": {"key": "responseTimeoutInSeconds", "type": "int"},
        "connect_timeout_in_seconds": {"key": "connectTimeoutInSeconds", "type": "int"},
    }

    def __init__(
        self,
        *,
        method_name: str = None,
        payload=None,
        response_timeout_in_seconds: int = None,
        connect_timeout_in_seconds: int = None,
        **kwargs
    ) -> None:
        super(CloudToDeviceMethod, self).__init__(**kwargs)
        self.method_name = method_name
        self.payload = payload
        self.response_timeout_in_seconds = response_timeout_in_seconds
        self.connect_timeout_in_seconds = connect_timeout_in_seconds
