Argon is a JSON framework for .NET. It is a hard fork of Newtonsoft.Json.
See Milestones for release notes.
var product = new Product
{
Name = "Apple",
Expiry = new(2008, 12, 28),
Sizes = ["Small"]
};
var json = JsonConvert.SerializeObject(product);
// {
// "Name": "Apple",
// "Expiry": "2008-12-28T00:00:00",
// "Sizes": [
// "Small"
// ]
// }
var json = """
{
'Name': 'Bad Boys',
'ReleaseDate': '1995-4-7T00:00:00',
'Genres': [
'Action',
'Comedy'
]
}
""";
var movie = JsonConvert.DeserializeObject<Movie>(json);
var name = movie.Name;
// Bad Boys
var jArray = new JArray
{
"Manual text",
new DateTime(2000, 5, 23)
};
var jObject = new JObject
{
["MyArray"] = jArray
};
var json = jObject.ToString();
// {
// "MyArray": [
// "Manual text",
// "2000-05-23T00:00:00"
// ]
// }
- Argon is JSON framework for .NET
- Serialization using ContractResolver
- Converting between JSON and XML
- Creating JSON
- Dates in JSON
- F#
- LINQ to JSON
- Parsing JSON
- Performance
- Preserving Object References
- Querying JSON with LINQ
- Basic Reading and Writing JSON
- Reducing JSON size
- Querying JSON with SelectToken
- Attributes
- Serialization callbacks
- Error handling during serialization and deserialization.
- Srialization Guide
- Serialization Settings
- Serializing Collections
- Serializing and Deserializing JSON
- Deserializing Partial JSON Fragments
- Json
- JsonPath
- Linq
- Cloning JSON with JToken.DeepClone
- Create JSON from an Anonymous Type
- Create JSON using Collection Initializers
- Create JSON declaratively with LINQ
- Create JSON with dynamic
- Create JSON with JTokenWriter
- Create JObject and JArray programatically
- Create JTokenReader from JToken
- Creates JTokenWriter JToken
- Comparing JSON with JToken.DeepEquals
- Deserializing from JSON with LINQ
- Create JSON from an Object
- Using JObject.Properties
- Casting JValue
- Using JValue.Value
- Modifying JSON
- Parse JSON using JToken.Parse
- Parse JSON using JArray.Parse
- Parsing JSON Object using JObject.Parse
- Querying JSON with complex JSON Path
- Querying JSON with dynamic
- Querying JSON with LINQ
- Read JSON from a file using JObject
- Serializing to JSON with LINQ
- Convert JSON to a Type
- LINQ to JSON with JToken.ToObject
- Convert JSON to a Type
- Write JSON text with JToken.ToString
- Write JSON to a file
- Serializer
- Custom IContractResolver
- Custom JsonConverter
- Custom
JsonConverter<T>
- DataContract and DataMember Attributes
- Serialize with DefaultSettings
- DefaultValueAttribute
- DefaultValueHandling setting
- Deserialize an Anonymous Type
- Deserialize a Collection
- ConstructorHandling setting
- Deserialize a DataSet
- Deserialize a Dictionary
- Deserialize an immutable collection
- MetadataPropertyHandling setting
- MissingMemberHandling setting
- Deserialize an Object
- ObjectCreationHandling setting
- Deserialize JSON from a file
- ErrorHandlingAttribute
- ErrorHandling setting
- Float Precision
- JsonConstructorAttribute
- JsonConverterAttribute on a class
- JsonConverterAttribute on a property
- JsonObjectAttribute opt-in serialization
- JsonObjectAttribute force object serialization
- JsonPropertyAttribute items setting
- JsonPropertyAttribute name
- JsonPropertyAttribute order
- JsonPropertyAttribute property setting
- JsonPropertyAttribute required
- MaxDepth setting
- Camel case property names
- Configure CamelCaseNamingStrategy
- Configure NamingStrategy property name serialization
- Snake case property names
- NullValueHandling setting
- PreserveReferencesHandling setting
- JsonIgnoreAttribute
- ReferenceLoopHandling setting
- Serialization Callback Interfaces
- Serializing Collections
- Custom IContractResolver
- Serialize a DataSet
- DateTimeZoneHandling setting
- Serialize a Dictionary
- Serialize an immutable collection
- Serialize an Object
- Serialize Raw JSON value
- Custom SerializationBinder
- TypeNameHandling setting
- Serialize Unindented JSON
- Serialize with JsonConverters
- Serialize JSON to a file
- Xml
Helmet designed by Juan Manuel Corredor from The Noun Project.