This project has moved and is read-only. For the latest updates, please go here.

Problem with treatment of $ref property in JsonSchemaBuilder

Jul 12, 2012 at 1:13 AM
Edited Jul 12, 2012 at 1:18 AM

I'm using the newest release to parse some Json Schema files. One of them contains something like the following code. The $ref property is not being recognized because it is not the first property in the token stream. See the code around line 100 in JsonSchemaBuilder.cs. I looked in the draft spec and there do not appear to be any restrictions on the position of the $ref attribute. When I remove the "type":"object" line, the code works properly.

	"id": "schema.models.Case",
	"description": "Full list of metadata details for a case.",
	"$schema": "",
	"type": "object",
	"properties": {
	"status": {
                        "type": "object",
 	        "$ref": "schema.models.StatusCode",
	        "required": false