This is an extremely strange issue however I've tested it several times and it seems to be consistent at least.
Take the following classes:
public class MyClass {
public int Id { get; set; }
public string Name { get; set; }
public Sub MySub { get; set; }
public MyClass()
{
}
}
public class Sub
{
public string Id { get; set; }
public string DId { get; set; }
public string Something { get; set; }
public Sub(){}
}
The following will fail with an exception (can be different exceptions)
var myClass = new MyClass() {
Id= 100,
MySub=new Sub() { Id= "SubId" },
Name="Testclass"
};
var serializer = MsgPack.Serialization.MessagePackSerializer.Create<MyClass>();
var data = serializer.PackSingleObject(myClass);
var result = serializer.UnpackSingleObject(data);
However comment out the property "DId" from class Sub or simply rename it to for example "SId" and it will work, "FId" will for example not work either. I'm running 0.3.2 for aspnet 4.0.
This is an extremely strange issue however I've tested it several times and it seems to be consistent at least.
Take the following classes:
The following will fail with an exception (can be different exceptions)
However comment out the property "DId" from class Sub or simply rename it to for example "SId" and it will work, "FId" will for example not work either. I'm running 0.3.2 for aspnet 4.0.