JsonHelper Class

Default implementation of Microsoft.AspNetCore.Mvc.Rendering.IJsonHelper.

Namespace
Microsoft.AspNetCore.Mvc.ViewFeatures
Assemblies
  • Microsoft.AspNetCore.Mvc.ViewFeatures

Syntax

public class JsonHelper : IJsonHelper
class Microsoft.AspNetCore.Mvc.ViewFeatures.JsonHelper

Constructors

JsonHelper(Microsoft.AspNetCore.Mvc.Formatters.JsonOutputFormatter, System.Buffers.ArrayPool<System.Char>)

Initializes a new instance of Microsoft.AspNetCore.Mvc.ViewFeatures.JsonHelper that is backed by <em>jsonOutputFormatter</em>.

Arguments:
public JsonHelper(JsonOutputFormatter jsonOutputFormatter, ArrayPool<char> charPool)

Methods

Serialize(System.Object)
Return type:Microsoft.AspNetCore.Html.IHtmlContent
public IHtmlContent Serialize(object value)
Serialize(System.Object, Newtonsoft.Json.JsonSerializerSettings)
Return type:Microsoft.AspNetCore.Html.IHtmlContent
public IHtmlContent Serialize(object value, JsonSerializerSettings serializerSettings)