I am using YamlDotNet library to serialize some objects in Yaml. I've met some problems with the serialization of Guid properties. Serialization of Guid properties generates empty brackets ( ex: {} )
See code below
Dim l As New List(Of Person)
l.Add(New Person() With {.Firstname = "MyFirstName", .Lastname = "MyLastName", .Id = Guid.NewGuid()})
Using sw As New StreamWriter("output.yaml", False)
Dim serializer = New Serializer()
serializer.Serialize(sw, l)
End Using
this code will output :
- Id: {}
Firstname: MyFirstName
Lastname: MyLastName
With the class:
Public Class Person
Public Property Id As Guid
Public Property Frstname As String
Public Property Lastname As String
End Class
Am I missing something or is this an issue of the library ?