{
	"description": "Imported control object text files",
	"type": "object",
	"$schema": "http://json-schema.org/draft-04/schema#",
	"title": "riegl.imported_control_objects",
	"required": [
		"control_objects",
		"imported_files"
	],
	"properties": {
		"control_objects": {
			"type": "object",
			"description": "One (optional) field per control object, field name is control object id",
			"patternProperties": {
				"^[0-9]+$": {
					"type": "object",
					"required": [
						"file",
						"line_start",
						"line_count"
					],
					"properties": {
						"file": {
							"type": "integer",
							"description": "Index (0-based) of the file in the 'imported_files' array"
						},
						"line_count": {
							"type": "integer",
							"description": "Number of lines used to import this object"
						},
						"line_start": {
							"type": "integer",
							"description": "Index (0-based) of the first line used from the 'lines' array"
						}
					}
				}
			}
		},
		"imported_files": {
			"type": "array",
			"description": "Array of imported files",
			"items": {
				"type": "object",
				"required": [
					"path",
					"lines"
				],
				"properties": {
					"lines": {
						"type": "array",
						"description": "Each entry in this array is a line (string) from the text file",
						"items": {
							"type": "string"
						}
					},
					"path": {
						"type": "string",
						"description": "Path of the text file"
					}
				}
			}
		}
	}
}