Interface IReferenceResolver
- Namespace
- Newtonsoft.Json.Serialization
- Assembly
- Newtonsoft.Json.dll
Used to resolve references when serializing and deserializing JSON by the JsonSerializer.
public interface IReferenceResolver
Methods
AddReference(object, string, object)
Adds a reference to the specified object.
void AddReference(object context, string reference, object value)
Parameters
contextobjectThe serialization context.
referencestringThe reference.
valueobjectThe object to reference.
GetReference(object, object)
Gets the reference for the sepecified object.
string GetReference(object context, object value)
Parameters
Returns
- string
The reference to the object.
IsReferenced(object, object)
Determines whether the specified object is referenced.
bool IsReferenced(object context, object value)
Parameters
Returns
- bool
trueif the specified object is referenced; otherwise,false.
ResolveReference(object, string)
Resolves a reference to its object.
object ResolveReference(object context, string reference)
Parameters
Returns
- object
The object that