Early Preview

This is currently very much a preview. Please feel free to try things out, but don't be upset if anything is not yet working. Feedback is welcome over on our GitHub Dicussions page.

class Newtonsoft.​Json.​Converters.​XmlNodeConverter

Assembly: Newtonsoft.Json

Inheritance: object → JsonConverter → XmlNodeConverter

Converts XML to and from JSON.

Properties

public string
DeserializeRootElementName
Gets or sets the name of the root element to insert when deserializing to XML if the JSON structure has produced multiple root elements.
public bool
WriteArrayAttribute
Gets or sets a flag to indicate whether to write the Json.NET array attribute. This attribute helps preserve arrays when converting the written XML back to JSON.
public bool
OmitRootObject
Gets or sets a value indicating whether to write the root JSON object.
public bool
CanRead
Gets a value indicating whether this <see cref="T:Newtonsoft.Json.JsonConverter" /> can read JSON.
public bool
CanWrite
Gets a value indicating whether this <see cref="T:Newtonsoft.Json.JsonConverter" /> can write JSON.

Methods

public void
WriteJson​(JsonWriter writer, object value, JsonSerializer serializer)
Writes the JSON representation of the object.
writer The <see cref="T:Newtonsoft.Json.JsonWriter" /> to write to.
value The value.
serializer The calling serializer.
public object
ReadJson​(JsonReader reader, System.​Type objectType, object existingValue, JsonSerializer serializer)
Reads the JSON representation of the object.
Returns The object value.
reader The <see cref="T:Newtonsoft.Json.JsonReader" /> to read from.
objectType Type of the object.
existingValue The existing value of object being read.
serializer The calling serializer.
public bool
CanConvert​(System.​Type valueType)
Determines whether this instance can convert the specified value type.
Returns <c>true</c> if this instance can convert the specified value type; otherwise, <c>false</c> .
valueType Type of the value.
public bool
Equals​(object obj)
Inherited from object
protected void
Finalize​()
Inherited from object
public int
GetHashCode​()
Inherited from object
GetType​()
Inherited from object
protected object
MemberwiseClone​()
Inherited from object
public string
ToString​()
Inherited from object