SharpYaml
SharpYaml copied to clipboard
No longer can set Alias for property like this: [YamlMember(Alias = "$ref")]
I switched over from YamlDotNet to SharpYaml to investigate shortcomings of YamlDotNet is improved, but I can no longer set the Alias for a property in an object I declared as I did with YamlDotNet, like this:
public class MessageObjectRef : IMessageObject {
[YamlMember(Alias = "$ref")]
public string Ref { get; set; }
}
I don't know what is alias but YamlMember in SharpYaml has a ctor taking a string directly:
https://github.com/xoofx/SharpYaml/blob/b21523e90b4f85c695d7871a827dad61b048d803/src/SharpYaml/Serialization/YamlMemberAttribute.cs#L82-L85