```html
The NetDataContractAttribute class is used to specify how a type is serialized using the .NET Framework serialization technology.
You can use the NetDataContractAttribute class to mark classes, structs, and enumerations that you want to be serialized and deserialized using the DataContractSerializer.
| Name | Description |
|---|---|
Name |
The name of the data contract. |
Namespace |
The namespace of the data contract. |
TypeDiscriminator |
Specifies the name of the type discriminator. |
[DataContract]
public class MyData
{
[DataMember(Name = "FirstName")]
public string FirstName { get; set; }
[DataMember(Name = "LastName")]
public string LastName { get; set; }
}