Custom Attribute for Serialization in JSON.NET

May 10, 2011 at 2:40 PM

Using JSON.NET, I would like to change the serialization attribute [JsonProperty] to [CustomSerializable].

[CustomSerializableEntity]
class Person
{ 

    int Age;

    [CustomSerializable] 
    string Name;
}

How to serialize this entity based on the custom attribute [CustomSerializable]?