I tried searching google and stackoverflow for this simple question but had no luck.
When using Json.NET I want to serialize an object with all of the fields except a specific type.
I don't want to mark every field/property with JsonIgnore to prevent serialization instead what I want to do is just mark the specific type as "NonSerialized". This of course won't work. Is there anyway to achieve it without marking properties and fields with attributes?
I tried resolving this using DefaultContractResolver but didn't manage to make it work.