YamlReferenceHandling
OfficeIMO.Yaml
How the serializer treats an object that is reached more than once.
Inheritance
- Enum
- YamlReferenceHandling
Usage
Explore 3 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by 3
Inherited Methods
public string ToString(IFormatProvider? provider) #Obsolete("The provider argument is not used. Use ToString() instead.")Parameters
- provider IFormatProvider?
Returns
stringpublic string ToString(string? format, IFormatProvider? provider) #Obsolete("The provider argument is not used. Use ToString(String) instead.")Parameters
- format string?
- provider IFormatProvider?
Returns
stringValues
public const YamlReferenceHandling None #Each reference is written in full, and a cycle fails with YamlErrorCodes.ReferenceCycle. An alias in the input read as a typed value is read again from its anchored node; one read as object returns the value read for its anchor, unless YamlSerializerOptions.CopyAliases is set. This is the default.
0public const YamlReferenceHandling Preserve #An object or collection reached again is written as an alias to an anchor on its first occurrence, so shared references and cycles round-trip. Reading maps each alias back to the instance created for its anchor.
1