export const createBuildingSchema = { buildingPrefix: { in: ['body'], exists: true, errorMessage: 'Missing field' }, buildingName: { in: ['body'], exists: true, errorMessage: 'Missing field' }, buildingAddress: { in: ['body'], exists: true, errorMessage: 'Missing field' }, buildingGmlId: { in: ['body'], errorMessage: 'Missing field' } } export const basementSchema = { id: { in: ['params'], exists: true, isString: true }, basementInsulatingMaterial: { in: ['body'], errorMessage: 'Missing field', isString: true, optional: { options: { nullable: true } } }, basementInsulatingMaterialThickness: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, basementRefurbishmentComment: { in: ['body'], errorMessage: 'Missing field', isString: true, optional: { options: { nullable: true } } }, heatedBasement: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, insulatedBasementCeiling: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, insulatedBasementFloor: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } } } export const characteristicsSchema = { id: { in: ['params'], exists: true, isString: true }, characteristicsComment: { in: ['body'], errorMessage: 'Missing field', isString: true, optional: { options: { nullable: true } } }, energyPerformanceCertificate: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, listedBuilding: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, livingSpace: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, numberOfFloors: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, yearOfConstruction: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } } } export const facadeSchema = { id: { in: ['params'], exists: true, isString: true }, buildingStructure: { in: ['body'], errorMessage: 'Missing field', isString: true, optional: { options: { nullable: true } } }, buildingStructureThickness: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, facadeEast: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, facadeInsulatingMaterial: { in: ['body'], errorMessage: 'Missing field', isString: true, optional: { options: { nullable: true } } }, facadeInsulatingMaterialThickness: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, facadeNorth: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, facadeRefurbishmentComment: { in: ['body'], errorMessage: 'Missing field', isString: true, optional: { options: { nullable: true } } }, facadeSouth: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, facadeWest: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } } } export const heatingSchema = { id: { in: ['params'], exists: true, isString: true }, heatingConsumption: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, heatingInstallation: { in: ['body'], errorMessage: 'Missing field', isString: true, optional: { options: { nullable: true } } }, heatingInstallationComment: { in: ['body'], errorMessage: 'Missing field', isString: true, optional: { options: { nullable: true } } }, photovoltaic: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, photovoltaicArea: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, photovoltaicYield: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, pipeSystem: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, selfContainedCentralHeating: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, solarHeat: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, solarHeatArea: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } } } export const roofSchema = { id: { in: ['params'], exists: true, isString: true }, clouding: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, flatRoof: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, heatedAttic: { in: ['body'], errorMessage: 'Missing field', isBoolean: true, toBoolean: true, optional: { options: { nullable: true } } }, roofArea: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, roofInsulatingMaterial: { in: ['body'], errorMessage: 'Missing field', isString: true, optional: { options: { nullable: true } } }, roofInsulatingMaterialThickness: { in: ['body'], errorMessage: 'Missing field', isInt: true, toInt: true, optional: { options: { nullable: true } } }, roofRefurbishmentComment: { in: ['body'], errorMessage: 'Missing field', isString: true, optional: { options: { nullable: true } } } } export const simulationSchema = { gmlId: { in: ['query'], errorMessage: 'Missing field', isAlphanumeric: true } }