-Documentation

This commit is contained in:
James Newton-King
2013-01-29 21:02:28 +13:00
parent 1c0e2856c2
commit f98c6a0d8d
22 changed files with 57 additions and 40 deletions
@@ -12,7 +12,10 @@ namespace Newtonsoft.Json.Tests.Documentation.Samples.Schema
public void Example()
{
#region Usage
JsonSchema schema = JsonSchema.Parse(@"{'type': 'object'}");
JsonSchema schema = new JsonSchema
{
Type = JsonSchemaType.Object
};
// serialize JsonSchema to a string and then write string to a file
File.WriteAllText(@"c:\schema.json", schema.ToString());