C# Client Library
A C# Client Library for the AnalyzeRe REST API
|
Deserializes AnalyzeRe API Reference objects to a new instance of a the target generic Reference type, and Serializes Reference objects too. More...
Public Types | |
enum | ReferenceSerializationMethod { UseReferencesOnly , ExpandIfResolved , ExpandReferenceValues } |
The SerializationMethod to use when serializing references. More... | |
Public Member Functions | |
ReferenceConverter (ReferenceSerializationMethod serializationMethod=ReferenceSerializationMethod.UseReferencesOnly) | |
Initializes the ReferenceConverter using the specified SerializationMethod. | |
override bool | CanConvert (Type objectType) |
Determines if this converter is designed for deserialization to objects of the specified type. | |
override object | ReadJson (JsonReader reader, Type objectType, object existingValue, JsonSerializer serializer) |
Parses the json to the specified type. | |
override void | WriteJson (JsonWriter writer, object value, JsonSerializer serializer) |
Serializes a Reference object based on the configured SerializationMethod controlling whether/when references are resolved. | |
Properties | |
ReferenceSerializationMethod | SerializationMethod [get, set] |
Used during serialization to determine whether references should be expanded in JSON. | |
Deserializes AnalyzeRe API Reference objects to a new instance of a the target generic Reference type, and Serializes Reference objects too.
Definition at line 15 of file ReferenceConverter.cs.
The SerializationMethod to use when serializing references.
Definition at line 21 of file ReferenceConverter.cs.
|
inline |
Initializes the ReferenceConverter using the specified SerializationMethod.
serializationMethod | The SerializationMethod to use when serializing references. |
Definition at line 50 of file ReferenceConverter.cs.
Determines if this converter is designed for deserialization to objects of the specified type.
objectType | The target type for deserialization. |
Definition at line 77 of file ReferenceConverter.cs.
|
inline |
Parses the json to the specified type.
reader | Newtonsoft.Json.JsonReader |
objectType | Target type. |
existingValue | Ignored |
serializer | Newtonsoft.Json.JsonSerializer to use. |
Definition at line 108 of file ReferenceConverter.cs.
|
inline |
Serializes a Reference object based on the configured SerializationMethod controlling whether/when references are resolved.
Definition at line 215 of file ReferenceConverter.cs.
|
getset |
Used during serialization to determine whether references should be expanded in JSON.
Definition at line 40 of file ReferenceConverter.cs.