Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@decaf-ts/decorator-validation

Package Overview
Dependencies
Maintainers
0
Versions
31
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@decaf-ts/decorator-validation - npm Package Compare versions

Comparing version 1.1.2 to 1.1.4

lib/esm/model/utils.d.ts

2

dist/decorator-validation.bundle.min.js
/*! For license information please see decorator-validation.bundle.min.js.LICENSE.txt */
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("decorator-validation",[],t):"object"==typeof exports?exports["decorator-validation"]=t():e["decorator-validation"]=t()}(this,(()=>(()=>{var e={729:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=void 0,o(r(935),t),o(r(839),t),o(r(965),t),o(r(847),t),t.VERSION="##VERSION##"},6:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Model=void 0,t.validate=h;const n=r(772),o=r(735),a=r(19),i=r(402),s=r(154),c=r(38),u=r(936),l=r(770),d=r(174),f=r(523),p=r(593),y=r(687);function h(e,...t){const r=[];for(const o in e)e.hasOwnProperty(o)&&-1===t.indexOf(o)&&r.push((0,d.getPropertyDecorators)(n.ValidationKeys.REFLECT,e,o));const o=r.reduce(((t,r)=>{const{prop:o,decorators:a}=r;if(!a||!a.length)return t;const c=a[0];a.find((e=>e.key===n.ValidationKeys.TYPE||!!e.props.types?.find((e=>e===c.props.name))))&&a.shift();let u=a.reduce(((t,r)=>{const n=l.Validation.get(r.key);if(!n)return t;const a=n.hasErrors(e[o.toString()],...r.key===s.ModelKeys.TYPE?[r.props]:Object.values(r.props));return a&&((t=t||{})[r.key]=a),t}),void 0);return u=u||Object.keys(e).filter((e=>!u||!u[e])).reduce(((t,r)=>{let o;const a=(0,d.getPropertyDecorators)(n.ValidationKeys.REFLECT,e,r).decorators,c=a.filter((e=>-1!==[s.ModelKeys.TYPE,n.ValidationKeys.TYPE].indexOf(e.key)));if(!c||!c.length)return t;const u=c.pop(),l=u.props.name?[u.props.name]:Array.isArray(u.props.customTypes)?u.props.customTypes:[u.props.customTypes],f=Object.values(i.ReservedModels).map((e=>e.toLowerCase()));return l.forEach((t=>{if(-1===f.indexOf(t.toLowerCase()))switch(t){case"Array":case"Set":if(a.length&&a.find((e=>e.key===n.ValidationKeys.LIST))){const a="Array"===t?e[r].find((e=>e.hasErrors())):e[r].values().find((e=>e.hasErrors()));a&&(o=(0,p.sf)(n.DEFAULT_ERROR_MESSAGES.LIST_INSIDE,a.toString()))}break;default:try{e[r]&&(o=e[r].hasErrors())}catch(e){console.warn((0,p.sf)("Model should be validatable but its not"))}}})),o&&((t=t||{})[r]=o),t}),void 0),u&&((t=t||{})[r.prop.toString()]=u),t}),void 0);return o?new a.ModelErrorDefinition(o):void 0}let g,v,_,E;class m{constructor(e){}hasErrors(...e){return h(this,...e)}equals(e,...t){return(0,y.isEqual)(this,e,...t)}serialize(){return m.serialize(this)}toString(){return this.constructor.name+": "+JSON.stringify(this,void 0,2)}toHash(){return m.getHashingFunction()(this).toString()}static deserialize(e){return m.getSerializer().deserialize(e)}static serialize(e){return m.getSerializer().serialize(e)}static hash(e){return m.getHashingFunction()(e)}static fromObject(e,t){return(0,c.constructFromObject)(e,t)}static fromModel(e,t){return(0,c.constructFromModel)(e,t)}static setBuilder(e){g=e}static getBuilder(){return g}static getRegistry(){return v||(v=new u.ModelRegistryManager),v}static setRegistry(e){v=e}static register(e,t){return m.getRegistry().register(e,t)}static get(e){return m.getRegistry().get(e)}static build(e={},t){return m.getRegistry().build(e,t)}static setSerializer(e){_=e}static getSerializer(){return _||(_=new o.JSONSerializer),_}static setHashingFunction(e){E=e}static getHashingFunction(){return E||(E=f.hashObj),E}}t.Model=m},19:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ModelErrorDefinition=void 0,t.ModelErrorDefinition=class{constructor(e){for(const t in e)e.hasOwnProperty(t)&&e[t]&&Object.defineProperty(this,t,{enumerable:!0,configurable:!1,value:e[t],writable:!1})}toString(){const e=this;return Object.keys(e).filter((t=>e.hasOwnProperty(t)&&"function"!=typeof e[t])).reduce(((t,r)=>{let n=Object.keys(e[r]).reduce(((t,n)=>(t?t+=`\n${e[r][n]}`:t=e[r][n],t)),void 0);return n&&(n=`${r} - ${n}`,t?t+=`\n${n}`:t=n),t}),"")}}},936:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ModelRegistryManager=void 0,t.bulkModelRegister=function(...e){e.forEach((e=>{const t=e.constructor?e.constructor:e;n.Model.register(t,e.name)}))};const n=r(6),o=r(154),a=r(174),i=r(593);t.ModelRegistryManager=class{constructor(e=o.ModelKeys.ANCHOR,t=a.isModel){this.cache={},this.testFunction=t,this.anchorKey=e}register(e,t){if("function"!=typeof e)throw new Error("Model registering failed. Missing Class name or constructor");t=t||e.name,this.cache[t]=e}get(e){try{return this.cache[e]}catch(e){return}}build(e={},t){if(!t&&!this.testFunction(e))throw new Error("Provided obj is not a Model object");const r=t||e[this.anchorKey].class;if(!(r in this.cache))throw new Error((0,i.sf)("Provided class {0} is not a registered Model object",r));return new this.cache[r](e)}}},402:(e,t)=>{"use strict";var r,n;Object.defineProperty(t,"__esModule",{value:!0}),t.ReservedModels=t.Primitives=void 0,function(e){e.STRING="string",e.NUMBER="number",e.BOOLEAN="boolean",e.BIGINT="bigint"}(r||(t.Primitives=r={})),function(e){e.STRING="string",e.OBJECT="object",e.NUMBER="number",e.BOOLEAN="boolean",e.BIGINT="bigint",e.DATE="date"}(n||(t.ReservedModels=n={}))},38:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.constructFromObject=function(e,t){if(!t)return e;for(const r in t)t.hasOwnProperty(r)&&(e.hasOwnProperty(r)||e.prototype&&e.prototype.hasOwnProperty(r))&&(e[r]=t[r]||void 0);return e},t.constructFromModel=function(e,t){if(!t)return e;let r,u;for(const l in t)if(t.hasOwnProperty(l)&&(e.hasOwnProperty(l)||e.prototype&&e.prototype.hasOwnProperty(l))){if(e[l]=t[l]||void 0,"object"!=typeof e[l])continue;if((0,s.isModel)(e[l])){try{e[l]=n.Model.build(e[l])}catch(e){console.error(e)}continue}const d=(0,s.getPropertyDecorators)(o.ValidationKeys.REFLECT,e,l).decorators;if(r=d.filter((e=>-1!==[i.ModelKeys.TYPE,o.ValidationKeys.TYPE].indexOf(e.key))),!r||!r.length)throw new Error((0,c.sf)("failed to find decorators for property {0}",l));u=r.pop();const f=u.props.name?[u.props.name]:Array.isArray(u.props.customTypes)?u.props.customTypes:[u.props.customTypes],p=Object.values(a.ReservedModels).map((e=>e.toLowerCase()));f.forEach((t=>{if(-1===p.indexOf(t.toLowerCase()))try{switch(t){case"Array":case"Set":if(d.length){const r=d.find((e=>e.key===o.ValidationKeys.LIST));if(r&&("Array"===t&&(e[l]=e[l].map((e=>n.Model.build(e,r.props.class)))),"Set"===t)){const t=new Set;for(const o of e[l])t.add(n.Model.build(o,r.props.class));e[l]=t}}break;default:e[l]&&(e[l]=n.Model.build(e[l],t))}}catch(e){console.log(e)}}))}return e},t.construct=function(e,...t){const r=(...t)=>new e(...t);return r.prototype=e.prototype,r(...t)};const n=r(6),o=r(772),a=r(402),i=r(154),s=r(174),c=r(593)},893:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getModelKey=void 0,t.model=function(e,r){return i=>{const s=function(...s){const c=(0,n.construct)(i,...s),u=a.Model.getBuilder();u&&u(c,s.length?s[0]:void 0);const l=Object.assign({},{class:i.name});return Object.defineProperty(c,o.ModelKeys.ANCHOR,{writable:!1,enumerable:!1,configurable:!1,value:l}),Reflect.defineMetadata((0,t.getModelKey)(o.ModelKeys.MODEL),Object.assign(l,e||{}),c.constructor),r&&r(c,...s),c};return s.prototype=i.prototype,Object.defineProperty(s,"name",{writable:!1,enumerable:!0,configurable:!1,value:i.prototype.constructor.name}),a.Model.register(s),s}};const n=r(38),o=r(154),a=r(6);t.getModelKey=e=>o.ModelKeys.REFLECT+e},847:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),o(r(402),t),o(r(38),t),o(r(893),t),o(r(6),t),o(r(19),t),o(r(936),t),o(r(282),t)},282:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},501:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.metadata=function(e,t){return(r,n,o)=>{o?Reflect.defineMetadata(e,t,o.value):n?Reflect.defineMetadata(e,t,r,n):Reflect.defineMetadata(e,t,r)}},t.apply=function(...e){return(t,r,n)=>{for(const o of e)t instanceof Function&&!n?o(t):o(t,r,n)}},r(630)},839:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),o(r(501),t),o(r(174),t)},174:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getPropertyDecorators=i,t.getTypeFromDecorator=function(e,t){const r=i(n.ModelKeys.REFLECT,e,t,!1);if(!r||!r.decorators)return;const o=r.decorators.shift(),a=o.props?o.props.name:void 0;return"Function"!==a?a:void 0},t.getAllPropertyDecorators=function(e,...t){if(t&&t.length)return Object.getOwnPropertyNames(e).reduce(((r,n)=>(t.forEach(((t,o)=>{const a=i(t,e,n,0!==o);r||(r={}),function(e,t,r){r&&r.length&&(e[t]||(e[t]=[]),e[t].push(...r))}(r,n,a.decorators)})),r)),void 0)},t.getAllProperties=function(e,t=!0,r="Object"){const n=[];let o=e;const a=function(){if(!t)return;const e=Object.getPrototypeOf(o);return e&&e.constructor.name!==r?(o=e,o):void 0};do{Object.getOwnPropertyNames(o).forEach((function(e){-1===n.indexOf(e)&&n.push(e)}))}while(a());return n},t.getClassDecorators=s,t.checkType=c,t.checkTypes=u,t.evaluateDesignTypes=function(e,t){switch(typeof t){case"string":return c(e,t);case"object":return!Array.isArray(t)||u(e,t);case"function":return!t.name||"Object"===t.name||c(e,t.name);default:return!0}},t.isModel=function(e){return!!e[n.ModelKeys.ANCHOR]||!!s(n.ModelKeys.REFLECT,e).find((e=>e.key===n.ModelKeys.MODEL&&e.props&&e.props.class))};const n=r(154),o=r(593),a=r(687);function i(e,t,r,s=!1,c=!0,u){const l=function(e,t,r,o=!1,a){const i=Reflect.getMetadataKeys(t,r).filter((t=>o?t.toString().startsWith(e):t===n.ModelKeys.TYPE||t.toString().startsWith(e))).reduce(((o,a)=>{const i={key:a!==n.ModelKeys.TYPE?a.substring(e.length):a,props:Reflect.getMetadata(a,t,r)};return o.concat(i)}),a||[]);return{prop:r.toString(),decorators:i}}(e,t,r,s,u);return c&&Object.getPrototypeOf(t)!==Object.prototype?i(e,Object.getPrototypeOf(t.constructor),r,!0,c,l.decorators):{prop:l.prop,decorators:function(e){const r={};return e.filter((e=>e.key in r?((0,a.isEqual)(e.props,r[e.key])||console.log((0,o.sf)("Found a similar decorator for the {0} property of a {1} model but with different attributes. The original one will be kept",e.key,t.constructor.name)),!1):(r[e.key.toString()]=e.props,!0)))}(l.decorators)}}function s(e,t){return Reflect.getOwnMetadataKeys(t.constructor).filter((t=>t.toString().startsWith(e))).reduce(((r,n)=>{const o={key:n.substring(e.length),props:Reflect.getMetadata(n,t.constructor)};return r.concat(o)}),[])}function c(e,t){return typeof e===t||e.constructor&&e.constructor.name.toLowerCase()===t.toLowerCase()}function u(e,t){return!t.every((t=>!c(e,t)))}r(630)},154:(e,t)=>{"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.ModelKeys=void 0,function(e){e.REFLECT="model.definition.",e.TYPE="design:type",e.PARAMS="design:paramtypes",e.RETURN="design:returntype",e.MODEL="model",e.ANCHOR="__modelDefinition"}(r||(t.ModelKeys=r={}))},46:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.dateFromFormat=a,t.bindDateToString=i,t.isValidDate=s,t.twoDigitPad=c,t.formatDate=u,t.parseDate=function(e,t){let r;if(t){if(t instanceof Date)try{r=a(u(t,e),e)}catch(r){throw new Error((0,o.sf)("Could not convert date {0} to format: {1}",t.toString(),e))}else if("string"==typeof t)r=a(t,e);else if("number"==typeof t)r=a(u(new Date(t),e),e);else{if(!s(t))throw new Error(`Invalid value provided ${t}`);try{r=a(u(new Date(t),e),e)}catch(r){throw new Error((0,o.sf)("Could not convert date {0} to format: {1}",t,e))}}return i(r,e)}},r(630);const n=r(772),o=r(593);function a(e,t){let r=t;r.match(/hh/)?r=r.replace("hh","(?<hour>\\d{2})"):r.match(/h/)?r=r.replace("h","(?<hour>\\d{1,2})"):r.match(/HH/)?r=r.replace("HH","(?<hour>\\d{2})"):r.match(/H/)&&(r=r.replace("H","(?<hour>\\d{1,2})")),r.match(/mm/)?r=r.replace("mm","(?<minutes>\\d{2})"):r.match(/m/)&&(r=r.replace("m","(?<minutes>\\d{1,2})")),r.match(/ss/)?r=r.replace("ss","(?<seconds>\\d{2})"):r.match(/s/)&&(r=r.replace("s","(?<seconds>\\d{1,2})")),r.match(/dd/)?r=r.replace("dd","(?<day>\\d{2})"):r.match(/d/)&&(r=r.replace("d","(?<day>\\d{1,2})")),r.match(/EEEE/)?r=r.replace("EEEE","(?<dayofweek>\\w+)"):r.match(/EEEE/)&&(r=r.replace("EEE","(?<dayofweek>\\w+)")),r.match(/yyyy/)?r=r.replace("yyyy","(?<year>\\d{4})"):r.match(/yy/)&&(r=r.replace("yy","(?<year>\\d{2})")),r.match(/MMMM/)?r=r.replace("MMMM","(?<monthname>\\w+)"):r.match(/MMM/)&&(r=r.replace("MMM","(?<monthnamesmall>\\w+)")),r.match(/MM/)?r=r.replace("MM","(?<month>\\d{2})"):r.match(/M/)&&(r=r.replace("M","(?<month>\\d{1,2})")),r=r.replace("S","(?<milis>\\d{1,3})").replace("aaa","(?<ampm>\\w{2})");const o=new RegExp(r,"g").exec(e);if(!o||!o.groups)return new Date(e);const a=function(e){if(!e)return 0;const t=parseInt(e);return isNaN(t)?0:t},i=a(o.groups.year),s=a(o.groups.day),c=o.groups.ampm;let u=a(o.groups.hour);c&&(u="PM"===c?u+12:u);const l=a(o.groups.minutes),d=a(o.groups.seconds),f=a(o.groups.milis),p=o.groups.monthname,y=o.groups.monthnamesmall;let h=o.groups.month;if(p)h=n.MONTH_NAMES.indexOf(p);else if(y){const t=n.MONTH_NAMES.find((e=>e.toLowerCase().startsWith(y.toLowerCase())));if(!t)return new Date(e);h=n.MONTH_NAMES.indexOf(t)}else h=a(`${h}`);return new Date(i,h-1,s,u,l,d,f)}function i(e,t){if(!e)return;const r=()=>u(e,t);return Object.defineProperty(e,"toISOString",{enumerable:!1,configurable:!1,value:r}),Object.defineProperty(e,"toString",{enumerable:!1,configurable:!1,value:r}),e}function s(e){return e&&"[object Date]"===Object.prototype.toString.call(e)&&!isNaN(e)}function c(e){return e<10?"0"+e:e.toString()}function u(e,t="yyyy/MM/dd"){const r=e.getDate(),o=e.getMonth(),a=e.getFullYear(),i=e.getHours(),s=e.getMinutes(),u=e.getSeconds(),l=e.getMilliseconds(),d=i%12,f=c(d),p=c(i),y=c(s),h=c(u),g=i<12?"AM":"PM",v=n.DAYS_OF_WEEK_NAMES[e.getDay()],_=v.substr(0,3),E=c(r),m=o+1,O=c(m),M=n.MONTH_NAMES[o],b=M.substr(0,3),R=a+"",S=R.substr(2,2);return(t=t.replace("hh",f).replace("h",d.toString()).replace("HH",p).replace("H",i.toString()).replace("mm",y).replace("m",s.toString()).replace("ss",h).replace("s",u.toString()).replace("S",l.toString()).replace("dd",E).replace("d",r.toString()).replace("EEEE",v).replace("EEE",_).replace("yyyy",R).replace("yy",S).replace("aaa",g)).indexOf("MMM")>-1?t.replace("MMMM",M).replace("MMM",b):t.replace("MM",O).replace("M",m.toString())}},687:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isEqual=function e(t,r,...n){if(t===r)return!0;if(t instanceof Date&&r instanceof Date)return t.getTime()===r.getTime();if(!t||!r||"object"!=typeof t&&"object"!=typeof r)return t===r;if(null==t||null==r)return!1;if(typeof t!=typeof r)return!1;if(t.prototype!==r.prototype)return!1;const o=Object.keys(t).filter((e=>-1===n.indexOf(e)));return o.length===Object.keys(r).filter((e=>-1===n.indexOf(e))).length&&o.every((o=>-1!==n.indexOf(o)||e(t[o],r[o],...n)))}},523:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hashCode=o,t.hashSerialization=function(e){return o(n.Model.serialize(e))},t.hashObj=function(e){const t=function(e,t){const r=n(t);return"string"==typeof r?n((e||"")+n(t)):0|(e=((e=e||0)<<5)-e+r)},r=o,n=function(e){return void 0===e?"":-1!==["string","number","symbol"].indexOf(typeof e)?r(e.toString()):e instanceof Date?r(e.getTime()):Array.isArray(e)?e.reduce(t,void 0):Object.values(e).reduce(t,void 0)},a=Object.values(e).reduce(t,0);return"number"==typeof a?Math.abs(a):a};const n=r(6);function o(e){e=String(e);let t=0;for(let r=0;r<e.length;r++)t=(t<<5)-t+e.charCodeAt(r),t|=0;return t}},935:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),o(r(154),t),o(r(46),t),o(r(687),t),o(r(523),t),o(r(735),t),o(r(904),t),o(r(735),t),o(r(593),t)},904:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},735:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.JSONSerializer=void 0;const n=r(6),o=r(154);t.JSONSerializer=class{preSerialize(e){const t=Object.assign({},e);return t[o.ModelKeys.ANCHOR]=e[o.ModelKeys.ANCHOR],t}deserialize(e){const t=JSON.parse(e);return n.Model.build(t)}serialize(e){return JSON.stringify(this.preSerialize(e))}}},593:(e,t)=>{"use strict";function r(e,...t){return e.replace(/{(\d+)}/g,(function(e,r){return void 0!==t[r]?t[r]:e}))}Object.defineProperty(t,"__esModule",{value:!0}),t.sf=void 0,t.stringFormat=r,t.sf=r},770:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Validation=void 0;const n=r(436);class o{static{this.actingValidatorRegistry=void 0}constructor(){}static setRegistry(e,t){t&&o.actingValidatorRegistry&&o.actingValidatorRegistry.getKeys().forEach((r=>{const n=e.get(r);n&&e.register(t(n))})),o.actingValidatorRegistry=e}static getRegistry(){return o.actingValidatorRegistry||(o.actingValidatorRegistry=new n.ValidatorRegistry),o.actingValidatorRegistry}static get(e){return o.getRegistry().get(e)}static register(...e){return o.getRegistry().register(...e)}}t.Validation=o},395:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.DateValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.DATE){super(e,Number.name,Date.name,String.name)}hasErrors(e,t,r){if(void 0!==e)return"string"==typeof e&&(e=new Date(e)),isNaN(e.getDate())?this.getMessage(r||this.message):void 0}};t.DateValidator=c,t.DateValidator=c=n([(0,s.validator)(i.ValidationKeys.DATE),o("design:paramtypes",[String])],c)},335:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.EmailValidator=void 0;const a=r(772),i=r(273),s=r(787);let c=class extends i.PatternValidator{constructor(e=a.DEFAULT_ERROR_MESSAGES.EMAIL){super(e)}hasErrors(e,t){return super.hasErrors(e,a.DEFAULT_PATTERNS.EMAIL,t)}};t.EmailValidator=c,t.EmailValidator=c=n([(0,s.validator)(a.ValidationKeys.EMAIL),o("design:paramtypes",[String])],c)},407:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.ListValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.LIST){super(e,Array.name,Set.name)}hasErrors(e,t,r){if(!e||(Array.isArray(e)?!e.length:!e.size))return;let n;for(let o=0;o<(Array.isArray(e)?e.length:e.size);o++)switch(n=e[o],typeof n){case"object":case"function":if(!n.constructor||n.constructor.name!==t)return this.getMessage(r||this.message,t);break;default:if(typeof n!==t)return this.getMessage(r||this.message,t)}}};t.ListValidator=c,t.ListValidator=c=n([(0,s.validator)(i.ValidationKeys.LIST),o("design:paramtypes",[String])],c)},169:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MaxLengthValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MAX_LENGTH){super(e,String.name,Array.name)}hasErrors(e,t,r){if(void 0!==e)return e.length>t?this.getMessage(r||this.message,t):void 0}};t.MaxLengthValidator=c,t.MaxLengthValidator=c=n([(0,s.validator)(i.ValidationKeys.MAX_LENGTH),o("design:paramtypes",[String])],c)},909:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MaxValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MAX){super(e,"number","Date","string")}hasErrors(e,t,r){if(void 0!==e){if(e instanceof Date&&!(t instanceof Date)&&(t=new Date(t),isNaN(t.getDate())))throw new Error("Invalid Max param defined");return e>t?this.getMessage(r||this.message,t):void 0}}};t.MaxValidator=c,t.MaxValidator=c=n([(0,s.validator)(i.ValidationKeys.MAX),o("design:paramtypes",[String])],c)},519:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MinLengthValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MIN_LENGTH){super(e,String.name,Array.name)}hasErrors(e,t,r){if(void 0!==e)return e.length<t?this.getMessage(r||this.message,t):void 0}};t.MinLengthValidator=c,t.MinLengthValidator=c=n([(0,s.validator)(i.ValidationKeys.MIN_LENGTH),o("design:paramtypes",[String])],c)},651:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MinValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MIN){super(e,"number","Date","string")}hasErrors(e,t,r){if(void 0!==e){if(e instanceof Date&&!(t instanceof Date)&&(t=new Date(t),isNaN(t.getDate())))throw new Error("Invalid Min param defined");return e<t?this.getMessage(r||this.message,t):void 0}}};t.MinValidator=c,t.MinValidator=c=n([(0,s.validator)(i.ValidationKeys.MIN),o("design:paramtypes",[String])],c)},354:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.PasswordValidator=void 0;const a=r(273),i=r(772),s=r(787);let c=class extends a.PatternValidator{constructor(e=i.DEFAULT_ERROR_MESSAGES.PASSWORD,t=i.DEFAULT_PATTERNS.PASSWORD.CHAR8_ONE_OF_EACH){super(e),this.pattern=t}hasErrors(e,t,r){return super.hasErrors(e,t||this.pattern,r||this.message)}};t.PasswordValidator=c,t.PasswordValidator=c=n([(0,s.validator)(i.ValidationKeys.PASSWORD),o("design:paramtypes",[Object,RegExp])],c)},273:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.PatternValidator=t.regexpParser=void 0;const a=r(116),i=r(772),s=r(787);t.regexpParser=new RegExp("^/(.+)/([gimus]*)$");let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.PATTERN){super(e,"string")}getPattern(e){if(!t.regexpParser.test(e))return new RegExp(e);const r=e.match(t.regexpParser);return new RegExp(r[1],r[2])}hasErrors(e,t,r){if(e){if(!t)throw new Error("Missing Pattern");return(t="string"==typeof t?this.getPattern(t):t).lastIndex=0,t.test(e)?void 0:this.getMessage(r||this.message)}}};t.PatternValidator=c,t.PatternValidator=c=n([(0,s.validator)(i.ValidationKeys.PATTERN),o("design:paramtypes",[String])],c)},812:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.RequiredValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.REQUIRED){super(e)}hasErrors(e,t){switch(typeof e){case"boolean":case"number":return void 0===e?this.getMessage(t||this.message):void 0;default:return e?void 0:this.getMessage(t||this.message)}}};t.RequiredValidator=c,t.RequiredValidator=c=n([(0,s.validator)(i.ValidationKeys.REQUIRED),o("design:paramtypes",[String])],c)},553:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.StepValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.STEP){super(e,"number","string")}hasErrors(e,t,r){if(void 0!==e)return Number(e)%Number(t)!=0?this.getMessage(r||this.message,t):void 0}};t.StepValidator=c,t.StepValidator=c=n([(0,s.validator)(i.ValidationKeys.STEP),o("design:paramtypes",[String])],c)},375:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.TypeValidator=void 0;const a=r(116),i=r(772),s=r(174),c=r(787),u=r(935),l=r(770);let d=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.TYPE){super(e)}hasErrors(e,t,r){if(void 0!==e)return(0,s.evaluateDesignTypes)(e,t)?void 0:this.getMessage(r||this.message,"string"==typeof t?t:Array.isArray(t)?t.join(", "):t.name,typeof e)}};t.TypeValidator=d,t.TypeValidator=d=n([(0,c.validator)(i.ValidationKeys.TYPE),o("design:paramtypes",[String])],d),l.Validation.register({validator:d,validationKey:u.ModelKeys.TYPE,save:!1})},964:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.URLValidator=void 0;const a=r(772),i=r(273),s=r(787);let c=class extends i.PatternValidator{constructor(e=a.DEFAULT_ERROR_MESSAGES.URL){super(e)}hasErrors(e,t){return super.hasErrors(e,a.DEFAULT_PATTERNS.URL,t)}};t.URLValidator=c,t.URLValidator=c=n([(0,s.validator)(a.ValidationKeys.URL),o("design:paramtypes",[String])],c)},116:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Validator=void 0;const n=r(772),o=r(593),a=r(174);t.Validator=class{constructor(e=n.DEFAULT_ERROR_MESSAGES.DEFAULT,...t){this.message=e,t.length&&(this.acceptedTypes=t),this.acceptedTypes&&(this.hasErrors=this.checkTypeAndHasErrors(this.hasErrors.bind(this)))}getMessage(e,...t){return(0,o.sf)(e,...t)}checkTypeAndHasErrors(e){return function(t,...r){return void 0!==t&&this.acceptedTypes?(0,a.checkTypes)(t,this.acceptedTypes)?e(t,...r):this.getMessage(n.DEFAULT_ERROR_MESSAGES.TYPE,this.acceptedTypes.join(", "),typeof t):e(t,...r)}.bind(this)}}},436:(e,t)=>{"use strict";function r(e){return e.constructor&&e.hasErrors}Object.defineProperty(t,"__esModule",{value:!0}),t.ValidatorRegistry=void 0,t.isValidator=r,t.ValidatorRegistry=class{constructor(...e){this.cache={},this.customKeyCache={},this.register(...e)}getCustomKeys(){return Object.assign({},this.customKeyCache)}getKeys(){return Object.keys(this.cache)}get(e){if(!(e in this.cache))return;const t=this.cache[e];if(r(t))return t;const n=new(t.default||t);return this.cache[e]=n,n}register(...e){e.forEach((e=>{if(r(e)){if(e.validationKey in this.cache)return;this.cache[e.validationKey]=e}else{const{validationKey:t,validator:r,save:n}=e;if(t in this.cache)return;if(this.cache[t]=r,!n)return;const o={};o[t.toUpperCase()]=t,this.customKeyCache=Object.assign({},this.customKeyCache,o)}}))}}},772:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_PATTERNS=t.DEFAULT_ERROR_MESSAGES=t.DAYS_OF_WEEK_NAMES=t.MONTH_NAMES=t.ValidationKeys=void 0,t.ValidationKeys={REFLECT:"model.validation.",VALIDATOR:"validator",REQUIRED:"required",MIN:"min",MAX:"max",STEP:"step",MIN_LENGTH:"minlength",MAX_LENGTH:"maxlength",PATTERN:"pattern",EMAIL:"email",URL:"url",DATE:"date",TYPE:"type",PASSWORD:"password",LIST:"list"},t.MONTH_NAMES=["January","February","March","April","May","June","July","August","September","October","November","December"],t.DAYS_OF_WEEK_NAMES=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],t.DEFAULT_ERROR_MESSAGES={REQUIRED:"This field is required",MIN:"The minimum value is {0}",MAX:"The maximum value is {0}",MIN_LENGTH:"The minimum length is {0}",MAX_LENGTH:"The maximum length is {0}",PATTERN:"The value does not match the pattern",EMAIL:"The value is not a valid email",URL:"The value is not a valid URL",TYPE:"Invalid type. Expected {0}, received {1}",STEP:"Invalid value. Not a step of {0}",DATE:"Invalid value. not a valid Date",DEFAULT:"There is an Error",PASSWORD:"Must be at least 8 characters and contain one of number, lower and upper case letters, and special character (@$!%*?&_-.,)",LIST:"Invalid list of {0}",LIST_INSIDE:"Elements of list are invalid: {0}",MODEL_NOT_FOUND:"No model registered under {0}"},t.DEFAULT_PATTERNS={EMAIL:/[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-zA-Z0-9](?:[a-z0-9-]*[a-zA-Z0-9])?\.)+[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?/,URL:/^(?:(?:(?:https?|ftp):)?\/\/)(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u00a1-\uffff][a-z0-9\u00a1-\uffff_-]{0,62})?[a-z0-9\u00a1-\uffff]\.)+(?:[a-z\u00a1-\uffff]{2,}\.?))(?::\d{2,5})?(?:[/?#]\S*)?$/i,PASSWORD:{CHAR8_ONE_OF_EACH:/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?=.*[@$!%*?&_\-.,])[A-Za-z\d@$!%*?&_\-.,]{8,}$/g}}},787:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validator=function(...e){return(0,o.apply)((t=>(e.forEach((e=>{n.Validation.register({validator:t,validationKey:e,save:!0})})),t)),(0,o.metadata)((0,i.getValidationKey)(a.ValidationKeys.VALIDATOR),e))};const n=r(770),o=r(839),a=r(772),i=r(844)},493:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.Validators=void 0;const a=r(395),i=r(375),s=r(354),c=r(553),u=r(964),l=r(273),d=r(651),f=r(519),p=r(909),y=r(169),h=r(812),g=r(335),v=r(407);o(r(772),t),o(r(395),t),o(r(787),t),o(r(335),t),o(r(407),t),o(r(169),t),o(r(909),t),o(r(519),t),o(r(651),t),o(r(354),t),o(r(273),t),o(r(812),t),o(r(553),t),o(r(168),t),o(r(375),t),o(r(964),t),o(r(116),t),o(r(436),t),t.Validators={EmailValidator:g.EmailValidator,RequiredValidator:h.RequiredValidator,MaxLengthValidator:y.MaxLengthValidator,MaxValidator:p.MaxValidator,MinLengthValidator:f.MinLengthValidator,MinValidator:d.MinValidator,PatternValidator:l.PatternValidator,URLValidator:u.URLValidator,StepValidator:c.StepValidator,DateValidator:a.DateValidator,TypeValidator:i.TypeValidator,PasswordValidator:s.PasswordValidator,ListValidator:v.ListValidator}},168:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},475:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.required=function(e=i.DEFAULT_ERROR_MESSAGES.REQUIRED){return(0,a.metadata)((0,l.getValidationKey)(i.ValidationKeys.REQUIRED),{message:e})},t.min=function(e,t=i.DEFAULT_ERROR_MESSAGES.MIN){return(0,a.metadata)((0,l.getValidationKey)(i.ValidationKeys.MIN),{value:e,message:t,types:[Number.name,Date.name]})},t.max=function(e,t=i.DEFAULT_ERROR_MESSAGES.MAX){return(0,a.metadata)((0,l.getValidationKey)(i.ValidationKeys.MAX),{value:e,message:t,types:[Number.name,Date.name]})},t.step=function(e,t=i.DEFAULT_ERROR_MESSAGES.STEP){return(0,a.metadata)((0,l.getValidationKey)(i.ValidationKeys.STEP),{value:e,message:t,types:[Number.name]})},t.minlength=function(e,t=i.DEFAULT_ERROR_MESSAGES.MIN_LENGTH){return(0,a.metadata)((0,l.getValidationKey)(i.ValidationKeys.MIN_LENGTH),{value:e,message:t,types:[String.name,Array.name,Set.name]})},t.maxlength=function(e,t=i.DEFAULT_ERROR_MESSAGES.MAX_LENGTH){return(0,a.metadata)((0,l.getValidationKey)(i.ValidationKeys.MAX_LENGTH),{value:e,message:t,types:[String.name,Array.name,Set.name]})},t.pattern=function(e,t=i.DEFAULT_ERROR_MESSAGES.PATTERN){return(0,a.metadata)((0,l.getValidationKey)(i.ValidationKeys.PATTERN),{value:"string"==typeof e?e:e.toString(),message:t,types:[String.name]})},t.email=function(e=i.DEFAULT_ERROR_MESSAGES.EMAIL){return(0,a.metadata)((0,l.getValidationKey)(i.ValidationKeys.EMAIL),{message:e,types:[String.name]})},t.url=function(e=i.DEFAULT_ERROR_MESSAGES.URL){return(0,a.metadata)((0,l.getValidationKey)(i.ValidationKeys.URL),{message:e,types:[String.name]})},t.type=d,t.date=function(e="dd/MM/yyyy",t=i.DEFAULT_ERROR_MESSAGES.DATE){return(r,n)=>{Reflect.defineMetadata((0,l.getValidationKey)(i.ValidationKeys.DATE),{format:e,message:t,types:[Date.name]},r,n);const o=new WeakMap;Object.defineProperty(r,n,{configurable:!1,set(t){const r=Object.getOwnPropertyDescriptor(this,n);r&&!r.configurable||Object.defineProperty(this,n,{enumerable:!0,configurable:!1,get:()=>o.get(this),set:t=>{let r;try{r=(0,u.parseDate)(e,t),o.set(this,r)}catch(e){console.error((0,s.sf)("Failed to parse date: {0}",e.message||e))}}}),this[n]=t},get(){console.log("here")}})}},t.password=function(e=i.DEFAULT_PATTERNS.PASSWORD.CHAR8_ONE_OF_EACH,t=i.DEFAULT_ERROR_MESSAGES.PASSWORD,r=c.PasswordValidator){return(n,a)=>{Reflect.defineMetadata((0,l.getValidationKey)(i.ValidationKeys.PASSWORD),{pattern:e,message:t,types:[String.name]},n,a),o.Validation.register({validator:r,validationKey:i.ValidationKeys.PASSWORD,save:!0})}},t.list=f,t.set=function(e,t=i.DEFAULT_ERROR_MESSAGES.LIST,r){return(n,o)=>{f(e,"Set",t,r)(n,o)}},r(630);const n=r(407),o=r(770),a=r(501),i=r(772),s=r(593),c=r(354),u=r(935),l=r(844);function d(e,t=i.DEFAULT_ERROR_MESSAGES.TYPE){return(0,a.metadata)((0,l.getValidationKey)(i.ValidationKeys.TYPE),{customTypes:e,message:t})}function f(e,t="Array",r=i.DEFAULT_ERROR_MESSAGES.LIST,a=n.ListValidator){return(n,s)=>{d(t)(n,s),Reflect.defineMetadata((0,l.getValidationKey)(i.ValidationKeys.LIST),{class:e.name,type:t,message:r},n,s),o.Validation.register({validator:a,validationKey:i.ValidationKeys.LIST,save:!0})}}},965:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),o(r(493),t),o(r(475),t),o(r(792),t),o(r(844),t),o(r(770),t)},792:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},844:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getValidationKey=function(e){return n.ValidationKeys.REFLECT+e};const n=r(772)},630:(e,t,r)=>{var n;!function(e){!function(){var t="object"==typeof globalThis?globalThis:"object"==typeof r.g?r.g:"object"==typeof self?self:"object"==typeof this?this:function(){try{return Function("return this;")()}catch(e){}}()||function(){try{return(0,eval)("(function() { return this; })()")}catch(e){}}(),n=o(e);function o(e,t){return function(r,n){Object.defineProperty(e,r,{configurable:!0,writable:!0,value:n}),t&&t(r,n)}}void 0!==t.Reflect&&(n=o(t.Reflect,n)),function(e,t){var r=Object.prototype.hasOwnProperty,n="function"==typeof Symbol,o=n&&void 0!==Symbol.toPrimitive?Symbol.toPrimitive:"@@toPrimitive",a=n&&void 0!==Symbol.iterator?Symbol.iterator:"@@iterator",i="function"==typeof Object.create,s={__proto__:[]}instanceof Array,c=!i&&!s,u={create:i?function(){return H(Object.create(null))}:s?function(){return H({__proto__:null})}:function(){return H({})},has:c?function(e,t){return r.call(e,t)}:function(e,t){return t in e},get:c?function(e,t){return r.call(e,t)?e[t]:void 0}:function(e,t){return e[t]}},l=Object.getPrototypeOf(Function),d="function"==typeof Map&&"function"==typeof Map.prototype.entries?Map:function(){var e={},t=[],r=function(){function e(e,t,r){this._index=0,this._keys=e,this._values=t,this._selector=r}return e.prototype["@@iterator"]=function(){return this},e.prototype[a]=function(){return this},e.prototype.next=function(){var e=this._index;if(e>=0&&e<this._keys.length){var r=this._selector(this._keys[e],this._values[e]);return e+1>=this._keys.length?(this._index=-1,this._keys=t,this._values=t):this._index++,{value:r,done:!1}}return{value:void 0,done:!0}},e.prototype.throw=function(e){throw this._index>=0&&(this._index=-1,this._keys=t,this._values=t),e},e.prototype.return=function(e){return this._index>=0&&(this._index=-1,this._keys=t,this._values=t),{value:e,done:!0}},e}();return function(){function t(){this._keys=[],this._values=[],this._cacheKey=e,this._cacheIndex=-2}return Object.defineProperty(t.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0}),t.prototype.has=function(e){return this._find(e,!1)>=0},t.prototype.get=function(e){var t=this._find(e,!1);return t>=0?this._values[t]:void 0},t.prototype.set=function(e,t){var r=this._find(e,!0);return this._values[r]=t,this},t.prototype.delete=function(t){var r=this._find(t,!1);if(r>=0){for(var n=this._keys.length,o=r+1;o<n;o++)this._keys[o-1]=this._keys[o],this._values[o-1]=this._values[o];return this._keys.length--,this._values.length--,K(t,this._cacheKey)&&(this._cacheKey=e,this._cacheIndex=-2),!0}return!1},t.prototype.clear=function(){this._keys.length=0,this._values.length=0,this._cacheKey=e,this._cacheIndex=-2},t.prototype.keys=function(){return new r(this._keys,this._values,n)},t.prototype.values=function(){return new r(this._keys,this._values,o)},t.prototype.entries=function(){return new r(this._keys,this._values,i)},t.prototype["@@iterator"]=function(){return this.entries()},t.prototype[a]=function(){return this.entries()},t.prototype._find=function(e,t){if(!K(this._cacheKey,e)){this._cacheIndex=-1;for(var r=0;r<this._keys.length;r++)if(K(this._keys[r],e)){this._cacheIndex=r;break}}return this._cacheIndex<0&&t&&(this._cacheIndex=this._keys.length,this._keys.push(e),this._values.push(void 0)),this._cacheIndex},t}();function n(e,t){return e}function o(e,t){return t}function i(e,t){return[e,t]}}(),f="function"==typeof Set&&"function"==typeof Set.prototype.entries?Set:function(){function e(){this._map=new d}return Object.defineProperty(e.prototype,"size",{get:function(){return this._map.size},enumerable:!0,configurable:!0}),e.prototype.has=function(e){return this._map.has(e)},e.prototype.add=function(e){return this._map.set(e,e),this},e.prototype.delete=function(e){return this._map.delete(e)},e.prototype.clear=function(){this._map.clear()},e.prototype.keys=function(){return this._map.keys()},e.prototype.values=function(){return this._map.keys()},e.prototype.entries=function(){return this._map.entries()},e.prototype["@@iterator"]=function(){return this.keys()},e.prototype[a]=function(){return this.keys()},e}(),p="function"==typeof WeakMap?WeakMap:function(){var e=u.create(),t=n();return function(){function e(){this._key=n()}return e.prototype.has=function(e){var t=o(e,!1);return void 0!==t&&u.has(t,this._key)},e.prototype.get=function(e){var t=o(e,!1);return void 0!==t?u.get(t,this._key):void 0},e.prototype.set=function(e,t){return o(e,!0)[this._key]=t,this},e.prototype.delete=function(e){var t=o(e,!1);return void 0!==t&&delete t[this._key]},e.prototype.clear=function(){this._key=n()},e}();function n(){var t;do{t="@@WeakMap@@"+i()}while(u.has(e,t));return e[t]=!0,t}function o(e,n){if(!r.call(e,t)){if(!n)return;Object.defineProperty(e,t,{value:u.create()})}return e[t]}function a(e,t){for(var r=0;r<t;++r)e[r]=255*Math.random()|0;return e}function i(){var e=function(e){if("function"==typeof Uint8Array){var t=new Uint8Array(e);return"undefined"!=typeof crypto?crypto.getRandomValues(t):"undefined"!=typeof msCrypto?msCrypto.getRandomValues(t):a(t,e),t}return a(new Array(e),e)}(16);e[6]=79&e[6]|64,e[8]=191&e[8]|128;for(var t="",r=0;r<16;++r){var n=e[r];4!==r&&6!==r&&8!==r||(t+="-"),n<16&&(t+="0"),t+=n.toString(16).toLowerCase()}return t}}(),y=n?Symbol.for("@reflect-metadata:registry"):void 0,h=function(){var e;return!S(y)&&P(t.Reflect)&&Object.isExtensible(t.Reflect)&&(e=t.Reflect[y]),S(e)&&(e=function(){var e,r,n,o;S(y)||void 0===t.Reflect||y in t.Reflect||"function"!=typeof t.Reflect.defineMetadata||(e=function(e){var t=e.defineMetadata,r=e.hasOwnMetadata,n=e.getOwnMetadata,o=e.getOwnMetadataKeys,a=e.deleteMetadata,i=new p;return{isProviderFor:function(e,t){var r=i.get(e);return!(S(r)||!r.has(t))||!!o(e,t).length&&(S(r)&&(r=new f,i.set(e,r)),r.add(t),!0)},OrdinaryDefineOwnMetadata:t,OrdinaryHasOwnMetadata:r,OrdinaryGetOwnMetadata:n,OrdinaryOwnMetadataKeys:o,OrdinaryDeleteMetadata:a}}(t.Reflect));var a=new p,i={registerProvider:s,getProvider:u,setProvider:h};return i;function s(t){if(!Object.isExtensible(i))throw new Error("Cannot add provider to a frozen registry.");switch(!0){case e===t:break;case S(r):r=t;break;case r===t:break;case S(n):n=t;break;case n===t:break;default:void 0===o&&(o=new f),o.add(t)}}function c(t,a){if(!S(r)){if(r.isProviderFor(t,a))return r;if(!S(n)){if(n.isProviderFor(t,a))return r;if(!S(o))for(var i=x(o);;){var s=k(i);if(!s)return;var c=F(s);if(c.isProviderFor(t,a))return I(i),c}}}if(!S(e)&&e.isProviderFor(t,a))return e}function u(e,t){var r,n=a.get(e);return S(n)||(r=n.get(t)),S(r)?(S(r=c(e,t))||(S(n)&&(n=new d,a.set(e,n)),n.set(t,r)),r):r}function l(e){if(S(e))throw new TypeError;return r===e||n===e||!S(o)&&o.has(e)}function h(e,t,r){if(!l(r))throw new Error("Metadata provider not registered.");var n=u(e,t);if(n!==r){if(!S(n))return!1;var o=a.get(e);S(o)&&(o=new d,a.set(e,o)),o.set(t,r)}return!0}}()),!S(y)&&P(t.Reflect)&&Object.isExtensible(t.Reflect)&&Object.defineProperty(t.Reflect,y,{enumerable:!1,configurable:!1,writable:!1,value:e}),e}(),g=function(e){var t=new p,r={isProviderFor:function(e,r){var n=t.get(e);return!S(n)&&n.has(r)},OrdinaryDefineOwnMetadata:function(e,t,r,o){n(r,o,!0).set(e,t)},OrdinaryHasOwnMetadata:function(e,t,r){var o=n(t,r,!1);return!S(o)&&A(o.has(e))},OrdinaryGetOwnMetadata:function(e,t,r){var o=n(t,r,!1);if(!S(o))return o.get(e)},OrdinaryOwnMetadataKeys:function(e,t){var r=[],o=n(e,t,!1);if(S(o))return r;for(var a=x(o.keys()),i=0;;){var s=k(a);if(!s)return r.length=i,r;var c=F(s);try{r[i]=c}catch(e){try{I(a)}finally{throw e}}i++}},OrdinaryDeleteMetadata:function(e,r,o){var a=n(r,o,!1);if(S(a))return!1;if(!a.delete(e))return!1;if(0===a.size){var i=t.get(r);S(i)||(i.delete(o),0===i.size&&t.delete(i))}return!0}};return h.registerProvider(r),r;function n(n,o,a){var i=t.get(n),s=!1;if(S(i)){if(!a)return;i=new d,t.set(n,i),s=!0}var c=i.get(o);if(S(c)){if(!a)return;if(c=new d,i.set(o,c),!e.setProvider(n,o,r))throw i.delete(o),s&&t.delete(n),new Error("Wrong provider for target.")}return c}}(h);function v(e,t,r){if(_(e,t,r))return!0;var n=U(t);return!w(n)&&v(e,n,r)}function _(e,t,r){var n=G(t,r,!1);return!S(n)&&A(n.OrdinaryHasOwnMetadata(e,t,r))}function E(e,t,r){if(_(e,t,r))return m(e,t,r);var n=U(t);return w(n)?void 0:E(e,n,r)}function m(e,t,r){var n=G(t,r,!1);if(!S(n))return n.OrdinaryGetOwnMetadata(e,t,r)}function O(e,t,r,n){G(r,n,!0).OrdinaryDefineOwnMetadata(e,t,r,n)}function M(e,t){var r=b(e,t),n=U(e);if(null===n)return r;var o=M(n,t);if(o.length<=0)return r;if(r.length<=0)return o;for(var a=new f,i=[],s=0,c=r;s<c.length;s++){var u=c[s];a.has(u)||(a.add(u),i.push(u))}for(var l=0,d=o;l<d.length;l++)u=d[l],a.has(u)||(a.add(u),i.push(u));return i}function b(e,t){var r=G(e,t,!1);return r?r.OrdinaryOwnMetadataKeys(e,t):[]}function R(e){if(null===e)return 1;switch(typeof e){case"undefined":return 0;case"boolean":return 2;case"string":return 3;case"symbol":return 4;case"number":return 5;case"object":return null===e?1:6;default:return 6}}function S(e){return void 0===e}function w(e){return null===e}function P(e){return"object"==typeof e?null!==e:"function"==typeof e}function T(e,t){switch(R(e)){case 0:case 1:case 2:case 3:case 4:case 5:return e}var r=3===t?"string":5===t?"number":"default",n=N(e,o);if(void 0!==n){var a=n.call(e,r);if(P(a))throw new TypeError;return a}return function(e,t){if("string"===t){var r=e.toString;if(D(r)&&!P(o=r.call(e)))return o;if(D(n=e.valueOf)&&!P(o=n.call(e)))return o}else{var n;if(D(n=e.valueOf)&&!P(o=n.call(e)))return o;var o,a=e.toString;if(D(a)&&!P(o=a.call(e)))return o}throw new TypeError}(e,"default"===r?"number":r)}function A(e){return!!e}function j(e){var t=T(e,3);return"symbol"==typeof t?t:function(e){return""+e}(t)}function V(e){return Array.isArray?Array.isArray(e):e instanceof Object?e instanceof Array:"[object Array]"===Object.prototype.toString.call(e)}function D(e){return"function"==typeof e}function L(e){return"function"==typeof e}function K(e,t){return e===t||e!=e&&t!=t}function N(e,t){var r=e[t];if(null!=r){if(!D(r))throw new TypeError;return r}}function x(e){var t=N(e,a);if(!D(t))throw new TypeError;var r=t.call(e);if(!P(r))throw new TypeError;return r}function F(e){return e.value}function k(e){var t=e.next();return!t.done&&t}function I(e){var t=e.return;t&&t.call(e)}function U(e){var t=Object.getPrototypeOf(e);if("function"!=typeof e||e===l)return t;if(t!==l)return t;var r=e.prototype,n=r&&Object.getPrototypeOf(r);if(null==n||n===Object.prototype)return t;var o=n.constructor;return"function"!=typeof o||o===e?t:o}function G(e,t,r){var n=h.getProvider(e,t);if(!S(n))return n;if(r){if(h.setProvider(e,t,g))return g;throw new Error("Illegal state.")}}function H(e){return e.__=void 0,delete e.__,e}e("decorate",(function(e,t,r,n){if(S(r)){if(!V(e))throw new TypeError;if(!L(t))throw new TypeError;return function(e,t){for(var r=e.length-1;r>=0;--r){var n=(0,e[r])(t);if(!S(n)&&!w(n)){if(!L(n))throw new TypeError;t=n}}return t}(e,t)}if(!V(e))throw new TypeError;if(!P(t))throw new TypeError;if(!P(n)&&!S(n)&&!w(n))throw new TypeError;return w(n)&&(n=void 0),function(e,t,r,n){for(var o=e.length-1;o>=0;--o){var a=(0,e[o])(t,r,n);if(!S(a)&&!w(a)){if(!P(a))throw new TypeError;n=a}}return n}(e,t,r=j(r),n)})),e("metadata",(function(e,t){return function(r,n){if(!P(r))throw new TypeError;if(!S(n)&&!function(e){switch(R(e)){case 3:case 4:return!0;default:return!1}}(n))throw new TypeError;O(e,t,r,n)}})),e("defineMetadata",(function(e,t,r,n){if(!P(r))throw new TypeError;return S(n)||(n=j(n)),O(e,t,r,n)})),e("hasMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),v(e,t,r)})),e("hasOwnMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),_(e,t,r)})),e("getMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),E(e,t,r)})),e("getOwnMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),m(e,t,r)})),e("getMetadataKeys",(function(e,t){if(!P(e))throw new TypeError;return S(t)||(t=j(t)),M(e,t)})),e("getOwnMetadataKeys",(function(e,t){if(!P(e))throw new TypeError;return S(t)||(t=j(t)),b(e,t)})),e("deleteMetadata",(function(e,t,r){if(!P(t))throw new TypeError;if(S(r)||(r=j(r)),!P(t))throw new TypeError;S(r)||(r=j(r));var n=G(t,r,!1);return!S(n)&&n.OrdinaryDeleteMetadata(e,t,r)}))}(n,t),void 0===t.Reflect&&(t.Reflect=e)}()}(n||(n={}))}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var a=t[n]={exports:{}};return e[n].call(a.exports,a,a.exports,r),a.exports}return r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r(729)})()));
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("decorator-validation",[],t):"object"==typeof exports?exports["decorator-validation"]=t():e["decorator-validation"]=t()}(this,(()=>(()=>{var e={729:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=void 0,o(r(935),t),o(r(965),t),o(r(847),t),t.VERSION="##VERSION##"},6:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Model=void 0,t.validate=y;const n=r(772),o=r(735),a=r(19),i=r(402),s=r(154),c=r(38),u=r(936),l=r(770),d=r(523),f=r(593),p=r(32);function y(e,...t){const r=[];for(const o in e)e.hasOwnProperty(o)&&-1===t.indexOf(o)&&r.push((0,p.getPropertyDecorators)(n.ValidationKeys.REFLECT,e,o));const o=r.reduce(((t,r)=>{const{prop:o,decorators:a}=r;if(!a||!a.length)return t;const c=a[0];a.find((e=>e.key===n.ValidationKeys.TYPE||!!e.props.types?.find((e=>e===c.props.name))))&&a.shift();let u=a.reduce(((t,r)=>{const n=l.Validation.get(r.key);if(!n)return t;const a=n.hasErrors(e[o.toString()],...r.key===s.ModelKeys.TYPE?[r.props]:Object.values(r.props));return a&&((t=t||{})[r.key]=a),t}),void 0);return u=u||Object.keys(e).filter((e=>!u||!u[e])).reduce(((t,r)=>{let o;const a=(0,p.getPropertyDecorators)(n.ValidationKeys.REFLECT,e,r).decorators,c=a.filter((e=>-1!==[s.ModelKeys.TYPE,n.ValidationKeys.TYPE].indexOf(e.key)));if(!c||!c.length)return t;const u=c.pop(),l=u.props.name?[u.props.name]:Array.isArray(u.props.customTypes)?u.props.customTypes:[u.props.customTypes],d=Object.values(i.ReservedModels).map((e=>e.toLowerCase()));return l.forEach((t=>{if(-1===d.indexOf(t.toLowerCase()))switch(t){case"Array":case"Set":if(a.length&&a.find((e=>e.key===n.ValidationKeys.LIST))){const a="Array"===t?e[r].find((e=>e.hasErrors())):e[r].values().find((e=>e.hasErrors()));a&&(o=(0,f.sf)(n.DEFAULT_ERROR_MESSAGES.LIST_INSIDE,a.toString()))}break;default:try{e[r]&&(o=e[r].hasErrors())}catch(e){console.warn((0,f.sf)("Model should be validatable but its not"))}}})),o&&((t=t||{})[r]=o),t}),void 0),u&&((t=t||{})[r.prop.toString()]=u),t}),void 0);return o?new a.ModelErrorDefinition(o):void 0}let h,g,v,_;class E{constructor(e){}hasErrors(...e){return y(this,...e)}equals(e,...t){return(0,p.isEqual)(this,e,...t)}serialize(){return E.serialize(this)}toString(){return this.constructor.name+": "+JSON.stringify(this,void 0,2)}toHash(){return E.getHashingFunction()(this).toString()}static deserialize(e){return E.getSerializer().deserialize(e)}static serialize(e){return E.getSerializer().serialize(e)}static hash(e){return E.getHashingFunction()(e)}static fromObject(e,t){return(0,c.constructFromObject)(e,t)}static fromModel(e,t){return(0,c.constructFromModel)(e,t)}static setBuilder(e){h=e}static getBuilder(){return h}static getRegistry(){return g||(g=new u.ModelRegistryManager),g}static setRegistry(e){g=e}static register(e,t){return E.getRegistry().register(e,t)}static get(e){return E.getRegistry().get(e)}static build(e={},t){return E.getRegistry().build(e,t)}static setSerializer(e){v=e}static getSerializer(){return v||(v=new o.JSONSerializer),v}static setHashingFunction(e){_=e}static getHashingFunction(){return _||(_=d.hashObj),_}}t.Model=E},19:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ModelErrorDefinition=void 0,t.ModelErrorDefinition=class{constructor(e){for(const t in e)e.hasOwnProperty(t)&&e[t]&&Object.defineProperty(this,t,{enumerable:!0,configurable:!1,value:e[t],writable:!1})}toString(){const e=this;return Object.keys(e).filter((t=>e.hasOwnProperty(t)&&"function"!=typeof e[t])).reduce(((t,r)=>{let n=Object.keys(e[r]).reduce(((t,n)=>(t?t+=`\n${e[r][n]}`:t=e[r][n],t)),void 0);return n&&(n=`${r} - ${n}`,t?t+=`\n${n}`:t=n),t}),"")}}},936:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ModelRegistryManager=void 0,t.bulkModelRegister=function(...e){e.forEach((e=>{const t=e.constructor?e.constructor:e;n.Model.register(t,e.name)}))};const n=r(6),o=r(154),a=r(593),i=r(710);t.ModelRegistryManager=class{constructor(e=o.ModelKeys.ANCHOR,t=i.isModel){this.cache={},this.testFunction=t,this.anchorKey=e}register(e,t){if("function"!=typeof e)throw new Error("Model registering failed. Missing Class name or constructor");t=t||e.name,this.cache[t]=e}get(e){try{return this.cache[e]}catch(e){return}}build(e={},t){if(!t&&!this.testFunction(e))throw new Error("Provided obj is not a Model object");const r=t||e[this.anchorKey].class;if(!(r in this.cache))throw new Error((0,a.sf)("Provided class {0} is not a registered Model object",r));return new this.cache[r](e)}}},402:(e,t)=>{"use strict";var r,n;Object.defineProperty(t,"__esModule",{value:!0}),t.ReservedModels=t.Primitives=void 0,function(e){e.STRING="string",e.NUMBER="number",e.BOOLEAN="boolean",e.BIGINT="bigint"}(r||(t.Primitives=r={})),function(e){e.STRING="string",e.OBJECT="object",e.NUMBER="number",e.BOOLEAN="boolean",e.BIGINT="bigint",e.DATE="date"}(n||(t.ReservedModels=n={}))},38:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.constructFromObject=function(e,t){if(!t)return e;for(const r in t)t.hasOwnProperty(r)&&(e.hasOwnProperty(r)||e.prototype&&e.prototype.hasOwnProperty(r))&&(e[r]=t[r]||void 0);return e},t.constructFromModel=function(e,t){if(!t)return e;let r,l;for(const d in t)if(t.hasOwnProperty(d)&&(e.hasOwnProperty(d)||e.prototype&&e.prototype.hasOwnProperty(d))){if(e[d]=t[d]||void 0,"object"!=typeof e[d])continue;if((0,u.isModel)(e[d])){try{e[d]=n.Model.build(e[d])}catch(e){console.error(e)}continue}const f=(0,c.getPropertyDecorators)(o.ValidationKeys.REFLECT,e,d).decorators;if(r=f.filter((e=>-1!==[i.ModelKeys.TYPE,o.ValidationKeys.TYPE].indexOf(e.key))),!r||!r.length)throw new Error((0,s.sf)("failed to find decorators for property {0}",d));l=r.pop();const p=l.props.name?[l.props.name]:Array.isArray(l.props.customTypes)?l.props.customTypes:[l.props.customTypes],y=Object.values(a.ReservedModels).map((e=>e.toLowerCase()));p.forEach((t=>{if(-1===y.indexOf(t.toLowerCase()))try{switch(t){case"Array":case"Set":if(f.length){const r=f.find((e=>e.key===o.ValidationKeys.LIST));if(r&&("Array"===t&&(e[d]=e[d].map((e=>n.Model.build(e,r.props.class)))),"Set"===t)){const t=new Set;for(const o of e[d])t.add(n.Model.build(o,r.props.class));e[d]=t}}break;default:e[d]&&(e[d]=n.Model.build(e[d],t))}}catch(e){console.log(e)}}))}return e},t.construct=function(e,...t){const r=(...t)=>new e(...t);return r.prototype=e.prototype,r(...t)};const n=r(6),o=r(772),a=r(402),i=r(154),s=r(593),c=r(32),u=r(710)},893:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getModelKey=void 0,t.model=function(e,r){return i=>{const s=function(...s){const c=(0,n.construct)(i,...s),u=a.Model.getBuilder();u&&u(c,s.length?s[0]:void 0);const l=Object.assign({},{class:i.name});return Object.defineProperty(c,o.ModelKeys.ANCHOR,{writable:!1,enumerable:!1,configurable:!1,value:l}),Reflect.defineMetadata((0,t.getModelKey)(o.ModelKeys.MODEL),Object.assign(l,e||{}),c.constructor),r&&r(c,...s),c};return s.prototype=i.prototype,Object.defineProperty(s,"name",{writable:!1,enumerable:!0,configurable:!1,value:i.prototype.constructor.name}),a.Model.register(s),s}};const n=r(38),o=r(154),a=r(6);t.getModelKey=e=>o.ModelKeys.REFLECT+e},847:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),o(r(402),t),o(r(38),t),o(r(893),t),o(r(6),t),o(r(19),t),o(r(936),t),o(r(282),t),o(r(710),t)},282:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},710:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isModel=function(e){return!!e[n.ModelKeys.ANCHOR]||!!(0,o.getClassDecorators)(n.ModelKeys.REFLECT,e).find((e=>e.key===n.ModelKeys.MODEL&&e.props&&e.props.class))};const n=r(154),o=r(32)},154:(e,t)=>{"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.ModelKeys=void 0,function(e){e.REFLECT="model.definition.",e.TYPE="design:type",e.PARAMS="design:paramtypes",e.RETURN="design:returntype",e.MODEL="model",e.ANCHOR="__modelDefinition"}(r||(t.ModelKeys=r={}))},46:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.dateFromFormat=a,t.bindDateToString=i,t.isValidDate=s,t.twoDigitPad=c,t.formatDate=u,t.parseDate=function(e,t){let r;if(t){if(t instanceof Date)try{r=a(u(t,e),e)}catch(r){throw new Error((0,o.sf)("Could not convert date {0} to format: {1}",t.toString(),e))}else if("string"==typeof t)r=a(t,e);else if("number"==typeof t)r=a(u(new Date(t),e),e);else{if(!s(t))throw new Error(`Invalid value provided ${t}`);try{r=a(u(new Date(t),e),e)}catch(r){throw new Error((0,o.sf)("Could not convert date {0} to format: {1}",t,e))}}return i(r,e)}},r(630);const n=r(772),o=r(593);function a(e,t){let r=t;r.match(/hh/)?r=r.replace("hh","(?<hour>\\d{2})"):r.match(/h/)?r=r.replace("h","(?<hour>\\d{1,2})"):r.match(/HH/)?r=r.replace("HH","(?<hour>\\d{2})"):r.match(/H/)&&(r=r.replace("H","(?<hour>\\d{1,2})")),r.match(/mm/)?r=r.replace("mm","(?<minutes>\\d{2})"):r.match(/m/)&&(r=r.replace("m","(?<minutes>\\d{1,2})")),r.match(/ss/)?r=r.replace("ss","(?<seconds>\\d{2})"):r.match(/s/)&&(r=r.replace("s","(?<seconds>\\d{1,2})")),r.match(/dd/)?r=r.replace("dd","(?<day>\\d{2})"):r.match(/d/)&&(r=r.replace("d","(?<day>\\d{1,2})")),r.match(/EEEE/)?r=r.replace("EEEE","(?<dayofweek>\\w+)"):r.match(/EEEE/)&&(r=r.replace("EEE","(?<dayofweek>\\w+)")),r.match(/yyyy/)?r=r.replace("yyyy","(?<year>\\d{4})"):r.match(/yy/)&&(r=r.replace("yy","(?<year>\\d{2})")),r.match(/MMMM/)?r=r.replace("MMMM","(?<monthname>\\w+)"):r.match(/MMM/)&&(r=r.replace("MMM","(?<monthnamesmall>\\w+)")),r.match(/MM/)?r=r.replace("MM","(?<month>\\d{2})"):r.match(/M/)&&(r=r.replace("M","(?<month>\\d{1,2})")),r=r.replace("S","(?<milis>\\d{1,3})").replace("aaa","(?<ampm>\\w{2})");const o=new RegExp(r,"g").exec(e);if(!o||!o.groups)return new Date(e);const a=function(e){if(!e)return 0;const t=parseInt(e);return isNaN(t)?0:t},i=a(o.groups.year),s=a(o.groups.day),c=o.groups.ampm;let u=a(o.groups.hour);c&&(u="PM"===c?u+12:u);const l=a(o.groups.minutes),d=a(o.groups.seconds),f=a(o.groups.milis),p=o.groups.monthname,y=o.groups.monthnamesmall;let h=o.groups.month;if(p)h=n.MONTH_NAMES.indexOf(p);else if(y){const t=n.MONTH_NAMES.find((e=>e.toLowerCase().startsWith(y.toLowerCase())));if(!t)return new Date(e);h=n.MONTH_NAMES.indexOf(t)}else h=a(`${h}`);return new Date(i,h-1,s,u,l,d,f)}function i(e,t){if(!e)return;const r=()=>u(e,t);return Object.defineProperty(e,"toISOString",{enumerable:!1,configurable:!1,value:r}),Object.defineProperty(e,"toString",{enumerable:!1,configurable:!1,value:r}),e}function s(e){return e&&"[object Date]"===Object.prototype.toString.call(e)&&!isNaN(e)}function c(e){return e<10?"0"+e:e.toString()}function u(e,t="yyyy/MM/dd"){const r=e.getDate(),o=e.getMonth(),a=e.getFullYear(),i=e.getHours(),s=e.getMinutes(),u=e.getSeconds(),l=e.getMilliseconds(),d=i%12,f=c(d),p=c(i),y=c(s),h=c(u),g=i<12?"AM":"PM",v=n.DAYS_OF_WEEK_NAMES[e.getDay()],_=v.substr(0,3),E=c(r),m=o+1,O=c(m),M=n.MONTH_NAMES[o],b=M.substr(0,3),R=a+"",S=R.substr(2,2);return(t=t.replace("hh",f).replace("h",d.toString()).replace("HH",p).replace("H",i.toString()).replace("mm",y).replace("m",s.toString()).replace("ss",h).replace("s",u.toString()).replace("S",l.toString()).replace("dd",E).replace("d",r.toString()).replace("EEEE",v).replace("EEE",_).replace("yyyy",R).replace("yy",S).replace("aaa",g)).indexOf("MMM")>-1?t.replace("MMMM",M).replace("MMM",b):t.replace("MM",O).replace("M",m.toString())}},523:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hashCode=o,t.hashSerialization=function(e){return o(n.Model.serialize(e))},t.hashObj=function(e){const t=function(e,t){const r=n(t);return"string"==typeof r?n((e||"")+n(t)):0|(e=((e=e||0)<<5)-e+r)},r=o,n=function(e){return void 0===e?"":-1!==["string","number","symbol"].indexOf(typeof e)?r(e.toString()):e instanceof Date?r(e.getTime()):Array.isArray(e)?e.reduce(t,void 0):Object.values(e).reduce(t,void 0)},a=Object.values(e).reduce(t,0);return"number"==typeof a?Math.abs(a):a};const n=r(6);function o(e){e=String(e);let t=0;for(let r=0;r<e.length;r++)t=(t<<5)-t+e.charCodeAt(r),t|=0;return t}},935:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),o(r(154),t),o(r(46),t),o(r(523),t),o(r(735),t),o(r(904),t),o(r(735),t),o(r(593),t)},904:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},735:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.JSONSerializer=void 0;const n=r(6),o=r(154);t.JSONSerializer=class{preSerialize(e){const t=Object.assign({},e);return t[o.ModelKeys.ANCHOR]=e[o.ModelKeys.ANCHOR],t}deserialize(e){const t=JSON.parse(e);return n.Model.build(t)}serialize(e){return JSON.stringify(this.preSerialize(e))}}},593:(e,t)=>{"use strict";function r(e,...t){return e.replace(/{(\d+)}/g,(function(e,r){return void 0!==t[r]?t[r]:e}))}Object.defineProperty(t,"__esModule",{value:!0}),t.sf=void 0,t.stringFormat=r,t.sf=r},770:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Validation=void 0;const n=r(436);class o{static{this.actingValidatorRegistry=void 0}constructor(){}static setRegistry(e,t){t&&o.actingValidatorRegistry&&o.actingValidatorRegistry.getKeys().forEach((r=>{const n=e.get(r);n&&e.register(t(n))})),o.actingValidatorRegistry=e}static getRegistry(){return o.actingValidatorRegistry||(o.actingValidatorRegistry=new n.ValidatorRegistry),o.actingValidatorRegistry}static get(e){return o.getRegistry().get(e)}static register(...e){return o.getRegistry().register(...e)}}t.Validation=o},395:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.DateValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.DATE){super(e,Number.name,Date.name,String.name)}hasErrors(e,t,r){if(void 0!==e)return"string"==typeof e&&(e=new Date(e)),isNaN(e.getDate())?this.getMessage(r||this.message):void 0}};t.DateValidator=c,t.DateValidator=c=n([(0,s.validator)(i.ValidationKeys.DATE),o("design:paramtypes",[String])],c)},335:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.EmailValidator=void 0;const a=r(772),i=r(273),s=r(787);let c=class extends i.PatternValidator{constructor(e=a.DEFAULT_ERROR_MESSAGES.EMAIL){super(e)}hasErrors(e,t){return super.hasErrors(e,a.DEFAULT_PATTERNS.EMAIL,t)}};t.EmailValidator=c,t.EmailValidator=c=n([(0,s.validator)(a.ValidationKeys.EMAIL),o("design:paramtypes",[String])],c)},407:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.ListValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.LIST){super(e,Array.name,Set.name)}hasErrors(e,t,r){if(!e||(Array.isArray(e)?!e.length:!e.size))return;let n;for(let o=0;o<(Array.isArray(e)?e.length:e.size);o++)switch(n=e[o],typeof n){case"object":case"function":if(!n.constructor||n.constructor.name!==t)return this.getMessage(r||this.message,t);break;default:if(typeof n!==t)return this.getMessage(r||this.message,t)}}};t.ListValidator=c,t.ListValidator=c=n([(0,s.validator)(i.ValidationKeys.LIST),o("design:paramtypes",[String])],c)},169:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MaxLengthValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MAX_LENGTH){super(e,String.name,Array.name)}hasErrors(e,t,r){if(void 0!==e)return e.length>t?this.getMessage(r||this.message,t):void 0}};t.MaxLengthValidator=c,t.MaxLengthValidator=c=n([(0,s.validator)(i.ValidationKeys.MAX_LENGTH),o("design:paramtypes",[String])],c)},909:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MaxValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MAX){super(e,"number","Date","string")}hasErrors(e,t,r){if(void 0!==e){if(e instanceof Date&&!(t instanceof Date)&&(t=new Date(t),isNaN(t.getDate())))throw new Error("Invalid Max param defined");return e>t?this.getMessage(r||this.message,t):void 0}}};t.MaxValidator=c,t.MaxValidator=c=n([(0,s.validator)(i.ValidationKeys.MAX),o("design:paramtypes",[String])],c)},519:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MinLengthValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MIN_LENGTH){super(e,String.name,Array.name)}hasErrors(e,t,r){if(void 0!==e)return e.length<t?this.getMessage(r||this.message,t):void 0}};t.MinLengthValidator=c,t.MinLengthValidator=c=n([(0,s.validator)(i.ValidationKeys.MIN_LENGTH),o("design:paramtypes",[String])],c)},889:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MinValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MIN){super(e,"number","Date","string")}hasErrors(e,t,r){if(void 0!==e){if(e instanceof Date&&!(t instanceof Date)&&(t=new Date(t),isNaN(t.getDate())))throw new Error("Invalid Min param defined");return e<t?this.getMessage(r||this.message,t):void 0}}};t.MinValidator=c,t.MinValidator=c=n([(0,s.validator)(i.ValidationKeys.MIN),o("design:paramtypes",[String])],c)},354:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.PasswordValidator=void 0;const a=r(273),i=r(772),s=r(787);let c=class extends a.PatternValidator{constructor(e=i.DEFAULT_ERROR_MESSAGES.PASSWORD,t=i.DEFAULT_PATTERNS.PASSWORD.CHAR8_ONE_OF_EACH){super(e),this.pattern=t}hasErrors(e,t,r){return super.hasErrors(e,t||this.pattern,r||this.message)}};t.PasswordValidator=c,t.PasswordValidator=c=n([(0,s.validator)(i.ValidationKeys.PASSWORD),o("design:paramtypes",[Object,RegExp])],c)},273:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.PatternValidator=t.regexpParser=void 0;const a=r(116),i=r(772),s=r(787);t.regexpParser=new RegExp("^/(.+)/([gimus]*)$");let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.PATTERN){super(e,"string")}getPattern(e){if(!t.regexpParser.test(e))return new RegExp(e);const r=e.match(t.regexpParser);return new RegExp(r[1],r[2])}hasErrors(e,t,r){if(e){if(!t)throw new Error("Missing Pattern");return(t="string"==typeof t?this.getPattern(t):t).lastIndex=0,t.test(e)?void 0:this.getMessage(r||this.message)}}};t.PatternValidator=c,t.PatternValidator=c=n([(0,s.validator)(i.ValidationKeys.PATTERN),o("design:paramtypes",[String])],c)},812:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.RequiredValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.REQUIRED){super(e)}hasErrors(e,t){switch(typeof e){case"boolean":case"number":return void 0===e?this.getMessage(t||this.message):void 0;default:return e?void 0:this.getMessage(t||this.message)}}};t.RequiredValidator=c,t.RequiredValidator=c=n([(0,s.validator)(i.ValidationKeys.REQUIRED),o("design:paramtypes",[String])],c)},553:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.StepValidator=void 0;const a=r(116),i=r(772),s=r(787);let c=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.STEP){super(e,"number","string")}hasErrors(e,t,r){if(void 0!==e)return Number(e)%Number(t)!=0?this.getMessage(r||this.message,t):void 0}};t.StepValidator=c,t.StepValidator=c=n([(0,s.validator)(i.ValidationKeys.STEP),o("design:paramtypes",[String])],c)},375:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.TypeValidator=void 0;const a=r(116),i=r(772),s=r(787),c=r(935),u=r(770),l=r(32);let d=class extends a.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.TYPE){super(e)}hasErrors(e,t,r){if(void 0!==e)return(0,l.evaluateDesignTypes)(e,t)?void 0:this.getMessage(r||this.message,"string"==typeof t?t:Array.isArray(t)?t.join(", "):t.name,typeof e)}};t.TypeValidator=d,t.TypeValidator=d=n([(0,s.validator)(i.ValidationKeys.TYPE),o("design:paramtypes",[String])],d),u.Validation.register({validator:d,validationKey:c.ModelKeys.TYPE,save:!1})},964:function(e,t,r){"use strict";var n=this&&this.__decorate||function(e,t,r,n){var o,a=arguments.length,i=a<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(i=(a<3?o(i):a>3?o(t,r,i):o(t,r))||i);return a>3&&i&&Object.defineProperty(t,r,i),i},o=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.URLValidator=void 0;const a=r(772),i=r(273),s=r(787);let c=class extends i.PatternValidator{constructor(e=a.DEFAULT_ERROR_MESSAGES.URL){super(e)}hasErrors(e,t){return super.hasErrors(e,a.DEFAULT_PATTERNS.URL,t)}};t.URLValidator=c,t.URLValidator=c=n([(0,s.validator)(a.ValidationKeys.URL),o("design:paramtypes",[String])],c)},116:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Validator=void 0;const n=r(772),o=r(593),a=r(32);t.Validator=class{constructor(e=n.DEFAULT_ERROR_MESSAGES.DEFAULT,...t){this.message=e,t.length&&(this.acceptedTypes=t),this.acceptedTypes&&(this.hasErrors=this.checkTypeAndHasErrors(this.hasErrors.bind(this)))}getMessage(e,...t){return(0,o.sf)(e,...t)}checkTypeAndHasErrors(e){return function(t,...r){return void 0!==t&&this.acceptedTypes?(0,a.checkTypes)(t,this.acceptedTypes)?e(t,...r):this.getMessage(n.DEFAULT_ERROR_MESSAGES.TYPE,this.acceptedTypes.join(", "),typeof t):e(t,...r)}.bind(this)}}},436:(e,t)=>{"use strict";function r(e){return e.constructor&&e.hasErrors}Object.defineProperty(t,"__esModule",{value:!0}),t.ValidatorRegistry=void 0,t.isValidator=r,t.ValidatorRegistry=class{constructor(...e){this.cache={},this.customKeyCache={},this.register(...e)}getCustomKeys(){return Object.assign({},this.customKeyCache)}getKeys(){return Object.keys(this.cache)}get(e){if(!(e in this.cache))return;const t=this.cache[e];if(r(t))return t;const n=new(t.default||t);return this.cache[e]=n,n}register(...e){e.forEach((e=>{if(r(e)){if(e.validationKey in this.cache)return;this.cache[e.validationKey]=e}else{const{validationKey:t,validator:r,save:n}=e;if(t in this.cache)return;if(this.cache[t]=r,!n)return;const o={};o[t.toUpperCase()]=t,this.customKeyCache=Object.assign({},this.customKeyCache,o)}}))}}},772:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_PATTERNS=t.DEFAULT_ERROR_MESSAGES=t.DAYS_OF_WEEK_NAMES=t.MONTH_NAMES=t.ValidationKeys=void 0,t.ValidationKeys={REFLECT:"model.validation.",VALIDATOR:"validator",REQUIRED:"required",MIN:"min",MAX:"max",STEP:"step",MIN_LENGTH:"minlength",MAX_LENGTH:"maxlength",PATTERN:"pattern",EMAIL:"email",URL:"url",DATE:"date",TYPE:"type",PASSWORD:"password",LIST:"list"},t.MONTH_NAMES=["January","February","March","April","May","June","July","August","September","October","November","December"],t.DAYS_OF_WEEK_NAMES=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],t.DEFAULT_ERROR_MESSAGES={REQUIRED:"This field is required",MIN:"The minimum value is {0}",MAX:"The maximum value is {0}",MIN_LENGTH:"The minimum length is {0}",MAX_LENGTH:"The maximum length is {0}",PATTERN:"The value does not match the pattern",EMAIL:"The value is not a valid email",URL:"The value is not a valid URL",TYPE:"Invalid type. Expected {0}, received {1}",STEP:"Invalid value. Not a step of {0}",DATE:"Invalid value. not a valid Date",DEFAULT:"There is an Error",PASSWORD:"Must be at least 8 characters and contain one of number, lower and upper case letters, and special character (@$!%*?&_-.,)",LIST:"Invalid list of {0}",LIST_INSIDE:"Elements of list are invalid: {0}",MODEL_NOT_FOUND:"No model registered under {0}"},t.DEFAULT_PATTERNS={EMAIL:/[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-zA-Z0-9](?:[a-z0-9-]*[a-zA-Z0-9])?\.)+[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?/,URL:/^(?:(?:(?:https?|ftp):)?\/\/)(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u00a1-\uffff][a-z0-9\u00a1-\uffff_-]{0,62})?[a-z0-9\u00a1-\uffff]\.)+(?:[a-z\u00a1-\uffff]{2,}\.?))(?::\d{2,5})?(?:[/?#]\S*)?$/i,PASSWORD:{CHAR8_ONE_OF_EACH:/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?=.*[@$!%*?&_\-.,])[A-Za-z\d@$!%*?&_\-.,]{8,}$/g}}},787:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validator=function(...e){return(0,i.apply)((t=>(e.forEach((e=>{n.Validation.register({validator:t,validationKey:e,save:!0})})),t)),(0,i.metadata)((0,a.getValidationKey)(o.ValidationKeys.VALIDATOR),e))};const n=r(770),o=r(772),a=r(844),i=r(32)},493:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.Validators=void 0;const a=r(395),i=r(375),s=r(354),c=r(553),u=r(964),l=r(273),d=r(889),f=r(519),p=r(909),y=r(169),h=r(812),g=r(335),v=r(407);o(r(772),t),o(r(395),t),o(r(787),t),o(r(335),t),o(r(407),t),o(r(169),t),o(r(909),t),o(r(519),t),o(r(889),t),o(r(354),t),o(r(273),t),o(r(812),t),o(r(553),t),o(r(168),t),o(r(375),t),o(r(964),t),o(r(116),t),o(r(436),t),t.Validators={EmailValidator:g.EmailValidator,RequiredValidator:h.RequiredValidator,MaxLengthValidator:y.MaxLengthValidator,MaxValidator:p.MaxValidator,MinLengthValidator:f.MinLengthValidator,MinValidator:d.MinValidator,PatternValidator:l.PatternValidator,URLValidator:u.URLValidator,StepValidator:c.StepValidator,DateValidator:a.DateValidator,TypeValidator:i.TypeValidator,PasswordValidator:s.PasswordValidator,ListValidator:v.ListValidator}},168:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},475:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.required=function(e=a.DEFAULT_ERROR_MESSAGES.REQUIRED){return(0,l.metadata)((0,u.getValidationKey)(a.ValidationKeys.REQUIRED),{message:e})},t.min=function(e,t=a.DEFAULT_ERROR_MESSAGES.MIN){return(0,l.metadata)((0,u.getValidationKey)(a.ValidationKeys.MIN),{value:e,message:t,types:[Number.name,Date.name]})},t.max=function(e,t=a.DEFAULT_ERROR_MESSAGES.MAX){return(0,l.metadata)((0,u.getValidationKey)(a.ValidationKeys.MAX),{value:e,message:t,types:[Number.name,Date.name]})},t.step=function(e,t=a.DEFAULT_ERROR_MESSAGES.STEP){return(0,l.metadata)((0,u.getValidationKey)(a.ValidationKeys.STEP),{value:e,message:t,types:[Number.name]})},t.minlength=function(e,t=a.DEFAULT_ERROR_MESSAGES.MIN_LENGTH){return(0,l.metadata)((0,u.getValidationKey)(a.ValidationKeys.MIN_LENGTH),{value:e,message:t,types:[String.name,Array.name,Set.name]})},t.maxlength=function(e,t=a.DEFAULT_ERROR_MESSAGES.MAX_LENGTH){return(0,l.metadata)((0,u.getValidationKey)(a.ValidationKeys.MAX_LENGTH),{value:e,message:t,types:[String.name,Array.name,Set.name]})},t.pattern=function(e,t=a.DEFAULT_ERROR_MESSAGES.PATTERN){return(0,l.metadata)((0,u.getValidationKey)(a.ValidationKeys.PATTERN),{value:"string"==typeof e?e:e.toString(),message:t,types:[String.name]})},t.email=function(e=a.DEFAULT_ERROR_MESSAGES.EMAIL){return(0,l.metadata)((0,u.getValidationKey)(a.ValidationKeys.EMAIL),{message:e,types:[String.name]})},t.url=function(e=a.DEFAULT_ERROR_MESSAGES.URL){return(0,l.metadata)((0,u.getValidationKey)(a.ValidationKeys.URL),{message:e,types:[String.name]})},t.type=d,t.date=function(e="dd/MM/yyyy",t=a.DEFAULT_ERROR_MESSAGES.DATE){return(r,n)=>{Reflect.defineMetadata((0,u.getValidationKey)(a.ValidationKeys.DATE),{format:e,message:t,types:[Date.name]},r,n);const o=new WeakMap;Object.defineProperty(r,n,{configurable:!1,set(t){const r=Object.getOwnPropertyDescriptor(this,n);r&&!r.configurable||Object.defineProperty(this,n,{enumerable:!0,configurable:!1,get:()=>o.get(this),set:t=>{let r;try{r=(0,c.parseDate)(e,t),o.set(this,r)}catch(e){console.error((0,i.sf)("Failed to parse date: {0}",e.message||e))}}}),this[n]=t},get(){console.log("here")}})}},t.password=function(e=a.DEFAULT_PATTERNS.PASSWORD.CHAR8_ONE_OF_EACH,t=a.DEFAULT_ERROR_MESSAGES.PASSWORD,r=s.PasswordValidator){return(n,i)=>{Reflect.defineMetadata((0,u.getValidationKey)(a.ValidationKeys.PASSWORD),{pattern:e,message:t,types:[String.name]},n,i),o.Validation.register({validator:r,validationKey:a.ValidationKeys.PASSWORD,save:!0})}},t.list=f,t.set=function(e,t=a.DEFAULT_ERROR_MESSAGES.LIST,r){return(n,o)=>{f(e,"Set",t,r)(n,o)}},r(630);const n=r(407),o=r(770),a=r(772),i=r(593),s=r(354),c=r(935),u=r(844),l=r(32);function d(e,t=a.DEFAULT_ERROR_MESSAGES.TYPE){return(0,l.metadata)((0,u.getValidationKey)(a.ValidationKeys.TYPE),{customTypes:e,message:t})}function f(e,t="Array",r=a.DEFAULT_ERROR_MESSAGES.LIST,i=n.ListValidator){return(n,s)=>{d(t)(n,s),Reflect.defineMetadata((0,u.getValidationKey)(a.ValidationKeys.LIST),{class:e.name,type:t,message:r},n,s),o.Validation.register({validator:i,validationKey:a.ValidationKeys.LIST,save:!0})}}},965:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),o(r(493),t),o(r(475),t),o(r(792),t),o(r(844),t),o(r(770),t)},792:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},844:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getValidationKey=function(e){return n.ValidationKeys.REFLECT+e};const n=r(772)},267:(e,t)=>{"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.ReflectionKeys=void 0,function(e){e.TYPE="design:type"}(r||(t.ReflectionKeys=r={}))},530:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.metadata=function(e,t){return(r,n,o)=>{o?Reflect.defineMetadata(e,t,o.value):n?Reflect.defineMetadata(e,t,r,n):Reflect.defineMetadata(e,t,r)}},t.apply=function(...e){return(t,r,n)=>{for(const o of e)t instanceof Function&&!n?o(t):o(t,r,n)}},r(630)},651:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isEqual=function e(t,r,...n){if(t===r)return!0;if(t instanceof Date&&r instanceof Date)return t.getTime()===r.getTime();if(!t||!r||"object"!=typeof t&&"object"!=typeof r)return t===r;if(null==t||null==r)return!1;if(typeof t!=typeof r)return!1;if(t.prototype!==r.prototype)return!1;const o=Object.keys(t).filter((e=>-1===n.indexOf(e)));return o.length===Object.keys(r).filter((e=>-1===n.indexOf(e))).length&&o.every((o=>-1!==n.indexOf(o)||e(t[o],r[o],...n)))}},32:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=void 0,o(r(267),t),o(r(530),t),o(r(651),t),o(r(199),t),o(r(115),t),t.VERSION="0.2.1"},199:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},115:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getPropertyDecorators=a,t.getTypeFromDecorator=function(e,t){const r=a(n.ReflectionKeys.TYPE,e,t,!1);if(!r||!r.decorators)return;const o=r.decorators.shift(),i=o.props?o.props.name:void 0;return"Function"!==i?i:void 0},t.getAllPropertyDecorators=function(e,...t){if(t&&t.length)return Object.getOwnPropertyNames(e).reduce(((r,n)=>(t.forEach(((t,o)=>{const i=a(t,e,n,0!==o);r||(r={}),function(e,t,r){r&&r.length&&(e[t]||(e[t]=[]),e[t].push(...r))}(r,n,i.decorators)})),r)),void 0)},t.getAllProperties=function(e,t=!0,r="Object"){const n=[];let o=e;const a=function(){if(!t)return;const e=Object.getPrototypeOf(o);return e&&e.constructor.name!==r?(o=e,o):void 0};do{Object.getOwnPropertyNames(o).forEach((function(e){-1===n.indexOf(e)&&n.push(e)}))}while(a());return n},t.getClassDecorators=function(e,t){return Reflect.getOwnMetadataKeys(t.constructor).filter((t=>t.toString().startsWith(e))).reduce(((r,n)=>{const o={key:n.substring(e.length),props:Reflect.getMetadata(n,t.constructor)};return r.concat(o)}),[])},t.checkType=i,t.checkTypes=s,t.evaluateDesignTypes=function(e,t){switch(typeof t){case"string":return i(e,t);case"object":return!Array.isArray(t)||s(e,t);case"function":return!t.name||"Object"===t.name||i(e,t.name);default:return!0}},r(630);const n=r(267),o=r(651);function a(e,t,r,i=!1,s=!0,c){const u=function(e,t,r,o=!1,a){const i=Reflect.getMetadataKeys(t,r).filter((t=>o?t.toString().startsWith(e):t===n.ReflectionKeys.TYPE||t.toString().startsWith(e))).reduce(((o,a)=>{const i={key:a!==n.ReflectionKeys.TYPE?a.substring(e.length):a,props:Reflect.getMetadata(a,t,r)};return o.concat(i)}),a||[]);return{prop:r.toString(),decorators:i}}(e,t,r,i,c);return s&&Object.getPrototypeOf(t)!==Object.prototype?a(e,Object.getPrototypeOf(t.constructor),r,!0,s,u.decorators):{prop:u.prop,decorators:function(e){const r={};return e.filter((e=>e.key in r?((0,o.isEqual)(e.props,r[e.key])||console.log(`Found a similar decorator for the ${e.key} property of a ${t.constructor.name} model but with different attributes. The original one will be kept`),!1):(r[e.key.toString()]=e.props,!0)))}(u.decorators)}}function i(e,t){return typeof e===t||e.constructor&&e.constructor.name.toLowerCase()===t.toLowerCase()}function s(e,t){return!t.every((t=>!i(e,t)))}},630:(e,t,r)=>{var n;!function(e){!function(){var t="object"==typeof globalThis?globalThis:"object"==typeof r.g?r.g:"object"==typeof self?self:"object"==typeof this?this:function(){try{return Function("return this;")()}catch(e){}}()||function(){try{return(0,eval)("(function() { return this; })()")}catch(e){}}(),n=o(e);function o(e,t){return function(r,n){Object.defineProperty(e,r,{configurable:!0,writable:!0,value:n}),t&&t(r,n)}}void 0!==t.Reflect&&(n=o(t.Reflect,n)),function(e,t){var r=Object.prototype.hasOwnProperty,n="function"==typeof Symbol,o=n&&void 0!==Symbol.toPrimitive?Symbol.toPrimitive:"@@toPrimitive",a=n&&void 0!==Symbol.iterator?Symbol.iterator:"@@iterator",i="function"==typeof Object.create,s={__proto__:[]}instanceof Array,c=!i&&!s,u={create:i?function(){return H(Object.create(null))}:s?function(){return H({__proto__:null})}:function(){return H({})},has:c?function(e,t){return r.call(e,t)}:function(e,t){return t in e},get:c?function(e,t){return r.call(e,t)?e[t]:void 0}:function(e,t){return e[t]}},l=Object.getPrototypeOf(Function),d="function"==typeof Map&&"function"==typeof Map.prototype.entries?Map:function(){var e={},t=[],r=function(){function e(e,t,r){this._index=0,this._keys=e,this._values=t,this._selector=r}return e.prototype["@@iterator"]=function(){return this},e.prototype[a]=function(){return this},e.prototype.next=function(){var e=this._index;if(e>=0&&e<this._keys.length){var r=this._selector(this._keys[e],this._values[e]);return e+1>=this._keys.length?(this._index=-1,this._keys=t,this._values=t):this._index++,{value:r,done:!1}}return{value:void 0,done:!0}},e.prototype.throw=function(e){throw this._index>=0&&(this._index=-1,this._keys=t,this._values=t),e},e.prototype.return=function(e){return this._index>=0&&(this._index=-1,this._keys=t,this._values=t),{value:e,done:!0}},e}();return function(){function t(){this._keys=[],this._values=[],this._cacheKey=e,this._cacheIndex=-2}return Object.defineProperty(t.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0}),t.prototype.has=function(e){return this._find(e,!1)>=0},t.prototype.get=function(e){var t=this._find(e,!1);return t>=0?this._values[t]:void 0},t.prototype.set=function(e,t){var r=this._find(e,!0);return this._values[r]=t,this},t.prototype.delete=function(t){var r=this._find(t,!1);if(r>=0){for(var n=this._keys.length,o=r+1;o<n;o++)this._keys[o-1]=this._keys[o],this._values[o-1]=this._values[o];return this._keys.length--,this._values.length--,K(t,this._cacheKey)&&(this._cacheKey=e,this._cacheIndex=-2),!0}return!1},t.prototype.clear=function(){this._keys.length=0,this._values.length=0,this._cacheKey=e,this._cacheIndex=-2},t.prototype.keys=function(){return new r(this._keys,this._values,n)},t.prototype.values=function(){return new r(this._keys,this._values,o)},t.prototype.entries=function(){return new r(this._keys,this._values,i)},t.prototype["@@iterator"]=function(){return this.entries()},t.prototype[a]=function(){return this.entries()},t.prototype._find=function(e,t){if(!K(this._cacheKey,e)){this._cacheIndex=-1;for(var r=0;r<this._keys.length;r++)if(K(this._keys[r],e)){this._cacheIndex=r;break}}return this._cacheIndex<0&&t&&(this._cacheIndex=this._keys.length,this._keys.push(e),this._values.push(void 0)),this._cacheIndex},t}();function n(e,t){return e}function o(e,t){return t}function i(e,t){return[e,t]}}(),f="function"==typeof Set&&"function"==typeof Set.prototype.entries?Set:function(){function e(){this._map=new d}return Object.defineProperty(e.prototype,"size",{get:function(){return this._map.size},enumerable:!0,configurable:!0}),e.prototype.has=function(e){return this._map.has(e)},e.prototype.add=function(e){return this._map.set(e,e),this},e.prototype.delete=function(e){return this._map.delete(e)},e.prototype.clear=function(){this._map.clear()},e.prototype.keys=function(){return this._map.keys()},e.prototype.values=function(){return this._map.keys()},e.prototype.entries=function(){return this._map.entries()},e.prototype["@@iterator"]=function(){return this.keys()},e.prototype[a]=function(){return this.keys()},e}(),p="function"==typeof WeakMap?WeakMap:function(){var e=u.create(),t=n();return function(){function e(){this._key=n()}return e.prototype.has=function(e){var t=o(e,!1);return void 0!==t&&u.has(t,this._key)},e.prototype.get=function(e){var t=o(e,!1);return void 0!==t?u.get(t,this._key):void 0},e.prototype.set=function(e,t){return o(e,!0)[this._key]=t,this},e.prototype.delete=function(e){var t=o(e,!1);return void 0!==t&&delete t[this._key]},e.prototype.clear=function(){this._key=n()},e}();function n(){var t;do{t="@@WeakMap@@"+i()}while(u.has(e,t));return e[t]=!0,t}function o(e,n){if(!r.call(e,t)){if(!n)return;Object.defineProperty(e,t,{value:u.create()})}return e[t]}function a(e,t){for(var r=0;r<t;++r)e[r]=255*Math.random()|0;return e}function i(){var e=function(e){if("function"==typeof Uint8Array){var t=new Uint8Array(e);return"undefined"!=typeof crypto?crypto.getRandomValues(t):"undefined"!=typeof msCrypto?msCrypto.getRandomValues(t):a(t,e),t}return a(new Array(e),e)}(16);e[6]=79&e[6]|64,e[8]=191&e[8]|128;for(var t="",r=0;r<16;++r){var n=e[r];4!==r&&6!==r&&8!==r||(t+="-"),n<16&&(t+="0"),t+=n.toString(16).toLowerCase()}return t}}(),y=n?Symbol.for("@reflect-metadata:registry"):void 0,h=function(){var e;return!S(y)&&P(t.Reflect)&&Object.isExtensible(t.Reflect)&&(e=t.Reflect[y]),S(e)&&(e=function(){var e,r,n,o;S(y)||void 0===t.Reflect||y in t.Reflect||"function"!=typeof t.Reflect.defineMetadata||(e=function(e){var t=e.defineMetadata,r=e.hasOwnMetadata,n=e.getOwnMetadata,o=e.getOwnMetadataKeys,a=e.deleteMetadata,i=new p;return{isProviderFor:function(e,t){var r=i.get(e);return!(S(r)||!r.has(t))||!!o(e,t).length&&(S(r)&&(r=new f,i.set(e,r)),r.add(t),!0)},OrdinaryDefineOwnMetadata:t,OrdinaryHasOwnMetadata:r,OrdinaryGetOwnMetadata:n,OrdinaryOwnMetadataKeys:o,OrdinaryDeleteMetadata:a}}(t.Reflect));var a=new p,i={registerProvider:s,getProvider:u,setProvider:h};return i;function s(t){if(!Object.isExtensible(i))throw new Error("Cannot add provider to a frozen registry.");switch(!0){case e===t:break;case S(r):r=t;break;case r===t:break;case S(n):n=t;break;case n===t:break;default:void 0===o&&(o=new f),o.add(t)}}function c(t,a){if(!S(r)){if(r.isProviderFor(t,a))return r;if(!S(n)){if(n.isProviderFor(t,a))return r;if(!S(o))for(var i=x(o);;){var s=k(i);if(!s)return;var c=F(s);if(c.isProviderFor(t,a))return I(i),c}}}if(!S(e)&&e.isProviderFor(t,a))return e}function u(e,t){var r,n=a.get(e);return S(n)||(r=n.get(t)),S(r)?(S(r=c(e,t))||(S(n)&&(n=new d,a.set(e,n)),n.set(t,r)),r):r}function l(e){if(S(e))throw new TypeError;return r===e||n===e||!S(o)&&o.has(e)}function h(e,t,r){if(!l(r))throw new Error("Metadata provider not registered.");var n=u(e,t);if(n!==r){if(!S(n))return!1;var o=a.get(e);S(o)&&(o=new d,a.set(e,o)),o.set(t,r)}return!0}}()),!S(y)&&P(t.Reflect)&&Object.isExtensible(t.Reflect)&&Object.defineProperty(t.Reflect,y,{enumerable:!1,configurable:!1,writable:!1,value:e}),e}(),g=function(e){var t=new p,r={isProviderFor:function(e,r){var n=t.get(e);return!S(n)&&n.has(r)},OrdinaryDefineOwnMetadata:function(e,t,r,o){n(r,o,!0).set(e,t)},OrdinaryHasOwnMetadata:function(e,t,r){var o=n(t,r,!1);return!S(o)&&A(o.has(e))},OrdinaryGetOwnMetadata:function(e,t,r){var o=n(t,r,!1);if(!S(o))return o.get(e)},OrdinaryOwnMetadataKeys:function(e,t){var r=[],o=n(e,t,!1);if(S(o))return r;for(var a=x(o.keys()),i=0;;){var s=k(a);if(!s)return r.length=i,r;var c=F(s);try{r[i]=c}catch(e){try{I(a)}finally{throw e}}i++}},OrdinaryDeleteMetadata:function(e,r,o){var a=n(r,o,!1);if(S(a))return!1;if(!a.delete(e))return!1;if(0===a.size){var i=t.get(r);S(i)||(i.delete(o),0===i.size&&t.delete(i))}return!0}};return h.registerProvider(r),r;function n(n,o,a){var i=t.get(n),s=!1;if(S(i)){if(!a)return;i=new d,t.set(n,i),s=!0}var c=i.get(o);if(S(c)){if(!a)return;if(c=new d,i.set(o,c),!e.setProvider(n,o,r))throw i.delete(o),s&&t.delete(n),new Error("Wrong provider for target.")}return c}}(h);function v(e,t,r){if(_(e,t,r))return!0;var n=U(t);return!w(n)&&v(e,n,r)}function _(e,t,r){var n=G(t,r,!1);return!S(n)&&A(n.OrdinaryHasOwnMetadata(e,t,r))}function E(e,t,r){if(_(e,t,r))return m(e,t,r);var n=U(t);return w(n)?void 0:E(e,n,r)}function m(e,t,r){var n=G(t,r,!1);if(!S(n))return n.OrdinaryGetOwnMetadata(e,t,r)}function O(e,t,r,n){G(r,n,!0).OrdinaryDefineOwnMetadata(e,t,r,n)}function M(e,t){var r=b(e,t),n=U(e);if(null===n)return r;var o=M(n,t);if(o.length<=0)return r;if(r.length<=0)return o;for(var a=new f,i=[],s=0,c=r;s<c.length;s++){var u=c[s];a.has(u)||(a.add(u),i.push(u))}for(var l=0,d=o;l<d.length;l++)u=d[l],a.has(u)||(a.add(u),i.push(u));return i}function b(e,t){var r=G(e,t,!1);return r?r.OrdinaryOwnMetadataKeys(e,t):[]}function R(e){if(null===e)return 1;switch(typeof e){case"undefined":return 0;case"boolean":return 2;case"string":return 3;case"symbol":return 4;case"number":return 5;case"object":return null===e?1:6;default:return 6}}function S(e){return void 0===e}function w(e){return null===e}function P(e){return"object"==typeof e?null!==e:"function"==typeof e}function T(e,t){switch(R(e)){case 0:case 1:case 2:case 3:case 4:case 5:return e}var r=3===t?"string":5===t?"number":"default",n=N(e,o);if(void 0!==n){var a=n.call(e,r);if(P(a))throw new TypeError;return a}return function(e,t){if("string"===t){var r=e.toString;if(D(r)&&!P(o=r.call(e)))return o;if(D(n=e.valueOf)&&!P(o=n.call(e)))return o}else{var n;if(D(n=e.valueOf)&&!P(o=n.call(e)))return o;var o,a=e.toString;if(D(a)&&!P(o=a.call(e)))return o}throw new TypeError}(e,"default"===r?"number":r)}function A(e){return!!e}function j(e){var t=T(e,3);return"symbol"==typeof t?t:function(e){return""+e}(t)}function V(e){return Array.isArray?Array.isArray(e):e instanceof Object?e instanceof Array:"[object Array]"===Object.prototype.toString.call(e)}function D(e){return"function"==typeof e}function L(e){return"function"==typeof e}function K(e,t){return e===t||e!=e&&t!=t}function N(e,t){var r=e[t];if(null!=r){if(!D(r))throw new TypeError;return r}}function x(e){var t=N(e,a);if(!D(t))throw new TypeError;var r=t.call(e);if(!P(r))throw new TypeError;return r}function F(e){return e.value}function k(e){var t=e.next();return!t.done&&t}function I(e){var t=e.return;t&&t.call(e)}function U(e){var t=Object.getPrototypeOf(e);if("function"!=typeof e||e===l)return t;if(t!==l)return t;var r=e.prototype,n=r&&Object.getPrototypeOf(r);if(null==n||n===Object.prototype)return t;var o=n.constructor;return"function"!=typeof o||o===e?t:o}function G(e,t,r){var n=h.getProvider(e,t);if(!S(n))return n;if(r){if(h.setProvider(e,t,g))return g;throw new Error("Illegal state.")}}function H(e){return e.__=void 0,delete e.__,e}e("decorate",(function(e,t,r,n){if(S(r)){if(!V(e))throw new TypeError;if(!L(t))throw new TypeError;return function(e,t){for(var r=e.length-1;r>=0;--r){var n=(0,e[r])(t);if(!S(n)&&!w(n)){if(!L(n))throw new TypeError;t=n}}return t}(e,t)}if(!V(e))throw new TypeError;if(!P(t))throw new TypeError;if(!P(n)&&!S(n)&&!w(n))throw new TypeError;return w(n)&&(n=void 0),function(e,t,r,n){for(var o=e.length-1;o>=0;--o){var a=(0,e[o])(t,r,n);if(!S(a)&&!w(a)){if(!P(a))throw new TypeError;n=a}}return n}(e,t,r=j(r),n)})),e("metadata",(function(e,t){return function(r,n){if(!P(r))throw new TypeError;if(!S(n)&&!function(e){switch(R(e)){case 3:case 4:return!0;default:return!1}}(n))throw new TypeError;O(e,t,r,n)}})),e("defineMetadata",(function(e,t,r,n){if(!P(r))throw new TypeError;return S(n)||(n=j(n)),O(e,t,r,n)})),e("hasMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),v(e,t,r)})),e("hasOwnMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),_(e,t,r)})),e("getMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),E(e,t,r)})),e("getOwnMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),m(e,t,r)})),e("getMetadataKeys",(function(e,t){if(!P(e))throw new TypeError;return S(t)||(t=j(t)),M(e,t)})),e("getOwnMetadataKeys",(function(e,t){if(!P(e))throw new TypeError;return S(t)||(t=j(t)),b(e,t)})),e("deleteMetadata",(function(e,t,r){if(!P(t))throw new TypeError;if(S(r)||(r=j(r)),!P(t))throw new TypeError;S(r)||(r=j(r));var n=G(t,r,!1);return!S(n)&&n.OrdinaryDeleteMetadata(e,t,r)}))}(n,t),void 0===t.Reflect&&(t.Reflect=e)}()}(n||(n={}))}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var a=t[n]={exports:{}};return e[n].call(a.exports,a,a.exports,r),a.exports}return r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r(729)})()));
/*! For license information please see decorator-validation.bundle.min.esm.js.LICENSE.txt */
var e={729:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=void 0,a(r(935),t),a(r(839),t),a(r(965),t),a(r(847),t),t.VERSION="##VERSION##"},6:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Model=void 0,t.validate=h;const n=r(772),a=r(735),o=r(19),i=r(402),s=r(154),c=r(38),u=r(936),l=r(770),d=r(174),f=r(523),p=r(593),y=r(687);function h(e,...t){const r=[];for(const a in e)e.hasOwnProperty(a)&&-1===t.indexOf(a)&&r.push((0,d.getPropertyDecorators)(n.ValidationKeys.REFLECT,e,a));const a=r.reduce(((t,r)=>{const{prop:a,decorators:o}=r;if(!o||!o.length)return t;const c=o[0];o.find((e=>e.key===n.ValidationKeys.TYPE||!!e.props.types?.find((e=>e===c.props.name))))&&o.shift();let u=o.reduce(((t,r)=>{const n=l.Validation.get(r.key);if(!n)return t;const o=n.hasErrors(e[a.toString()],...r.key===s.ModelKeys.TYPE?[r.props]:Object.values(r.props));return o&&((t=t||{})[r.key]=o),t}),void 0);return u=u||Object.keys(e).filter((e=>!u||!u[e])).reduce(((t,r)=>{let a;const o=(0,d.getPropertyDecorators)(n.ValidationKeys.REFLECT,e,r).decorators,c=o.filter((e=>-1!==[s.ModelKeys.TYPE,n.ValidationKeys.TYPE].indexOf(e.key)));if(!c||!c.length)return t;const u=c.pop(),l=u.props.name?[u.props.name]:Array.isArray(u.props.customTypes)?u.props.customTypes:[u.props.customTypes],f=Object.values(i.ReservedModels).map((e=>e.toLowerCase()));return l.forEach((t=>{if(-1===f.indexOf(t.toLowerCase()))switch(t){case"Array":case"Set":if(o.length&&o.find((e=>e.key===n.ValidationKeys.LIST))){const o="Array"===t?e[r].find((e=>e.hasErrors())):e[r].values().find((e=>e.hasErrors()));o&&(a=(0,p.sf)(n.DEFAULT_ERROR_MESSAGES.LIST_INSIDE,o.toString()))}break;default:try{e[r]&&(a=e[r].hasErrors())}catch(e){console.warn((0,p.sf)("Model should be validatable but its not"))}}})),a&&((t=t||{})[r]=a),t}),void 0),u&&((t=t||{})[r.prop.toString()]=u),t}),void 0);return a?new o.ModelErrorDefinition(a):void 0}let g,v,_,E;class m{constructor(e){}hasErrors(...e){return h(this,...e)}equals(e,...t){return(0,y.isEqual)(this,e,...t)}serialize(){return m.serialize(this)}toString(){return this.constructor.name+": "+JSON.stringify(this,void 0,2)}toHash(){return m.getHashingFunction()(this).toString()}static deserialize(e){return m.getSerializer().deserialize(e)}static serialize(e){return m.getSerializer().serialize(e)}static hash(e){return m.getHashingFunction()(e)}static fromObject(e,t){return(0,c.constructFromObject)(e,t)}static fromModel(e,t){return(0,c.constructFromModel)(e,t)}static setBuilder(e){g=e}static getBuilder(){return g}static getRegistry(){return v||(v=new u.ModelRegistryManager),v}static setRegistry(e){v=e}static register(e,t){return m.getRegistry().register(e,t)}static get(e){return m.getRegistry().get(e)}static build(e={},t){return m.getRegistry().build(e,t)}static setSerializer(e){_=e}static getSerializer(){return _||(_=new a.JSONSerializer),_}static setHashingFunction(e){E=e}static getHashingFunction(){return E||(E=f.hashObj),E}}t.Model=m},19:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ModelErrorDefinition=void 0,t.ModelErrorDefinition=class{constructor(e){for(const t in e)e.hasOwnProperty(t)&&e[t]&&Object.defineProperty(this,t,{enumerable:!0,configurable:!1,value:e[t],writable:!1})}toString(){const e=this;return Object.keys(e).filter((t=>e.hasOwnProperty(t)&&"function"!=typeof e[t])).reduce(((t,r)=>{let n=Object.keys(e[r]).reduce(((t,n)=>(t?t+=`\n${e[r][n]}`:t=e[r][n],t)),void 0);return n&&(n=`${r} - ${n}`,t?t+=`\n${n}`:t=n),t}),"")}}},936:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ModelRegistryManager=void 0,t.bulkModelRegister=function(...e){e.forEach((e=>{const t=e.constructor?e.constructor:e;n.Model.register(t,e.name)}))};const n=r(6),a=r(154),o=r(174),i=r(593);t.ModelRegistryManager=class{constructor(e=a.ModelKeys.ANCHOR,t=o.isModel){this.cache={},this.testFunction=t,this.anchorKey=e}register(e,t){if("function"!=typeof e)throw new Error("Model registering failed. Missing Class name or constructor");t=t||e.name,this.cache[t]=e}get(e){try{return this.cache[e]}catch(e){return}}build(e={},t){if(!t&&!this.testFunction(e))throw new Error("Provided obj is not a Model object");const r=t||e[this.anchorKey].class;if(!(r in this.cache))throw new Error((0,i.sf)("Provided class {0} is not a registered Model object",r));return new this.cache[r](e)}}},402:(e,t)=>{var r,n;Object.defineProperty(t,"__esModule",{value:!0}),t.ReservedModels=t.Primitives=void 0,function(e){e.STRING="string",e.NUMBER="number",e.BOOLEAN="boolean",e.BIGINT="bigint"}(r||(t.Primitives=r={})),function(e){e.STRING="string",e.OBJECT="object",e.NUMBER="number",e.BOOLEAN="boolean",e.BIGINT="bigint",e.DATE="date"}(n||(t.ReservedModels=n={}))},38:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.constructFromObject=function(e,t){if(!t)return e;for(const r in t)t.hasOwnProperty(r)&&(e.hasOwnProperty(r)||e.prototype&&e.prototype.hasOwnProperty(r))&&(e[r]=t[r]||void 0);return e},t.constructFromModel=function(e,t){if(!t)return e;let r,u;for(const l in t)if(t.hasOwnProperty(l)&&(e.hasOwnProperty(l)||e.prototype&&e.prototype.hasOwnProperty(l))){if(e[l]=t[l]||void 0,"object"!=typeof e[l])continue;if((0,s.isModel)(e[l])){try{e[l]=n.Model.build(e[l])}catch(e){console.error(e)}continue}const d=(0,s.getPropertyDecorators)(a.ValidationKeys.REFLECT,e,l).decorators;if(r=d.filter((e=>-1!==[i.ModelKeys.TYPE,a.ValidationKeys.TYPE].indexOf(e.key))),!r||!r.length)throw new Error((0,c.sf)("failed to find decorators for property {0}",l));u=r.pop();const f=u.props.name?[u.props.name]:Array.isArray(u.props.customTypes)?u.props.customTypes:[u.props.customTypes],p=Object.values(o.ReservedModels).map((e=>e.toLowerCase()));f.forEach((t=>{if(-1===p.indexOf(t.toLowerCase()))try{switch(t){case"Array":case"Set":if(d.length){const r=d.find((e=>e.key===a.ValidationKeys.LIST));if(r&&("Array"===t&&(e[l]=e[l].map((e=>n.Model.build(e,r.props.class)))),"Set"===t)){const t=new Set;for(const a of e[l])t.add(n.Model.build(a,r.props.class));e[l]=t}}break;default:e[l]&&(e[l]=n.Model.build(e[l],t))}}catch(e){console.log(e)}}))}return e},t.construct=function(e,...t){const r=(...t)=>new e(...t);return r.prototype=e.prototype,r(...t)};const n=r(6),a=r(772),o=r(402),i=r(154),s=r(174),c=r(593)},893:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getModelKey=void 0,t.model=function(e,r){return i=>{const s=function(...s){const c=(0,n.construct)(i,...s),u=o.Model.getBuilder();u&&u(c,s.length?s[0]:void 0);const l=Object.assign({},{class:i.name});return Object.defineProperty(c,a.ModelKeys.ANCHOR,{writable:!1,enumerable:!1,configurable:!1,value:l}),Reflect.defineMetadata((0,t.getModelKey)(a.ModelKeys.MODEL),Object.assign(l,e||{}),c.constructor),r&&r(c,...s),c};return s.prototype=i.prototype,Object.defineProperty(s,"name",{writable:!1,enumerable:!0,configurable:!1,value:i.prototype.constructor.name}),o.Model.register(s),s}};const n=r(38),a=r(154),o=r(6);t.getModelKey=e=>a.ModelKeys.REFLECT+e},847:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),a(r(402),t),a(r(38),t),a(r(893),t),a(r(6),t),a(r(19),t),a(r(936),t),a(r(282),t)},282:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},501:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.metadata=function(e,t){return(r,n,a)=>{a?Reflect.defineMetadata(e,t,a.value):n?Reflect.defineMetadata(e,t,r,n):Reflect.defineMetadata(e,t,r)}},t.apply=function(...e){return(t,r,n)=>{for(const a of e)t instanceof Function&&!n?a(t):a(t,r,n)}},r(630)},839:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),a(r(501),t),a(r(174),t)},174:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getPropertyDecorators=i,t.getTypeFromDecorator=function(e,t){const r=i(n.ModelKeys.REFLECT,e,t,!1);if(!r||!r.decorators)return;const a=r.decorators.shift(),o=a.props?a.props.name:void 0;return"Function"!==o?o:void 0},t.getAllPropertyDecorators=function(e,...t){if(t&&t.length)return Object.getOwnPropertyNames(e).reduce(((r,n)=>(t.forEach(((t,a)=>{const o=i(t,e,n,0!==a);r||(r={}),function(e,t,r){r&&r.length&&(e[t]||(e[t]=[]),e[t].push(...r))}(r,n,o.decorators)})),r)),void 0)},t.getAllProperties=function(e,t=!0,r="Object"){const n=[];let a=e;const o=function(){if(!t)return;const e=Object.getPrototypeOf(a);return e&&e.constructor.name!==r?(a=e,a):void 0};do{Object.getOwnPropertyNames(a).forEach((function(e){-1===n.indexOf(e)&&n.push(e)}))}while(o());return n},t.getClassDecorators=s,t.checkType=c,t.checkTypes=u,t.evaluateDesignTypes=function(e,t){switch(typeof t){case"string":return c(e,t);case"object":return!Array.isArray(t)||u(e,t);case"function":return!t.name||"Object"===t.name||c(e,t.name);default:return!0}},t.isModel=function(e){return!!e[n.ModelKeys.ANCHOR]||!!s(n.ModelKeys.REFLECT,e).find((e=>e.key===n.ModelKeys.MODEL&&e.props&&e.props.class))};const n=r(154),a=r(593),o=r(687);function i(e,t,r,s=!1,c=!0,u){const l=function(e,t,r,a=!1,o){const i=Reflect.getMetadataKeys(t,r).filter((t=>a?t.toString().startsWith(e):t===n.ModelKeys.TYPE||t.toString().startsWith(e))).reduce(((a,o)=>{const i={key:o!==n.ModelKeys.TYPE?o.substring(e.length):o,props:Reflect.getMetadata(o,t,r)};return a.concat(i)}),o||[]);return{prop:r.toString(),decorators:i}}(e,t,r,s,u);return c&&Object.getPrototypeOf(t)!==Object.prototype?i(e,Object.getPrototypeOf(t.constructor),r,!0,c,l.decorators):{prop:l.prop,decorators:function(e){const r={};return e.filter((e=>e.key in r?((0,o.isEqual)(e.props,r[e.key])||console.log((0,a.sf)("Found a similar decorator for the {0} property of a {1} model but with different attributes. The original one will be kept",e.key,t.constructor.name)),!1):(r[e.key.toString()]=e.props,!0)))}(l.decorators)}}function s(e,t){return Reflect.getOwnMetadataKeys(t.constructor).filter((t=>t.toString().startsWith(e))).reduce(((r,n)=>{const a={key:n.substring(e.length),props:Reflect.getMetadata(n,t.constructor)};return r.concat(a)}),[])}function c(e,t){return typeof e===t||e.constructor&&e.constructor.name.toLowerCase()===t.toLowerCase()}function u(e,t){return!t.every((t=>!c(e,t)))}r(630)},154:(e,t)=>{var r;Object.defineProperty(t,"__esModule",{value:!0}),t.ModelKeys=void 0,function(e){e.REFLECT="model.definition.",e.TYPE="design:type",e.PARAMS="design:paramtypes",e.RETURN="design:returntype",e.MODEL="model",e.ANCHOR="__modelDefinition"}(r||(t.ModelKeys=r={}))},46:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.dateFromFormat=o,t.bindDateToString=i,t.isValidDate=s,t.twoDigitPad=c,t.formatDate=u,t.parseDate=function(e,t){let r;if(t){if(t instanceof Date)try{r=o(u(t,e),e)}catch(r){throw new Error((0,a.sf)("Could not convert date {0} to format: {1}",t.toString(),e))}else if("string"==typeof t)r=o(t,e);else if("number"==typeof t)r=o(u(new Date(t),e),e);else{if(!s(t))throw new Error(`Invalid value provided ${t}`);try{r=o(u(new Date(t),e),e)}catch(r){throw new Error((0,a.sf)("Could not convert date {0} to format: {1}",t,e))}}return i(r,e)}},r(630);const n=r(772),a=r(593);function o(e,t){let r=t;r.match(/hh/)?r=r.replace("hh","(?<hour>\\d{2})"):r.match(/h/)?r=r.replace("h","(?<hour>\\d{1,2})"):r.match(/HH/)?r=r.replace("HH","(?<hour>\\d{2})"):r.match(/H/)&&(r=r.replace("H","(?<hour>\\d{1,2})")),r.match(/mm/)?r=r.replace("mm","(?<minutes>\\d{2})"):r.match(/m/)&&(r=r.replace("m","(?<minutes>\\d{1,2})")),r.match(/ss/)?r=r.replace("ss","(?<seconds>\\d{2})"):r.match(/s/)&&(r=r.replace("s","(?<seconds>\\d{1,2})")),r.match(/dd/)?r=r.replace("dd","(?<day>\\d{2})"):r.match(/d/)&&(r=r.replace("d","(?<day>\\d{1,2})")),r.match(/EEEE/)?r=r.replace("EEEE","(?<dayofweek>\\w+)"):r.match(/EEEE/)&&(r=r.replace("EEE","(?<dayofweek>\\w+)")),r.match(/yyyy/)?r=r.replace("yyyy","(?<year>\\d{4})"):r.match(/yy/)&&(r=r.replace("yy","(?<year>\\d{2})")),r.match(/MMMM/)?r=r.replace("MMMM","(?<monthname>\\w+)"):r.match(/MMM/)&&(r=r.replace("MMM","(?<monthnamesmall>\\w+)")),r.match(/MM/)?r=r.replace("MM","(?<month>\\d{2})"):r.match(/M/)&&(r=r.replace("M","(?<month>\\d{1,2})")),r=r.replace("S","(?<milis>\\d{1,3})").replace("aaa","(?<ampm>\\w{2})");const a=new RegExp(r,"g").exec(e);if(!a||!a.groups)return new Date(e);const o=function(e){if(!e)return 0;const t=parseInt(e);return isNaN(t)?0:t},i=o(a.groups.year),s=o(a.groups.day),c=a.groups.ampm;let u=o(a.groups.hour);c&&(u="PM"===c?u+12:u);const l=o(a.groups.minutes),d=o(a.groups.seconds),f=o(a.groups.milis),p=a.groups.monthname,y=a.groups.monthnamesmall;let h=a.groups.month;if(p)h=n.MONTH_NAMES.indexOf(p);else if(y){const t=n.MONTH_NAMES.find((e=>e.toLowerCase().startsWith(y.toLowerCase())));if(!t)return new Date(e);h=n.MONTH_NAMES.indexOf(t)}else h=o(`${h}`);return new Date(i,h-1,s,u,l,d,f)}function i(e,t){if(!e)return;const r=()=>u(e,t);return Object.defineProperty(e,"toISOString",{enumerable:!1,configurable:!1,value:r}),Object.defineProperty(e,"toString",{enumerable:!1,configurable:!1,value:r}),e}function s(e){return e&&"[object Date]"===Object.prototype.toString.call(e)&&!isNaN(e)}function c(e){return e<10?"0"+e:e.toString()}function u(e,t="yyyy/MM/dd"){const r=e.getDate(),a=e.getMonth(),o=e.getFullYear(),i=e.getHours(),s=e.getMinutes(),u=e.getSeconds(),l=e.getMilliseconds(),d=i%12,f=c(d),p=c(i),y=c(s),h=c(u),g=i<12?"AM":"PM",v=n.DAYS_OF_WEEK_NAMES[e.getDay()],_=v.substr(0,3),E=c(r),m=a+1,O=c(m),M=n.MONTH_NAMES[a],b=M.substr(0,3),R=o+"",S=R.substr(2,2);return(t=t.replace("hh",f).replace("h",d.toString()).replace("HH",p).replace("H",i.toString()).replace("mm",y).replace("m",s.toString()).replace("ss",h).replace("s",u.toString()).replace("S",l.toString()).replace("dd",E).replace("d",r.toString()).replace("EEEE",v).replace("EEE",_).replace("yyyy",R).replace("yy",S).replace("aaa",g)).indexOf("MMM")>-1?t.replace("MMMM",M).replace("MMM",b):t.replace("MM",O).replace("M",m.toString())}},687:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.isEqual=function e(t,r,...n){if(t===r)return!0;if(t instanceof Date&&r instanceof Date)return t.getTime()===r.getTime();if(!t||!r||"object"!=typeof t&&"object"!=typeof r)return t===r;if(null==t||null==r)return!1;if(typeof t!=typeof r)return!1;if(t.prototype!==r.prototype)return!1;const a=Object.keys(t).filter((e=>-1===n.indexOf(e)));return a.length===Object.keys(r).filter((e=>-1===n.indexOf(e))).length&&a.every((a=>-1!==n.indexOf(a)||e(t[a],r[a],...n)))}},523:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.hashCode=a,t.hashSerialization=function(e){return a(n.Model.serialize(e))},t.hashObj=function(e){const t=function(e,t){const r=n(t);return"string"==typeof r?n((e||"")+n(t)):0|(e=((e=e||0)<<5)-e+r)},r=a,n=function(e){return void 0===e?"":-1!==["string","number","symbol"].indexOf(typeof e)?r(e.toString()):e instanceof Date?r(e.getTime()):Array.isArray(e)?e.reduce(t,void 0):Object.values(e).reduce(t,void 0)},o=Object.values(e).reduce(t,0);return"number"==typeof o?Math.abs(o):o};const n=r(6);function a(e){e=String(e);let t=0;for(let r=0;r<e.length;r++)t=(t<<5)-t+e.charCodeAt(r),t|=0;return t}},935:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),a(r(154),t),a(r(46),t),a(r(687),t),a(r(523),t),a(r(735),t),a(r(904),t),a(r(735),t),a(r(593),t)},904:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},735:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.JSONSerializer=void 0;const n=r(6),a=r(154);t.JSONSerializer=class{preSerialize(e){const t=Object.assign({},e);return t[a.ModelKeys.ANCHOR]=e[a.ModelKeys.ANCHOR],t}deserialize(e){const t=JSON.parse(e);return n.Model.build(t)}serialize(e){return JSON.stringify(this.preSerialize(e))}}},593:(e,t)=>{function r(e,...t){return e.replace(/{(\d+)}/g,(function(e,r){return void 0!==t[r]?t[r]:e}))}Object.defineProperty(t,"__esModule",{value:!0}),t.sf=void 0,t.stringFormat=r,t.sf=r},770:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Validation=void 0;const n=r(436);class a{static{this.actingValidatorRegistry=void 0}constructor(){}static setRegistry(e,t){t&&a.actingValidatorRegistry&&a.actingValidatorRegistry.getKeys().forEach((r=>{const n=e.get(r);n&&e.register(t(n))})),a.actingValidatorRegistry=e}static getRegistry(){return a.actingValidatorRegistry||(a.actingValidatorRegistry=new n.ValidatorRegistry),a.actingValidatorRegistry}static get(e){return a.getRegistry().get(e)}static register(...e){return a.getRegistry().register(...e)}}t.Validation=a},395:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.DateValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.DATE){super(e,Number.name,Date.name,String.name)}hasErrors(e,t,r){if(void 0!==e)return"string"==typeof e&&(e=new Date(e)),isNaN(e.getDate())?this.getMessage(r||this.message):void 0}};t.DateValidator=c,t.DateValidator=c=n([(0,s.validator)(i.ValidationKeys.DATE),a("design:paramtypes",[String])],c)},335:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.EmailValidator=void 0;const o=r(772),i=r(273),s=r(787);let c=class extends i.PatternValidator{constructor(e=o.DEFAULT_ERROR_MESSAGES.EMAIL){super(e)}hasErrors(e,t){return super.hasErrors(e,o.DEFAULT_PATTERNS.EMAIL,t)}};t.EmailValidator=c,t.EmailValidator=c=n([(0,s.validator)(o.ValidationKeys.EMAIL),a("design:paramtypes",[String])],c)},407:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.ListValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.LIST){super(e,Array.name,Set.name)}hasErrors(e,t,r){if(!e||(Array.isArray(e)?!e.length:!e.size))return;let n;for(let a=0;a<(Array.isArray(e)?e.length:e.size);a++)switch(n=e[a],typeof n){case"object":case"function":if(!n.constructor||n.constructor.name!==t)return this.getMessage(r||this.message,t);break;default:if(typeof n!==t)return this.getMessage(r||this.message,t)}}};t.ListValidator=c,t.ListValidator=c=n([(0,s.validator)(i.ValidationKeys.LIST),a("design:paramtypes",[String])],c)},169:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MaxLengthValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MAX_LENGTH){super(e,String.name,Array.name)}hasErrors(e,t,r){if(void 0!==e)return e.length>t?this.getMessage(r||this.message,t):void 0}};t.MaxLengthValidator=c,t.MaxLengthValidator=c=n([(0,s.validator)(i.ValidationKeys.MAX_LENGTH),a("design:paramtypes",[String])],c)},909:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MaxValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MAX){super(e,"number","Date","string")}hasErrors(e,t,r){if(void 0!==e){if(e instanceof Date&&!(t instanceof Date)&&(t=new Date(t),isNaN(t.getDate())))throw new Error("Invalid Max param defined");return e>t?this.getMessage(r||this.message,t):void 0}}};t.MaxValidator=c,t.MaxValidator=c=n([(0,s.validator)(i.ValidationKeys.MAX),a("design:paramtypes",[String])],c)},519:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MinLengthValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MIN_LENGTH){super(e,String.name,Array.name)}hasErrors(e,t,r){if(void 0!==e)return e.length<t?this.getMessage(r||this.message,t):void 0}};t.MinLengthValidator=c,t.MinLengthValidator=c=n([(0,s.validator)(i.ValidationKeys.MIN_LENGTH),a("design:paramtypes",[String])],c)},651:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MinValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MIN){super(e,"number","Date","string")}hasErrors(e,t,r){if(void 0!==e){if(e instanceof Date&&!(t instanceof Date)&&(t=new Date(t),isNaN(t.getDate())))throw new Error("Invalid Min param defined");return e<t?this.getMessage(r||this.message,t):void 0}}};t.MinValidator=c,t.MinValidator=c=n([(0,s.validator)(i.ValidationKeys.MIN),a("design:paramtypes",[String])],c)},354:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.PasswordValidator=void 0;const o=r(273),i=r(772),s=r(787);let c=class extends o.PatternValidator{constructor(e=i.DEFAULT_ERROR_MESSAGES.PASSWORD,t=i.DEFAULT_PATTERNS.PASSWORD.CHAR8_ONE_OF_EACH){super(e),this.pattern=t}hasErrors(e,t,r){return super.hasErrors(e,t||this.pattern,r||this.message)}};t.PasswordValidator=c,t.PasswordValidator=c=n([(0,s.validator)(i.ValidationKeys.PASSWORD),a("design:paramtypes",[Object,RegExp])],c)},273:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.PatternValidator=t.regexpParser=void 0;const o=r(116),i=r(772),s=r(787);t.regexpParser=new RegExp("^/(.+)/([gimus]*)$");let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.PATTERN){super(e,"string")}getPattern(e){if(!t.regexpParser.test(e))return new RegExp(e);const r=e.match(t.regexpParser);return new RegExp(r[1],r[2])}hasErrors(e,t,r){if(e){if(!t)throw new Error("Missing Pattern");return(t="string"==typeof t?this.getPattern(t):t).lastIndex=0,t.test(e)?void 0:this.getMessage(r||this.message)}}};t.PatternValidator=c,t.PatternValidator=c=n([(0,s.validator)(i.ValidationKeys.PATTERN),a("design:paramtypes",[String])],c)},812:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.RequiredValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.REQUIRED){super(e)}hasErrors(e,t){switch(typeof e){case"boolean":case"number":return void 0===e?this.getMessage(t||this.message):void 0;default:return e?void 0:this.getMessage(t||this.message)}}};t.RequiredValidator=c,t.RequiredValidator=c=n([(0,s.validator)(i.ValidationKeys.REQUIRED),a("design:paramtypes",[String])],c)},553:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.StepValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.STEP){super(e,"number","string")}hasErrors(e,t,r){if(void 0!==e)return Number(e)%Number(t)!=0?this.getMessage(r||this.message,t):void 0}};t.StepValidator=c,t.StepValidator=c=n([(0,s.validator)(i.ValidationKeys.STEP),a("design:paramtypes",[String])],c)},375:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.TypeValidator=void 0;const o=r(116),i=r(772),s=r(174),c=r(787),u=r(935),l=r(770);let d=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.TYPE){super(e)}hasErrors(e,t,r){if(void 0!==e)return(0,s.evaluateDesignTypes)(e,t)?void 0:this.getMessage(r||this.message,"string"==typeof t?t:Array.isArray(t)?t.join(", "):t.name,typeof e)}};t.TypeValidator=d,t.TypeValidator=d=n([(0,c.validator)(i.ValidationKeys.TYPE),a("design:paramtypes",[String])],d),l.Validation.register({validator:d,validationKey:u.ModelKeys.TYPE,save:!1})},964:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.URLValidator=void 0;const o=r(772),i=r(273),s=r(787);let c=class extends i.PatternValidator{constructor(e=o.DEFAULT_ERROR_MESSAGES.URL){super(e)}hasErrors(e,t){return super.hasErrors(e,o.DEFAULT_PATTERNS.URL,t)}};t.URLValidator=c,t.URLValidator=c=n([(0,s.validator)(o.ValidationKeys.URL),a("design:paramtypes",[String])],c)},116:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Validator=void 0;const n=r(772),a=r(593),o=r(174);t.Validator=class{constructor(e=n.DEFAULT_ERROR_MESSAGES.DEFAULT,...t){this.message=e,t.length&&(this.acceptedTypes=t),this.acceptedTypes&&(this.hasErrors=this.checkTypeAndHasErrors(this.hasErrors.bind(this)))}getMessage(e,...t){return(0,a.sf)(e,...t)}checkTypeAndHasErrors(e){return function(t,...r){return void 0!==t&&this.acceptedTypes?(0,o.checkTypes)(t,this.acceptedTypes)?e(t,...r):this.getMessage(n.DEFAULT_ERROR_MESSAGES.TYPE,this.acceptedTypes.join(", "),typeof t):e(t,...r)}.bind(this)}}},436:(e,t)=>{function r(e){return e.constructor&&e.hasErrors}Object.defineProperty(t,"__esModule",{value:!0}),t.ValidatorRegistry=void 0,t.isValidator=r,t.ValidatorRegistry=class{constructor(...e){this.cache={},this.customKeyCache={},this.register(...e)}getCustomKeys(){return Object.assign({},this.customKeyCache)}getKeys(){return Object.keys(this.cache)}get(e){if(!(e in this.cache))return;const t=this.cache[e];if(r(t))return t;const n=new(t.default||t);return this.cache[e]=n,n}register(...e){e.forEach((e=>{if(r(e)){if(e.validationKey in this.cache)return;this.cache[e.validationKey]=e}else{const{validationKey:t,validator:r,save:n}=e;if(t in this.cache)return;if(this.cache[t]=r,!n)return;const a={};a[t.toUpperCase()]=t,this.customKeyCache=Object.assign({},this.customKeyCache,a)}}))}}},772:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_PATTERNS=t.DEFAULT_ERROR_MESSAGES=t.DAYS_OF_WEEK_NAMES=t.MONTH_NAMES=t.ValidationKeys=void 0,t.ValidationKeys={REFLECT:"model.validation.",VALIDATOR:"validator",REQUIRED:"required",MIN:"min",MAX:"max",STEP:"step",MIN_LENGTH:"minlength",MAX_LENGTH:"maxlength",PATTERN:"pattern",EMAIL:"email",URL:"url",DATE:"date",TYPE:"type",PASSWORD:"password",LIST:"list"},t.MONTH_NAMES=["January","February","March","April","May","June","July","August","September","October","November","December"],t.DAYS_OF_WEEK_NAMES=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],t.DEFAULT_ERROR_MESSAGES={REQUIRED:"This field is required",MIN:"The minimum value is {0}",MAX:"The maximum value is {0}",MIN_LENGTH:"The minimum length is {0}",MAX_LENGTH:"The maximum length is {0}",PATTERN:"The value does not match the pattern",EMAIL:"The value is not a valid email",URL:"The value is not a valid URL",TYPE:"Invalid type. Expected {0}, received {1}",STEP:"Invalid value. Not a step of {0}",DATE:"Invalid value. not a valid Date",DEFAULT:"There is an Error",PASSWORD:"Must be at least 8 characters and contain one of number, lower and upper case letters, and special character (@$!%*?&_-.,)",LIST:"Invalid list of {0}",LIST_INSIDE:"Elements of list are invalid: {0}",MODEL_NOT_FOUND:"No model registered under {0}"},t.DEFAULT_PATTERNS={EMAIL:/[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-zA-Z0-9](?:[a-z0-9-]*[a-zA-Z0-9])?\.)+[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?/,URL:/^(?:(?:(?:https?|ftp):)?\/\/)(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u00a1-\uffff][a-z0-9\u00a1-\uffff_-]{0,62})?[a-z0-9\u00a1-\uffff]\.)+(?:[a-z\u00a1-\uffff]{2,}\.?))(?::\d{2,5})?(?:[/?#]\S*)?$/i,PASSWORD:{CHAR8_ONE_OF_EACH:/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?=.*[@$!%*?&_\-.,])[A-Za-z\d@$!%*?&_\-.,]{8,}$/g}}},787:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.validator=function(...e){return(0,a.apply)((t=>(e.forEach((e=>{n.Validation.register({validator:t,validationKey:e,save:!0})})),t)),(0,a.metadata)((0,i.getValidationKey)(o.ValidationKeys.VALIDATOR),e))};const n=r(770),a=r(839),o=r(772),i=r(844)},493:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.Validators=void 0;const o=r(395),i=r(375),s=r(354),c=r(553),u=r(964),l=r(273),d=r(651),f=r(519),p=r(909),y=r(169),h=r(812),g=r(335),v=r(407);a(r(772),t),a(r(395),t),a(r(787),t),a(r(335),t),a(r(407),t),a(r(169),t),a(r(909),t),a(r(519),t),a(r(651),t),a(r(354),t),a(r(273),t),a(r(812),t),a(r(553),t),a(r(168),t),a(r(375),t),a(r(964),t),a(r(116),t),a(r(436),t),t.Validators={EmailValidator:g.EmailValidator,RequiredValidator:h.RequiredValidator,MaxLengthValidator:y.MaxLengthValidator,MaxValidator:p.MaxValidator,MinLengthValidator:f.MinLengthValidator,MinValidator:d.MinValidator,PatternValidator:l.PatternValidator,URLValidator:u.URLValidator,StepValidator:c.StepValidator,DateValidator:o.DateValidator,TypeValidator:i.TypeValidator,PasswordValidator:s.PasswordValidator,ListValidator:v.ListValidator}},168:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},475:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.required=function(e=i.DEFAULT_ERROR_MESSAGES.REQUIRED){return(0,o.metadata)((0,l.getValidationKey)(i.ValidationKeys.REQUIRED),{message:e})},t.min=function(e,t=i.DEFAULT_ERROR_MESSAGES.MIN){return(0,o.metadata)((0,l.getValidationKey)(i.ValidationKeys.MIN),{value:e,message:t,types:[Number.name,Date.name]})},t.max=function(e,t=i.DEFAULT_ERROR_MESSAGES.MAX){return(0,o.metadata)((0,l.getValidationKey)(i.ValidationKeys.MAX),{value:e,message:t,types:[Number.name,Date.name]})},t.step=function(e,t=i.DEFAULT_ERROR_MESSAGES.STEP){return(0,o.metadata)((0,l.getValidationKey)(i.ValidationKeys.STEP),{value:e,message:t,types:[Number.name]})},t.minlength=function(e,t=i.DEFAULT_ERROR_MESSAGES.MIN_LENGTH){return(0,o.metadata)((0,l.getValidationKey)(i.ValidationKeys.MIN_LENGTH),{value:e,message:t,types:[String.name,Array.name,Set.name]})},t.maxlength=function(e,t=i.DEFAULT_ERROR_MESSAGES.MAX_LENGTH){return(0,o.metadata)((0,l.getValidationKey)(i.ValidationKeys.MAX_LENGTH),{value:e,message:t,types:[String.name,Array.name,Set.name]})},t.pattern=function(e,t=i.DEFAULT_ERROR_MESSAGES.PATTERN){return(0,o.metadata)((0,l.getValidationKey)(i.ValidationKeys.PATTERN),{value:"string"==typeof e?e:e.toString(),message:t,types:[String.name]})},t.email=function(e=i.DEFAULT_ERROR_MESSAGES.EMAIL){return(0,o.metadata)((0,l.getValidationKey)(i.ValidationKeys.EMAIL),{message:e,types:[String.name]})},t.url=function(e=i.DEFAULT_ERROR_MESSAGES.URL){return(0,o.metadata)((0,l.getValidationKey)(i.ValidationKeys.URL),{message:e,types:[String.name]})},t.type=d,t.date=function(e="dd/MM/yyyy",t=i.DEFAULT_ERROR_MESSAGES.DATE){return(r,n)=>{Reflect.defineMetadata((0,l.getValidationKey)(i.ValidationKeys.DATE),{format:e,message:t,types:[Date.name]},r,n);const a=new WeakMap;Object.defineProperty(r,n,{configurable:!1,set(t){const r=Object.getOwnPropertyDescriptor(this,n);r&&!r.configurable||Object.defineProperty(this,n,{enumerable:!0,configurable:!1,get:()=>a.get(this),set:t=>{let r;try{r=(0,u.parseDate)(e,t),a.set(this,r)}catch(e){console.error((0,s.sf)("Failed to parse date: {0}",e.message||e))}}}),this[n]=t},get(){console.log("here")}})}},t.password=function(e=i.DEFAULT_PATTERNS.PASSWORD.CHAR8_ONE_OF_EACH,t=i.DEFAULT_ERROR_MESSAGES.PASSWORD,r=c.PasswordValidator){return(n,o)=>{Reflect.defineMetadata((0,l.getValidationKey)(i.ValidationKeys.PASSWORD),{pattern:e,message:t,types:[String.name]},n,o),a.Validation.register({validator:r,validationKey:i.ValidationKeys.PASSWORD,save:!0})}},t.list=f,t.set=function(e,t=i.DEFAULT_ERROR_MESSAGES.LIST,r){return(n,a)=>{f(e,"Set",t,r)(n,a)}},r(630);const n=r(407),a=r(770),o=r(501),i=r(772),s=r(593),c=r(354),u=r(935),l=r(844);function d(e,t=i.DEFAULT_ERROR_MESSAGES.TYPE){return(0,o.metadata)((0,l.getValidationKey)(i.ValidationKeys.TYPE),{customTypes:e,message:t})}function f(e,t="Array",r=i.DEFAULT_ERROR_MESSAGES.LIST,o=n.ListValidator){return(n,s)=>{d(t)(n,s),Reflect.defineMetadata((0,l.getValidationKey)(i.ValidationKeys.LIST),{class:e.name,type:t,message:r},n,s),a.Validation.register({validator:o,validationKey:i.ValidationKeys.LIST,save:!0})}}},965:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),a(r(493),t),a(r(475),t),a(r(792),t),a(r(844),t),a(r(770),t)},792:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},844:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getValidationKey=function(e){return n.ValidationKeys.REFLECT+e};const n=r(772)},630:(e,t,r)=>{var n;!function(e){!function(){var t="object"==typeof globalThis?globalThis:"object"==typeof r.g?r.g:"object"==typeof self?self:"object"==typeof this?this:function(){try{return Function("return this;")()}catch(e){}}()||function(){try{return(0,eval)("(function() { return this; })()")}catch(e){}}(),n=a(e);function a(e,t){return function(r,n){Object.defineProperty(e,r,{configurable:!0,writable:!0,value:n}),t&&t(r,n)}}void 0!==t.Reflect&&(n=a(t.Reflect,n)),function(e,t){var r=Object.prototype.hasOwnProperty,n="function"==typeof Symbol,a=n&&void 0!==Symbol.toPrimitive?Symbol.toPrimitive:"@@toPrimitive",o=n&&void 0!==Symbol.iterator?Symbol.iterator:"@@iterator",i="function"==typeof Object.create,s={__proto__:[]}instanceof Array,c=!i&&!s,u={create:i?function(){return H(Object.create(null))}:s?function(){return H({__proto__:null})}:function(){return H({})},has:c?function(e,t){return r.call(e,t)}:function(e,t){return t in e},get:c?function(e,t){return r.call(e,t)?e[t]:void 0}:function(e,t){return e[t]}},l=Object.getPrototypeOf(Function),d="function"==typeof Map&&"function"==typeof Map.prototype.entries?Map:function(){var e={},t=[],r=function(){function e(e,t,r){this._index=0,this._keys=e,this._values=t,this._selector=r}return e.prototype["@@iterator"]=function(){return this},e.prototype[o]=function(){return this},e.prototype.next=function(){var e=this._index;if(e>=0&&e<this._keys.length){var r=this._selector(this._keys[e],this._values[e]);return e+1>=this._keys.length?(this._index=-1,this._keys=t,this._values=t):this._index++,{value:r,done:!1}}return{value:void 0,done:!0}},e.prototype.throw=function(e){throw this._index>=0&&(this._index=-1,this._keys=t,this._values=t),e},e.prototype.return=function(e){return this._index>=0&&(this._index=-1,this._keys=t,this._values=t),{value:e,done:!0}},e}();return function(){function t(){this._keys=[],this._values=[],this._cacheKey=e,this._cacheIndex=-2}return Object.defineProperty(t.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0}),t.prototype.has=function(e){return this._find(e,!1)>=0},t.prototype.get=function(e){var t=this._find(e,!1);return t>=0?this._values[t]:void 0},t.prototype.set=function(e,t){var r=this._find(e,!0);return this._values[r]=t,this},t.prototype.delete=function(t){var r=this._find(t,!1);if(r>=0){for(var n=this._keys.length,a=r+1;a<n;a++)this._keys[a-1]=this._keys[a],this._values[a-1]=this._values[a];return this._keys.length--,this._values.length--,K(t,this._cacheKey)&&(this._cacheKey=e,this._cacheIndex=-2),!0}return!1},t.prototype.clear=function(){this._keys.length=0,this._values.length=0,this._cacheKey=e,this._cacheIndex=-2},t.prototype.keys=function(){return new r(this._keys,this._values,n)},t.prototype.values=function(){return new r(this._keys,this._values,a)},t.prototype.entries=function(){return new r(this._keys,this._values,i)},t.prototype["@@iterator"]=function(){return this.entries()},t.prototype[o]=function(){return this.entries()},t.prototype._find=function(e,t){if(!K(this._cacheKey,e)){this._cacheIndex=-1;for(var r=0;r<this._keys.length;r++)if(K(this._keys[r],e)){this._cacheIndex=r;break}}return this._cacheIndex<0&&t&&(this._cacheIndex=this._keys.length,this._keys.push(e),this._values.push(void 0)),this._cacheIndex},t}();function n(e,t){return e}function a(e,t){return t}function i(e,t){return[e,t]}}(),f="function"==typeof Set&&"function"==typeof Set.prototype.entries?Set:function(){function e(){this._map=new d}return Object.defineProperty(e.prototype,"size",{get:function(){return this._map.size},enumerable:!0,configurable:!0}),e.prototype.has=function(e){return this._map.has(e)},e.prototype.add=function(e){return this._map.set(e,e),this},e.prototype.delete=function(e){return this._map.delete(e)},e.prototype.clear=function(){this._map.clear()},e.prototype.keys=function(){return this._map.keys()},e.prototype.values=function(){return this._map.keys()},e.prototype.entries=function(){return this._map.entries()},e.prototype["@@iterator"]=function(){return this.keys()},e.prototype[o]=function(){return this.keys()},e}(),p="function"==typeof WeakMap?WeakMap:function(){var e=u.create(),t=n();return function(){function e(){this._key=n()}return e.prototype.has=function(e){var t=a(e,!1);return void 0!==t&&u.has(t,this._key)},e.prototype.get=function(e){var t=a(e,!1);return void 0!==t?u.get(t,this._key):void 0},e.prototype.set=function(e,t){return a(e,!0)[this._key]=t,this},e.prototype.delete=function(e){var t=a(e,!1);return void 0!==t&&delete t[this._key]},e.prototype.clear=function(){this._key=n()},e}();function n(){var t;do{t="@@WeakMap@@"+i()}while(u.has(e,t));return e[t]=!0,t}function a(e,n){if(!r.call(e,t)){if(!n)return;Object.defineProperty(e,t,{value:u.create()})}return e[t]}function o(e,t){for(var r=0;r<t;++r)e[r]=255*Math.random()|0;return e}function i(){var e=function(e){if("function"==typeof Uint8Array){var t=new Uint8Array(e);return"undefined"!=typeof crypto?crypto.getRandomValues(t):"undefined"!=typeof msCrypto?msCrypto.getRandomValues(t):o(t,e),t}return o(new Array(e),e)}(16);e[6]=79&e[6]|64,e[8]=191&e[8]|128;for(var t="",r=0;r<16;++r){var n=e[r];4!==r&&6!==r&&8!==r||(t+="-"),n<16&&(t+="0"),t+=n.toString(16).toLowerCase()}return t}}(),y=n?Symbol.for("@reflect-metadata:registry"):void 0,h=function(){var e;return!S(y)&&P(t.Reflect)&&Object.isExtensible(t.Reflect)&&(e=t.Reflect[y]),S(e)&&(e=function(){var e,r,n,a;S(y)||void 0===t.Reflect||y in t.Reflect||"function"!=typeof t.Reflect.defineMetadata||(e=function(e){var t=e.defineMetadata,r=e.hasOwnMetadata,n=e.getOwnMetadata,a=e.getOwnMetadataKeys,o=e.deleteMetadata,i=new p;return{isProviderFor:function(e,t){var r=i.get(e);return!(S(r)||!r.has(t))||!!a(e,t).length&&(S(r)&&(r=new f,i.set(e,r)),r.add(t),!0)},OrdinaryDefineOwnMetadata:t,OrdinaryHasOwnMetadata:r,OrdinaryGetOwnMetadata:n,OrdinaryOwnMetadataKeys:a,OrdinaryDeleteMetadata:o}}(t.Reflect));var o=new p,i={registerProvider:s,getProvider:u,setProvider:h};return i;function s(t){if(!Object.isExtensible(i))throw new Error("Cannot add provider to a frozen registry.");switch(!0){case e===t:break;case S(r):r=t;break;case r===t:break;case S(n):n=t;break;case n===t:break;default:void 0===a&&(a=new f),a.add(t)}}function c(t,o){if(!S(r)){if(r.isProviderFor(t,o))return r;if(!S(n)){if(n.isProviderFor(t,o))return r;if(!S(a))for(var i=x(a);;){var s=k(i);if(!s)return;var c=F(s);if(c.isProviderFor(t,o))return I(i),c}}}if(!S(e)&&e.isProviderFor(t,o))return e}function u(e,t){var r,n=o.get(e);return S(n)||(r=n.get(t)),S(r)?(S(r=c(e,t))||(S(n)&&(n=new d,o.set(e,n)),n.set(t,r)),r):r}function l(e){if(S(e))throw new TypeError;return r===e||n===e||!S(a)&&a.has(e)}function h(e,t,r){if(!l(r))throw new Error("Metadata provider not registered.");var n=u(e,t);if(n!==r){if(!S(n))return!1;var a=o.get(e);S(a)&&(a=new d,o.set(e,a)),a.set(t,r)}return!0}}()),!S(y)&&P(t.Reflect)&&Object.isExtensible(t.Reflect)&&Object.defineProperty(t.Reflect,y,{enumerable:!1,configurable:!1,writable:!1,value:e}),e}(),g=function(e){var t=new p,r={isProviderFor:function(e,r){var n=t.get(e);return!S(n)&&n.has(r)},OrdinaryDefineOwnMetadata:function(e,t,r,a){n(r,a,!0).set(e,t)},OrdinaryHasOwnMetadata:function(e,t,r){var a=n(t,r,!1);return!S(a)&&A(a.has(e))},OrdinaryGetOwnMetadata:function(e,t,r){var a=n(t,r,!1);if(!S(a))return a.get(e)},OrdinaryOwnMetadataKeys:function(e,t){var r=[],a=n(e,t,!1);if(S(a))return r;for(var o=x(a.keys()),i=0;;){var s=k(o);if(!s)return r.length=i,r;var c=F(s);try{r[i]=c}catch(e){try{I(o)}finally{throw e}}i++}},OrdinaryDeleteMetadata:function(e,r,a){var o=n(r,a,!1);if(S(o))return!1;if(!o.delete(e))return!1;if(0===o.size){var i=t.get(r);S(i)||(i.delete(a),0===i.size&&t.delete(i))}return!0}};return h.registerProvider(r),r;function n(n,a,o){var i=t.get(n),s=!1;if(S(i)){if(!o)return;i=new d,t.set(n,i),s=!0}var c=i.get(a);if(S(c)){if(!o)return;if(c=new d,i.set(a,c),!e.setProvider(n,a,r))throw i.delete(a),s&&t.delete(n),new Error("Wrong provider for target.")}return c}}(h);function v(e,t,r){if(_(e,t,r))return!0;var n=U(t);return!w(n)&&v(e,n,r)}function _(e,t,r){var n=G(t,r,!1);return!S(n)&&A(n.OrdinaryHasOwnMetadata(e,t,r))}function E(e,t,r){if(_(e,t,r))return m(e,t,r);var n=U(t);return w(n)?void 0:E(e,n,r)}function m(e,t,r){var n=G(t,r,!1);if(!S(n))return n.OrdinaryGetOwnMetadata(e,t,r)}function O(e,t,r,n){G(r,n,!0).OrdinaryDefineOwnMetadata(e,t,r,n)}function M(e,t){var r=b(e,t),n=U(e);if(null===n)return r;var a=M(n,t);if(a.length<=0)return r;if(r.length<=0)return a;for(var o=new f,i=[],s=0,c=r;s<c.length;s++){var u=c[s];o.has(u)||(o.add(u),i.push(u))}for(var l=0,d=a;l<d.length;l++)u=d[l],o.has(u)||(o.add(u),i.push(u));return i}function b(e,t){var r=G(e,t,!1);return r?r.OrdinaryOwnMetadataKeys(e,t):[]}function R(e){if(null===e)return 1;switch(typeof e){case"undefined":return 0;case"boolean":return 2;case"string":return 3;case"symbol":return 4;case"number":return 5;case"object":return null===e?1:6;default:return 6}}function S(e){return void 0===e}function w(e){return null===e}function P(e){return"object"==typeof e?null!==e:"function"==typeof e}function T(e,t){switch(R(e)){case 0:case 1:case 2:case 3:case 4:case 5:return e}var r=3===t?"string":5===t?"number":"default",n=N(e,a);if(void 0!==n){var o=n.call(e,r);if(P(o))throw new TypeError;return o}return function(e,t){if("string"===t){var r=e.toString;if(D(r)&&!P(a=r.call(e)))return a;if(D(n=e.valueOf)&&!P(a=n.call(e)))return a}else{var n;if(D(n=e.valueOf)&&!P(a=n.call(e)))return a;var a,o=e.toString;if(D(o)&&!P(a=o.call(e)))return a}throw new TypeError}(e,"default"===r?"number":r)}function A(e){return!!e}function j(e){var t=T(e,3);return"symbol"==typeof t?t:function(e){return""+e}(t)}function V(e){return Array.isArray?Array.isArray(e):e instanceof Object?e instanceof Array:"[object Array]"===Object.prototype.toString.call(e)}function D(e){return"function"==typeof e}function L(e){return"function"==typeof e}function K(e,t){return e===t||e!=e&&t!=t}function N(e,t){var r=e[t];if(null!=r){if(!D(r))throw new TypeError;return r}}function x(e){var t=N(e,o);if(!D(t))throw new TypeError;var r=t.call(e);if(!P(r))throw new TypeError;return r}function F(e){return e.value}function k(e){var t=e.next();return!t.done&&t}function I(e){var t=e.return;t&&t.call(e)}function U(e){var t=Object.getPrototypeOf(e);if("function"!=typeof e||e===l)return t;if(t!==l)return t;var r=e.prototype,n=r&&Object.getPrototypeOf(r);if(null==n||n===Object.prototype)return t;var a=n.constructor;return"function"!=typeof a||a===e?t:a}function G(e,t,r){var n=h.getProvider(e,t);if(!S(n))return n;if(r){if(h.setProvider(e,t,g))return g;throw new Error("Illegal state.")}}function H(e){return e.__=void 0,delete e.__,e}e("decorate",(function(e,t,r,n){if(S(r)){if(!V(e))throw new TypeError;if(!L(t))throw new TypeError;return function(e,t){for(var r=e.length-1;r>=0;--r){var n=(0,e[r])(t);if(!S(n)&&!w(n)){if(!L(n))throw new TypeError;t=n}}return t}(e,t)}if(!V(e))throw new TypeError;if(!P(t))throw new TypeError;if(!P(n)&&!S(n)&&!w(n))throw new TypeError;return w(n)&&(n=void 0),function(e,t,r,n){for(var a=e.length-1;a>=0;--a){var o=(0,e[a])(t,r,n);if(!S(o)&&!w(o)){if(!P(o))throw new TypeError;n=o}}return n}(e,t,r=j(r),n)})),e("metadata",(function(e,t){return function(r,n){if(!P(r))throw new TypeError;if(!S(n)&&!function(e){switch(R(e)){case 3:case 4:return!0;default:return!1}}(n))throw new TypeError;O(e,t,r,n)}})),e("defineMetadata",(function(e,t,r,n){if(!P(r))throw new TypeError;return S(n)||(n=j(n)),O(e,t,r,n)})),e("hasMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),v(e,t,r)})),e("hasOwnMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),_(e,t,r)})),e("getMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),E(e,t,r)})),e("getOwnMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),m(e,t,r)})),e("getMetadataKeys",(function(e,t){if(!P(e))throw new TypeError;return S(t)||(t=j(t)),M(e,t)})),e("getOwnMetadataKeys",(function(e,t){if(!P(e))throw new TypeError;return S(t)||(t=j(t)),b(e,t)})),e("deleteMetadata",(function(e,t,r){if(!P(t))throw new TypeError;if(S(r)||(r=j(r)),!P(t))throw new TypeError;S(r)||(r=j(r));var n=G(t,r,!1);return!S(n)&&n.OrdinaryDeleteMetadata(e,t,r)}))}(n,t),void 0===t.Reflect&&(t.Reflect=e)}()}(n||(n={}))}},t={};function r(n){var a=t[n];if(void 0!==a)return a.exports;var o=t[n]={exports:{}};return e[n].call(o.exports,o,o.exports,r),o.exports}r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r(729);
var e={729:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=void 0,a(r(935),t),a(r(965),t),a(r(847),t),t.VERSION="##VERSION##"},6:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Model=void 0,t.validate=y;const n=r(772),a=r(735),o=r(19),i=r(402),s=r(154),c=r(38),u=r(936),l=r(770),d=r(523),f=r(593),p=r(32);function y(e,...t){const r=[];for(const a in e)e.hasOwnProperty(a)&&-1===t.indexOf(a)&&r.push((0,p.getPropertyDecorators)(n.ValidationKeys.REFLECT,e,a));const a=r.reduce(((t,r)=>{const{prop:a,decorators:o}=r;if(!o||!o.length)return t;const c=o[0];o.find((e=>e.key===n.ValidationKeys.TYPE||!!e.props.types?.find((e=>e===c.props.name))))&&o.shift();let u=o.reduce(((t,r)=>{const n=l.Validation.get(r.key);if(!n)return t;const o=n.hasErrors(e[a.toString()],...r.key===s.ModelKeys.TYPE?[r.props]:Object.values(r.props));return o&&((t=t||{})[r.key]=o),t}),void 0);return u=u||Object.keys(e).filter((e=>!u||!u[e])).reduce(((t,r)=>{let a;const o=(0,p.getPropertyDecorators)(n.ValidationKeys.REFLECT,e,r).decorators,c=o.filter((e=>-1!==[s.ModelKeys.TYPE,n.ValidationKeys.TYPE].indexOf(e.key)));if(!c||!c.length)return t;const u=c.pop(),l=u.props.name?[u.props.name]:Array.isArray(u.props.customTypes)?u.props.customTypes:[u.props.customTypes],d=Object.values(i.ReservedModels).map((e=>e.toLowerCase()));return l.forEach((t=>{if(-1===d.indexOf(t.toLowerCase()))switch(t){case"Array":case"Set":if(o.length&&o.find((e=>e.key===n.ValidationKeys.LIST))){const o="Array"===t?e[r].find((e=>e.hasErrors())):e[r].values().find((e=>e.hasErrors()));o&&(a=(0,f.sf)(n.DEFAULT_ERROR_MESSAGES.LIST_INSIDE,o.toString()))}break;default:try{e[r]&&(a=e[r].hasErrors())}catch(e){console.warn((0,f.sf)("Model should be validatable but its not"))}}})),a&&((t=t||{})[r]=a),t}),void 0),u&&((t=t||{})[r.prop.toString()]=u),t}),void 0);return a?new o.ModelErrorDefinition(a):void 0}let h,g,v,_;class E{constructor(e){}hasErrors(...e){return y(this,...e)}equals(e,...t){return(0,p.isEqual)(this,e,...t)}serialize(){return E.serialize(this)}toString(){return this.constructor.name+": "+JSON.stringify(this,void 0,2)}toHash(){return E.getHashingFunction()(this).toString()}static deserialize(e){return E.getSerializer().deserialize(e)}static serialize(e){return E.getSerializer().serialize(e)}static hash(e){return E.getHashingFunction()(e)}static fromObject(e,t){return(0,c.constructFromObject)(e,t)}static fromModel(e,t){return(0,c.constructFromModel)(e,t)}static setBuilder(e){h=e}static getBuilder(){return h}static getRegistry(){return g||(g=new u.ModelRegistryManager),g}static setRegistry(e){g=e}static register(e,t){return E.getRegistry().register(e,t)}static get(e){return E.getRegistry().get(e)}static build(e={},t){return E.getRegistry().build(e,t)}static setSerializer(e){v=e}static getSerializer(){return v||(v=new a.JSONSerializer),v}static setHashingFunction(e){_=e}static getHashingFunction(){return _||(_=d.hashObj),_}}t.Model=E},19:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ModelErrorDefinition=void 0,t.ModelErrorDefinition=class{constructor(e){for(const t in e)e.hasOwnProperty(t)&&e[t]&&Object.defineProperty(this,t,{enumerable:!0,configurable:!1,value:e[t],writable:!1})}toString(){const e=this;return Object.keys(e).filter((t=>e.hasOwnProperty(t)&&"function"!=typeof e[t])).reduce(((t,r)=>{let n=Object.keys(e[r]).reduce(((t,n)=>(t?t+=`\n${e[r][n]}`:t=e[r][n],t)),void 0);return n&&(n=`${r} - ${n}`,t?t+=`\n${n}`:t=n),t}),"")}}},936:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ModelRegistryManager=void 0,t.bulkModelRegister=function(...e){e.forEach((e=>{const t=e.constructor?e.constructor:e;n.Model.register(t,e.name)}))};const n=r(6),a=r(154),o=r(593),i=r(710);t.ModelRegistryManager=class{constructor(e=a.ModelKeys.ANCHOR,t=i.isModel){this.cache={},this.testFunction=t,this.anchorKey=e}register(e,t){if("function"!=typeof e)throw new Error("Model registering failed. Missing Class name or constructor");t=t||e.name,this.cache[t]=e}get(e){try{return this.cache[e]}catch(e){return}}build(e={},t){if(!t&&!this.testFunction(e))throw new Error("Provided obj is not a Model object");const r=t||e[this.anchorKey].class;if(!(r in this.cache))throw new Error((0,o.sf)("Provided class {0} is not a registered Model object",r));return new this.cache[r](e)}}},402:(e,t)=>{var r,n;Object.defineProperty(t,"__esModule",{value:!0}),t.ReservedModels=t.Primitives=void 0,function(e){e.STRING="string",e.NUMBER="number",e.BOOLEAN="boolean",e.BIGINT="bigint"}(r||(t.Primitives=r={})),function(e){e.STRING="string",e.OBJECT="object",e.NUMBER="number",e.BOOLEAN="boolean",e.BIGINT="bigint",e.DATE="date"}(n||(t.ReservedModels=n={}))},38:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.constructFromObject=function(e,t){if(!t)return e;for(const r in t)t.hasOwnProperty(r)&&(e.hasOwnProperty(r)||e.prototype&&e.prototype.hasOwnProperty(r))&&(e[r]=t[r]||void 0);return e},t.constructFromModel=function(e,t){if(!t)return e;let r,l;for(const d in t)if(t.hasOwnProperty(d)&&(e.hasOwnProperty(d)||e.prototype&&e.prototype.hasOwnProperty(d))){if(e[d]=t[d]||void 0,"object"!=typeof e[d])continue;if((0,u.isModel)(e[d])){try{e[d]=n.Model.build(e[d])}catch(e){console.error(e)}continue}const f=(0,c.getPropertyDecorators)(a.ValidationKeys.REFLECT,e,d).decorators;if(r=f.filter((e=>-1!==[i.ModelKeys.TYPE,a.ValidationKeys.TYPE].indexOf(e.key))),!r||!r.length)throw new Error((0,s.sf)("failed to find decorators for property {0}",d));l=r.pop();const p=l.props.name?[l.props.name]:Array.isArray(l.props.customTypes)?l.props.customTypes:[l.props.customTypes],y=Object.values(o.ReservedModels).map((e=>e.toLowerCase()));p.forEach((t=>{if(-1===y.indexOf(t.toLowerCase()))try{switch(t){case"Array":case"Set":if(f.length){const r=f.find((e=>e.key===a.ValidationKeys.LIST));if(r&&("Array"===t&&(e[d]=e[d].map((e=>n.Model.build(e,r.props.class)))),"Set"===t)){const t=new Set;for(const a of e[d])t.add(n.Model.build(a,r.props.class));e[d]=t}}break;default:e[d]&&(e[d]=n.Model.build(e[d],t))}}catch(e){console.log(e)}}))}return e},t.construct=function(e,...t){const r=(...t)=>new e(...t);return r.prototype=e.prototype,r(...t)};const n=r(6),a=r(772),o=r(402),i=r(154),s=r(593),c=r(32),u=r(710)},893:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getModelKey=void 0,t.model=function(e,r){return i=>{const s=function(...s){const c=(0,n.construct)(i,...s),u=o.Model.getBuilder();u&&u(c,s.length?s[0]:void 0);const l=Object.assign({},{class:i.name});return Object.defineProperty(c,a.ModelKeys.ANCHOR,{writable:!1,enumerable:!1,configurable:!1,value:l}),Reflect.defineMetadata((0,t.getModelKey)(a.ModelKeys.MODEL),Object.assign(l,e||{}),c.constructor),r&&r(c,...s),c};return s.prototype=i.prototype,Object.defineProperty(s,"name",{writable:!1,enumerable:!0,configurable:!1,value:i.prototype.constructor.name}),o.Model.register(s),s}};const n=r(38),a=r(154),o=r(6);t.getModelKey=e=>a.ModelKeys.REFLECT+e},847:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),a(r(402),t),a(r(38),t),a(r(893),t),a(r(6),t),a(r(19),t),a(r(936),t),a(r(282),t),a(r(710),t)},282:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},710:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.isModel=function(e){return!!e[n.ModelKeys.ANCHOR]||!!(0,a.getClassDecorators)(n.ModelKeys.REFLECT,e).find((e=>e.key===n.ModelKeys.MODEL&&e.props&&e.props.class))};const n=r(154),a=r(32)},154:(e,t)=>{var r;Object.defineProperty(t,"__esModule",{value:!0}),t.ModelKeys=void 0,function(e){e.REFLECT="model.definition.",e.TYPE="design:type",e.PARAMS="design:paramtypes",e.RETURN="design:returntype",e.MODEL="model",e.ANCHOR="__modelDefinition"}(r||(t.ModelKeys=r={}))},46:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.dateFromFormat=o,t.bindDateToString=i,t.isValidDate=s,t.twoDigitPad=c,t.formatDate=u,t.parseDate=function(e,t){let r;if(t){if(t instanceof Date)try{r=o(u(t,e),e)}catch(r){throw new Error((0,a.sf)("Could not convert date {0} to format: {1}",t.toString(),e))}else if("string"==typeof t)r=o(t,e);else if("number"==typeof t)r=o(u(new Date(t),e),e);else{if(!s(t))throw new Error(`Invalid value provided ${t}`);try{r=o(u(new Date(t),e),e)}catch(r){throw new Error((0,a.sf)("Could not convert date {0} to format: {1}",t,e))}}return i(r,e)}},r(630);const n=r(772),a=r(593);function o(e,t){let r=t;r.match(/hh/)?r=r.replace("hh","(?<hour>\\d{2})"):r.match(/h/)?r=r.replace("h","(?<hour>\\d{1,2})"):r.match(/HH/)?r=r.replace("HH","(?<hour>\\d{2})"):r.match(/H/)&&(r=r.replace("H","(?<hour>\\d{1,2})")),r.match(/mm/)?r=r.replace("mm","(?<minutes>\\d{2})"):r.match(/m/)&&(r=r.replace("m","(?<minutes>\\d{1,2})")),r.match(/ss/)?r=r.replace("ss","(?<seconds>\\d{2})"):r.match(/s/)&&(r=r.replace("s","(?<seconds>\\d{1,2})")),r.match(/dd/)?r=r.replace("dd","(?<day>\\d{2})"):r.match(/d/)&&(r=r.replace("d","(?<day>\\d{1,2})")),r.match(/EEEE/)?r=r.replace("EEEE","(?<dayofweek>\\w+)"):r.match(/EEEE/)&&(r=r.replace("EEE","(?<dayofweek>\\w+)")),r.match(/yyyy/)?r=r.replace("yyyy","(?<year>\\d{4})"):r.match(/yy/)&&(r=r.replace("yy","(?<year>\\d{2})")),r.match(/MMMM/)?r=r.replace("MMMM","(?<monthname>\\w+)"):r.match(/MMM/)&&(r=r.replace("MMM","(?<monthnamesmall>\\w+)")),r.match(/MM/)?r=r.replace("MM","(?<month>\\d{2})"):r.match(/M/)&&(r=r.replace("M","(?<month>\\d{1,2})")),r=r.replace("S","(?<milis>\\d{1,3})").replace("aaa","(?<ampm>\\w{2})");const a=new RegExp(r,"g").exec(e);if(!a||!a.groups)return new Date(e);const o=function(e){if(!e)return 0;const t=parseInt(e);return isNaN(t)?0:t},i=o(a.groups.year),s=o(a.groups.day),c=a.groups.ampm;let u=o(a.groups.hour);c&&(u="PM"===c?u+12:u);const l=o(a.groups.minutes),d=o(a.groups.seconds),f=o(a.groups.milis),p=a.groups.monthname,y=a.groups.monthnamesmall;let h=a.groups.month;if(p)h=n.MONTH_NAMES.indexOf(p);else if(y){const t=n.MONTH_NAMES.find((e=>e.toLowerCase().startsWith(y.toLowerCase())));if(!t)return new Date(e);h=n.MONTH_NAMES.indexOf(t)}else h=o(`${h}`);return new Date(i,h-1,s,u,l,d,f)}function i(e,t){if(!e)return;const r=()=>u(e,t);return Object.defineProperty(e,"toISOString",{enumerable:!1,configurable:!1,value:r}),Object.defineProperty(e,"toString",{enumerable:!1,configurable:!1,value:r}),e}function s(e){return e&&"[object Date]"===Object.prototype.toString.call(e)&&!isNaN(e)}function c(e){return e<10?"0"+e:e.toString()}function u(e,t="yyyy/MM/dd"){const r=e.getDate(),a=e.getMonth(),o=e.getFullYear(),i=e.getHours(),s=e.getMinutes(),u=e.getSeconds(),l=e.getMilliseconds(),d=i%12,f=c(d),p=c(i),y=c(s),h=c(u),g=i<12?"AM":"PM",v=n.DAYS_OF_WEEK_NAMES[e.getDay()],_=v.substr(0,3),E=c(r),O=a+1,m=c(O),M=n.MONTH_NAMES[a],b=M.substr(0,3),R=o+"",S=R.substr(2,2);return(t=t.replace("hh",f).replace("h",d.toString()).replace("HH",p).replace("H",i.toString()).replace("mm",y).replace("m",s.toString()).replace("ss",h).replace("s",u.toString()).replace("S",l.toString()).replace("dd",E).replace("d",r.toString()).replace("EEEE",v).replace("EEE",_).replace("yyyy",R).replace("yy",S).replace("aaa",g)).indexOf("MMM")>-1?t.replace("MMMM",M).replace("MMM",b):t.replace("MM",m).replace("M",O.toString())}},523:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.hashCode=a,t.hashSerialization=function(e){return a(n.Model.serialize(e))},t.hashObj=function(e){const t=function(e,t){const r=n(t);return"string"==typeof r?n((e||"")+n(t)):0|(e=((e=e||0)<<5)-e+r)},r=a,n=function(e){return void 0===e?"":-1!==["string","number","symbol"].indexOf(typeof e)?r(e.toString()):e instanceof Date?r(e.getTime()):Array.isArray(e)?e.reduce(t,void 0):Object.values(e).reduce(t,void 0)},o=Object.values(e).reduce(t,0);return"number"==typeof o?Math.abs(o):o};const n=r(6);function a(e){e=String(e);let t=0;for(let r=0;r<e.length;r++)t=(t<<5)-t+e.charCodeAt(r),t|=0;return t}},935:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),a(r(154),t),a(r(46),t),a(r(523),t),a(r(735),t),a(r(904),t),a(r(735),t),a(r(593),t)},904:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},735:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.JSONSerializer=void 0;const n=r(6),a=r(154);t.JSONSerializer=class{preSerialize(e){const t=Object.assign({},e);return t[a.ModelKeys.ANCHOR]=e[a.ModelKeys.ANCHOR],t}deserialize(e){const t=JSON.parse(e);return n.Model.build(t)}serialize(e){return JSON.stringify(this.preSerialize(e))}}},593:(e,t)=>{function r(e,...t){return e.replace(/{(\d+)}/g,(function(e,r){return void 0!==t[r]?t[r]:e}))}Object.defineProperty(t,"__esModule",{value:!0}),t.sf=void 0,t.stringFormat=r,t.sf=r},770:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Validation=void 0;const n=r(436);class a{static{this.actingValidatorRegistry=void 0}constructor(){}static setRegistry(e,t){t&&a.actingValidatorRegistry&&a.actingValidatorRegistry.getKeys().forEach((r=>{const n=e.get(r);n&&e.register(t(n))})),a.actingValidatorRegistry=e}static getRegistry(){return a.actingValidatorRegistry||(a.actingValidatorRegistry=new n.ValidatorRegistry),a.actingValidatorRegistry}static get(e){return a.getRegistry().get(e)}static register(...e){return a.getRegistry().register(...e)}}t.Validation=a},395:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.DateValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.DATE){super(e,Number.name,Date.name,String.name)}hasErrors(e,t,r){if(void 0!==e)return"string"==typeof e&&(e=new Date(e)),isNaN(e.getDate())?this.getMessage(r||this.message):void 0}};t.DateValidator=c,t.DateValidator=c=n([(0,s.validator)(i.ValidationKeys.DATE),a("design:paramtypes",[String])],c)},335:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.EmailValidator=void 0;const o=r(772),i=r(273),s=r(787);let c=class extends i.PatternValidator{constructor(e=o.DEFAULT_ERROR_MESSAGES.EMAIL){super(e)}hasErrors(e,t){return super.hasErrors(e,o.DEFAULT_PATTERNS.EMAIL,t)}};t.EmailValidator=c,t.EmailValidator=c=n([(0,s.validator)(o.ValidationKeys.EMAIL),a("design:paramtypes",[String])],c)},407:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.ListValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.LIST){super(e,Array.name,Set.name)}hasErrors(e,t,r){if(!e||(Array.isArray(e)?!e.length:!e.size))return;let n;for(let a=0;a<(Array.isArray(e)?e.length:e.size);a++)switch(n=e[a],typeof n){case"object":case"function":if(!n.constructor||n.constructor.name!==t)return this.getMessage(r||this.message,t);break;default:if(typeof n!==t)return this.getMessage(r||this.message,t)}}};t.ListValidator=c,t.ListValidator=c=n([(0,s.validator)(i.ValidationKeys.LIST),a("design:paramtypes",[String])],c)},169:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MaxLengthValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MAX_LENGTH){super(e,String.name,Array.name)}hasErrors(e,t,r){if(void 0!==e)return e.length>t?this.getMessage(r||this.message,t):void 0}};t.MaxLengthValidator=c,t.MaxLengthValidator=c=n([(0,s.validator)(i.ValidationKeys.MAX_LENGTH),a("design:paramtypes",[String])],c)},909:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MaxValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MAX){super(e,"number","Date","string")}hasErrors(e,t,r){if(void 0!==e){if(e instanceof Date&&!(t instanceof Date)&&(t=new Date(t),isNaN(t.getDate())))throw new Error("Invalid Max param defined");return e>t?this.getMessage(r||this.message,t):void 0}}};t.MaxValidator=c,t.MaxValidator=c=n([(0,s.validator)(i.ValidationKeys.MAX),a("design:paramtypes",[String])],c)},519:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MinLengthValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MIN_LENGTH){super(e,String.name,Array.name)}hasErrors(e,t,r){if(void 0!==e)return e.length<t?this.getMessage(r||this.message,t):void 0}};t.MinLengthValidator=c,t.MinLengthValidator=c=n([(0,s.validator)(i.ValidationKeys.MIN_LENGTH),a("design:paramtypes",[String])],c)},889:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.MinValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.MIN){super(e,"number","Date","string")}hasErrors(e,t,r){if(void 0!==e){if(e instanceof Date&&!(t instanceof Date)&&(t=new Date(t),isNaN(t.getDate())))throw new Error("Invalid Min param defined");return e<t?this.getMessage(r||this.message,t):void 0}}};t.MinValidator=c,t.MinValidator=c=n([(0,s.validator)(i.ValidationKeys.MIN),a("design:paramtypes",[String])],c)},354:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.PasswordValidator=void 0;const o=r(273),i=r(772),s=r(787);let c=class extends o.PatternValidator{constructor(e=i.DEFAULT_ERROR_MESSAGES.PASSWORD,t=i.DEFAULT_PATTERNS.PASSWORD.CHAR8_ONE_OF_EACH){super(e),this.pattern=t}hasErrors(e,t,r){return super.hasErrors(e,t||this.pattern,r||this.message)}};t.PasswordValidator=c,t.PasswordValidator=c=n([(0,s.validator)(i.ValidationKeys.PASSWORD),a("design:paramtypes",[Object,RegExp])],c)},273:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.PatternValidator=t.regexpParser=void 0;const o=r(116),i=r(772),s=r(787);t.regexpParser=new RegExp("^/(.+)/([gimus]*)$");let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.PATTERN){super(e,"string")}getPattern(e){if(!t.regexpParser.test(e))return new RegExp(e);const r=e.match(t.regexpParser);return new RegExp(r[1],r[2])}hasErrors(e,t,r){if(e){if(!t)throw new Error("Missing Pattern");return(t="string"==typeof t?this.getPattern(t):t).lastIndex=0,t.test(e)?void 0:this.getMessage(r||this.message)}}};t.PatternValidator=c,t.PatternValidator=c=n([(0,s.validator)(i.ValidationKeys.PATTERN),a("design:paramtypes",[String])],c)},812:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.RequiredValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.REQUIRED){super(e)}hasErrors(e,t){switch(typeof e){case"boolean":case"number":return void 0===e?this.getMessage(t||this.message):void 0;default:return e?void 0:this.getMessage(t||this.message)}}};t.RequiredValidator=c,t.RequiredValidator=c=n([(0,s.validator)(i.ValidationKeys.REQUIRED),a("design:paramtypes",[String])],c)},553:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.StepValidator=void 0;const o=r(116),i=r(772),s=r(787);let c=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.STEP){super(e,"number","string")}hasErrors(e,t,r){if(void 0!==e)return Number(e)%Number(t)!=0?this.getMessage(r||this.message,t):void 0}};t.StepValidator=c,t.StepValidator=c=n([(0,s.validator)(i.ValidationKeys.STEP),a("design:paramtypes",[String])],c)},375:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.TypeValidator=void 0;const o=r(116),i=r(772),s=r(787),c=r(935),u=r(770),l=r(32);let d=class extends o.Validator{constructor(e=i.DEFAULT_ERROR_MESSAGES.TYPE){super(e)}hasErrors(e,t,r){if(void 0!==e)return(0,l.evaluateDesignTypes)(e,t)?void 0:this.getMessage(r||this.message,"string"==typeof t?t:Array.isArray(t)?t.join(", "):t.name,typeof e)}};t.TypeValidator=d,t.TypeValidator=d=n([(0,s.validator)(i.ValidationKeys.TYPE),a("design:paramtypes",[String])],d),u.Validation.register({validator:d,validationKey:c.ModelKeys.TYPE,save:!1})},964:function(e,t,r){var n=this&&this.__decorate||function(e,t,r,n){var a,o=arguments.length,i=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,r,i):a(t,r))||i);return o>3&&i&&Object.defineProperty(t,r,i),i},a=this&&this.__metadata||function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)};Object.defineProperty(t,"__esModule",{value:!0}),t.URLValidator=void 0;const o=r(772),i=r(273),s=r(787);let c=class extends i.PatternValidator{constructor(e=o.DEFAULT_ERROR_MESSAGES.URL){super(e)}hasErrors(e,t){return super.hasErrors(e,o.DEFAULT_PATTERNS.URL,t)}};t.URLValidator=c,t.URLValidator=c=n([(0,s.validator)(o.ValidationKeys.URL),a("design:paramtypes",[String])],c)},116:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Validator=void 0;const n=r(772),a=r(593),o=r(32);t.Validator=class{constructor(e=n.DEFAULT_ERROR_MESSAGES.DEFAULT,...t){this.message=e,t.length&&(this.acceptedTypes=t),this.acceptedTypes&&(this.hasErrors=this.checkTypeAndHasErrors(this.hasErrors.bind(this)))}getMessage(e,...t){return(0,a.sf)(e,...t)}checkTypeAndHasErrors(e){return function(t,...r){return void 0!==t&&this.acceptedTypes?(0,o.checkTypes)(t,this.acceptedTypes)?e(t,...r):this.getMessage(n.DEFAULT_ERROR_MESSAGES.TYPE,this.acceptedTypes.join(", "),typeof t):e(t,...r)}.bind(this)}}},436:(e,t)=>{function r(e){return e.constructor&&e.hasErrors}Object.defineProperty(t,"__esModule",{value:!0}),t.ValidatorRegistry=void 0,t.isValidator=r,t.ValidatorRegistry=class{constructor(...e){this.cache={},this.customKeyCache={},this.register(...e)}getCustomKeys(){return Object.assign({},this.customKeyCache)}getKeys(){return Object.keys(this.cache)}get(e){if(!(e in this.cache))return;const t=this.cache[e];if(r(t))return t;const n=new(t.default||t);return this.cache[e]=n,n}register(...e){e.forEach((e=>{if(r(e)){if(e.validationKey in this.cache)return;this.cache[e.validationKey]=e}else{const{validationKey:t,validator:r,save:n}=e;if(t in this.cache)return;if(this.cache[t]=r,!n)return;const a={};a[t.toUpperCase()]=t,this.customKeyCache=Object.assign({},this.customKeyCache,a)}}))}}},772:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_PATTERNS=t.DEFAULT_ERROR_MESSAGES=t.DAYS_OF_WEEK_NAMES=t.MONTH_NAMES=t.ValidationKeys=void 0,t.ValidationKeys={REFLECT:"model.validation.",VALIDATOR:"validator",REQUIRED:"required",MIN:"min",MAX:"max",STEP:"step",MIN_LENGTH:"minlength",MAX_LENGTH:"maxlength",PATTERN:"pattern",EMAIL:"email",URL:"url",DATE:"date",TYPE:"type",PASSWORD:"password",LIST:"list"},t.MONTH_NAMES=["January","February","March","April","May","June","July","August","September","October","November","December"],t.DAYS_OF_WEEK_NAMES=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],t.DEFAULT_ERROR_MESSAGES={REQUIRED:"This field is required",MIN:"The minimum value is {0}",MAX:"The maximum value is {0}",MIN_LENGTH:"The minimum length is {0}",MAX_LENGTH:"The maximum length is {0}",PATTERN:"The value does not match the pattern",EMAIL:"The value is not a valid email",URL:"The value is not a valid URL",TYPE:"Invalid type. Expected {0}, received {1}",STEP:"Invalid value. Not a step of {0}",DATE:"Invalid value. not a valid Date",DEFAULT:"There is an Error",PASSWORD:"Must be at least 8 characters and contain one of number, lower and upper case letters, and special character (@$!%*?&_-.,)",LIST:"Invalid list of {0}",LIST_INSIDE:"Elements of list are invalid: {0}",MODEL_NOT_FOUND:"No model registered under {0}"},t.DEFAULT_PATTERNS={EMAIL:/[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-zA-Z0-9](?:[a-z0-9-]*[a-zA-Z0-9])?\.)+[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?/,URL:/^(?:(?:(?:https?|ftp):)?\/\/)(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u00a1-\uffff][a-z0-9\u00a1-\uffff_-]{0,62})?[a-z0-9\u00a1-\uffff]\.)+(?:[a-z\u00a1-\uffff]{2,}\.?))(?::\d{2,5})?(?:[/?#]\S*)?$/i,PASSWORD:{CHAR8_ONE_OF_EACH:/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?=.*[@$!%*?&_\-.,])[A-Za-z\d@$!%*?&_\-.,]{8,}$/g}}},787:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.validator=function(...e){return(0,i.apply)((t=>(e.forEach((e=>{n.Validation.register({validator:t,validationKey:e,save:!0})})),t)),(0,i.metadata)((0,o.getValidationKey)(a.ValidationKeys.VALIDATOR),e))};const n=r(770),a=r(772),o=r(844),i=r(32)},493:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.Validators=void 0;const o=r(395),i=r(375),s=r(354),c=r(553),u=r(964),l=r(273),d=r(889),f=r(519),p=r(909),y=r(169),h=r(812),g=r(335),v=r(407);a(r(772),t),a(r(395),t),a(r(787),t),a(r(335),t),a(r(407),t),a(r(169),t),a(r(909),t),a(r(519),t),a(r(889),t),a(r(354),t),a(r(273),t),a(r(812),t),a(r(553),t),a(r(168),t),a(r(375),t),a(r(964),t),a(r(116),t),a(r(436),t),t.Validators={EmailValidator:g.EmailValidator,RequiredValidator:h.RequiredValidator,MaxLengthValidator:y.MaxLengthValidator,MaxValidator:p.MaxValidator,MinLengthValidator:f.MinLengthValidator,MinValidator:d.MinValidator,PatternValidator:l.PatternValidator,URLValidator:u.URLValidator,StepValidator:c.StepValidator,DateValidator:o.DateValidator,TypeValidator:i.TypeValidator,PasswordValidator:s.PasswordValidator,ListValidator:v.ListValidator}},168:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},475:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.required=function(e=o.DEFAULT_ERROR_MESSAGES.REQUIRED){return(0,l.metadata)((0,u.getValidationKey)(o.ValidationKeys.REQUIRED),{message:e})},t.min=function(e,t=o.DEFAULT_ERROR_MESSAGES.MIN){return(0,l.metadata)((0,u.getValidationKey)(o.ValidationKeys.MIN),{value:e,message:t,types:[Number.name,Date.name]})},t.max=function(e,t=o.DEFAULT_ERROR_MESSAGES.MAX){return(0,l.metadata)((0,u.getValidationKey)(o.ValidationKeys.MAX),{value:e,message:t,types:[Number.name,Date.name]})},t.step=function(e,t=o.DEFAULT_ERROR_MESSAGES.STEP){return(0,l.metadata)((0,u.getValidationKey)(o.ValidationKeys.STEP),{value:e,message:t,types:[Number.name]})},t.minlength=function(e,t=o.DEFAULT_ERROR_MESSAGES.MIN_LENGTH){return(0,l.metadata)((0,u.getValidationKey)(o.ValidationKeys.MIN_LENGTH),{value:e,message:t,types:[String.name,Array.name,Set.name]})},t.maxlength=function(e,t=o.DEFAULT_ERROR_MESSAGES.MAX_LENGTH){return(0,l.metadata)((0,u.getValidationKey)(o.ValidationKeys.MAX_LENGTH),{value:e,message:t,types:[String.name,Array.name,Set.name]})},t.pattern=function(e,t=o.DEFAULT_ERROR_MESSAGES.PATTERN){return(0,l.metadata)((0,u.getValidationKey)(o.ValidationKeys.PATTERN),{value:"string"==typeof e?e:e.toString(),message:t,types:[String.name]})},t.email=function(e=o.DEFAULT_ERROR_MESSAGES.EMAIL){return(0,l.metadata)((0,u.getValidationKey)(o.ValidationKeys.EMAIL),{message:e,types:[String.name]})},t.url=function(e=o.DEFAULT_ERROR_MESSAGES.URL){return(0,l.metadata)((0,u.getValidationKey)(o.ValidationKeys.URL),{message:e,types:[String.name]})},t.type=d,t.date=function(e="dd/MM/yyyy",t=o.DEFAULT_ERROR_MESSAGES.DATE){return(r,n)=>{Reflect.defineMetadata((0,u.getValidationKey)(o.ValidationKeys.DATE),{format:e,message:t,types:[Date.name]},r,n);const a=new WeakMap;Object.defineProperty(r,n,{configurable:!1,set(t){const r=Object.getOwnPropertyDescriptor(this,n);r&&!r.configurable||Object.defineProperty(this,n,{enumerable:!0,configurable:!1,get:()=>a.get(this),set:t=>{let r;try{r=(0,c.parseDate)(e,t),a.set(this,r)}catch(e){console.error((0,i.sf)("Failed to parse date: {0}",e.message||e))}}}),this[n]=t},get(){console.log("here")}})}},t.password=function(e=o.DEFAULT_PATTERNS.PASSWORD.CHAR8_ONE_OF_EACH,t=o.DEFAULT_ERROR_MESSAGES.PASSWORD,r=s.PasswordValidator){return(n,i)=>{Reflect.defineMetadata((0,u.getValidationKey)(o.ValidationKeys.PASSWORD),{pattern:e,message:t,types:[String.name]},n,i),a.Validation.register({validator:r,validationKey:o.ValidationKeys.PASSWORD,save:!0})}},t.list=f,t.set=function(e,t=o.DEFAULT_ERROR_MESSAGES.LIST,r){return(n,a)=>{f(e,"Set",t,r)(n,a)}},r(630);const n=r(407),a=r(770),o=r(772),i=r(593),s=r(354),c=r(935),u=r(844),l=r(32);function d(e,t=o.DEFAULT_ERROR_MESSAGES.TYPE){return(0,l.metadata)((0,u.getValidationKey)(o.ValidationKeys.TYPE),{customTypes:e,message:t})}function f(e,t="Array",r=o.DEFAULT_ERROR_MESSAGES.LIST,i=n.ListValidator){return(n,s)=>{d(t)(n,s),Reflect.defineMetadata((0,u.getValidationKey)(o.ValidationKeys.LIST),{class:e.name,type:t,message:r},n,s),a.Validation.register({validator:i,validationKey:o.ValidationKeys.LIST,save:!0})}}},965:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),a(r(493),t),a(r(475),t),a(r(792),t),a(r(844),t),a(r(770),t)},792:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},844:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getValidationKey=function(e){return n.ValidationKeys.REFLECT+e};const n=r(772)},267:(e,t)=>{var r;Object.defineProperty(t,"__esModule",{value:!0}),t.ReflectionKeys=void 0,function(e){e.TYPE="design:type"}(r||(t.ReflectionKeys=r={}))},530:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.metadata=function(e,t){return(r,n,a)=>{a?Reflect.defineMetadata(e,t,a.value):n?Reflect.defineMetadata(e,t,r,n):Reflect.defineMetadata(e,t,r)}},t.apply=function(...e){return(t,r,n)=>{for(const a of e)t instanceof Function&&!n?a(t):a(t,r,n)}},r(630)},651:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.isEqual=function e(t,r,...n){if(t===r)return!0;if(t instanceof Date&&r instanceof Date)return t.getTime()===r.getTime();if(!t||!r||"object"!=typeof t&&"object"!=typeof r)return t===r;if(null==t||null==r)return!1;if(typeof t!=typeof r)return!1;if(t.prototype!==r.prototype)return!1;const a=Object.keys(t).filter((e=>-1===n.indexOf(e)));return a.length===Object.keys(r).filter((e=>-1===n.indexOf(e))).length&&a.every((a=>-1!==n.indexOf(a)||e(t[a],r[a],...n)))}},32:function(e,t,r){var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var a=Object.getOwnPropertyDescriptor(t,r);a&&!("get"in a?!t.__esModule:a.writable||a.configurable)||(a={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,a)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),a=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=void 0,a(r(267),t),a(r(530),t),a(r(651),t),a(r(199),t),a(r(115),t),t.VERSION="0.2.1"},199:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0})},115:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getPropertyDecorators=o,t.getTypeFromDecorator=function(e,t){const r=o(n.ReflectionKeys.TYPE,e,t,!1);if(!r||!r.decorators)return;const a=r.decorators.shift(),i=a.props?a.props.name:void 0;return"Function"!==i?i:void 0},t.getAllPropertyDecorators=function(e,...t){if(t&&t.length)return Object.getOwnPropertyNames(e).reduce(((r,n)=>(t.forEach(((t,a)=>{const i=o(t,e,n,0!==a);r||(r={}),function(e,t,r){r&&r.length&&(e[t]||(e[t]=[]),e[t].push(...r))}(r,n,i.decorators)})),r)),void 0)},t.getAllProperties=function(e,t=!0,r="Object"){const n=[];let a=e;const o=function(){if(!t)return;const e=Object.getPrototypeOf(a);return e&&e.constructor.name!==r?(a=e,a):void 0};do{Object.getOwnPropertyNames(a).forEach((function(e){-1===n.indexOf(e)&&n.push(e)}))}while(o());return n},t.getClassDecorators=function(e,t){return Reflect.getOwnMetadataKeys(t.constructor).filter((t=>t.toString().startsWith(e))).reduce(((r,n)=>{const a={key:n.substring(e.length),props:Reflect.getMetadata(n,t.constructor)};return r.concat(a)}),[])},t.checkType=i,t.checkTypes=s,t.evaluateDesignTypes=function(e,t){switch(typeof t){case"string":return i(e,t);case"object":return!Array.isArray(t)||s(e,t);case"function":return!t.name||"Object"===t.name||i(e,t.name);default:return!0}},r(630);const n=r(267),a=r(651);function o(e,t,r,i=!1,s=!0,c){const u=function(e,t,r,a=!1,o){const i=Reflect.getMetadataKeys(t,r).filter((t=>a?t.toString().startsWith(e):t===n.ReflectionKeys.TYPE||t.toString().startsWith(e))).reduce(((a,o)=>{const i={key:o!==n.ReflectionKeys.TYPE?o.substring(e.length):o,props:Reflect.getMetadata(o,t,r)};return a.concat(i)}),o||[]);return{prop:r.toString(),decorators:i}}(e,t,r,i,c);return s&&Object.getPrototypeOf(t)!==Object.prototype?o(e,Object.getPrototypeOf(t.constructor),r,!0,s,u.decorators):{prop:u.prop,decorators:function(e){const r={};return e.filter((e=>e.key in r?((0,a.isEqual)(e.props,r[e.key])||console.log(`Found a similar decorator for the ${e.key} property of a ${t.constructor.name} model but with different attributes. The original one will be kept`),!1):(r[e.key.toString()]=e.props,!0)))}(u.decorators)}}function i(e,t){return typeof e===t||e.constructor&&e.constructor.name.toLowerCase()===t.toLowerCase()}function s(e,t){return!t.every((t=>!i(e,t)))}},630:(e,t,r)=>{var n;!function(e){!function(){var t="object"==typeof globalThis?globalThis:"object"==typeof r.g?r.g:"object"==typeof self?self:"object"==typeof this?this:function(){try{return Function("return this;")()}catch(e){}}()||function(){try{return(0,eval)("(function() { return this; })()")}catch(e){}}(),n=a(e);function a(e,t){return function(r,n){Object.defineProperty(e,r,{configurable:!0,writable:!0,value:n}),t&&t(r,n)}}void 0!==t.Reflect&&(n=a(t.Reflect,n)),function(e,t){var r=Object.prototype.hasOwnProperty,n="function"==typeof Symbol,a=n&&void 0!==Symbol.toPrimitive?Symbol.toPrimitive:"@@toPrimitive",o=n&&void 0!==Symbol.iterator?Symbol.iterator:"@@iterator",i="function"==typeof Object.create,s={__proto__:[]}instanceof Array,c=!i&&!s,u={create:i?function(){return H(Object.create(null))}:s?function(){return H({__proto__:null})}:function(){return H({})},has:c?function(e,t){return r.call(e,t)}:function(e,t){return t in e},get:c?function(e,t){return r.call(e,t)?e[t]:void 0}:function(e,t){return e[t]}},l=Object.getPrototypeOf(Function),d="function"==typeof Map&&"function"==typeof Map.prototype.entries?Map:function(){var e={},t=[],r=function(){function e(e,t,r){this._index=0,this._keys=e,this._values=t,this._selector=r}return e.prototype["@@iterator"]=function(){return this},e.prototype[o]=function(){return this},e.prototype.next=function(){var e=this._index;if(e>=0&&e<this._keys.length){var r=this._selector(this._keys[e],this._values[e]);return e+1>=this._keys.length?(this._index=-1,this._keys=t,this._values=t):this._index++,{value:r,done:!1}}return{value:void 0,done:!0}},e.prototype.throw=function(e){throw this._index>=0&&(this._index=-1,this._keys=t,this._values=t),e},e.prototype.return=function(e){return this._index>=0&&(this._index=-1,this._keys=t,this._values=t),{value:e,done:!0}},e}();return function(){function t(){this._keys=[],this._values=[],this._cacheKey=e,this._cacheIndex=-2}return Object.defineProperty(t.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0}),t.prototype.has=function(e){return this._find(e,!1)>=0},t.prototype.get=function(e){var t=this._find(e,!1);return t>=0?this._values[t]:void 0},t.prototype.set=function(e,t){var r=this._find(e,!0);return this._values[r]=t,this},t.prototype.delete=function(t){var r=this._find(t,!1);if(r>=0){for(var n=this._keys.length,a=r+1;a<n;a++)this._keys[a-1]=this._keys[a],this._values[a-1]=this._values[a];return this._keys.length--,this._values.length--,K(t,this._cacheKey)&&(this._cacheKey=e,this._cacheIndex=-2),!0}return!1},t.prototype.clear=function(){this._keys.length=0,this._values.length=0,this._cacheKey=e,this._cacheIndex=-2},t.prototype.keys=function(){return new r(this._keys,this._values,n)},t.prototype.values=function(){return new r(this._keys,this._values,a)},t.prototype.entries=function(){return new r(this._keys,this._values,i)},t.prototype["@@iterator"]=function(){return this.entries()},t.prototype[o]=function(){return this.entries()},t.prototype._find=function(e,t){if(!K(this._cacheKey,e)){this._cacheIndex=-1;for(var r=0;r<this._keys.length;r++)if(K(this._keys[r],e)){this._cacheIndex=r;break}}return this._cacheIndex<0&&t&&(this._cacheIndex=this._keys.length,this._keys.push(e),this._values.push(void 0)),this._cacheIndex},t}();function n(e,t){return e}function a(e,t){return t}function i(e,t){return[e,t]}}(),f="function"==typeof Set&&"function"==typeof Set.prototype.entries?Set:function(){function e(){this._map=new d}return Object.defineProperty(e.prototype,"size",{get:function(){return this._map.size},enumerable:!0,configurable:!0}),e.prototype.has=function(e){return this._map.has(e)},e.prototype.add=function(e){return this._map.set(e,e),this},e.prototype.delete=function(e){return this._map.delete(e)},e.prototype.clear=function(){this._map.clear()},e.prototype.keys=function(){return this._map.keys()},e.prototype.values=function(){return this._map.keys()},e.prototype.entries=function(){return this._map.entries()},e.prototype["@@iterator"]=function(){return this.keys()},e.prototype[o]=function(){return this.keys()},e}(),p="function"==typeof WeakMap?WeakMap:function(){var e=u.create(),t=n();return function(){function e(){this._key=n()}return e.prototype.has=function(e){var t=a(e,!1);return void 0!==t&&u.has(t,this._key)},e.prototype.get=function(e){var t=a(e,!1);return void 0!==t?u.get(t,this._key):void 0},e.prototype.set=function(e,t){return a(e,!0)[this._key]=t,this},e.prototype.delete=function(e){var t=a(e,!1);return void 0!==t&&delete t[this._key]},e.prototype.clear=function(){this._key=n()},e}();function n(){var t;do{t="@@WeakMap@@"+i()}while(u.has(e,t));return e[t]=!0,t}function a(e,n){if(!r.call(e,t)){if(!n)return;Object.defineProperty(e,t,{value:u.create()})}return e[t]}function o(e,t){for(var r=0;r<t;++r)e[r]=255*Math.random()|0;return e}function i(){var e=function(e){if("function"==typeof Uint8Array){var t=new Uint8Array(e);return"undefined"!=typeof crypto?crypto.getRandomValues(t):"undefined"!=typeof msCrypto?msCrypto.getRandomValues(t):o(t,e),t}return o(new Array(e),e)}(16);e[6]=79&e[6]|64,e[8]=191&e[8]|128;for(var t="",r=0;r<16;++r){var n=e[r];4!==r&&6!==r&&8!==r||(t+="-"),n<16&&(t+="0"),t+=n.toString(16).toLowerCase()}return t}}(),y=n?Symbol.for("@reflect-metadata:registry"):void 0,h=function(){var e;return!S(y)&&P(t.Reflect)&&Object.isExtensible(t.Reflect)&&(e=t.Reflect[y]),S(e)&&(e=function(){var e,r,n,a;S(y)||void 0===t.Reflect||y in t.Reflect||"function"!=typeof t.Reflect.defineMetadata||(e=function(e){var t=e.defineMetadata,r=e.hasOwnMetadata,n=e.getOwnMetadata,a=e.getOwnMetadataKeys,o=e.deleteMetadata,i=new p;return{isProviderFor:function(e,t){var r=i.get(e);return!(S(r)||!r.has(t))||!!a(e,t).length&&(S(r)&&(r=new f,i.set(e,r)),r.add(t),!0)},OrdinaryDefineOwnMetadata:t,OrdinaryHasOwnMetadata:r,OrdinaryGetOwnMetadata:n,OrdinaryOwnMetadataKeys:a,OrdinaryDeleteMetadata:o}}(t.Reflect));var o=new p,i={registerProvider:s,getProvider:u,setProvider:h};return i;function s(t){if(!Object.isExtensible(i))throw new Error("Cannot add provider to a frozen registry.");switch(!0){case e===t:break;case S(r):r=t;break;case r===t:break;case S(n):n=t;break;case n===t:break;default:void 0===a&&(a=new f),a.add(t)}}function c(t,o){if(!S(r)){if(r.isProviderFor(t,o))return r;if(!S(n)){if(n.isProviderFor(t,o))return r;if(!S(a))for(var i=x(a);;){var s=k(i);if(!s)return;var c=F(s);if(c.isProviderFor(t,o))return I(i),c}}}if(!S(e)&&e.isProviderFor(t,o))return e}function u(e,t){var r,n=o.get(e);return S(n)||(r=n.get(t)),S(r)?(S(r=c(e,t))||(S(n)&&(n=new d,o.set(e,n)),n.set(t,r)),r):r}function l(e){if(S(e))throw new TypeError;return r===e||n===e||!S(a)&&a.has(e)}function h(e,t,r){if(!l(r))throw new Error("Metadata provider not registered.");var n=u(e,t);if(n!==r){if(!S(n))return!1;var a=o.get(e);S(a)&&(a=new d,o.set(e,a)),a.set(t,r)}return!0}}()),!S(y)&&P(t.Reflect)&&Object.isExtensible(t.Reflect)&&Object.defineProperty(t.Reflect,y,{enumerable:!1,configurable:!1,writable:!1,value:e}),e}(),g=function(e){var t=new p,r={isProviderFor:function(e,r){var n=t.get(e);return!S(n)&&n.has(r)},OrdinaryDefineOwnMetadata:function(e,t,r,a){n(r,a,!0).set(e,t)},OrdinaryHasOwnMetadata:function(e,t,r){var a=n(t,r,!1);return!S(a)&&A(a.has(e))},OrdinaryGetOwnMetadata:function(e,t,r){var a=n(t,r,!1);if(!S(a))return a.get(e)},OrdinaryOwnMetadataKeys:function(e,t){var r=[],a=n(e,t,!1);if(S(a))return r;for(var o=x(a.keys()),i=0;;){var s=k(o);if(!s)return r.length=i,r;var c=F(s);try{r[i]=c}catch(e){try{I(o)}finally{throw e}}i++}},OrdinaryDeleteMetadata:function(e,r,a){var o=n(r,a,!1);if(S(o))return!1;if(!o.delete(e))return!1;if(0===o.size){var i=t.get(r);S(i)||(i.delete(a),0===i.size&&t.delete(i))}return!0}};return h.registerProvider(r),r;function n(n,a,o){var i=t.get(n),s=!1;if(S(i)){if(!o)return;i=new d,t.set(n,i),s=!0}var c=i.get(a);if(S(c)){if(!o)return;if(c=new d,i.set(a,c),!e.setProvider(n,a,r))throw i.delete(a),s&&t.delete(n),new Error("Wrong provider for target.")}return c}}(h);function v(e,t,r){if(_(e,t,r))return!0;var n=U(t);return!w(n)&&v(e,n,r)}function _(e,t,r){var n=G(t,r,!1);return!S(n)&&A(n.OrdinaryHasOwnMetadata(e,t,r))}function E(e,t,r){if(_(e,t,r))return O(e,t,r);var n=U(t);return w(n)?void 0:E(e,n,r)}function O(e,t,r){var n=G(t,r,!1);if(!S(n))return n.OrdinaryGetOwnMetadata(e,t,r)}function m(e,t,r,n){G(r,n,!0).OrdinaryDefineOwnMetadata(e,t,r,n)}function M(e,t){var r=b(e,t),n=U(e);if(null===n)return r;var a=M(n,t);if(a.length<=0)return r;if(r.length<=0)return a;for(var o=new f,i=[],s=0,c=r;s<c.length;s++){var u=c[s];o.has(u)||(o.add(u),i.push(u))}for(var l=0,d=a;l<d.length;l++)u=d[l],o.has(u)||(o.add(u),i.push(u));return i}function b(e,t){var r=G(e,t,!1);return r?r.OrdinaryOwnMetadataKeys(e,t):[]}function R(e){if(null===e)return 1;switch(typeof e){case"undefined":return 0;case"boolean":return 2;case"string":return 3;case"symbol":return 4;case"number":return 5;case"object":return null===e?1:6;default:return 6}}function S(e){return void 0===e}function w(e){return null===e}function P(e){return"object"==typeof e?null!==e:"function"==typeof e}function T(e,t){switch(R(e)){case 0:case 1:case 2:case 3:case 4:case 5:return e}var r=3===t?"string":5===t?"number":"default",n=N(e,a);if(void 0!==n){var o=n.call(e,r);if(P(o))throw new TypeError;return o}return function(e,t){if("string"===t){var r=e.toString;if(D(r)&&!P(a=r.call(e)))return a;if(D(n=e.valueOf)&&!P(a=n.call(e)))return a}else{var n;if(D(n=e.valueOf)&&!P(a=n.call(e)))return a;var a,o=e.toString;if(D(o)&&!P(a=o.call(e)))return a}throw new TypeError}(e,"default"===r?"number":r)}function A(e){return!!e}function j(e){var t=T(e,3);return"symbol"==typeof t?t:function(e){return""+e}(t)}function V(e){return Array.isArray?Array.isArray(e):e instanceof Object?e instanceof Array:"[object Array]"===Object.prototype.toString.call(e)}function D(e){return"function"==typeof e}function L(e){return"function"==typeof e}function K(e,t){return e===t||e!=e&&t!=t}function N(e,t){var r=e[t];if(null!=r){if(!D(r))throw new TypeError;return r}}function x(e){var t=N(e,o);if(!D(t))throw new TypeError;var r=t.call(e);if(!P(r))throw new TypeError;return r}function F(e){return e.value}function k(e){var t=e.next();return!t.done&&t}function I(e){var t=e.return;t&&t.call(e)}function U(e){var t=Object.getPrototypeOf(e);if("function"!=typeof e||e===l)return t;if(t!==l)return t;var r=e.prototype,n=r&&Object.getPrototypeOf(r);if(null==n||n===Object.prototype)return t;var a=n.constructor;return"function"!=typeof a||a===e?t:a}function G(e,t,r){var n=h.getProvider(e,t);if(!S(n))return n;if(r){if(h.setProvider(e,t,g))return g;throw new Error("Illegal state.")}}function H(e){return e.__=void 0,delete e.__,e}e("decorate",(function(e,t,r,n){if(S(r)){if(!V(e))throw new TypeError;if(!L(t))throw new TypeError;return function(e,t){for(var r=e.length-1;r>=0;--r){var n=(0,e[r])(t);if(!S(n)&&!w(n)){if(!L(n))throw new TypeError;t=n}}return t}(e,t)}if(!V(e))throw new TypeError;if(!P(t))throw new TypeError;if(!P(n)&&!S(n)&&!w(n))throw new TypeError;return w(n)&&(n=void 0),function(e,t,r,n){for(var a=e.length-1;a>=0;--a){var o=(0,e[a])(t,r,n);if(!S(o)&&!w(o)){if(!P(o))throw new TypeError;n=o}}return n}(e,t,r=j(r),n)})),e("metadata",(function(e,t){return function(r,n){if(!P(r))throw new TypeError;if(!S(n)&&!function(e){switch(R(e)){case 3:case 4:return!0;default:return!1}}(n))throw new TypeError;m(e,t,r,n)}})),e("defineMetadata",(function(e,t,r,n){if(!P(r))throw new TypeError;return S(n)||(n=j(n)),m(e,t,r,n)})),e("hasMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),v(e,t,r)})),e("hasOwnMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),_(e,t,r)})),e("getMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),E(e,t,r)})),e("getOwnMetadata",(function(e,t,r){if(!P(t))throw new TypeError;return S(r)||(r=j(r)),O(e,t,r)})),e("getMetadataKeys",(function(e,t){if(!P(e))throw new TypeError;return S(t)||(t=j(t)),M(e,t)})),e("getOwnMetadataKeys",(function(e,t){if(!P(e))throw new TypeError;return S(t)||(t=j(t)),b(e,t)})),e("deleteMetadata",(function(e,t,r){if(!P(t))throw new TypeError;if(S(r)||(r=j(r)),!P(t))throw new TypeError;S(r)||(r=j(r));var n=G(t,r,!1);return!S(n)&&n.OrdinaryDeleteMetadata(e,t,r)}))}(n,t),void 0===t.Reflect&&(t.Reflect=e)}()}(n||(n={}))}},t={};function r(n){var a=t[n];if(void 0!==a)return a.exports;var o=t[n]={exports:{}};return e[n].call(o.exports,o,o.exports,r),o.exports}r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r(729);

@@ -63,5 +63,4 @@ /**

export * from "./utils";
export * from "./reflection";
export * from "./validation";
export * from "./model";
export declare const VERSION = "1.1.1";
export declare const VERSION = "1.1.3";

@@ -63,7 +63,6 @@ /**

export * from "./utils";
export * from "./reflection";
export * from "./validation";
export * from "./model";
export const VERSION = "1.1.1";
export const VERSION = "1.1.3";
//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNyYy9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTs7R0FFRztBQUVIOzs7O0dBSUc7QUFFSDs7OztHQUlHO0FBRUg7OztHQUdHO0FBRUg7OztHQUdHO0FBRUg7OztHQUdHO0FBRUg7OztHQUdHO0FBRUg7OztHQUdHO0FBRUg7OztHQUdHO0FBRUg7OztHQUdHO0FBRUg7OztHQUdHO0FBRUg7OztHQUdHO0FBRUg7OztHQUdHO0FBRUg7OztHQUdHO0FBRUg7OztHQUdHO0FBRUgsY0FBYyxTQU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xuICogQG1lbWJlck9mIG1vZHVsZTpkZWNvcmF0b3ItdmFsaWRhdGlvbi5VdGlsc1xuICovXG5cbi8qKlxuICogQG5hbWVzcGFjZSBGb3JtYXRcbiAqIEBtZW1iZXJPZiBtb2R1bGU6ZGVjb3JhdG9yLXZhbGlkYXRpb24uVXRpbHNcbiAqL1xuXG5leHBvcnQgKiBmcm9tIFwiLi91dGlsc1wiO1xuZXhwb3J0ICogZnJvbSBcIi4vdmFsaWRhdGlvblwiO1xuZXhwb3J0ICogZnJvbSBcIi4vbW9kZWxcIjtcblxuZXhwb3J0IGNvbnN0IFZFUlNJT04gPSBcIjEuMS4zXCI7XG4iXX0=

@@ -5,4 +5,5 @@ import { Model } from "./Model";

import { ModelKeys } from "../utils/constants";
import { getPropertyDecorators, isModel } from "../reflection/utils";
import { sf } from "../utils/strings";
import { getPropertyDecorators } from "@decaf-ts/reflection";
import { isModel } from "./utils";
/**

@@ -125,2 +126,2 @@ * @summary Repopulates the Object properties with the ones from the new object

//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNyYy9tb2RlbC9jb25zdHJ1Y3Rpb24udHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLEtBQUssRUFBRSxNQUFNLFNBQVMsQ0FBQztBQUVoQyxPQUFPLEVBQUUsY0FBYyxFQUFFLE1BQU0sb0NBQW9DLENBQUM7QUFDcEUsT0FBTyxFQUFFLGNBQWMsRUFBRSxNQUFNLGFBQWEsQ0FBQztBQUM3QyxPQUFPLEVBQUUsU0FBUyxFQUFFLE1BQU0sb0JBQW9CLENBQUM7QUFDL0MsT0FBTyxFQUFFLHFCQUFxQixFQUFFLE9BQU8sRUFBRSxNQUFNLHFCQUFxQixDQUFDO0FBQ3JFLE9BQU8sRUFBRSxFQUFFLEVBQUUsTUFBTSxrQkFBa0IsQ0FBQztBQUV0Qzs7Ozs7Ozs7OztHQVVHO0FBQ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SB7MH1cIiwgcHJvcCkpO1xuICAgICAgZGVjID0gZGVjb3JhdG9ycy5wb3AoKSBhcyBEZWNvcmF0b3JNZXRhZGF0YTtcbiAgICAgIGNvbnN0IGNsYXp6ID0gZGVjLnByb3BzLm5hbWVcbiAgICAgICAgPyBbZGVjLnByb3BzLm5hbWVdXG4gICAgICAgIDogQXJyYXkuaXNBcnJheShkZWMucHJvcHMuY3VzdG9tVHlwZXMpXG4gICAgICAgICAgPyBkZWMucHJvcHMuY3VzdG9tVHlwZXNcbiAgICAgICAgICA6IFtkZWMucHJvcHMuY3VzdG9tVHlwZXNdO1xuICAgICAgY29uc3QgcmVzZXJ2ZWQgPSBPYmplY3QudmFsdWVzKFJlc2VydmVkTW9kZWxzKS5tYXAoKHYpID0+XG4gICAgICAgIHYudG9Mb3dlckNhc2UoKSxcbiAgICAgICkgYXMgc3RyaW5nW107XG5cbiAgICAgIGNsYXp6LmZvckVhY2goKGMpID0+IHtcbiAgICAgICAgaWYgKHJlc2VydmVkLmluZGV4T2YoYy50b0xvd2VyQ2FzZSgpKSA9PT0gLTEpXG4gICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgIHN3aXRjaCAoYykge1xuICAgICAgICAgICAgICBjYXNlIFwiQXJyYXlcIjpcbiAgICAgICAgICAgICAgY2FzZSBcIlNldFwiOlxuICAgICAgICAgICAgICAgIGlmIChhbGxEZWNvcmF0b3JzLmxlbmd0aCkge1xuICAgICAgICAgICAgICAgICAgY29uc3QgbGlzdERlYyA9IGFsbERlY29yYXRvcnMuZmluZChcbiAgICAgICAgICAgICAgICAgICAgKGQpID0+IGQua2V5ID09PSBWYWxpZGF0aW9uS2V5cy5MSVNULFxuICAgICAgICAgICAgICAgICAgKTtcbiAgICAgICAgICAgICAgICAgIGlmIChsaXN0RGVjKSB7XG4gICAgICAgICAgICAgICAgICAgIGlmIChjID09PSBcIkFycmF5XCIpXG4gICAgICAgICAgICAgICAgICAgICAgKHNlbGYgYXMgUmVjb3JkPHN0cmluZywgYW55PilbcHJvcF0gPSAoXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmIGFzIFJlY29yZDxzdHJpbmcsIGFueT5cbiAgICAgICAgICAgICAgICAgICAgICApW3Byb3BdLm1hcCgoZWw6IGFueSkgPT5cbiAgICAgICAgICAgICAgICAgICAgICAgIE1vZGVsLmJ1aWxkKGVsLCBsaXN0RGVjLnByb3BzLmNsYXNzKSxcbiAgICAgICAgICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgICAgICAgICBpZiAoYyA9PT0gXCJTZXRcIikge1xuICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IHMgPSBuZXcgU2V0KCk7XG4gICAgICAgICAgICAgICAgICAgICAgZm9yIChjb25zdCB2IG9mIChzZWxmIGFzIFJlY29yZDxzdHJpbmcsIGFueT4pW3Byb3BdKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBzLmFkZChNb2RlbC5idWlsZCh2LCBsaXN0RGVjLnByb3BzLmNsYXNzKSk7XG4gICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICAgIChzZWxmIGFzIFJlY29yZDxzdHJpbmcsIGFueT4pW3Byb3BdID0gcztcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgZGVmYXVsdDpcbiAgICAgICAgICAgICAgICBpZiAoKHNlbGYgYXMgUmVjb3JkPHN0cmluZywgYW55PilbcHJvcF0pXG4gICAgICAgICAgICAgICAgICAoc2VsZiBhcyBSZWNvcmQ8c3RyaW5nLCBhbnk+KVtwcm9wXSA9IE1vZGVsLmJ1aWxkKFxuICAgICAgICAgICAgICAgICAgICBzZWxmW3Byb3BdLFxuICAgICAgICAgICAgICAgICAgICBjLFxuICAgICAgICAgICAgICAgICAgKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICB9IGNhdGNoIChlOiBhbn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udmFsdWVzKFJlc2VydmVkTW9kZWxzKS5tYXAoKHYpID0+XG4gICAgICAgIHYudG9Mb3dlckNhc2UoKSxcbiAgICAgICkgYXMgc3RyaW5nW107XG5cbiAgICAgIGNsYXp6LmZvckVhY2goKGMpID0+IHtcbiAgICAgICAgaWYgKHJlc2VydmVkLmluZGV4T2YoYy50b0xvd2VyQ2FzZSgpKSA9PT0gLTEpXG4gICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgIHN3aXRjaCAoYykge1xuICAgICAgICAgICAgICBjYXNlIFwiQXJyYXlcIjpcbiAgICAgICAgICAgICAgY2FzZSBcIlNldFwiOlxuICAgICAgICAgICAgICAgIGlmIChhbGxEZWNvcmF0b3JzLmxlbmd0aCkge1xuICAgICAgICAgICAgICAgICAgY29uc3QgbGlzdERlYyA9IGFsbERlY29yYXRvcnMuZmluZChcbiAgICAgICAgICAgICAgICAgICAgKGQpID0+IGQua2V5ID09PSBWYWxpZGF0aW9uS2V5cy5MSVNULFxuICAgICAgICAgICAgICAgICAgKTtcbiAgICAgICAgICAgICAgICAgIGlmIChsaXN0RGVjKSB7XG4gICAgICAgICAgICAgICAgICAgIGlmIChjID09PSBcIkFycmF5XCIpXG4gICAgICAgICAgICAgICAgICAgICAgKHNlbGYgYXMgUmVjb3JkPHN0cmluZywgYW55PilbcHJvcF0gPSAoXG4gICAgICAgICAgICAgICAgICAgICAgICBzZWxmIGFzIFJlY29yZDxzdHJpbmcsIGFueT5cbiAgICAgICAgICAgICAgICAgICAgICApW3Byb3BdLm1hcCgoZWw6IGFueSkgPT5cbiAgICAgICAgICAgICAgICAgICAgICAgIE1vZGVsLmJ1aWxkKGVsLCBsaXN0RGVjLnByb3BzLmNsYXNzKSxcbiAgICAgICAgICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgICAgICAgICBpZiAoYyA9PT0gXCJTZXRcIikge1xuICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IHMgPSBuZXcgU2V0KCk7XG4gICAgICAgICAgICAgICAgICAgICAgZm9yIChjb25zdCB2IG9mIChzZWxmIGFzIFJlY29yZDxzdHJpbmcsIGFueT4pW3Byb3BdKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBzLmFkZChNb2RlbC5idWlsZCh2LCBsaXN0RGVjLnByb3BzLmNsYXNzKSk7XG4gICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICAgIChzZWxmIGFzIFJlY29yZDxzdHJpbmcsIGFueT4pW3Byb3BdID0gcztcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgZGVmYXVsdDpcbiAgICAgICAgICAgICAgICBpZiAoKHNlbGYgYXMgUmVjb3JkPHN0cmluZywgYW55PilbcHJvcF0pXG4gICAgICAgICAgICAgICAgICAoc2VsZiBhcyBSZWNvcmQ8c3RyaW5nLCBhbnk+KVtwcm9wXSA9IE1vZGVsLmJ1aWxkKFxuICAgICAgICAgICAgICAgICAgICBzZWxmW3Byb3BdLFxuICAgICAgICAgICAgICAgICAgICBjLFxuICAgICAgICAgICAgICAgICAgKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICB9IGNhdGNoIChlOiBhbnkpIHtcbiAgICAgICAgICAgIGNvbnNvbGUubG9nKGUpO1xuICAgICAgICAgICAgLy8gZG8gbm90aGluZy4gd2UgaGF2ZSBubyByZWdpc3RyeSBvZiB0aGlzIGNsYXNzXG4gICAgICAgICAgfVxuICAgICAgfSk7XG4gICAgfVxuXG4gIHJldHVybiBzZWxmO1xufVxuXG4vKipcbiAqIEBzdW1tYXJ5IEhlbHBlciBGdW5jdGlvbiB0byBvdmVycmlkZSBjb25zdHJ1Y3RvcnNcbiAqXG4gKiBAcGFyYW0ge0Z1bmN0aW9ufSBjb25zdHJ1Y3RvclxuICogQHBhcmFtIHthbnlbXX0gW2FyZ3NdXG4gKiBAcmV0dXJuIHtUfSB0aGUgbmV3IGluc3RhbmNlXG4gKlxuICogQGZ1bmN0aW9uIGNvbnN0cnVjdFxuICogQG1lbWJlck9mIG1vZHVsZTpkZWNvcmF0b3ItdmFsaWRhdGlvbi5Db25zdHJ1Y3Rpb25cbiAqIEBjYXRlZ29yeSBDb25zdHJ1Y3Rpb25cbiAqL1xuZXhwb3J0IGZ1bmN0aW9uIGNvbnN0cnVjdDxUIGV4dGVuZHMgTW9kZWw+KFxuICBjb25zdHJ1Y3RvcjogYW55LFxuICAuLi5hcmdzOiBhbnlbXVxuKTogVCB7XG4gIGNvbnN0IF9jb25zdHIgPSAoLi4uYXJnejogYW55W10pID0+IG5ldyBjb25zdHJ1Y3RvciguLi5hcmd6KTtcbiAgX2NvbnN0ci5wcm90b3R5cGUgPSBjb25zdHJ1Y3Rvci5wcm90b3R5cGU7XG4gIHJldHVybiBfY29uc3RyKC4uLmFyZ3MpO1xufVxuXG4vKipcbiAqIEBzdW1tYXJ5IFR5cG8gb2YgYSBNb2RlbCBidWlsZGVyIGZ1bmN0aW9uXG4gKiBAbWVtYmVyT2YgbW9kdWxlOmRlY29yYXRvci12YWxpZGF0aW9uLkNvbnN0cnVjdGlvblxuICogQGNhdGVnb3J5IENvbnN0cnVjdGlvblxuICovXG5leHBvcnQgdHlwZSBNb2RlbEJ1aWxkZXJGdW5jdGlvbiA9IDxUIGV4dGVuZHMgTW9kZWw+KFxuICBzZWxmOiBULFxuICBvYmo/OiBUIHwgUmVjb3JkPHN0cmluZywgYW55PixcbikgPT4gVDtcbiJdfQ==

@@ -8,1 +8,2 @@ export * from "./constants";

export * from "./types";
export * from "./utils";

@@ -8,3 +8,4 @@ export * from "./constants";

export * from "./types";
export * from "./utils";
//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNyYy9tb2RlbC9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxjQUFjLGFBQWEsQ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SBcIi4vZGVjb3JhdG9yc1wiO1xuZXhwb3J0ICogZnJvbSBcIi4vTW9kZWxcIjtcbmV4cG9ydCAqIGZyb20gXCIuL01vZGVsRXJyb3JEZWZpbml0aW9uXCI7XG5leHBvcnQgKiBmcm9tIFwiLi9SZWdpc3RyeVwiO1xuZXhwb3J0ICogZnJvbSBcIi4vdHlwZXNcIjtcbmV4cG9ydCAqIGZyb20gXCIuL3V0aWxzXCI7XG4iXX0=

@@ -9,6 +9,5 @@ import { DEFAULT_ERROR_MESSAGES, ValidationKeys, } from "../validation/Validators/constants";

import { Validation } from "../validation/Validation";
import { getPropertyDecorators } from "../reflection/utils";
import { hashObj } from "../utils/hashing";
import { sf } from "../utils/strings";
import { isEqual } from "../utils/equality";
import { getPropertyDecorators, isEqual, } from "@decaf-ts/reflection";
/**

@@ -34,3 +33,2 @@ * @summary Analyses the decorations of the properties and validates the obj according to them

return accum;
// @ts-expect-error due to type casting in decorators
const defaultTypeDecorator = decorators[0];

@@ -318,2 +316,2 @@ // tries to find any type decorators or other decorators that already enforce type (the ones with the allowed types property defined). if so, skip the default type verification

//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNyYy9tb2RlbC9Nb2RlbC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQ0wsc0JBQXNCLEVBQ3RCLGNBQWMsR0FDZixNQUFNLG9DQUFvQyxDQUFDO0FBTzVDLE9BQU8sRUFBRSxjQUFjLEVBQWMsTUFBTSx3QkFBd0IsQ0FBQztBQUVwRSxPQUFPLEVBQUUsb0JBQW9CLEVBQUUsTUFBTSx3QkFBd0IsQ0FBQztBQUU5RCxPQUFPLEVBQUUsY0FBYyxFQUFFLE1BQU0sYUFBYSxDQUFDO0FBQzdDLE9BQU8sRUFBRSxTQUFTLEVBQUUsTUFBTSxvQkFBb0IsQ0FBQztBQUMvQyxPQUFPLEVBQ0wsa0JBQWtCLE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mIChlcnIpIHtcbiAgICAgICAgICAgIGFjYyA9IGFjYyB8fCB7fTtcbiAgICAgICAgICAgIGFjY1tkZWNvcmF0b3Iua2V5XSA9IGVycjtcbiAgICAgICAgICB9XG5cbiAgICAgICAgICByZXR1cm4gYWNjO1xuICAgICAgICB9LFxuICAgICAgICB1bmRlZmluZWQsXG4gICAgICApO1xuXG4gICAgICBlcnJzID1cbiAgICAgICAgZXJycyB8fFxuICAgICAgICBPYmplY3Qua2V5cyhvYmopXG4gICAgICAgICAgLmZpbHRlcigoaykgPT4gIWVycnMgfHwgIWVycnNba10pXG4gICAgICAgICAgLnJlZHVjZSgoYWNjOiBSZWNvcmQ8c3RyaW5nLCBhbnk+IHwgdW5kZWZpbmVkLCBwcm9wKSA9PiB7XG4gICAgICAgICAgICBsZXQgZXJyOiBFcnJvcnM7XG4gICAgICAgICAgICAvLyBpZiBhIG5lc3RlZCBNb2RlbFxuICAgICAgICAgICAgY29uc3QgYWxsRGVjb3JhdG9ycyA9IGdldFByb3BlcnR5RGVjb3JhdG9ycyhcbiAgICAgICAgICAgICAgVmFsaWRhdGlvbktleXMuUkVGTEVDVCxcbiAgICAgICAgICAgICAgb2JqLFxuICAgICAgICAgICAgICBwcm9wLFxuICAgICAgICAgICAgKS5kZWNvcmF0b3JzO1xuICAgICAgICAgICAgY29uc3QgZGVjb3JhdG9ycyA9IGFsbERlY29yYXRvcnMuZmlsdGVyKFxuICAgICAgICAgICAgICAoZCkgPT5cbiAgICAgICAgICAgICAgICBbTW9kZWxLZXlzLlRZUEUsIFZhbGlkYXRpb25LZXlzLlRZUEVdLmluZGV4T2YoZC5rZXkpICE9PSAtMSxcbiAgICAgICAgICAgICk7XG4gICAgICAgICAgICBpZiAoIWRlY29yYXRvcnMgfHwgIWRlY29yYXRvcnMubGVuZ3RoKSByZXR1cm4gYWNjO1xuICAgICAgICAgICAgY29uc3QgZGVjID0gZGVjb3JhdG9ycy5wb3AoKSBhcyBEZWNvcmF0b3JNZXRhZGF0YTtcbiAgICAgICAgICAgIGNvbnN0IGNsYXp6ID0gZGVjLnByb3BzLm5hbWVcbiAgICAgICAgICAgICAgPyBbZGVjLnByb3BzLm5hbWVdXG4gICAgICAgICAgICAgIDogQXJyYXkuaXNBcnJheShkZWMucHJvcHMuY3VzdG9tVHlwZXMpXG4gICAgICAgICAgICAgICAgPyBkZWMucHJvcHMuY3VzdG9tVHlwZXNcbiAgICAgICAgICAgICAgICA6IFtkZWMucHJvcHMuY3VzdG9tVHlwZXNdO1xuICAgICAgICAgICAgY29uc3QgcmVzZXJ2ZWQgPSBPYmplY3QudmFsdWVzKFJlc2VydmVkTW9kZWxzKS5tYXAoKHYpID0+XG4gICAgICAgICAgICAgIHYudG9Mb3dlckNhc2UoKSxcbiAgICAgICAgICAgICkgYXMgc3RyaW5nW107XG5cbiAgICAgICAgICAgIGNsYXp6LmZvckVhY2goKGM6IHN0cmluZykgPT4ge1xuICAgICAgICAgICAgICBpZiAocmVzZXJ2ZWQuaW5kZXhPZihjLnRvTG93ZXJDYXNlKCkpID09PSAtMSkge1xuICAgICAgICAgICAgICAgIHN3aXRjaCAoYykge1xuICAgICAgICAgICAgICAgICAgY2FzZSBcIkFycmF5XCI6XG4gICAgICAgICAgICAgICAgICBjYXNlIFwiU2V0XCI6XG4gICAgICAgICAgICAgICAgICAgIGlmIChhbGxEZWNvcmF0b3JzLmxlbmd0aCkge1xuICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IGxpc3REZWMgPSBhbGxEZWNvcmF0b3JzLmZpbmQoXG4gICAgICAgICAgICAgICAgICAgICAgICAoZCkgPT4gZC5rZXkgPT09IFZhbGlkYXRpb25LZXlzLkxJU1QsXG4gICAgICAgICAgICAgICAgICAgICAgKTtcbiAgICAgICAgICAgICAgICAgICAgICBpZiAobGlzdERlYykge1xuICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgZSA9XG4gICAgICAgICAgICAgICAgICAgICAgICAgIGMgPT09IFwiQXJyYXlcIlxuICAgICAgICAgICAgICAgICAgICAgICAgICAgID8gKG9iaiBhcyBSZWNvcmQ8c3RyaW5nLCBhbnk+KVtwcm9wXS5maW5kKFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAoYzogVmFsaWRhdGFibGUpID0+IGMuaGFzRXJyb3JzKCksXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgOiAob2JqIGFzIFJlY29yZDxzdHJpbmcsIGFueT4pW3Byb3BdXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC52YWx1ZXMoKVxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAuZmluZCgoYzogVmFsaWRhdGFibGUpID0+IGMuaGFzRXJyb3JzKCkpO1xuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGUpXG4gICAgICAgICAgICAgICAgICAgICAgICAgIGVyciA9IHNmKFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIERFRkFVTFRfRVJST1JfTUVTU0FHRVMuTElTVF9JTlNJREUsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZS50b1N0cmluZygpLFxuICAgICAgICAgICAgICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgIGRlZmF1bHQ6XG4gICAgICAgICAgICAgICAgICAgIHRyeSB7XG4gICAgICAgICAgICAgICAgICAgICAgaWYgKChvYmogYXMgUmVjb3JkPHN0cmluZywgYW55PilbcHJvcF0pXG4gICAgICAgICAgICAgICAgICAgICAgICBlcnIgPSAob2JqIGFzIFJlY29yZDxzdHJpbmcsIGFueT4pW3Byb3BdLmhhc0Vycm9ycygpO1xuICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChlOiBhbnkpIHtcbiAgICAgICAgICAgICAgICAgICAgICBjb25zb2xlLndhcm4oXG4gICAgICAgICAgICAgICAgICAgICAgICBzZihcIk1vZGVsIHNob3VsZCBiZSB2YWxpZGF0YWJsZSBidXQgaXRzIG5vdFwiKSxcbiAgICAgICAgICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9KTtcblxuICAgICAgICAgICAgaWYgKGVycikge1xuICAgICAgICAgICAgICBhY2MgPSBhY2MgfHwge307XG4gICAgICAgICAgICAgIGFjY1twcm9wXSA9IGVycjtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIHJldHVybiBhY2M7XG4gICAgICAgICAgfSwgdW5kZWZpbmVkKTtcblxuICAgICAgaWYgKGVycnMpIHtcbiAgICAgICAgYWNjdW0gPSBhY2N1bSB8fCB7fTtcbiAgICAgICAgYWNjdW1bZGVjb3JhdGVkUHJvcGVydHkucHJvcC50b1N0cmluZygpXSA9IGVycnM7XG4gICAgICB9XG5cbiAgICAgIHJldHVybiBhY2N1bTtcbiAgICB9LFxuICAgIHVuZGVmaW5lZCxcbiAgKTtcbiAgcmV0dXJuIHJlc3VsdCA/IG5ldyBNb2RlbEVycm9yRGVmaW5pdGlvbihyZXN1bHQpIDogdW5kZWZpbmVkO1xufVxuXG5sZXQgbW9kZWxCdWlsZGVyRnVuY3Rpb246IE1vZGVsQnVpbGRlckZ1bmN0aW9uIHwgdW5kZWZpbmVkO1xubGV0IGFjdGluZ01vZGVsUmVnaXN0cnk6IEJ1aWxkZXJSZWdpc3RyeTxhbnk+O1xubGV0IHNlcmlhbGl6ZXI6IFNlcmlhbGl6ZXI8YW55PjtcbmxldCBoYXNoaW5nRnVuY3Rpb246IGFueTtcblxuLyoqXG4gKiBAc3VtbWFyeSBBYnN0cmFjdCBjbGFzcyByZXByZXNlbnRpbmcgYSBWYWxpZGF0YWJsZSBNb2RlbCBvYmplY3RcbiAqIEBkZXNjcmlwdGlvbiBNZWFudCB0byBiZSB1c2VkIGFzIGEgYmFzZ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gICAgICB9LFxuICAgICAgICB1bmRlZmluZWQsXG4gICAgICApO1xuXG4gICAgICBlcnJzID1cbiAgICAgICAgZXJycyB8fFxuICAgICAgICBPYmplY3Qua2V5cyhvYmopXG4gICAgICAgICAgLmZpbHRlcigoaykgPT4gIWVycnMgfHwgIWVycnNba10pXG4gICAgICAgICAgLnJlZHVjZSgoYWNjOiBSZWNvcmQ8c3RyaW5nLCBhbnk+IHwgdW5kZWZpbmVkLCBwcm9wKSA9PiB7XG4gICAgICAgICAgICBsZXQgZXJyOiBFcnJvcnM7XG4gICAgICAgICAgICAvLyBpZiBhIG5lc3RlZCBNb2RlbFxuICAgICAgICAgICAgY29uc3QgYWxsRGVjb3JhdG9ycyA9IGdldFByb3BlcnR5RGVjb3JhdG9ycyhcbiAgICAgICAgICAgICAgVmFsaWRhdGlvbktleXMuUkVGTEVDVCxcbiAgICAgICAgICAgICAgb2JqLFxuICAgICAgICAgICAgICBwcm9wLFxuICAgICAgICAgICAgKS5kZWNvcmF0b3JzO1xuICAgICAgICAgICAgY29uc3QgZGVjb3JhdG9ycyA9IGFsbERlY29yYXRvcnMuZmlsdGVyKFxuICAgICAgICAgICAgICAoZCkgPT5cbiAgICAgICAgICAgICAgICBbTW9kZWxLZXlzLlRZUEUsIFZhbGlkYXRpb25LZXlzLlRZUEVdLmluZGV4T2YoZC5rZXkpICE9PSAtMSxcbiAgICAgICAgICAgICk7XG4gICAgICAgICAgICBpZiAoIWRlY29yYXRvcnMgfHwgIWRlY29yYXRvcnMubGVuZ3RoKSByZXR1cm4gYWNjO1xuICAgICAgICAgICAgY29uc3QgZGVjID0gZGVjb3JhdG9ycy5wb3AoKSBhcyBEZWNvcmF0b3JNZXRhZGF0YTtcbiAgICAgICAgICAgIGNvbnN0IGNsYXp6ID0gZGVjLnByb3BzLm5hbWVcbiAgICAgICAgICAgICAgPyBbZGVjLnByb3BzLm5hbWVdXG4gICAgICAgICAgICAgIDogQXJyYXkuaXNBcnJheShkZWMucHJvcHMuY3VzdG9tVHlwZXMpXG4gICAgICAgICAgICAgICAgPyBkZWMucHJvcHMuY3VzdG9tVHlwZXNcbiAgICAgICAgICAgICAgICA6IFtkZWMucHJvcHMuY3VzdG9tVHlwZXNdO1xuICAgICAgICAgICAgY29uc3QgcmVzZXJ2ZWQgPSBPYmplY3QudmFsdWVzKFJlc2VydmVkTW9kZWxzKS5tYXAoKHYpID0+XG4gICAgICAgICAgICAgIHYudG9Mb3dlckNhc2UoKSxcbiAgICAgICAgICAgICkgYXMgc3RyaW5nW107XG5cbiAgICAgICAgICAgIGNsYXp6LmZvckVhY2goKGM6IHN0cmluZykgPT4ge1xuICAgICAgICAgICAgICBpZiAocmVzZXJ2ZWQuaW5kZXhPZihjLnRvTG93ZXJDYXNlKCkpID09PSAtMSkge1xuICAgICAgICAgICAgICAgIHN3aXRjaCAoYykge1xuICAgICAgICAgICAgICAgICAgY2FzZSBcIkFycmF5XCI6XG4gICAgICAgICAgICAgICAgICBjYXNlIFwiU2V0XCI6XG4gICAgICAgICAgICAgICAgICAgIGlmIChhbGxEZWNvcmF0b3JzLmxlbmd0aCkge1xuICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IGxpc3REZWMgPSBhbGxEZWNvcmF0b3JzLmZpbmQoXG4gICAgICAgICAgICAgICAgICAgICAgICAoZCkgPT4gZC5rZXkgPT09IFZhbGlkYXRpb25LZXlzLkxJU1QsXG4gICAgICAgICAgICAgICAgICAgICAgKTtcbiAgICAgICAgICAgICAgICAgICAgICBpZiAobGlzdERlYykge1xuICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgZSA9XG4gICAgICAgICAgICAgICAgICAgICAgICAgIGMgPT09IFwiQXJyYXlcIlxuICAgICAgICAgICAgICAgICAgICAgICAgICAgID8gKG9iaiBhcyBSZWNvcmQ8c3RyaW5nLCBhbnk+KVtwcm9wXS5maW5kKFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAoYzogVmFsaWRhdGFibGUpID0+IGMuaGFzRXJyb3JzKCksXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICApXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgOiAob2JqIGFzIFJlY29yZDxzdHJpbmcsIGFueT4pW3Byb3BdXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC52YWx1ZXMoKVxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAuZmluZCgoYzogVmFsaWRhdGFibGUpID0+IGMuaGFzRXJyb3JzKCkpO1xuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGUpXG4gICAgICAgICAgICAgICAgICAgICAgICAgIGVyciA9IHNmKFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIERFRkFVTFRfRVJST1JfTUVTU0FHRVMuTElTVF9JTlNJREUsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZS50b1N0cmluZygpLFxuICAgICAgICAgICAgICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgIGRlZmF1bHQ6XG4gICAgICAgICAgICAgICAgICAgIHRyeSB7XG4gICAgICAgICAgICAgICAgICAgICAgaWYgKChvYmogYXMgUmVjb3JkPHN0cmluZywgYW55PilbcHJvcF0pXG4gICAgICAgICAgICAgICAgICAgICAgICBlcnIgPSAob2JqIGFzIFJlY29yZDxzdHJpbmcsIGFueT4pW3Byb3BdLmhhc0Vycm9ycygpO1xuICAgICAgICAgICAgICAgICAgICB9IGNhdGNoIChlOiBhbnkpIHtcbiAgICAgICAgICAgICAgICAgICAgICBjb25zb2xlLndhcm4oXG4gICAgICAgICAgICAgICAgICAgICAgICBzZihcIk1vZGVsIHNob3VsZCBiZSB2YWxpZGF0YWJsZSBidXQgaXRzIG5vdFwiKSxcbiAgICAgICAgICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVx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biAgICogQHN1bW1hcnkgUmV0cmlldmVzIHRoZSBjdXJyZW50IGRlZmluZWQge0BsaW5rIEhhc2hpbmdGdW5jdGlvbn1cbiAgICpcbiAgICovXG4gIHByaXZhdGUgc3RhdGljIGdldEhhc2hpbmdGdW5jdGlvbigpIHtcbiAgICBpZiAoIWhhc2hpbmdGdW5jdGlvbikgaGFzaGluZ0Z1bmN0aW9uID0gaGFzaE9iajtcbiAgICByZXR1cm4gaGFzaGluZ0Z1bmN0aW9uO1xuICB9XG59XG4iXX0=
import { Model } from "./Model";
import { ModelKeys } from "../utils/constants";
import { isModel } from "../reflection/utils";
import { sf } from "../utils/strings";
import { isModel } from "./utils";
/**

@@ -76,2 +76,2 @@ * @summary Util class to enable serialization and correct rebuilding

//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNyYy9tb2RlbC9SZWdpc3RyeS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsS0FBSyxFQUFFLE1BQU0sU0FBUyxDQUFDO0FBR2hDLE9BQU8sRUFBRSxTQUFTLEVBQUUsTUFBTSxvQkFBb0IsQ0FBQztBQUMvQyxPQUFPLEVBQUUsT0FBTyxFQUFFLE1BQU0scUJBQXFCLENBQUM7QUFDOUMsT0FBTyxFQUFFLEVBQUUsRUFBRSxNQUFNLGtCQUFrQixDQUFDO0FBWXRDOzs7Ozs7Ozs7O0dBVUc7QUFDSCxNQUFNLE9BQU8sb0JBQW9CO0lBSy9CLFlBQ0UsWUFBb0IsU0FBUyxDQUFDLE1BQU0sRUFDcEMsZUFBc0QsT0FBTztRQU52RCxVQUFLLEdBQXdDLEVBQUUsQ0FBQztRQVF0RCxJQUFJLENBQUMsWUFBWSxHQUFHLFlBQVksQ0FBQztRQUNqQyxJQUFJLENBQUMsU0FBUyxHQUFHLFNBQVMsQ0FBQztJQUM3QixDQUFDO0lBRUQ7Ozs7T0FJRztJQUNILF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4cG9ydCBmdW5jdGlvbiBidWxrTW9kZWxSZWdpc3RlcjxUIGV4dGVuZHMgTW9kZWw+KFxuICAuLi5tb2RlbHM6IChDb25zdHJ1Y3RvcjxUPiB8IHsgbmFtZTogc3RyaW5nOyBjb25zdHJ1Y3RvcjogQ29uc3RydWN0b3I8VD4gfSlbXVxuKSB7XG4gIG1vZGVscy5mb3JFYWNoKFxuICAgIChtOiBDb25zdHJ1Y3RvcjxUPiB8IHsgbmFtZTogc3RyaW5nOyBjb25zdHJ1Y3RvcjogQ29uc3RydWN0b3I8VD4gfSkgPT4ge1xuICAgICAgY29uc3QgY29uc3RydWN0b3I6IENvbnN0cnVjdG9yPFQ+ID0gKFxuICAgICAgICBtLmNvbnN0cnVjdG9yID8gbS5jb25zdHJ1Y3RvciA6IG1cbiAgICAgICkgYXMgQ29uc3RydWN0b3I8VD47XG4gICAgICBNb2RlbC5yZWdpc3Rlcihjb25zdHJ1Y3RvciwgKG0gYXMgQ29uc3RydWN0b3I8VD4pLm5hbWUpO1xuICAgIH0sXG4gICk7XG59XG4iXX0=
export * from "./constants";
export * from "./dates";
export * from "./equality";
export * from "./hashing";

@@ -5,0 +4,0 @@ export * from "./serialization";

export * from "./constants";
export * from "./dates";
export * from "./equality";
export * from "./hashing";

@@ -10,2 +9,2 @@ export * from "./serialization";

//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNyYy91dGlscy9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxjQUFjLGFBQWEsQ0FBQztBQUM1QixjQUFjLFNBQVMsQ0FBQztBQUN4QixjQUFjLFlBQVksQ0FBQztBQUMzQixjQUFjLFdBQVcsQ0FBQztBQUMxQixjQUFjLGlCQUFpQixDQUFDO0FBQ2hDLGNBQWMsWUFBWSxDQUFDO0FBQzNCLGNBQWMsaUJBQWlCLENBQUM7QUFDaEMsY0FBYyxXQUFXLENBQUMiLCJmaWxl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1xuIl19

@@ -14,3 +14,3 @@ import "reflect-metadata";

*/
export declare function required(message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function required(message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -27,3 +27,3 @@ * @summary Defines a minimum value for the property

*/
export declare function min(value: number | Date | string, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function min(value: number | Date | string, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -40,3 +40,3 @@ * @summary Defines a maximum value for the property

*/
export declare function max(value: number | Date | string, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function max(value: number | Date | string, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -53,3 +53,3 @@ * @summary Defines a step value for the property

*/
export declare function step(value: number, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function step(value: number, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -66,3 +66,3 @@ * @summary Defines a minimum length for the property

*/
export declare function minlength(value: number, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function minlength(value: number, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -79,3 +79,3 @@ * @summary Defines a maximum length for the property

*/
export declare function maxlength(value: number, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function maxlength(value: number, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -92,3 +92,3 @@ * @summary Defines a RegExp pattern the property must respect

*/
export declare function pattern(value: RegExp | string, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function pattern(value: RegExp | string, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -104,3 +104,3 @@ * @summary Defines the property as an email

*/
export declare function email(message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function email(message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -116,3 +116,3 @@ * @summary Defines the property as an URL

*/
export declare function url(message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function url(message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -129,3 +129,3 @@ * @summary Enforces type verification

*/
export declare function type(types: string[] | string, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function type(types: string[] | string, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -132,0 +132,0 @@ * @summary Date Handler Decorator

import "reflect-metadata";
import { ListValidator } from "./Validators/ListValidator";
import { Validation } from "./Validation";
import { metadata } from "../reflection/decorators";
import { DEFAULT_ERROR_MESSAGES, DEFAULT_PATTERNS, ValidationKeys, } from "./Validators/constants";

@@ -10,2 +9,3 @@ import { sf } from "../utils/strings";

import { getValidationKey } from "./utils";
import { metadata } from "@decaf-ts/reflection";
/**

@@ -309,2 +309,2 @@ * @summary Marks the property as required.

//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNyYy92YWxpZGF0aW9uL2RlY29yYXRvcnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxrQkFBa0IsQ0FBQztBQUMxQixPQUFPLEVBQUUsYUFBYSxFQUFFLE1BQU0sNEJBQTRCLENBQUM7QUFDM0QsT0FBTyxFQUFFLFVBQVUsRUFBRSxNQUFNLGNBQWMsQ0FBQztBQUUxQyxPQUFPLEVBQUUsUUFBUSxFQUFFLE1BQU0sMEJBQTBCLENBQUM7QUFDcEQsT0FBTyxFQUNMLHNCQUFzQixFQUN0QixnQkFBZ0IsRUFDaEIsY0FBYyxHQUNmLE1BQU0sd0JBQXdCLENBQUM7QUFDaEMsT0FBTyxFQUFFLEVBQUUsRUFBRSxNQUFNLGtCQUFrQixDQUFDO0FBRXRDLE9BQU8sRUFBRSxpQkFBaUIsRUFBRSxNQUFNLGdDQUFnQyxDQUFDO0FBR25FLE9BQU8sRUFBRSxTQUFTLEVBQUUsTUFBTSxVQUFVLENBQUM7QUFDckMsT0FBTyxFQUFFLGd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XG5cbiAgICBjb25zdCB2YWx1ZXMgPSBuZXcgV2Vha01hcCgpO1xuXG4gICAgT2JqZWN0LmRlZmluZVByb3BlcnR5KHRhcmdldCwgcHJvcGVydHlLZXksIHtcbiAgICAgIGNvbmZpZ3VyYWJsZTogZmFsc2UsXG4gICAgICBzZXQodGhpczogYW55LCBuZXdWYWx1ZTogc3RyaW5nIHwgRGF0ZSkge1xuICAgICAgICBjb25zdCBkZXNjcmlwdG9yID0gT2JqZWN0LmdldE93blByb3BlcnR5RGVzY3JpcHRvcih0aGlzLCBwcm9wZXJ0eUtleSk7XG4gICAgICAgIGlmICghZGVzY3JpcHRvciB8fCBkZXNjcmlwdG9yLmNvbmZpZ3VyYWJsZSlcbiAgICAgICAgICBPYmplY3QuZGVmaW5lUHJvcGVydHkodGhpcywgcHJvcGVydHlLZXksIHtcbiAgICAgICAgICAgIGVudW1lcmFibGU6IHRydWUsXG4gICAgICAgICAgICBjb25maWd1cmFibGU6IGZhbHNlLFxuICAgICAgICAgICAgZ2V0OiAoKSA9PiB2YWx1ZXMuZ2V0KHRoaXMpLFxuICAgICAgICAgICAgc2V0OiAobmV3VmFsdWU6IHN0cmluZyB8IERhdGUgfCBudW1iZXIpID0+IHtcbiAgICAgICAgICAgICAgbGV0IHZhbDogRGF0ZSB8IHVuZGVmaW5lZDtcbiAgICAgICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgICAgICB2YWwgPSBwYXJzZURhdGUoZm9ybWF0LCBuZXdWYWx1ZSk7XG4gICAgICAgICAgICAgICAgdmFsdWVzLnNldCh0aGlzLCB2YWwpO1xuICAgICAgICAgICAgICB9IGNhdGNoIChlOiBhbnkpIHtcbiAgICAgICAgICAgICAgICBjb25zb2xlLmVycm9yKHNmKFwiRmFpbGVkIHRvIHBhcnNlIGRhdGU6IHswfVwiLCBlLm1lc3NhZ2UgfHwgZSkpO1xuICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9LFxuICAgICAgICAgIH0pO1xuICAgICAgICB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gKlxuICogQGZ1bmN0aW9uIHNldFxuICpcbiAqIEBtZW1iZXJPZiBtb2R1bGU6ZGVjb3JhdG9yLXZhbGlkYXRpb24uRGVjb3JhdG9ycy5WYWxpZGF0aW9uXG4gKiBAY2F0ZWdvcnkgRGVjb3JhdG9yc1xuICovXG5leHBvcnQgZnVuY3Rpb24gc2V0KFxuICBjbGF6ejogTW9kZWxDb25zdHJ1Y3Rvcjxhbnk+LFxuICBtZXNzYWdlOiBzdHJpbmcgPSBERUZBVUxUX0VSUk9SX01FU1NBR0VTLkxJU1QsXG4gIHZhbGlkYXRvcj86IENvbnN0cnVjdG9yPFZhbGlkYXRvcj4sXG4pIHtcbiAgcmV0dXJuICh0YXJnZXQ6IGFueSwgcHJvcGVydHlLZXk6IHN0cmluZyk6IGFueSA9PiB7XG4gICAgbGlzdChjbGF6eiwgXCJTZXRcIiwgbWVzc2FnZSwgdmFsaWRhdG9yKSh0YXJnZXQsIHByb3BlcnR5S2V5KTtcbiAgfTtcbn1cbiJdfQ==

@@ -0,1 +1,2 @@

import { DecoratorMetadata } from "@decaf-ts/reflection";
/**

@@ -19,11 +20,2 @@ * @summary Validator Error type

/**
* @summary Type for decorator metadata
* @memberOf module:decorator-validation.Reflection
* @category Reflection
*/
export type DecoratorMetadata = {
key: string;
props: Record<string, any>;
};
/**
* @summary Type for a validator property decorator definition

@@ -30,0 +22,0 @@ * @memberOf module:decorator-validation.Validation

export {};
//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNyYy92YWxpZGF0aW9uL3R5cGVzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiIiLCJmaWxlIjoidmFsaWRhdGlvbi90eXBlcy5qcyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogQHN1bW1hcnkgVmFsaWRhdG9yIEVycm9yIHR5cGVcbiAqIEBtZW1iZXJPZiBtb2R1bGU6ZGVjb3JhdG9yLXZhbGlkYXRpb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luZywgUmVjb3JkPHN0cmluZywgRXJyb3JzPj47XG4iXX0=
import { Validation } from "../Validation";
import { apply, metadata } from "../../reflection";
import { ValidationKeys } from "./constants";
import { getValidationKey } from "../utils";
import { apply, metadata } from "@decaf-ts/reflection";
/**

@@ -28,2 +28,2 @@ * @summary Marks the class as a validator for a certain key.

//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNyYy92YWxpZGF0aW9uL1ZhbGlkYXRvcnMvZGVjb3JhdG9ycy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFDQSxPQUFPLEVBQUUsVUFBVSxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBRzNDLE9BQU8sRUFBRSxLQUFLLEVBQUUsUUFBUSxFQUFFLE1BQU0sa0JBQWtCLENBQUM7QUFDbkQsT0FBTyxFQUFFLGNBQWMsRUFBRSxNQUFNLGFBQWEsQ0FBQztBQUM3QyxPQUFPLEVBQUUsZ0JBQWdCLEVBQUUsTUFBTSxVQUFVLENBQUM7QUFFNUM7Ozs7Ozs7OztHQVNHO0FBQ0gsTUFBTSxVQUFVLFNBQVMsQ0FBc0IsR0FBRyxJQUFjO0lBQzlELE9BQU8sS0FBSyxDQUNWLENBQUMsQ0FBQyxRQUF3QixFQUFFLEVBQUU7UUFDNUIsSUFBSSxDQUFDLE9BQU8sQ0FBQyxDQUFDLENBQVMsRUFBRSxFQUFFO1lBQ3pCLFVBQVUsQ0FBQyxRQUFRLENBQUM7Z0JBQ2xCLFNBQVMsRUFBRSxRQUFRO2dCQUNuQixhQUFhLEVBQUUsQ0FBQztnQkFDaEIsSUFBSSxFQUFFLElBQUk7YUFDWSxDQUFDLENBQUM7UUFDNUIsQ0FBQyxDQUFDLENBQUM7UUFDSCxPQUFPLFFBQVEsQ0FBQztJQUNsQixDQUFDLENBQW1CLEVBQ3BCLFFBQVEsQ0FBQyxnQkFBZ0IsQ0FBQyxjQUFjLENBQUMsU0FB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B0aGUge0BsaW5rIFZhbGlkYXRpb259IHdpdGggdGhlIHByb3ZpZGVkIGtleVxuICpcbiAqIEBwYXJhbSB7c3RyaW5nfSBrZXlzIHRoZSB2YWxpZGF0aW9uIGtleVxuICpcbiAqIEBmdW5jdGlvbiB2YWxpZGF0b3JcbiAqXG4gKiBAY2F0ZWdvcnkgRGVjb3JhdG9yc1xuICovXG5leHBvcnQgZnVuY3Rpb24gdmFsaWRhdG9yPFQgZXh0ZW5kcyBWYWxpZGF0b3I+KC4uLmtleXM6IHN0cmluZ1tdKSB7XG4gIHJldHVybiBhcHBseShcbiAgICAoKG9yaWdpbmFsOiBDb25zdHJ1Y3RvcjxUPikgPT4ge1xuICAgICAga2V5cy5mb3JFYWNoKChrOiBzdHJpbmcpID0+IHtcbiAgICAgICAgVmFsaWRhdGlvbi5yZWdpc3Rlcih7XG4gICAgICAgICAgdmFsaWRhdG9yOiBvcmlnaW5hbCxcbiAgICAgICAgICB2YWxpZGF0aW9uS2V5OiBrLFxuICAgICAgICAgIHNhdmU6IHRydWUsXG4gICAgICAgIH0gYXMgVmFsaWRhdG9yRGVmaW5pdGlvbik7XG4gICAgICB9KTtcbiAgICAgIHJldHVybiBvcmlnaW5hbDtcbiAgICB9KSBhcyBDbGFzc0RlY29yYXRvcixcbiAgICBtZXRhZGF0YShnZXRWYWxpZGF0aW9uS2V5KFZhbGlkYXRpb25LZXlzLlZBTElEQVRPUiksIGtleXMpLFxuICApO1xufVxuIl19

@@ -12,6 +12,6 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {

import { DEFAULT_ERROR_MESSAGES, ValidationKeys } from "./constants";
import { evaluateDesignTypes } from "../../reflection/utils";
import { validator } from "./decorators";
import { ModelKeys } from "../../utils";
import { Validation } from "../Validation";
import { evaluateDesignTypes } from "@decaf-ts/reflection";
/**

@@ -63,2 +63,2 @@ * @summary Required Validator

//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2Vz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GES } from "./constants";
import { sf } from "../../utils/strings";
import { checkTypes } from "../../reflection/utils";
import { checkTypes } from "@decaf-ts/reflection";
/**

@@ -49,2 +49,2 @@ * @summary Base Implementation for Validators

//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNyYy92YWxpZGF0aW9uL1ZhbGlkYXRvcnMvVmFsaWRhdG9yLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUNBLE9BQU8sRUFBRSxzQkFBc0IsRUFBRSxNQUFNLGFBQWEsQ0FBQztBQUNyRCxPQUFPLEVBQUUsRUFBRSxFQUFFLE1BQU0scUJBQXFCLENBQUM7QUFDekMsT0FBTyxFQUFFLFVBQVUsRUFBRSxNQUFNLHdCQUF3QixDQUFDO0FBRXBEOzs7Ozs7Ozs7OztHQVdHO0FBQ0gsTUFBTSxPQUFnQixTQUFTO0lBSTdCLFlBQ0UsVUFBa0Isc0JBQXNCLENBQUMsT0FBTyxFQUNoRCxHQUFHLGFBQXVCO1FBRTFCLElBQUksQ0FBQyxPQUFPLEdBQUcsT0FBTyxDQUFDO1FBRXZCLElBQUksYUFBYSxDQUFDLE1BQU07WUFBRSxJQUFJLENBQUMsYUFBYSxHQUFHLGFBQWEsQ0FBQztRQUM3RCxJQUFJLElBQUksQ0FBQyxhQUFhO1lBQ3BCLElBQUksQ0FBQyxTQUFTLEdBQUcsSUFBSSxDQUFDLHFCQUFxQixDQUFDLElBQUksQ0FBQyxTQUFTLENBQUMsSUFBSSxDQUFDLElBQUksQ0FBQyxDQUFDLENBQUM7SUFDM0UsQ0FBQztJQUVEOzs7OztPQUtHO0lBQ08sVUFBVSxDQUFDLE9BQWUsRUFBRSxHQUFHLElBQVc7UUFDbEQsT0FBTyxFQUFFLENBQUMsT0FBTyxFQUFFLEdBQUcsSUFBSSxDQUFDLENBQUM7SUFDOUIsQ0FBQztJQUVEOzs7O09BSUc7SUFDSyxxQkFBcUIsQ0FDM0IsT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cy5hY2NlcHRlZFR5cGVzKSlcbiAgICAgICAgcmV0dXJuIHRoaXMuZ2V0TWVzc2FnZShcbiAgICAgICAgICBERUZBVUxUX0VSUk9SX01FU1NBR0VTLlRZUEUsXG4gICAgICAgICAgdGhpcy5hY2NlcHRlZFR5cGVzLmpvaW4oXCIsIFwiKSxcbiAgICAgICAgICB0eXBlb2YgdmFsdWUsXG4gICAgICAgICk7XG4gICAgICByZXR1cm4gdW5ib3VuZCh2YWx1ZSwgLi4uYXJncyk7XG4gICAgfS5iaW5kKHRoaXMpO1xuICB9XG5cbiAgLyoqXG4gICAqIEBzdW1tYXJ5IFZhbGlkYXRlcyBhbiBhdHRyaWJ1dGVcbiAgICogQHBhcmFtIHthbnl9IHZhbHVlXG4gICAqIEBwYXJhbSB7YW55W119IGFyZ3NcbiAgICpcbiAgICogQGFic3RyYWN0XG4gICAqXG4gICAqIEBzZWUgTW9kZWwjaGFzRXJyb3JzXG4gICAqL1xuICBwdWJsaWMgYWJzdHJhY3QgaGFzRXJyb3JzKHZhbHVlOiBhbnksIC4uLmFyZ3M6IGFueVtdKTogRXJyb3JzO1xufVxuIl19

@@ -63,5 +63,4 @@ /**

export * from "./utils";
export * from "./reflection";
export * from "./validation";
export * from "./model";
export declare const VERSION = "1.1.1";
export declare const VERSION = "1.1.3";

@@ -8,1 +8,2 @@ export * from "./constants";

export * from "./types";
export * from "./utils";
export * from "./constants";
export * from "./dates";
export * from "./equality";
export * from "./hashing";

@@ -5,0 +4,0 @@ export * from "./serialization";

@@ -14,3 +14,3 @@ import "reflect-metadata";

*/
export declare function required(message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function required(message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -27,3 +27,3 @@ * @summary Defines a minimum value for the property

*/
export declare function min(value: number | Date | string, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function min(value: number | Date | string, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -40,3 +40,3 @@ * @summary Defines a maximum value for the property

*/
export declare function max(value: number | Date | string, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function max(value: number | Date | string, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -53,3 +53,3 @@ * @summary Defines a step value for the property

*/
export declare function step(value: number, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function step(value: number, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -66,3 +66,3 @@ * @summary Defines a minimum length for the property

*/
export declare function minlength(value: number, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function minlength(value: number, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -79,3 +79,3 @@ * @summary Defines a maximum length for the property

*/
export declare function maxlength(value: number, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function maxlength(value: number, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -92,3 +92,3 @@ * @summary Defines a RegExp pattern the property must respect

*/
export declare function pattern(value: RegExp | string, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function pattern(value: RegExp | string, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -104,3 +104,3 @@ * @summary Defines the property as an email

*/
export declare function email(message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function email(message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -116,3 +116,3 @@ * @summary Defines the property as an URL

*/
export declare function url(message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function url(message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -129,3 +129,3 @@ * @summary Enforces type verification

*/
export declare function type(types: string[] | string, message?: string): import("../reflection/decorators").CustomDecorator<V>;
export declare function type(types: string[] | string, message?: string): import("@decaf-ts/reflection").CustomDecorator<V>;
/**

@@ -132,0 +132,0 @@ * @summary Date Handler Decorator

@@ -0,1 +1,2 @@

import { DecoratorMetadata } from "@decaf-ts/reflection";
/**

@@ -19,11 +20,2 @@ * @summary Validator Error type

/**
* @summary Type for decorator metadata
* @memberOf module:decorator-validation.Reflection
* @category Reflection
*/
export type DecoratorMetadata = {
key: string;
props: Record<string, any>;
};
/**
* @summary Type for a validator property decorator definition

@@ -30,0 +22,0 @@ * @memberOf module:decorator-validation.Validation

{
"name": "@decaf-ts/decorator-validation",
"version": "1.1.2",
"version": "1.1.4",
"description": "simple decorator based validation engine",

@@ -95,4 +95,5 @@ "type": "module",

"peerDependencies": {
"@decaf-ts/reflection": "latest",
"reflect-metadata": "^0.2.1"
}
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc