{
	"$schema":"https://json-schema.org/draft/2020-12/schema",
	"$id":"http://www.itu.int/schema/image-info-list",
	"description":"Structure definition of image list",	
	"type":"array",
	"items":{
		"$ref":"#/$defs/imageInfo"
	},
	"$defs":{
		"imageInfo":{
			"type":"object",
			"description":"Image content definition",
			"properties" : {
				"ImageID":{
					"description":"Image ID",
					"$ref":"/schema/components#/$defs/basicObjectId"
				},
				"InfoKind":{
					"$ref":"/schema/components#/$defs/infoKind"
				},
				"ImageSourcePos":{
					"description":"Image acquisition part, key public area part, A\\d{6}",
					"type":"string",
					"deprecated":true
				},
				"SourceVideoID":{
						"description":"Source video ID",
						"$ref":"/schema/components#/$defs/basicObjectId"
				},
				"OriginImageID":{
					"description":"Original image ID",
					"$ref":"/schema/components#/$defs/basicObjectId"
				},
				"EventSort":{
					"$ref":"/schema/video-slice-info-list#/$defs/videoSliceInfo/properties/EventSort"
				},
				"DeviceID":{
					"description":" Acquisition device code",
					"$ref":"/schema/components#/$defs/deviceID"
				},
				"StoragePath":{
					"description":"Storage path",
					"$ref":"/schema/components#/$defs/storagePath"
				},
				"FileHash":{
					"$ref":"/schema/video-slice-info-list#/$defs/videoSliceInfo/properties/FileHash"
				},
				"FileFormat":{
					"description":"Image format",
					"enum":["Bmp","Gif","Jpeg","Jfif","Kdc","Pcd","Pcx","Pic","Pix","Png","Psd","Tapga","Tiff","Wmf","Jp2","Other"]
				},
				"ShotTime":{
					"description":"Shooting Time",
					"type":"string",
					"format":"dateTime"
				},
				"Title":{
					"description":"Description of image name",
					"type":"string"
				},
				"TitleNote":{
					"description":"Title supplements and remarks",
					"type":"string"
				},
				"SpecialName":{
					"description":"The name of the subject to which the video belongs",
					"type":"string"
				},
				"Keyword":{
					"description":"Words or phrases with retrieval significance that express the main content of the video",
					"type":"string"
				},
				"ContentDescription":{
					"description":"Brief description of video content",
					"type":"string"
				},
				"ShotPlaceCode":{
					"description":"Shooting location area code",
					"$ref":"/schema/ape-list#/$defs/ape/properties/PlaceCode"
				},
				"ShotPlaceFullAdress":{
					"$ref":"/schema/ape-list#/$defs/ape/properties/Place"
				},
				"ShotPlaceLongitude":{
					"$ref":"/schema/ape-list#/$defs/ape/properties/Longitude"
				},
				"ShoPlacetLatitude":{
					"$ref":"/schema/ape-list#/$defs/ape/properties/Latitude"
				},
				"HorizontalShotDirection":{
					"description":"Horizontal shooting direction",
					"$ref":"/schema/components#/$defs/hDirection"
				},
				"VerticalShotDirection":{
					"description":"Vertical shooting direction",
					"$ref":"/schema/components#/$defs/vDirection"
				},
				"SecurityLevel":{
					"$ref":"/schema/components#/$defs/securityLevel"
				},
				"Width":{
					"description":"Width in pixels",
					"type":"integer"
				},
				"Height":{
					"description":"Height in pixels",
					"type":"integer"
				},
				"CameraManufacturer":{
					"description":"manufacturer name, if the photo is from a camera, fill in the camera manufacturer",
					"type":"string"
				},
				"CameraVersion":{
					"description":"Camera brand and model. If the photo is from a camera, fill in the model of the camera.",
					"type":"string"
				},
				"ApertureValue":{
					"description":"Aperture value",
					"type":"integer"
				},
				"ISOSensitivity":{
					"description":"ISO sensitivity value",
					"type":"integer"
				},
				"FocalLength":{
					"description":"Focal length",
					"type":"integer"
				},
				"QualityGrade":{
					"description":"Video quality level. 1: worst; 2: bad; 3: normal; 4: fine; 5: best",
					"enum":[1,2,3,4,5]
				},
				"CollectorName":{
					"description":"The name of the person who collected the video data or the name of the acquisition system/platform",
					"type":"string"
				},
				"CollectorOrg":{
					"description":"The name of the video data acquisition unit",
					"type":"string"
				},
				"CollectorPhone":{
					"description":"Contact number of the person who collected the video.",
					"type":"string"
				},
				"EntryClrk":{
					"description":"The name of the entry person of the video or the name of the entry system",
					"type":"string"
				},
				"EntryClrkOrg":{
					"description":"The name of storage unit of video",
					"type":"string"
				},
				"EntryTime":{
					"description":"Entry time, this attribute is not needed in the POST method, it is automatically generated when creating",
					"type":"string",
					"format":"dateTime"
				},
				"ImgProcFlag":{
					"description":"Image processing flag",
					"$ref":"/schema/components#/$defs/flag"
				},	
				"FileSize":{
					"description":"Video slice size, in bytes",
					"type":"number",
					"format":"long"
				},
				"FileData":{
					"$ref":"/schema/components#/$defs/binary"
				}
			},
			
			"required":["InfoKind","ImageSourcePos","FileFormat","ShotTime","Title","ContentDescription","ShotPlaceFullAdress","SecurityLevel","Width","Height"],
			
			"allOf":[
			{
				"if":{
					"properties":{	"InfoKind":1	}
				},
				"then":{
					"required":["EventSort"]
				}
			},
			{
				"if":{
					"properties":{	"InfoKind":2	}
				},
				"then":{
					"required":["ImageID","ShotPlaceCode","CollectorName","CollectorOrg","EntryClrk","EntryClrkOrg"]
				}
			}
			]
			
		}
	}
}
