| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596 |
- {
- "$schema": "http://json-schema.org/draft-04/schema#",
- "definitions": {
- "names": {
- "items": {"type": "string"},
- "type": "array"
- }
- },
- "properties": {
- "@class": {"type": "string"},
- "classRef": {"type": "string"},
- "spellInfo": {
- "patternProperties": {
- "^[0-9]$": {
- "properties": {
- "spellsPerDay": {"type": "integer"},
- "spellsPerDayRemaining": {"type": "integer"},
- "spellsKnown": {"$ref": "#/definitions/names"},
- "spellsPrepared": {"$ref": "#/definitions/names"},
- "spellsPreparedPreviously": {"$ref": "#/definitions/names"}
- },
- "type": "object"
- }
- },
- "type": "object"
- }
- },
- "oneOf": [
- {
- "properties": {
- "@class": {
- "enum": [
- "org.leumasjaffe.charsheet.model.magic.impl.Inspired"
- ]
- },
- "spellInfo": {
- "^[0-9]$": {
- "required": [
- "spellsPerDay",
- "spellsPrepared",
- "spellsPreparedPreviously"
- ],
- "additionalProperties":false
- }
- }
- }
- },
- {
- "properties": {
- "@class": {
- "enum": [
- "org.leumasjaffe.charsheet.model.magic.impl.Spontaneous"
- ]
- },
- "spellInfo": {
- "^[0-9]$": {
- "required": [
- "spellsPerDay",
- "spellsPerDayRemaining",
- "spellsKnown"
- ],
- "additionalProperties":false
- }
- }
- }
- },
- {
- "properties": {
- "@class": {
- "enum": [
- "org.leumasjaffe.charsheet.model.magic.impl.Researched",
- "org.leumasjaffe.charsheet.model.magic.impl.Unearthed"
- ]
- },
- "spellInfo": {
- "^[0-9]$": {
- "required": [
- "spellsPerDay",
- "spellsPerDayRemaining",
- "spellsKnown",
- "spellsPrepared",
- "spellsPreparedPreviously"
- ],
- "additionalProperties":false
- }
- }
- }
- }
- ],
- "required": [
- "@class",
- "classRef",
- "spellInfo"
- ],
- "type": "object"
- }
|