C# Class Qowaiv.Json.QowaivJsonConverter

The Qowaiv JSON converter converts types from and to JSON that implement the Qowaiv.Json.IJsonSerializable.
Inheritance: Newtonsoft.Json.JsonConverter
Afficher le fichier Open project: Corniel/Qowaiv Class Usage Examples

Méthodes publiques

Méthode Description
CanConvert ( Type objectType ) : bool

Returns true if the object type is (nullable) IJsonSerializable.

ReadJson ( JsonReader reader, Type objectType, object existingValue, JsonSerializer serializer ) : object

Reads the JSON representation of an IJsonSerializable.

Register ( ) : void

Registers the Qowaiv JSON converter.

WriteJson ( JsonWriter writer, object value, JsonSerializer serializer ) : void

Writes the JSON representation of an IJsonSerializable.

Method Details

CanConvert() public méthode

Returns true if the object type is (nullable) IJsonSerializable.
public CanConvert ( Type objectType ) : bool
objectType System.Type /// The object type to convert. ///
Résultat bool

ReadJson() public méthode

Reads the JSON representation of an IJsonSerializable.
public ReadJson ( JsonReader reader, Type objectType, object existingValue, JsonSerializer serializer ) : object
reader Newtonsoft.Json.JsonReader /// The Newtonsoft.Json.JsonReader to read from. ///
objectType System.Type /// The type of the object. ///
existingValue object /// The existing value of object being read. ///
serializer Newtonsoft.Json.JsonSerializer /// The calling serializer. ///
Résultat object

Register() public static méthode

Registers the Qowaiv JSON converter.
public static Register ( ) : void
Résultat void

WriteJson() public méthode

Writes the JSON representation of an IJsonSerializable.
public WriteJson ( JsonWriter writer, object value, JsonSerializer serializer ) : void
writer Newtonsoft.Json.JsonWriter /// The Newtonsoft.Json.JsonWriter to write to. ///
value object /// The value. ///
serializer Newtonsoft.Json.JsonSerializer /// The calling serializer. ///
Résultat void