Table of Contents

Class MethodResponse

Namespace
nanoFramework.Azure.Devices.Client
Assembly
nanoFramework.Azure.Devices.Client.dll

The response to a direct method call.

public class MethodResponse
Inheritance
MethodResponse
Inherited Members
Extension Methods

Constructors

MethodResponse(int, string)

Creates a MethodResponse.

public MethodResponse(int status, string payload = null)

Parameters

status int

The status code returned to the caller (ex: 200 for OK, 202 for accepted).

payload string

The payload returned to the caller. It must be valid JSON. null returns an empty payload.

Properties

Payload

Gets the payload returned to the caller. It must be valid JSON. null returns an empty payload.

public string Payload { get; }

Property Value

string

Status

Gets the status code returned to the caller (ex: 200 for OK, 202 for accepted).

public int Status { get; }

Property Value

int