-
-
Save lgolubyev/5a691bcbcc268061c8046e8ee28d6576 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[JsonDerivedType(typeof(Base), typeDiscriminator: "base")] | |
[JsonDerivedType(typeof(Derived), typeDiscriminator: "derived")] | |
public class Base | |
{ | |
public int X { get; set; } | |
} | |
public class Derived : Base | |
{ | |
public int Y { get; set; } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment