Show / Hide Table of Contents

Method ToJsonString

| Improve this Doc View Source

ToJsonString(Boolean, IJsonCustomizer)

Serializes into JSON string.

Declaration
public string ToJsonString(bool isPretty, IJsonCustomizer customizer = null)
Parameters
Type Name Description
System.Boolean isPretty

Specifies whether the serialized JSON string should be indented.

IJsonCustomizer customizer

The customizer for JSON serialization.

Returns
Type Description
System.String

The result JSON string.

| Improve this Doc View Source

ToJsonString(IEnumerable<DataRow>, Boolean, IJsonCustomizer)

Serializes into JSON string for specified DataRow objects.

Declaration
public string ToJsonString(IEnumerable<DataRow> dataRows, bool isPretty, IJsonCustomizer customizer = null)
Parameters
Type Name Description
System.Collections.Generic.IEnumerable<DataRow> dataRows

The specified DataRow objects.

System.Boolean isPretty

Specifies whether the serialized JSON string should be indented.

IJsonCustomizer customizer

The customizer for JSON serialization.

Returns
Type Description
System.String

The result JSON string.

  • Improve this Doc
  • View Source
Back to top Copyright © Weifen Luo | DevZest