@elyx-code/project-logic-tree 0.0.6031 → 0.0.6033
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.umd.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(u,r){typeof exports=="object"&&typeof module<"u"?r(exports):typeof define=="function"&&define.amd?define(["exports"],r):(u=typeof globalThis<"u"?globalThis:u||self,r(u["@elyx-code/project-logic-tree"]={}))})(this,function(u){"use strict";var y5=Object.defineProperty;var h5=(u,r,V)=>r in u?y5(u,r,{enumerable:!0,configurable:!0,writable:!0,value:V}):u[r]=V;var c=(u,r,V)=>(h5(u,typeof r!="symbol"?r+"":r,V),V);var r=(n=>(n.CustomEntity="custom-entity",n.BuiltInBaseEntity="built-in-base-entity",n.Project="project",n.InstalledProject="installed-project",n.GlobalEvent="global-event",n.DataType="data-type",n.FunctionCall="function-call",n.FunctionDeclaration="function-declaration",n.ActionDescriptor="action-descriptor",n.ValueDescriptor="value-descriptor",n.ArgumentDeclaration="argument-declaration",n.InputMap="input-map",n.ReturnStatement="return-statement",n.BreakStatement="break-statement",n.ContinueStatement="continue-statement",n.ReturnDeclaration="return-declaration",n.OutputMap="output-map",n.PrimitiveEntity="primitive-entity",n.PrimitiveValue="primitive-value",n.Property="property",n.Operation="operation",n.Condition="condition",n.VariableDeclaration="variable-declaration",n.VariableInstance="variable-instance",n.Search="search",n.Loop="loop",n.InternalCall="internal-call",n.GenericReference="generic-reference",n))(r||{}),V=(n=>(n.HTTP_ENDPOINT="BUILT_IN_HTTP_ENDPOINT_ENTITY",n.RELATIONAL_DATABASE="BUILT_IN_RELATIONAL_DATABASE_ENTITY",n.PERSISTED_ENTITY="BUILT_IN_PERSISTED_ENTITY_ENTITY",n.CRON_JOB="BUILT_IN_CRON_JOB_ENTITY",n.EXECUTION="BUILT_IN_EXECUTION_ENTITY",n.KEY_VALUE_PARAM="BUILT_IN_KEY_VALUE_PARAM_ENTITY",n))(V||{}),qe=(n=>(n.CurrentDateAndTime="current-date-and-time",n.Unique="unique",n.Random="random",n))(qe||{}),Ot=(n=>(n.DeletePersistedEntity="base-delete-persisted-entity",n.SoftDeletePersistedEntity="base-soft-delete-persisted-entity",n.AbortExecution="base-abort-execution",n))(Ot||{}),U=(n=>(n.Fixed="fixed",n.None="none",n.Dynamic="dynamic",n))(U||{}),M=(n=>(n.FixedArguments="fixed-arguments",n.FixedReturns="fixed-returns",n.ReturnedError="returned-error",n.OngoingProcessExecution="ongoing-process-execution",n))(M||{}),A=(n=>(n.EntityTemplate="entity-template",n.ActionDescriptor="action-descriptor",n.String="string",n.Number="number",n.Boolean="boolean",n.Null="null",n.Enum="enum",n.JSON="json",n.Date="date",n.UUID="uuid",n.File="file",n))(A||{}),lt=(n=>(n.Addition="addition",n.Substraction="substraction",n.Multiplication="multiplication",n.Division="division",n.Remainder="remainder",n.Exponentiation="exponentiation",n))(lt||{}),Ae=(n=>(n.Join="string-join",n.Split="stringSsplit",n.DeleteLast="string-delete-last",n.DeleteFirst="string-delete-first",n.DeleteIndex="string-delete-index",n.AddIndex="string-add-index",n.ReplaceFirst="string-replace-first",n.ReplaceLast="string-replace-last",n.ReplaceIndex="string-replace-index",n.ReplaceSingleMatch="string-replace-single-match",n.ReplaceAllMatches="string-replace-all-matches",n.GetIndex="string-get-index",n.GetFirst="string-get-first",n.GetLast="string-get-last",n.Append="string-append",n.Prepend="string-prepend",n))(Ae||{}),W=(n=>(n.Join="list-join",n.Split="list-split",n.DeleteLast="list-delete-last",n.DeleteFirst="list-delete-first",n.DeleteIndex="list-delete-index",n.AddIndex="list-add-index",n.ReplaceFirst="list-replace-first",n.ReplaceLast="list-replace-last",n.ReplaceIndex="list-replace-index",n.ReplaceSingleMatch="list-replace-single-match",n.ReplaceAllMatches="list-replace-all-matches",n.GetIndex="list-get-index",n.GetFirst="list-get-first",n.GetLast="list-get-last",n.Append="list-append",n.Prepend="list-prepend",n))(W||{}),Oe=(n=>(n.Parallel="parallel",n.Sequential="sequential",n.Wait="wait",n))(Oe||{}),Ze=(n=>(n.CreateNewInstance="create-new-instance",n.Validate="validate",n))(Ze||{}),Xe=(n=>(n.HttpRequest="base-http-request",n))(Xe||{}),_e=(n=>(n.Equal="equal",n.NotEqual="not-equal",n.And="and",n.Or="or",n.LessThan="less-than",n.MoreThan="more-than",n.LessThanOrEqual="less-than-or-equal",n.MoreThanOrEqual="more-than-or-equal",n))(_e||{}),Nt=(n=>(n.Empty="empty",n.NotEmpty="not-empty",n))(Nt||{}),Q=(n=>(n.ManualFlow="manual-flow-loop",n.Counted="counted-loop",n.List="list-loop",n.ObjectKeys="object-keys-loop",n.ObjectValues="object-values-loop",n.String="string-loop",n))(Q||{}),Ue=(n=>(n.OrDataTypeGroup="or-data-type-group",n.AndDataTypeGroup="and-data-type-group",n.DynamicArgumentTypes="dynamic-argument-types",n.DynamicReturnTypes="dynamic-return-types",n))(Ue||{}),on=(n=>(n.PROJECT_PUBLICATION_COMPLETED="GLOBAL_EVENT_PROJECT_PUBLICATION_COMPLETED",n))(on||{}),Hd=(n=>(n.Error="error",n.Task="task",n.Return="return",n))(Hd||{});const zn=[r.VariableDeclaration,r.VariableInstance,r.InputMap,r.ReturnDeclaration],hI=[r.VariableDeclaration,r.VariableInstance,r.InputMap,r.ReturnDeclaration],Ve=[r.VariableDeclaration,r.VariableInstance,r.ArgumentDeclaration,r.OutputMap],fI=[r.VariableDeclaration,r.VariableInstance,r.ArgumentDeclaration,r.OutputMap],Yd=[...zn,...Ve],xe=[r.VariableDeclaration,r.VariableInstance],Lr=[r.GlobalEvent],$e=[r.Operation,r.FunctionCall,r.Condition,r.Search,r.VariableDeclaration,r.VariableInstance,r.InternalCall,r.Loop],Oo=[r.Operation,r.FunctionCall,r.Condition,r.Search,r.VariableDeclaration,r.VariableInstance,r.Loop],Me=[r.FunctionDeclaration,...Lr],Pn=[...$e,r.ReturnStatement,r.BreakStatement,r.ContinueStatement],Co=[...Oo,r.ReturnStatement,r.BreakStatement,r.ContinueStatement],ln=[...$e,...Me],zd=[...Oo,...Me],mI=[...Pn,...Me],TI=[...Co,...Me],ct=[...Me,r.Loop],Ne=[r.ReturnStatement,r.BreakStatement,r.ContinueStatement],EI=[r.CustomEntity,r.BuiltInBaseEntity,r.Project,r.InstalledProject,r.GlobalEvent,r.DataType,r.FunctionCall,r.FunctionDeclaration,r.ActionDescriptor,r.ValueDescriptor,r.ArgumentDeclaration,r.InputMap,r.ReturnStatement,r.BreakStatement,r.ContinueStatement,r.ReturnDeclaration,r.OutputMap,r.PrimitiveEntity,r.PrimitiveValue,r.Property,r.Operation,r.Condition,r.VariableDeclaration,r.VariableInstance,r.Search,r.Loop,r.InternalCall],Bo=[r.CustomEntity,r.GlobalEvent,r.FunctionDeclaration,r.FunctionCall,r.VariableDeclaration,r.VariableInstance,r.Operation,r.Condition,r.ReturnStatement,r.BreakStatement,r.ContinueStatement,r.InstalledProject,r.Loop,r.Search],Zd=[r.CustomEntity,r.FunctionDeclaration,r.ArgumentDeclaration,r.ReturnDeclaration,r.Property,r.VariableDeclaration,r.Search,r.Project,r.InstalledProject,r.ActionDescriptor,r.ValueDescriptor],Gr=[r.BuiltInBaseEntity,r.PrimitiveEntity],RI=[r.CustomEntity,r.FunctionDeclaration,r.ArgumentDeclaration,r.ReturnDeclaration,r.Property,r.VariableDeclaration,r.GlobalEvent,r.Search,r.Project,r.InstalledProject,r.ActionDescriptor,r.ValueDescriptor,r.InputMap,r.OutputMap,r.FunctionCall,r.Operation,r.Condition,r.ReturnStatement,r.BreakStatement,r.ContinueStatement,r.VariableInstance,r.PrimitiveValue,r.InternalCall];var wo=(n=>(n.ActionOngoingProcessOutputValue="action-ongoing-process-output-value-descriptor-id",n))(wo||{});const x={[r.PrimitiveEntity]:{[A.String]:{id:"8b5fbe15-4c2b-48c0-9fd8-e5efbe3978dc",properties:{}},[A.Boolean]:{id:"f596545d-1565-4faa-9969-d95fa5edfea4",properties:{}},[A.Number]:{id:"ecb84c29-6153-4b82-86a5-fce2b5f92002",properties:{}},[A.JSON]:{id:"b6f3c3c4-9c3d-4f9d-9e9e-1c0f6a3c8c6b",properties:{}},[A.Enum]:{id:"9542b8b4-2642-4eee-9db9-def7963a17a0",properties:{options:{id:"00ccfcae-2104-45ef-bf6c-50ddccd74286",dataType:{id:"7dd59b70-f97b-43a7-a051-fde1842ce5d6",defaultValue:{id:"enum-options-property-data-type-default-value-id"}}}}},[A.UUID]:{id:"4a6234aa-c0f6-4731-b4dd-750388029226",properties:{}},[A.Date]:{id:"dc58f38b-d574-4956-aac6-32ce9529b937",properties:{}}},[r.ValueDescriptor]:{"action-ongoing-process-output-value-descriptor-id":{id:"action-ongoing-process-output-value-descriptor-id",dataType:{id:"process-output-value-data-type-id"}}},[r.BuiltInBaseEntity]:{[V.KEY_VALUE_PARAM]:{id:V.KEY_VALUE_PARAM},[V.HTTP_ENDPOINT]:{id:V.HTTP_ENDPOINT,properties:{method:{id:"http-endpoint-built-in-method-property-id"},path:{id:"http-endpoint-built-in-path-property-id"},cors:{id:"http-endpoint-built-in-cors-property-id"}}},[V.PERSISTED_ENTITY]:{id:V.PERSISTED_ENTITY,properties:{database:{id:"persisted-built-in-base-entity-database-property-id"},identifier:{id:"persisted-built-in-base-entity-identifier-property-id"}}},[V.RELATIONAL_DATABASE]:{id:V.RELATIONAL_DATABASE,properties:{identifier:{id:"relational-database-built-in-base-entity-identifier-property-id"},username:{id:"relational-database-built-in-base-entity-username-property-id"},password:{id:"relational-database-built-in-base-entity-password-property-id"},minSize:{id:"relational-database-built-in-base-entity-min-size-property-id"},default:{id:"relational-database-built-in-base-entity-default-property-id"},autoscaling:{id:"relational-database-built-in-base-entity-autoscaling-property-id"}}},[V.CRON_JOB]:{id:V.CRON_JOB,properties:{expression:{id:"cron-job-built-in-base-entity-expression-property-id"}}}},[r.Operation]:{[Ae.Join]:{id:Ae.Join,inputs:{first:{id:"join-string-first-string-input-id"},second:{id:"join-string-second-string-input-id"}},outputs:{result:{id:"join-string-result-string-return-delaration-id"},error:{id:"join-string-error-return-delaration-id"}}},[Xe.HttpRequest]:{id:Xe.HttpRequest,inputs:{url:{id:"http-request-url-input-id"},query:{id:"http-request-query-input-id"},method:{id:"http-request-method-input-id"},headers:{id:"http-request-headers-input-id"},body:{id:"http-request-body-string-input-id"}},outputs:{code:{id:"http-response-code-return-delaration-id"},body:{id:"http-response-body-return-delaration-id"},headers:{id:"http-response-headers-return-delaration-id"},error:{id:"http-request-error-return-delaration-id"}}}},[r.Loop]:{[Q.List]:{id:Q.List,inputs:{list:{id:"iterate-over-list-loop-list-input-id"}},outputs:{results:{id:"iterate-over-list-loop-output-id"}}},[Q.String]:{id:Q.String,inputs:{string:{id:"iterate-over-string-loop-string-input-id"}},outputs:{results:{id:"iterate-over-string-loop-output-id"}}},[Q.ObjectKeys]:{id:Q.ObjectKeys,inputs:{object:{id:"iterate-over-object-keys-loop-object-input-id"}},outputs:{results:{id:"iterate-over-object-keys-loop-output-id"}}},[Q.ObjectValues]:{id:Q.ObjectValues,inputs:{object:{id:"iterate-over-object-values-loop-object-input-id"}},outputs:{results:{id:"iterate-over-object-values-loop-output-id"}}},[Q.ManualFlow]:{id:Q.ManualFlow,inputs:{},outputs:{results:{id:"manual-flow-loop-output-id"}}},[Q.Counted]:{id:Q.Counted,inputs:{number:{id:"iterate-over-counted-loop-number-input-id"}},outputs:{results:{id:"iterate-over-counted-loop-output-id"}}}},[r.Condition]:{[_e.MoreThanOrEqual]:{id:_e.MoreThanOrEqual,inputs:{leftHand:{id:"condition-more-than-or-equal-left-hand-input-id"},rightHand:{id:"condition-more-than-or-equal-right-hand-input-id"}}},[Nt.NotEmpty]:{id:Nt.NotEmpty,inputs:{leftHand:{id:"condition-not-empty-input-id"}}}},[r.GlobalEvent]:{[on.PROJECT_PUBLICATION_COMPLETED]:{id:on.PROJECT_PUBLICATION_COMPLETED}}},Yt=x["primitive-entity"],k={type:r.PrimitiveEntity,id:Yt.string.id,description:"A string of characters.",version:1,name:A.String,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]},An={type:r.PrimitiveEntity,id:Yt.boolean.id,description:"A 'true' or 'false' value.",version:1,name:A.Boolean,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]},Ce={type:r.PrimitiveEntity,id:Yt.number.id,description:"A number value.",version:1,name:A.Number,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]},et={type:r.PrimitiveEntity,id:"730e8ea9-8498-439a-9001-b07de55aaa7d",description:"A complex data structure with any combination of properties with names and values.",version:1,name:A.JSON,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]},Xd={id:"c2f52f01-8f2e-490e-8083-72289c8189c1",type:r.GenericReference,entityId:"7dd59b70-f97b-43a7-a051-fde1842ce5d6",entityType:r.DataType},Qd={id:"4e803941-2e6a-4227-b803-b8877c0d7fee",type:r.GenericReference,entityId:"00ccfcae-2104-45ef-bf6c-50ddccd74286",entityType:r.Property},Kd={like:!1,id:Yt.enum.properties.options.dataType.id,version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:k,asType:!1,defaultValue:{id:Yt.enum.properties.options.dataType.defaultValue.id,type:r.PrimitiveValue,version:1,name:A.JSON,autogeneration:null,value:[],valueAsType:null,parent:Xd},parent:Qd},eu={id:"a2983c4c-0286-4ef1-8b5c-5a52904d3200",type:r.GenericReference,entityId:"9542b8b4-2642-4eee-9db9-def7963a17a0",entityType:r.PrimitiveEntity},tu={hidden:!1,required:!0,id:Yt.enum.properties.options.id,name:"Options",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:0,dataType:Kd,description:"Options for the enum. Each option is a text value.",parent:eu},Sn={type:r.PrimitiveEntity,id:Yt.enum.id,description:"A set of text options to choose from.",version:1,name:A.Enum,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[tu],methods:[]},cn={type:r.PrimitiveEntity,id:Yt.date.id,description:"A date and time value.",version:1,name:A.Date,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]},Ba={type:r.PrimitiveEntity,id:Yt.uuid.id,description:"A unique identifier in the form of a 36-character string.",version:1,name:A.UUID,static:!1,abstract:!1,abstractMethods:[],extends:[k],properties:[],methods:[]},_o={type:r.PrimitiveEntity,id:Yt.json.id,description:"A complex data structure with any combination of properties with names and values.",version:1,name:A.JSON,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]};var nu=(n=>(n.FirstInputNumber="number-addition-first-number-argument-declaration",n.SecondInputNumber="number-addition-second-number-argument-declaration",n))(nu||{}),ru=(n=>(n.ResultNumber="number-addition-result-number-return-delaration",n.Error="number-addition-error-return-delaration",n))(ru||{});const iu={type:r.GenericReference,id:"3bd4aeb2-e3b7-4120-b289-011ebb03dba5",entityId:"number-addition-first-number-argument-declaration",entityType:r.ValueDescriptor},au={like:!1,id:"number-addition-first-number-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:iu},su={type:r.GenericReference,id:"9f486db2-a983-4293-9eef-81d4fc8d2d3e",entityId:"number-addition-second-number-argument-declaration",entityType:r.ValueDescriptor},ou={like:!1,id:"1d4abe83-3e87-4f74-99be-c1fd8c2f8d2d",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:su},lu={type:r.GenericReference,id:"da5e9fe9-f18a-49e3-98e5-c1bf7b9b3153",entityId:"number-addition-result-number-return-delaration",entityType:r.ValueDescriptor},cu={like:!1,id:"b761acec-0755-4582-a68b-76267038bbe1",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:lu},du={type:r.GenericReference,id:"a6c14305-d4f7-43ae-9d5e-b7dbacdc830a",entityId:lt.Addition,entityType:r.ActionDescriptor},Mo={id:"number-addition-first-number-argument-declaration",type:r.ValueDescriptor,version:1,name:"First value",description:"The first number to add",dataType:au,required:!0,parentRelationType:M.FixedArguments,index:0,parent:du},uu={type:r.GenericReference,id:"c5015128-4a65-462c-9da0-1c86e83ef897",entityId:lt.Addition,entityType:r.ActionDescriptor},No={id:"number-addition-second-number-argument-declaration",type:r.ValueDescriptor,description:"The second number to add",version:1,name:"Second value",dataType:ou,required:!0,parentRelationType:M.FixedArguments,index:1,parent:uu},pu={type:r.GenericReference,id:"caac2bc7-c23c-4f01-9581-a515c2e4637f",entityId:lt.Addition,entityType:r.ActionDescriptor},Vo={parentRelationType:M.FixedReturns,id:"number-addition-result-number-return-delaration",type:r.ValueDescriptor,description:"The result number of the addition",version:1,name:"Result",dataType:cu,required:!0,index:0,parent:pu},yu={type:r.GenericReference,id:"number-addition-operation-error-parent-ref",entityId:lt.Addition,entityType:r.ActionDescriptor},hu={parentRelationType:M.FixedReturns,id:"number-addition-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:yu},wa={id:lt.Addition,type:r.ActionDescriptor,description:"Add two numbers together",version:1,name:lt.Addition,fixedArguments:[Mo,No],error:hu,fixedReturns:[Vo],argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},fu={[lt.Addition]:wa};var mu=(n=>(n.FirstInputString="join-string-first-string-argument-declaration",n.SecondInputString="join-string-second-string-argument-declaration",n))(mu||{}),Tu=(n=>(n.ResultString="join-string-result-string-return-delaration",n.Error="join-string-error-return-delaration",n))(Tu||{});const Eu={type:r.GenericReference,id:"join-string-first-string-argument-declaration",entityId:"join-string-first-string-argument-declaration",entityType:r.ValueDescriptor},Ru={like:!1,id:"join-string-first-string-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Eu},bu={type:r.GenericReference,id:"join-string-second-string-argument-declaration",entityId:"join-string-second-string-argument-declaration",entityType:r.ValueDescriptor},gu={like:!1,id:"join-string-second-string-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:bu},vu={type:r.GenericReference,id:"join-string-result-string-return-delaration",entityId:"join-string-result-string-return-delaration",entityType:r.ValueDescriptor},Iu={like:!1,id:"join-string-result-string-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:vu},Du={type:r.GenericReference,id:"join-string-operation-first-string-argument-parent-ref",entityId:Ae.Join,entityType:r.ActionDescriptor},_a={id:"join-string-first-string-argument-declaration",type:r.ValueDescriptor,version:1,name:"First value",description:"The first text to join to the second one. Its value will be at the beginning of the resulting text.",dataType:Ru,parentRelationType:M.FixedArguments,required:!0,index:0,parent:Du},Pu={type:r.GenericReference,id:"join-string-operation-second-string-argument-parent-ref",entityId:Ae.Join,entityType:r.ActionDescriptor},Ma={id:"join-string-second-string-argument-declaration",type:r.ValueDescriptor,version:1,name:"Second value",description:"The second text to join to the first one. Its value will be at the end of the resulting text.",dataType:gu,parentRelationType:M.FixedArguments,required:!0,index:1,parent:Pu},Au={type:r.GenericReference,id:"join-string-operation-result-string-return-parent-ref",entityId:Ae.Join,entityType:r.ActionDescriptor},bi={parentRelationType:M.FixedReturns,id:"join-string-result-string-return-delaration",type:r.ValueDescriptor,version:1,name:"Result",description:"The resulting text value.",dataType:Iu,required:!0,index:0,parent:Au},Su={type:r.GenericReference,id:"join-string-operation-error-parent-ref",entityId:Ae.Join,entityType:r.ActionDescriptor},Ou={parentRelationType:M.FixedReturns,id:"join-string-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Su},gi={id:Ae.Join,type:r.ActionDescriptor,version:1,name:Ae.Join,description:"Join two text together, to form a single resulting text value.",fixedArguments:[_a,Ma],fixedReturns:[bi],error:Ou,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},Cu={[Ae.Join]:gi};var Bu=(n=>(n.FirstInputList="join-list-first-list-argument-declaration",n.SecondInputList="join-list-second-list-argument-declaration",n))(Bu||{}),wu=(n=>(n.ResultList="join-list-result-list-return-delaration",n.Error="join-list-error-return-delaration",n))(wu||{});const _u={type:r.GenericReference,id:"join-list-operation-first-list-argument-ref",entityId:"join-list-first-list-argument-declaration",entityType:r.ValueDescriptor},Mu={like:!1,id:"join-list-first-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:_u},Nu={type:r.GenericReference,id:"join-list-operation-second-list-argument-ref",entityId:"join-list-second-list-argument-declaration",entityType:r.ValueDescriptor},Vu={like:!1,id:"join-list-second-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Nu},$u={type:r.GenericReference,id:"join-list-operation-result-list-return-ref",entityId:"join-list-result-list-return-delaration",entityType:r.ValueDescriptor},Lu={like:!1,id:"join-list-result-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:$u},Gu={type:r.GenericReference,id:"join-list-operation-first-list-argument-parent-ref",entityId:W.Join,entityType:r.ActionDescriptor},Fu={id:"join-list-first-list-argument-declaration",type:r.ValueDescriptor,version:1,name:"First value",description:"The first list to join to the second one. Its values will be at the beginning of the resulting list.",dataType:Mu,parentRelationType:M.FixedArguments,required:!0,index:0,parent:Gu},Uu={type:r.GenericReference,id:"join-list-operation-second-list-argument-parent-ref",entityId:W.Join,entityType:r.ActionDescriptor},xu={id:"join-list-second-list-argument-declaration",type:r.ValueDescriptor,version:1,name:"Second value",description:"The second list to join to the first one. Its values will be at the end of the resulting list.",dataType:Vu,parentRelationType:M.FixedArguments,required:!0,index:1,parent:Uu},ku={type:r.GenericReference,id:"join-list-operation-result-list-return-parent-ref",entityId:W.Join,entityType:r.ActionDescriptor},ju={parentRelationType:M.FixedReturns,id:"join-list-result-list-return-delaration",type:r.ValueDescriptor,version:1,name:"Result",description:"The resulting list value.",dataType:Lu,required:!0,index:0,parent:ku},qu={type:r.GenericReference,id:"join-list-operation-error-parent-ref",entityId:W.Join,entityType:r.ActionDescriptor},Ju={parentRelationType:M.FixedReturns,id:"join-list-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:qu},$o={id:W.Join,type:r.ActionDescriptor,version:1,name:W.Join,description:"Join two lists together, to form a single resulting list value.",fixedArguments:[Fu,xu],error:Ju,fixedReturns:[ju],argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null};var Wu=(n=>(n.InputList="list-to-split-argument-declaration",n.SplitIndex="split-list-index-argument-declaration",n))(Wu||{}),Hu=(n=>(n.FirstOutputList="split-list-first-output-list-return-delaration",n.SecondOutputList="split-list-second-output-list-return-delaration",n.Error="split-list-error-return-delaration",n))(Hu||{});const Yu={type:r.GenericReference,id:"split-list-operation-input-list-argument-ref",entityId:"list-to-split-argument-declaration",entityType:r.ValueDescriptor},zu={like:!1,id:"split-list-operation-input-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Yu},Zu={type:r.GenericReference,id:"split-list-operation-split-index-argument-ref",entityId:"split-list-index-argument-declaration",entityType:r.ValueDescriptor},Xu={like:!1,id:"split-list-operation-split-index-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Zu},Lo={type:r.GenericReference,id:"split-list-operation-first-output-list-return-ref",entityId:"split-list-first-output-list-return-delaration",entityType:r.ValueDescriptor},Qu={like:!1,id:"split-list-operation-first-output-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Lo},Ku={type:r.GenericReference,id:"split-list-operation-input-list-argument-parent-ref",entityId:W.Split,entityType:r.ActionDescriptor},ep={id:"list-to-split-argument-declaration",type:r.ValueDescriptor,version:1,name:"List to split",description:"The list to split at the given index",dataType:zu,parentRelationType:M.FixedArguments,required:!0,index:0,parent:Ku},tp={type:r.GenericReference,id:"split-list-operation-split-index-argument-parent-ref",entityId:W.Split,entityType:r.ActionDescriptor},np={id:"split-list-index-argument-declaration",type:r.ValueDescriptor,version:1,name:"Split location",description:"The index at which to split the list. The value at this index will be the first value of the second list.",dataType:Xu,parentRelationType:M.FixedArguments,required:!0,index:1,parent:tp},rp={type:r.GenericReference,id:"split-list-operation-first-output-list-return-parent-ref",entityId:W.Split,entityType:r.ActionDescriptor},ip={parentRelationType:M.FixedReturns,id:"split-list-first-output-list-return-delaration",type:r.ValueDescriptor,version:1,name:"First list",description:"The list of values up to the split index",dataType:Qu,required:!0,index:0,parent:rp},ap={like:!1,id:"split-list-operation-second-output-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Lo},sp={type:r.GenericReference,id:"split-list-operation-second-output-list-return-parent-ref",entityId:W.Split,entityType:r.ActionDescriptor},op={parentRelationType:M.FixedReturns,id:"split-list-second-output-list-return-delaration",type:r.ValueDescriptor,version:1,name:"Second list",description:"The list of values up to the split index",dataType:ap,required:!0,index:0,parent:sp},lp={type:r.GenericReference,id:"split-list-operation-error-parent-ref",entityId:W.Split,entityType:r.ActionDescriptor},cp={parentRelationType:M.FixedReturns,id:"split-list-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:lp},Go={id:W.Split,type:r.ActionDescriptor,version:1,name:W.Split,description:"Splits a given list at the given index, and returns two lists, one with the values up to the index, and the other with the values after the index",fixedArguments:[ep,np],fixedReturns:[ip,op],error:cp,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null};var dp=(n=>(n.InputList="get-last-in-list-input-list-argument-declaration",n))(dp||{}),up=(n=>(n.OutputElement="get-last-in-list-output-element-return-delaration",n.Error="get-last-in-list-error-return-delaration",n))(up||{});const pp={type:r.GenericReference,id:"get-last-in-list-operation-input-list-argument-ref",entityId:"get-last-in-list-input-list-argument-declaration",entityType:r.ValueDescriptor},yp={like:!1,id:"get-last-in-list-input-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:pp},hp={type:r.GenericReference,id:"get-last-in-list-operation-output-element-return-ref",entityId:"get-last-in-list-output-element-return-delaration",entityType:r.ValueDescriptor},fp={like:!1,id:"get-last-in-list-output-element-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:hp},mp={type:r.GenericReference,id:"get-last-in-list-operation-input-list-argument-parent-ref",entityId:W.GetLast,entityType:r.ActionDescriptor},Tp={id:"get-last-in-list-input-list-argument-declaration",type:r.ValueDescriptor,version:1,name:"List",description:"The list to get the last element from.",dataType:yp,parentRelationType:M.FixedArguments,required:!0,index:0,parent:mp},Ep={type:r.GenericReference,id:"get-last-in-list-operation-output-element-return-parent-ref",entityId:W.GetLast,entityType:r.ActionDescriptor},Rp={parentRelationType:M.FixedReturns,id:"get-last-in-list-output-element-return-delaration",type:r.ValueDescriptor,version:1,name:"Last element",description:"The last element of the given list.",dataType:fp,required:!0,index:0,parent:Ep},bp={type:r.GenericReference,id:"get-last-in-list-operation-error-parent-ref",entityId:W.GetLast,entityType:r.ActionDescriptor},gp={parentRelationType:M.FixedReturns,id:"get-last-in-list-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:bp},Fo={id:W.GetLast,type:r.ActionDescriptor,version:1,name:W.GetLast,description:"Outputs the last element of a given list.",fixedArguments:[Tp],fixedReturns:[Rp],error:gp,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null};var vp=(n=>(n.List="append-to-list-lsit-argument-declaration",n.ElementToAppend="append-to-list-element-to-append-argument-declaration",n))(vp||{}),Ip=(n=>(n.ResultList="append-to-list-result-list-return-delaration",n.Error="append-to-list-error-return-delaration",n))(Ip||{});const Dp={type:r.GenericReference,id:"append-to-list-operation-lsit-argument-ref",entityId:"append-to-list-lsit-argument-declaration",entityType:r.ValueDescriptor},Pp={like:!1,id:"append-to-list-lsit-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Dp},Ap={type:r.GenericReference,id:"append-to-list-operation-second-list-argument-ref",entityId:"append-to-list-element-to-append-argument-declaration",entityType:r.ValueDescriptor},Sp={like:!1,id:"append-to-list-second-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Ap},Op={type:r.GenericReference,id:"append-to-list-operation-result-list-return-ref",entityId:"append-to-list-result-list-return-delaration",entityType:r.ValueDescriptor},Cp={like:!1,id:"append-to-list-result-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Op},Bp={type:r.GenericReference,id:"append-to-list-operation-lsit-argument-parent-ref",entityId:W.Append,entityType:r.ActionDescriptor},Uo={id:"append-to-list-lsit-argument-declaration",type:r.ValueDescriptor,version:1,name:"List value",description:"The list to which the element will be appended",dataType:Pp,parentRelationType:M.FixedArguments,required:!0,index:0,parent:Bp},wp={type:r.GenericReference,id:"append-to-list-operation-second-list-argument-parent-ref",entityId:W.Append,entityType:r.ActionDescriptor},xo={id:"append-to-list-element-to-append-argument-declaration",type:r.ValueDescriptor,version:1,name:"Element",description:"The element that will be added at the end of the list",dataType:Sp,parentRelationType:M.FixedArguments,required:!0,index:1,parent:wp},_p={type:r.GenericReference,id:"append-to-list-operation-result-list-return-parent-ref",entityId:W.Append,entityType:r.ActionDescriptor},Mp={parentRelationType:M.FixedReturns,id:"append-to-list-result-list-return-delaration",type:r.ValueDescriptor,version:1,name:"Result",description:"The resulting list value.",dataType:Cp,required:!0,index:0,parent:_p},Np={type:r.GenericReference,id:"append-to-list-operation-error-parent-ref",entityId:W.Append,entityType:r.ActionDescriptor},Vp={parentRelationType:M.FixedReturns,id:"append-to-list-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Np},Na={id:W.Append,type:r.ActionDescriptor,version:1,name:W.Append,description:"Adds a given element to the end of a list value.",fixedArguments:[Uo,xo],error:Vp,fixedReturns:[Mp],argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},$p={[W.Join]:$o,[W.Split]:Go,[W.GetLast]:Fo,[W.Append]:Na};var Lp=(n=>(n.ListOfFunctions="parallel-execution-list-of-functions-argument-declaration",n))(Lp||{}),Gp=(n=>(n.ListOfExecutionResults="parallel-execution-result-return-delaration",n.Error="parallel-execution-error-return-delaration",n))(Gp||{});const Fp={id:"parallel-execution-list-of-functions-blueprint-id",type:r.ActionDescriptor,version:1,name:"Action to execute",description:"An action of any type, to be executed. It can contain any number of inputs and outputs.",argumentsType:U.Dynamic,dynamicArgumentTypes:null,fixedArguments:[],returnsType:U.Dynamic,dynamicReturnTypes:null,fixedReturns:[],error:null,parent:null},Up={type:r.GenericReference,id:"3bd4aeb2-e3b7-4120-b289-011ebb03dba5",entityId:"parallel-execution-list-of-functions-argument-declaration",entityType:r.ValueDescriptor},xp={like:!1,id:"parallel-execution-list-of-functions-argument-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Fp,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Up},kp={type:r.GenericReference,id:"da5e9fe9-f18a-49e3-98e5-c1bf7b9b3153",entityId:"parallel-execution-result-return-delaration",entityType:r.ValueDescriptor},jp={like:!1,id:"b761acec-0755-4582-a68b-76267038bbe1",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:kp},qp={type:r.GenericReference,id:"a6c14305-d4f7-43ae-9d5e-b7dbacdc830a",entityId:Oe.Parallel,entityType:r.ActionDescriptor},ko={id:"parallel-execution-list-of-functions-argument-declaration",type:r.ValueDescriptor,version:1,name:"Actions to execute",description:"A value, of a list of actions to be executed in parallel",dataType:xp,required:!0,index:0,parent:qp,parentRelationType:M.FixedArguments},Jp={type:r.GenericReference,id:"caac2bc7-c23c-4f01-9581-a515c2e4637f",entityId:Oe.Parallel,entityType:r.ActionDescriptor},jo={id:"parallel-execution-result-return-delaration",type:r.ValueDescriptor,version:1,name:"List of execution results",description:"Each execution result, in the same order as the input list of actions. One item on this list for each executed action.",dataType:jp,required:!0,index:0,parent:Jp,parentRelationType:M.FixedReturns},Wp={type:r.GenericReference,id:"parallel-execution-operation-error-parent-ref",entityId:Oe.Parallel,entityType:r.ActionDescriptor},Hp={id:"parallel-execution-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Wp,parentRelationType:M.ReturnedError},xt={id:Oe.Parallel,type:r.ActionDescriptor,description:"Execute a list of actions in parallel",version:1,name:Oe.Parallel,fixedArguments:[ko],fixedReturns:[jo],argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,error:Hp,parent:null};var Yp=(n=>(n.MillisecondsNumber="wait-milliseconds-number-argument-declaration",n))(Yp||{}),zp=(n=>(n.Error="wait-operation-error-return-delaration",n))(zp||{});const Zp={type:r.GenericReference,id:"3bd4aeb2-e3b7-4120-b289-011ebb03dba5",entityType:r.ValueDescriptor,entityId:"wait-milliseconds-number-argument-declaration"},Xp={like:!1,id:"wait-milliseconds-number-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Zp},Qp={type:r.GenericReference,id:"a6c14305-d4f7-43ae-9d5e-b7dbacdc830a",entityType:r.ActionDescriptor,entityId:Oe.Wait},Zn={id:"wait-milliseconds-number-argument-declaration",type:r.ValueDescriptor,version:1,name:"Milliseconds to wait",description:"The amount of milliseconds to wait before calling the next entity",dataType:Xp,required:!0,index:0,parent:Qp,parentRelationType:M.FixedArguments},Kp={type:r.GenericReference,id:"wait-operation-error-parent-ref",entityId:Oe.Wait,entityType:r.ActionDescriptor},ey={id:"wait-operation-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Kp,parentRelationType:M.ReturnedError},dt={id:Oe.Wait,type:r.ActionDescriptor,description:"Wait for the given amount of milliseconds before calling the next entity",version:1,name:Oe.Wait,fixedArguments:[Zn],fixedReturns:[],error:ey,argumentsType:U.Fixed,returnsType:U.None,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null};var ty=(n=>(n.ListOfFunctions="sequential-execution-list-of-functions-argument-declaration",n))(ty||{}),ny=(n=>(n.ListOfExecutionResults="sequential-execution-result-return-delaration",n.Error="sequential-execution-error-return-delaration",n))(ny||{});const ry={id:"sequential-execution-list-of-functions-blueprint-id",type:r.ActionDescriptor,version:1,name:"Action to execute",description:"An action of any type, to be executed. It can contain any number of inputs and outputs.",argumentsType:U.Dynamic,dynamicArgumentTypes:null,fixedArguments:[],returnsType:U.Dynamic,dynamicReturnTypes:null,fixedReturns:[],error:null,parent:null},iy={type:r.GenericReference,id:"parallel-execution-list-of-functions-argument-declaration-id",entityId:"sequential-execution-list-of-functions-argument-declaration",entityType:r.ValueDescriptor},ay={like:!1,id:"sequential-execution-list-of-functions-argument-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:ry,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:iy},sy={type:r.GenericReference,id:"sequential-execution-list-of-execution-results-return-declaration-id",entityId:"sequential-execution-result-return-delaration",entityType:r.ValueDescriptor},oy={like:!1,id:"sequential-execution-list-of-execution-results-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:sy},ly={type:r.GenericReference,id:"parallel-execution-operation-list-of-functions-argument-parent-ref",entityId:Oe.Sequential,entityType:r.ActionDescriptor},qo={id:"sequential-execution-list-of-functions-argument-declaration",type:r.ValueDescriptor,version:1,name:"Actions to execute",description:"A value, of a list of actions to be executed in parallel",dataType:ay,required:!0,index:0,parent:ly,parentRelationType:M.FixedArguments},cy={type:r.GenericReference,id:"parallel-execution-operation-list-of-execution-results-return-parent-ref",entityId:Oe.Sequential,entityType:r.ActionDescriptor},Jo={id:"sequential-execution-result-return-delaration",type:r.ValueDescriptor,version:1,name:"List of execution results",description:"Each execution result, in the same order as the input list of actions. One item on this list for each executed action.",dataType:oy,required:!0,index:0,parent:cy,parentRelationType:M.FixedReturns},dy={type:r.GenericReference,id:"sequential-execution-operation-error-parent-ref",entityId:Oe.Sequential,entityType:r.ActionDescriptor},uy={id:"sequential-execution-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:dy,parentRelationType:M.ReturnedError},dn={id:Oe.Sequential,type:r.ActionDescriptor,description:"Execute a list of actions one after the other",version:1,name:Oe.Sequential,fixedArguments:[qo],fixedReturns:[Jo],error:uy,returnsType:U.Fixed,argumentsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},py={[Oe.Parallel]:xt,[Oe.Wait]:dt,[Oe.Sequential]:dn};var yy=(n=>(n.EntityToInstanciate="entity-to-instanciate-argument-declaration",n.NewEntityData="new-entity-data-argument-declaration",n))(yy||{}),hy=(n=>(n.Error="create-new-instance-error-return-delaration",n))(hy||{});const fy={type:r.GenericReference,id:"new-entity-data-argument-declaration-parent-ref",entityId:Ze.CreateNewInstance,entityType:r.ActionDescriptor},my={type:r.GenericReference,id:"new-entity-data-argument-data-type-parent-ref",entityId:"new-entity-data-argument-declaration",entityType:r.ValueDescriptor},Ty={like:!1,id:"new-entity-data-argument-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:my},bI={id:"new-entity-data-argument-declaration",type:r.ValueDescriptor,version:1,name:"Data for new entity",description:"The data to be used to create the new entity, with all the required properties",dataType:Ty,required:!0,parentRelationType:M.FixedArguments,index:1,parent:fy},Ey={type:r.GenericReference,id:"entity-to-instanciate-argument-declaration-ref",entityType:r.ValueDescriptor,entityId:"entity-to-instanciate-argument-declaration"},Ry={like:!1,id:"entity-to-instanciate-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,isList:!1,asType:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Ey},by={type:r.GenericReference,id:"create-new-instance-operation-ref",entityType:r.ActionDescriptor,entityId:Ze.CreateNewInstance},gy={id:"entity-to-instanciate-argument-declaration",type:r.ValueDescriptor,version:1,name:"Entity to create a new copy of",description:"The entity of which a new copy will to be created",dataType:Ry,required:!0,parentRelationType:M.FixedArguments,index:0,parent:by},vy={type:r.GenericReference,id:"create-new-instance-output-entity-declaration-parent-ref",entityId:Ze.CreateNewInstance,entityType:r.ActionDescriptor},Iy={parentRelationType:M.FixedReturns,id:"create-new-instance-output-entity-declaration",type:r.ValueDescriptor,version:1,dataType:null,name:"Created entity",description:"The entity that was created",parent:vy,required:!0,index:0},Dy={type:r.GenericReference,id:"create-new-instance-error-parent-ref",entityId:Ze.CreateNewInstance,entityType:r.ActionDescriptor},Py={parentRelationType:M.FixedReturns,id:"create-new-instance-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Dy},Xn={id:Ze.CreateNewInstance,type:r.ActionDescriptor,description:"Creates a new copy of a given entity, with the given values for each property, or default values if a value is not provided",version:1,name:Ze.CreateNewInstance,fixedArguments:[gy],fixedReturns:[Iy],error:Py,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null};var Ay=(n=>(n.EntityToMatchType="validate-data-operation-entity-to-match-type-argument-declaration",n.DataToValidate="validate-data-operation-data-to-validate-argument-declaration",n))(Ay||{}),Sy=(n=>(n.Error="validate-data-error-return-delaration",n.OutputEntity="validate-data-output-entity-declaration",n))(Sy||{});const Oy={type:r.GenericReference,id:"validate-data-operation-data-to-validate-argument-declaration-ref",entityType:r.ValueDescriptor,entityId:"validate-data-operation-data-to-validate-argument-declaration"},Cy={like:!1,id:"validate-data-operation-data-to-validate-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Oy},By={type:r.GenericReference,id:"validate-data-operation-data-to-validate-argument-parent-ref",entityType:r.ActionDescriptor,entityId:Ze.Validate},wy={id:"validate-data-operation-data-to-validate-argument-declaration",type:r.ValueDescriptor,version:1,name:"Data to validate",description:"The value to validate against the given entity type",dataType:Cy,required:!0,parentRelationType:M.FixedArguments,index:0,parent:By},_y={type:r.GenericReference,id:"validate-data-operation-entity-to-match-type-argument-declaration-ref",entityType:r.ValueDescriptor,entityId:"validate-data-operation-entity-to-match-type-argument-declaration"},My={like:!1,id:"validate-data-operation-entity-to-match-type-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,isList:!1,asType:!0,isNullable:!1,defaultValue:null,constant:!1,parent:_y},Ny={type:r.GenericReference,id:"validate-data-operation-entity-to-match-type-argument-parent-ref",entityType:r.ActionDescriptor,entityId:Ze.Validate},Vy={id:"validate-data-operation-entity-to-match-type-argument-declaration",type:r.ValueDescriptor,version:1,name:"Entity to match",description:"The entity to match the data against",dataType:My,required:!0,index:0,parentRelationType:M.FixedArguments,parent:Ny},$y={type:r.GenericReference,id:"validate-data-operation-output-entity-declaration-parent-ref",entityId:Ze.Validate,entityType:r.ActionDescriptor},Ly={id:"validate-data-output-entity-declaration",type:r.ValueDescriptor,version:1,dataType:null,name:"Output value",description:"A value with the type of the entity that was validated",parent:$y,required:!0,index:0,parentRelationType:M.FixedReturns},Gy={type:r.GenericReference,id:"wait-operation-error-parent-ref",entityId:Ze.Validate,entityType:r.ActionDescriptor},Fy={id:"validate-data-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Gy,parentRelationType:M.ReturnedError},Qn={id:Ze.Validate,type:r.ActionDescriptor,description:"Validates the given data to see if it matches the structure of a given type/entity",version:1,name:Ze.Validate,fixedArguments:[Vy,wy],fixedReturns:[Ly],error:Fy,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},Uy={[Ze.CreateNewInstance]:Xn,[Ze.Validate]:Qn},He=x[r.Operation]["base-http-request"],xy={type:r.GenericReference,id:"d87cf943-57e1-4d19-9f05-190fa8c8ebc4",entityType:r.DataType,entityId:"0deb4ef7-d739-4ddc-a4d6-50bd6fababe3"},ky={id:"http-request-url-default-value-id",type:r.PrimitiveValue,version:1,value:"https://some-url.com",name:A.String,valueAsType:null,parent:xy,autogeneration:null},jy={type:r.GenericReference,id:"aed50d73-eab5-42ce-b00e-7f5c45a9026f",entityId:He.inputs.url.id,entityType:r.ValueDescriptor},qy={like:!1,id:"0deb4ef7-d739-4ddc-a4d6-50bd6fababe3",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:ky,constant:!1,parent:jy},Jy={type:r.GenericReference,id:"c3145af6-3387-464a-8887-272e483c856d",entityId:He.inputs.query.id,entityType:r.ValueDescriptor},Wy={like:!1,id:"2a5ba737-6335-4cc4-a2c0-16dca4052fac",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Jy},Hy={type:r.GenericReference,id:"075556b7-e468-48f7-8485-7159eaf389b2",entityType:r.DataType,entityId:"6df7ec2b-5dbd-44af-896b-17b314e88560"},Yy={id:"http-request-method-default-value-id",type:r.PrimitiveValue,version:1,value:"GET",name:A.Enum,valueAsType:null,parent:Hy,autogeneration:null},zy={type:r.GenericReference,id:"aed647c8-a1b5-4cfc-9a3d-97887a567a80",entityId:He.inputs.method.id,entityType:r.ValueDescriptor},Zy={like:!1,id:"6df7ec2b-5dbd-44af-896b-17b314e88560",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Sn,isList:!1,asType:!1,isNullable:!1,defaultValue:Yy,options:["GET","POST","PUT","DELETE","PATCH","OPTIONS","HEAD","TRACE","CONNECT","CUSTOM"],constant:!1,parent:zy},Xy={type:r.GenericReference,id:"77203dfa-d2f6-4804-9556-e1cce46228f3",entityId:He.inputs.headers.id,entityType:r.ValueDescriptor},Qy={like:!1,id:"2c8a2a07-69c6-40ad-b5c9-f0dc4d5955ce",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Xy},Ky={type:r.GenericReference,id:"03db68a0-7ab6-4c6a-85b6-f4b95ebb53ff",entityId:He.inputs.body.id,entityType:r.ValueDescriptor},eh={like:!1,id:"0397876c-ed54-4ee9-85a4-04fd16dad973",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Ky},th={type:r.GenericReference,id:"182f767f-50e8-4394-ba5f-43e78c232733",entityType:r.ValueDescriptor,entityId:He.outputs.code.id},nh={like:!1,id:"45e6d0bc-0c0e-4059-a7a1-6bee925d73d0",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:th},rh={type:r.GenericReference,id:"2baaa53a-9aef-4bd1-b06d-967c17b7b627",entityType:r.DataType,entityId:"dac63bfa-640d-4f4e-ba0f-86c2401bcfbe"},ih={type:r.GenericReference,id:"69f34d6c-c686-4165-b6ff-70dae8e1778b",entityType:r.ValueDescriptor,entityId:He.outputs.headers.id},ah={like:!1,id:"dac63bfa-640d-4f4e-ba0f-86c2401bcfbe",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,isList:!1,isNullable:!1,asType:!1,defaultValue:{id:"http-response-headers-default-value-id",type:r.PrimitiveValue,version:1,value:{},name:A.JSON,parent:rh,valueAsType:null,autogeneration:null},constant:!1,parent:ih},sh={type:r.GenericReference,id:"744334e0-5135-4214-85d0-809437cb620b",entityType:r.DataType,entityId:"05fc1a5d-151a-479a-9c4e-4063f3456177"},oh={type:r.GenericReference,id:"0e0e20df-1a46-432c-ba01-fd96508a6a61",entityType:r.ValueDescriptor,entityId:He.outputs.body.id},lh={like:!1,id:"05fc1a5d-151a-479a-9c4e-4063f3456177",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,isList:!1,isNullable:!1,asType:!1,defaultValue:{id:"http-response-body-default-value-id",type:r.PrimitiveValue,version:1,value:{},name:A.JSON,parent:sh,valueAsType:null,autogeneration:null},constant:!1,parent:oh},ch={type:r.GenericReference,id:"26911792-f707-4bf1-b6f7-03d04a84232c",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Va={id:He.inputs.method.id,type:r.ValueDescriptor,description:"A single word that represents the type of request you want to make. For example: GET, POST, PUT, DELETE, PATCH, OPTIONS, HEAD, TRACE, CONNECT, CUSTOM",version:1,name:"Method",dataType:Zy,required:!1,index:0,parentRelationType:M.FixedArguments,parent:ch},dh={type:r.GenericReference,id:"eee0c501-0ae6-4448-b914-aada76d63163",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},$a={id:He.inputs.url.id,type:r.ValueDescriptor,description:"The base domain, or address where the request is being sent to. For example: https://some-url.com",version:1,name:"URL",dataType:qy,required:!1,index:1,parentRelationType:M.FixedArguments,parent:dh},uh={type:r.GenericReference,id:"670091a4-21b1-4223-ad4c-b6dada0aec49",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Wo={id:He.inputs.query.id,type:r.ValueDescriptor,description:"A text with standarized format, without spaces that is added at the end of the URL path, after the ? character. It contains data that might be used to process the request. For example: /api/users?name=John&age=30",version:1,name:"Query Params",dataType:Wy,required:!1,index:2,parentRelationType:M.FixedArguments,parent:uh},ph={type:r.GenericReference,id:"85aad3eb-22fe-45f9-b68c-1dc7061f41e0",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},La={id:He.inputs.headers.id,type:r.ValueDescriptor,description:"A set of any properties, with names and values that represent metadata about the request, such as the server, date, content type, and more, that you want to send alongside your request data.",version:1,name:"Headers",dataType:Qy,required:!1,index:3,parent:ph,parentRelationType:M.FixedArguments},yh={type:r.GenericReference,id:"c3e2a4af-9b84-4574-8b30-5044ffc51776",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Ga={id:He.inputs.body.id,type:r.ValueDescriptor,description:"The main data payload of the request. This is the data that you want to send to the server. It could be anything, but it is usually a JSON data structure or a text value.",version:1,name:"Body",dataType:eh,required:!1,index:4,parentRelationType:M.FixedArguments,parent:yh},hh={type:r.GenericReference,id:"92e04dc7-2145-4a31-908e-03810f7235e8",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Ho={id:He.outputs.code.id,type:r.ValueDescriptor,description:'A standardized status code of the response. It is a 3-digit number that represents the response status. For example, 200 means "OK", 404 means "Not Found", and 500 means "Internal Server Error".',version:1,name:"Code",dataType:nh,required:!0,index:0,parentRelationType:M.FixedReturns,parent:hh},fh={type:r.GenericReference,id:"86aca556-bbf1-4679-9909-31db61b288e2",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Fa={parentRelationType:M.FixedReturns,id:He.outputs.headers.id,type:r.ValueDescriptor,description:"A set of any properties, with names and value that the server sent back to you. It represents metadata about the response, such as the server, date, content type, and more.",version:1,name:"Headers",dataType:ah,required:!0,index:1,parent:fh},mh={type:r.GenericReference,id:"ccf3d1be-04e4-4d03-99fd-5bc1e1919f90",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},vi={parentRelationType:M.FixedReturns,id:He.outputs.body.id,type:r.ValueDescriptor,description:"The main data payload of the response. This is the data that the server sent back to you. It could be anything, but it is usually a JSON data structure or a text value.",version:1,name:"Body",dataType:lh,required:!0,index:2,parent:mh},Th={type:r.GenericReference,id:"21487ffc-82b9-473d-bc19-6e7d7c480ed7",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Eh={type:r.GenericReference,id:"ad69861b-32f7-4461-b7f7-aa84a82578d9",entityType:r.ValueDescriptor,entityId:He.outputs.error.id},Rh={like:!1,id:"5da68b15-57bc-40c1-b79f-a9075e0f22c1",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,isList:!1,asType:!1,isNullable:!1,constant:!1,defaultValue:null,parent:Eh},Yo={parentRelationType:M.ReturnedError,id:He.outputs.error.id,type:r.ValueDescriptor,description:"Http request error, if any. Contains a payload describing what went wrong.",version:1,name:"Error",dataType:Rh,required:!0,index:0,parent:Th},Ii={type:r.ActionDescriptor,id:Xe.HttpRequest,name:Xe.HttpRequest,description:"Make an HTTP request, out to the internet, to a given URL with the specified method, query parameters, headers, and body.",version:1,fixedArguments:[Va,$a,Wo,La,Ga],fixedReturns:[Ho,Fa,vi],argumentsType:U.Fixed,returnsType:U.Fixed,error:Yo,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},bh={[Xe.HttpRequest]:Ii},gI={...Cu,...fu,...$p,...py,...Uy,...bh},gh=x[r.Loop]["list-loop"],vh={id:"iterate-over-list-loop-return-declaration-parent-ref-id",type:r.GenericReference,entityId:Q.List,entityType:r.ActionDescriptor},Ih={id:gh.outputs.results.id,type:r.ValueDescriptor,version:1,name:"Results",description:"List of results from the loop. One item in the list for each iteration of the loop.",dataType:null,required:!0,index:0,parent:vh,parentRelationType:M.FixedReturns},Dh={id:"iterate-over-list-loop-list-argument-declaration-data-type-parent-ref-id",type:r.GenericReference,entityId:"iterate-over-list-loop-list-argument-declaration-id",entityType:r.ArgumentDeclaration},Ph={like:!1,id:"iterate-over-list-loop-list-argument-declaration-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,isList:!0,isNullable:!1,constant:!1,entity:null,asType:!1,defaultValue:null,parent:Dh},Ah={id:"iterate-over-list-loop-list-argument-declaration-parent-ref-id",type:r.GenericReference,entityId:Q.List,entityType:r.ActionDescriptor},Sh={id:gh.inputs.list.id,type:r.ValueDescriptor,version:1,name:"List",description:"The list to iterate over",required:!0,dataType:Ph,index:0,parent:Ah,parentRelationType:M.FixedArguments},Kn={id:Q.List,type:r.ActionDescriptor,version:1,name:Q.List,description:"Iterates over a list of entities",fixedArguments:[Sh],fixedReturns:[Ih],error:null,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},vI=x[r.Loop]["list-loop"],Oh={id:"manual-flow-loop-previous-iterations-results-declaration-data-type-parent-ref-id",type:r.GenericReference,entityId:"manual-flow-loop-previous-iterations-results-declaration-id",entityType:r.ReturnDeclaration},Ch={like:!1,id:"manual-flow-loop-previous-iterations-results-declaration-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,isList:!0,isNullable:!1,constant:!1,entity:null,asType:!1,defaultValue:null,parent:Oh},Bh={id:"manual-flow-loop-previous-iterations-results-declaration-parent-ref-id",type:r.GenericReference,entityId:Q.ManualFlow,entityType:r.ActionDescriptor},wh={id:vI.outputs.results.id,type:r.ValueDescriptor,version:1,name:"Results",description:"List of results from the loop. One item in the list for each iteration of the loop.",dataType:Ch,required:!0,index:1,parentRelationType:M.FixedReturns,parent:Bh},zo={id:Q.ManualFlow,type:r.ActionDescriptor,version:1,name:Q.ManualFlow,description:"A loop that is manually controlled by the continue and break statements. It runs until the break statement is called, and it can skip to the next iteration with the continue statement.",fixedArguments:[],dynamicArgumentTypes:null,dynamicReturnTypes:null,fixedReturns:[wh],argumentsType:U.None,returnsType:U.Fixed,error:null,parent:null},Ua=x[r.BuiltInBaseEntity][V.KEY_VALUE_PARAM],II={id:"key-value-param-built-in-base-entity-name-property-data-type-ref",type:r.GenericReference,entityId:"key-value-param-built-in-base-entity-name-property-data-type",entityType:r.DataType},_h={id:"key-value-param-built-in-base-entity-name-property-ref",type:r.GenericReference,entityId:"key-value-param-built-in-base-entity-name-property",entityType:r.Property},DI={like:!1,id:"key-value-param-built-in-base-entity-name-property-data-type",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:k,asType:!1,defaultValue:null,parent:_h},Mh={id:"key-value-param-built-in-base-entity-name-property-parent-ref",type:r.GenericReference,entityId:Ua.id,entityType:r.BuiltInBaseEntity},Nh={hidden:!1,required:!0,id:"key-value-param-built-in-base-entity-name-property",name:"Parameter name",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:0,dataType:DI,description:"The name of the path parameter",parent:Mh},PI={id:"key-value-param-built-in-base-entity-value-property-data-type-ref",type:r.GenericReference,entityId:"key-value-param-built-in-base-entity-value-property-data-type",entityType:r.DataType},Vh={id:"key-value-param-built-in-base-entity-value-property-ref",type:r.GenericReference,entityId:"key-value-param-built-in-base-entity-value-property",entityType:r.Property},AI={like:!1,id:"key-value-param-built-in-base-entity-value-property-data-type",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:k,asType:!1,defaultValue:null,parent:Vh},$h={id:"key-value-param-built-in-base-entity-value-property-parent-ref",type:r.GenericReference,entityId:Ua.id,entityType:r.BuiltInBaseEntity},Lh={hidden:!1,required:!0,id:"key-value-param-built-in-base-entity-value-property",name:"Parameter Value",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:1,dataType:AI,description:"The value of the path parameter",parent:$h},xa={id:Ua.id,version:1,description:'An entity with a "name" and "value" property representing a breakdown of a key-value pair.',name:Ua.id,type:r.BuiltInBaseEntity,abstract:!1,static:!1,interactive:!0,properties:[Nh,Lh],abstractMethods:[],methods:[],extends:[]},Di=x[r.BuiltInBaseEntity][V.HTTP_ENDPOINT].properties,Gh={id:"endpointBuiltInCorsPropertyDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointBuiltInCorsPropertyDataType"},Fh={id:"endpointBuiltInCorsPropertyRef",type:r.GenericReference,entityType:r.Property,entityId:Di.cors.id},Uh={like:!1,id:"endpointBuiltInCorsPropertyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"endpointBuiltInCorsPropertyDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:["*"],parent:Gh,autogeneration:null,valueAsType:null},parent:Fh},xh={id:"endpointBuiltInBaseEntityRef",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},kh={hidden:!0,required:!0,id:Di.cors.id,name:"Allowed origins",version:1,type:r.Property,private:!1,abstract:!0,implements:null,static:!0,index:0,dataType:Uh,description:"The origins that are allowed to access this endpoint, use * for all origins, or http://example.com/* to be as specific as you need.",parent:xh},jh={id:"endpointBuiltInPathPropertyDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointBuiltInPathPropertyDataType"},qh={id:"endpointBuiltInPathPropertyRef",type:r.GenericReference,entityType:r.Property,entityId:Di.path.id},Jh={like:!1,id:"endpointBuiltInPathPropertyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"endpointBuiltInPathPropertyDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.String,value:"/",parent:jh,autogeneration:null,valueAsType:null},parent:qh},Wh={id:"endpointBuiltInBaseEntityRefTwo",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},Zo={hidden:!1,required:!0,id:Di.path.id,name:"Path",version:1,type:r.Property,private:!1,abstract:!0,implements:null,static:!0,index:1,dataType:Jh,description:"Path to the endpoint, for example /api/users, or /api/users/{id}, or /api/users/{id}/:name. The path can contain parameters, which are defined by curly braces, and will be passed to the endpoint event as variables with the same name.",parent:Wh},Hh={id:"endpointBuiltInMethodPropertyDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointBuiltInMethodPropertyDataType"},Yh={id:"endpointBuiltInMethodPropertyRef",type:r.GenericReference,entityType:r.Property,entityId:"endpointBuiltInMethodProperty"},zh={like:!1,id:"endpointBuiltInMethodPropertyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:Sn,isList:!0,isNullable:!1,constant:!0,asType:!1,defaultValue:{id:"endpointBuiltInMethodPropertyDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,value:"GET",name:A.Enum,parent:Hh,autogeneration:null,valueAsType:null},options:["GET","POST","PUT","DELETE","PATCH","OPTIONS","HEAD","TRACE","CONNECT","CUSTOM"],parent:Yh},Zh={id:"endpointBuiltInBaseEntityRefThree",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},Xo={hidden:!1,required:!0,id:Di.method.id,name:"Method",version:1,type:r.Property,private:!1,index:2,implements:null,abstract:!0,static:!0,dataType:zh,description:"The HTTP method that this endpoint will respond to, for example GET, POST, PUT, DELETE, etc.",parent:Zh},Xh={id:"endpointRequestHeadersVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointRequestHeadersVariableDataType"},Qh={id:"endpointRequestHeadersArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"endpointRequestHeadersArgumentDeclaration"},Kh={like:!1,id:"endpointRequestHeadersVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:et,asType:!1,defaultValue:{id:"endpointRequestHeadersVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:Xh,autogeneration:null,valueAsType:null},parent:Qh},ef={id:"endpointRequestBodyArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"endpointRequestBodyArgumentDeclaration"},tf={like:!1,id:"endpointRequestBodyVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,asType:!1,constant:!1,entity:et,defaultValue:null,parent:ef},nf={id:"endpointRequestQueryParamsVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointRequestQueryParamsVariableDataType"},rf={id:"endpointRequestQueryParamsArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"endpointRequestQueryParamsArgumentDeclaration"},af={like:!1,id:"endpointRequestQueryParamsVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,asType:!1,entity:xa,defaultValue:{id:"endpointRequestQueryParamsVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:[],parent:nf,autogeneration:null,valueAsType:null},parent:rf},sf={id:"endpointPathParamsVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointPathParamsVariableDataType"},of={id:"endpointPathParamsArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"endpointPathParamsArgumentDeclaration"},lf={like:!1,id:"endpointPathParamsVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:xa,asType:!1,defaultValue:{id:"endpointPathParamsVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:[],parent:sf,autogeneration:null,valueAsType:null},parent:of},cf={id:"endpointReachedTriggerActionDescriptorRef",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReachedTriggerActionDescriptor"},df={id:"endpointRequestHeadersArgumentDeclaration",version:1,description:"A set of any properties, with names and value that transmit metadata about the request.",type:r.ValueDescriptor,name:"Request headers",dataType:Kh,required:!0,index:0,parentRelationType:M.FixedArguments,parent:cf},uf={id:"endpointReachedTriggerActionDescriptorRefTwo",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReachedTriggerActionDescriptor"},pf={id:"endpointPathParamsArgumentDeclaration",type:r.ValueDescriptor,description:"A standarized text, without spaces that is added at the end of the domain and routes the request to a specific resource within the target server. For example: /api/users/123, /api/users/123/:name, /api/users/123/:name/:age.",version:1,name:"Path parameters",dataType:lf,required:!0,index:1,parentRelationType:M.FixedArguments,parent:uf},yf={id:"endpointReachedTriggerActionDescriptorRefThree",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReachedTriggerActionDescriptor"},hf={id:"endpointRequestQueryParamsArgumentDeclaration",version:1,description:"A text with standarized format, without spaces that is added at the end of the URL path, after the ? character. It contains data that might be used to process the request. For example: /api/users?name=John&age=30",type:r.ValueDescriptor,name:"Request query params",dataType:af,required:!0,index:2,parentRelationType:M.FixedArguments,parent:yf},ff={id:"endpointReachedTriggerActionDescriptorRefFour",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReachedTriggerActionDescriptor"},mf={id:"endpointRequestBodyArgumentDeclaration",version:1,description:"The main data payload of the request.",type:r.ValueDescriptor,name:"Request body",dataType:tf,index:3,required:!0,parentRelationType:M.FixedArguments,parent:ff},Tf={id:"endpointResponseCodeReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"endpointResponseCodeReturnDeclaration"},Ef={like:!1,id:"9ba575b0-6f8e-436d-a3de-3b843622aa17",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Tf},Rf={id:"endpointReturnStatementRef",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReturnStatement"},bf={id:"endpointResponseCodeReturnDeclaration",version:1,description:"A standarized number that represents the status of the response. 200 for OK, 404 for not found, 500 for server error, etc.",type:r.ValueDescriptor,name:"Response code",dataType:Ef,required:!0,index:0,parentRelationType:M.FixedReturns,parent:Rf},gf={id:"endpointResponseHeadersDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointResponseHeadersDataType"},vf={id:"endpointResponseHeadersReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"endpointResponseHeadersReturnDeclaration"},If={like:!1,id:"endpointResponseHeadersDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:et,asType:!1,defaultValue:{id:"endpointResponseHeadersDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:gf,autogeneration:null,valueAsType:null},parent:vf},Df={id:"endpointReturnStatementRefTwo",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReturnStatement"},Pf={id:"endpointResponseHeadersReturnDeclaration",version:1,description:"A set of any properties, with names and value that transmit metadata about the response.",type:r.ValueDescriptor,name:"Response headers",dataType:If,required:!1,index:1,parentRelationType:M.FixedReturns,parent:Df},Af={id:"endpointResponseBodyReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"endpointResponseBodyReturnDeclaration"},Sf={like:!1,id:"endpointResponseBodyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,asType:!1,constant:!1,entity:et,defaultValue:null,parent:Af},Of={id:"endpointReturnStatementRefThree",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReturnStatement"},Cf={id:"endpointResponseBodyReturnDeclaration",version:1,description:"The main data payload of the response.",type:r.ValueDescriptor,name:"Response body",dataType:Sf,required:!1,index:2,parentRelationType:M.FixedReturns,parent:Of},Bf={id:"endpointBuiltInBaseEntityRefFour",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},Qo={id:"endpointReachedTriggerActionDescriptor",type:r.ActionDescriptor,version:1,name:"Endpoint reached",description:"Fired when the endpoint is reached.",argumentsType:U.Fixed,dynamicArgumentTypes:null,fixedArguments:[df,pf,hf,mf],returnsType:U.Fixed,fixedReturns:[bf,Pf,Cf],error:null,dynamicReturnTypes:null,parent:Bf},ka={id:V.HTTP_ENDPOINT,version:1,description:"An HTTP endpoint that can be reached by a client from the internet.",name:V.HTTP_ENDPOINT,type:r.BuiltInBaseEntity,interactive:!1,abstract:!0,static:!0,properties:[kh,Zo,Xo],abstractMethods:[Qo],extends:[],methods:[]},Vt=x[r.BuiltInBaseEntity].BUILT_IN_RELATIONAL_DATABASE_ENTITY,wf={id:"relational-database-built-in-base-entity-identifier-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-identifier-property-data-type-id",entityType:r.DataType},_f={id:"relational-database-built-in-base-entity-identifier-property-ref-id",type:r.GenericReference,entityId:Vt.properties.identifier.id,entityType:r.Property},SI={like:!1,id:"relational-database-built-in-base-entity-identifier-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"relational-database-built-in-base-entity-identifier-property-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:null,parent:wf,autogeneration:{type:qe.Unique,rangeStart:null,rangeEnd:null},valueAsType:null},parent:_f},Fr={id:"relational-database-built-in-base-entity-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},ja={hidden:!1,required:!0,id:Vt.properties.identifier.id,name:"Identifier name",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:0,dataType:SI,description:"The name of the main database inside of the server instance where the data will be stored.",parent:Fr},OI={id:"relational-database-built-in-base-entity-username-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-username-property-data-type-idd",entityType:r.DataType},Mf={id:"relational-database-built-in-base-entity-username-property-ref-id",type:r.GenericReference,entityId:Vt.properties.username.id,entityType:r.Property},CI={like:!1,id:"relational-database-built-in-base-entity-username-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"relational-database-built-in-base-entity-username-property-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"postgres",parent:{id:"relational-database-built-in-base-entity-username-property-data-type-default-value-parent-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-username-property-data-type-id",entityType:r.DataType},autogeneration:null,valueAsType:null},parent:Mf},qa={hidden:!1,required:!0,id:Vt.properties.username.id,name:"Username",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:1,dataType:CI,description:"The username that will be used to connect to the database.",parent:Fr},BI={id:"relational-database-built-in-base-entity-password-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-password-property-data-type-id",entityType:r.DataType},Nf={id:"relational-database-built-in-base-entity-password-property-ref-id",type:r.GenericReference,entityId:Vt.properties.password.id,entityType:r.Property},wI={like:!1,id:"relational-database-built-in-base-entity-password-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:null,parent:Nf},Ja={hidden:!1,required:!0,id:Vt.properties.password.id,name:"Password",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:2,dataType:wI,description:"The password that will be used to connect to the database.",parent:Fr},Vf={id:"relational-database-built-in-base-entity-min-size-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-min-size-property-data-type-id",entityType:r.DataType},$f={id:"relational-database-built-in-base-entity-min-size-property-ref-id",type:r.GenericReference,entityId:Vt.properties.minSize.id,entityType:r.Property},_I={like:!1,id:"relational-database-built-in-base-entity-min-size-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ce,asType:!1,defaultValue:{id:"relational-database-built-in-base-entity-min-size-property-default-value-id",type:r.PrimitiveValue,version:1,name:A.Number,value:6,parent:Vf,autogeneration:null,valueAsType:null},parent:$f},Wa={hidden:!0,required:!0,id:Vt.properties.minSize.id,name:"Minimum GB size",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:3,dataType:_I,description:"The minimum size of the database in GB.",parent:Fr},Lf={id:"relational-database-built-in-base-entity-default-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-default-property-data-type-id",entityType:r.DataType},Gf={id:"relational-database-built-in-base-entity-default-property-ref-id",type:r.GenericReference,entityId:Vt.properties.default.id,entityType:r.Property},MI={like:!1,id:"relational-database-built-in-base-entity-default-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:An,asType:!1,defaultValue:{id:"relational-database-built-in-base-entity-default-property-default-value-id",type:r.PrimitiveValue,version:1,name:A.Boolean,value:!1,parent:Lf,autogeneration:null,valueAsType:null},parent:Gf},Ko={hidden:!0,required:!0,id:Vt.properties.default.id,name:"Default",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:4,dataType:MI,description:"If true, this database will be the default database for the server instance and all the new entities.",parent:Fr},Ff={id:"relational-database-built-in-base-entity-autoscaling-property-ref-id",type:r.GenericReference,entityId:Vt.properties.autoscaling.id,entityType:r.Property},Uf={id:"relational-database-built-in-base-entity-autoscaling-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-autoscaling-property-data-type-id",entityType:r.DataType},NI={like:!1,id:"relational-database-built-in-base-entity-autoscaling-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:An,asType:!1,defaultValue:{id:"relational-database-built-in-base-entity-autoscaling-property-default-value-id",type:r.PrimitiveValue,version:1,name:A.Boolean,value:!1,parent:Uf,autogeneration:null,valueAsType:null},parent:Ff},xf={id:"relational-database-built-in-base-entity-autoscaling-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},el={hidden:!0,required:!0,id:Vt.properties.autoscaling.id,name:"Auto-scaling",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:4,dataType:NI,description:"If true, this database will automatically scale up or down in memory size, based on the usage.",parent:xf},On={id:V.RELATIONAL_DATABASE,version:1,description:"This entity provisions a relational database in the cloud.",name:V.RELATIONAL_DATABASE,type:r.BuiltInBaseEntity,abstract:!0,static:!0,interactive:!1,properties:[ja,qa,Ja,Wa,Ko,el],abstractMethods:[],methods:[],extends:[]},kf={type:r.GenericReference,entityId:"persisted-built-in-base-entity-ref-id",entityType:r.BuiltInBaseEntity,id:Ot.DeletePersistedEntity},tl={type:r.FunctionDeclaration,id:Ot.DeletePersistedEntity,name:Ot.DeletePersistedEntity,description:"Permanently deletes the current copy of an entity from the database",version:1,parent:kf,inputs:[],calls:[],implements:null,collapsed:!1,returnStatements:[],index:0,private:!1,x:0,y:0},jf={type:r.GenericReference,entityId:"persisted-built-in-base-entity-ref-id",entityType:r.BuiltInBaseEntity,id:Ot.SoftDeletePersistedEntity},qf={type:r.FunctionDeclaration,id:Ot.SoftDeletePersistedEntity,name:Ot.SoftDeletePersistedEntity,description:"Designates the entity as deleted, but does not remove it from the database.",version:1,parent:jf,inputs:[],calls:[],implements:null,collapsed:!1,returnStatements:[],index:0,private:!1,x:0,y:0},Jf=x[r.BuiltInBaseEntity][V.PERSISTED_ENTITY].properties,VI={id:"persisted-built-in-base-entity-database-property-data-type-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-database-property-data-type-id",entityType:r.DataType},Wf={id:"persisted-built-in-base-entity-database-property-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-database-property-id",entityType:r.Property},$I={like:!1,id:"persisted-built-in-base-entity-database-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:On,asType:!1,defaultValue:null,parent:Wf},Hf={id:"persisted-built-in-base-entity-database-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},Pi={hidden:!0,required:!0,id:Jf.database.id,name:"Database",version:1,type:r.Property,private:!1,abstract:!0,implements:null,static:!0,index:0,dataType:$I,description:"The database that the entity belongs to.",parent:Hf},Yf={id:"persisted-built-in-base-entity-identifier-property-data-type-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-identifier-property-data-type-id",entityType:r.DataType},zf={id:"persisted-built-in-base-entity-identifier-property-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-identifier-property-id",entityType:r.Property},LI={like:!1,id:"persisted-built-in-base-entity-identifier-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ba,asType:!1,defaultValue:{id:"persisted-built-in-base-entity-identifier-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.UUID,value:null,parent:Yf,autogeneration:{type:qe.Unique,rangeStart:null,rangeEnd:null},valueAsType:null},parent:zf},Zf={id:"persisted-built-in-base-entity-identifier-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},Xf={hidden:!1,required:!0,id:Jf.identifier.id,name:"Identifier",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:0,dataType:LI,description:"Auto-generated unique identifier for the entity, can be used to identify the entity among other entities of the same type.",parent:Zf},GI={id:"persisted-built-in-base-entity-deleted-at-property-data-type-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-deleted-at-property-data-type-id",entityType:r.DataType},Qf={id:"persisted-built-in-base-entity-deleted-at-property-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-deleted-at-property-id",entityType:r.Property},Kf={like:!1,id:"persisted-built-in-base-entity-deleted-at-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!0,constant:!1,entity:cn,asType:!1,defaultValue:null,parent:Qf},em={id:"persisted-built-in-base-entity-deleted-at-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},tm={hidden:!1,required:!0,id:"persisted-built-in-base-entity-deleted-at-property-id",name:"Deleted at",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:0,dataType:Kf,description:"The date and time when the entity was deleted.",parent:em},FI={id:"persisted-built-in-base-entity-created-at-property-data-type-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-created-at-property-data-type-id",entityType:r.DataType},nm={id:"persisted-built-in-base-entity-created-at-property-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-created-at-property-id",entityType:r.Property},rm={like:!1,id:"persisted-built-in-base-entity-created-at-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:cn,asType:!1,defaultValue:null,parent:nm},im={id:"persisted-built-in-base-entity-created-at-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},am={hidden:!1,required:!0,id:"persisted-built-in-base-entity-created-at-property-id",name:"Created at",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:0,dataType:rm,description:"The date and time when the entity was created.",parent:im},UI={id:"persisted-built-in-base-entity-updated-at-property-data-type-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-updated-at-property-data-type-id",entityType:r.DataType},sm={id:"persisted-built-in-base-entity-updated-at-property-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-updated-at-property-id",entityType:r.Property},om={like:!1,id:"persisted-built-in-base-entity-updated-at-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:cn,asType:!1,defaultValue:null,parent:sm},lm={id:"persisted-built-in-base-entity-updated-at-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},cm={hidden:!1,required:!0,id:"persisted-built-in-base-entity-updated-at-property-id",name:"Updated at",version:1,type:r.Property,private:!1,implements:null,abstract:!1,static:!1,index:0,dataType:om,description:"The date and time when the entity was last updated.",parent:lm},Le={id:V.PERSISTED_ENTITY,version:1,description:"An entity that is permanently stored in the database and can be accessed at any point.",name:V.PERSISTED_ENTITY,type:r.BuiltInBaseEntity,abstract:!0,static:!1,interactive:!0,abstractMethods:[],properties:[Pi,Xf,tm,am,cm],methods:[tl,qf],extends:[]},dm={id:"cron-job-triggered-function-declaration-blueprint-parent-ref-id",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},nl={id:"cron-job-triggered-function-declaration-blueprint-id",name:"Cron job triggered",version:1,type:r.ActionDescriptor,argumentsType:U.None,returnsType:U.None,description:"Executed when the cron job is triggered",fixedArguments:[],dynamicArgumentTypes:null,error:null,fixedReturns:[],dynamicReturnTypes:null,parent:dm},um=x[r.BuiltInBaseEntity].BUILT_IN_CRON_JOB_ENTITY,xI={id:"cron-job-built-in-base-entity-expression-property-data-type-ref",type:r.GenericReference,entityId:"cron-job-built-in-base-entity-expression-property-data-type",entityType:r.DataType},pm={id:"cron-job-built-in-base-entity-expression-property-ref",type:r.GenericReference,entityId:um.properties.expression.id,entityType:r.Property},kI={like:!1,id:"cron-job-built-in-base-entity-expression-property-data-type",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:null,parent:pm},ym={id:"cron-job-built-in-base-entity-ref",type:r.GenericReference,entityId:V.CRON_JOB,entityType:r.BuiltInBaseEntity},hm={hidden:!1,required:!0,id:um.properties.expression.id,name:"Cron expression",version:1,type:r.Property,private:!1,abstract:!0,implements:null,static:!0,index:0,dataType:kI,description:"The cron-job expression that defines when the cron-job job should be triggered. The expression should be in the format of a cron-job expression.",parent:ym},rl={id:V.CRON_JOB,version:1,description:"This entity represents a scheduled trigger. The action on this entity will be executed one the time set by the cron-job expression is reached.",name:V.CRON_JOB,type:r.BuiltInBaseEntity,abstract:!0,static:!0,interactive:!1,properties:[hm],methods:[],abstractMethods:[nl],extends:[]},fm={type:r.GenericReference,id:"execution-built-in-entity-abort-method-parent-ref-id",entityType:r.BuiltInBaseEntity,entityId:"execution-built-in-entity-id"},il={id:"execution-built-in-entity-abort-method-id",type:r.FunctionDeclaration,version:1,name:Ot.AbortExecution,description:"Aborts the execution of the entity",inputs:[],returnStatements:[],calls:[],implements:null,private:!1,collapsed:!1,index:null,x:0,y:0,parent:fm},al={id:V.EXECUTION,type:r.BuiltInBaseEntity,version:1,name:V.EXECUTION,description:"A reference to an ongoing execution of any entity that can be called. Eg: Operations, custom trigger calls, etc.",static:!1,abstract:!1,interactive:!0,extends:[],properties:[],methods:[il],abstractMethods:[]},jI=x[r.Condition]["not-empty"],mm={type:r.GenericReference,id:"not-empty-condition-ref",entityType:r.ActionDescriptor,entityId:Nt.NotEmpty},Tm={id:jI.inputs.leftHand.id,type:r.ValueDescriptor,version:1,name:"Value",description:"The value to check if it is not empty",dataType:null,required:!0,parentRelationType:M.FixedArguments,index:0,parent:mm},er={type:r.ActionDescriptor,id:Nt.NotEmpty,version:1,name:Nt.NotEmpty,description:"Checks if the value is not empty",parent:null,fixedArguments:[Tm],fixedReturns:[],dynamicArgumentTypes:null,dynamicReturnTypes:null,argumentsType:U.Fixed,returnsType:U.None,error:null},Em={[Nt.NotEmpty]:er},Rm=x[r.Condition]["more-than-or-equal"],bm={type:r.GenericReference,id:"more-than-or-equal-condition-left-hand-argument-parent-ref",entityType:r.ActionDescriptor,entityId:_e.MoreThanOrEqual},gm={id:Rm.inputs.leftHand.id,type:r.ValueDescriptor,version:1,name:"First value",description:"The first value to compare",dataType:null,required:!0,parentRelationType:M.FixedArguments,index:0,parent:bm},vm={type:r.GenericReference,id:"more-than-or-equal-condition-right-hand-argument-parent-ref",entityType:r.ActionDescriptor,entityId:_e.MoreThanOrEqual},Im={id:Rm.inputs.rightHand.id,type:r.ValueDescriptor,version:1,name:"Second value",description:"The second value to compare",dataType:null,required:!0,parentRelationType:M.FixedArguments,index:1,parent:vm},Ur={type:r.ActionDescriptor,id:_e.MoreThanOrEqual,version:1,name:_e.MoreThanOrEqual,description:"Checks if the value is not empty",parent:null,fixedArguments:[gm,Im],fixedReturns:[],dynamicArgumentTypes:null,dynamicReturnTypes:null,argumentsType:U.Fixed,returnsType:U.None,error:null},Dm={[_e.MoreThanOrEqual]:Ur},qI={...Em,...Dm},Ha={type:r.ActionDescriptor,id:on.PROJECT_PUBLICATION_COMPLETED,version:1,name:on.PROJECT_PUBLICATION_COMPLETED,description:"The event that is triggered when the project has completed its publication and all its code and resurces are now deployed and ready to be used by the users",parent:null,fixedArguments:[],fixedReturns:[],dynamicArgumentTypes:null,dynamicReturnTypes:null,argumentsType:U.None,returnsType:U.None,error:null},JI={[on.PROJECT_PUBLICATION_COMPLETED]:Ha},sl=x[r.ValueDescriptor][wo.ActionOngoingProcessOutputValue],Pm={type:r.GenericReference,id:"182f767f-50e8-4394-ba5f-43e78c232733",entityType:r.ValueDescriptor,entityId:sl.id},Am={like:!1,id:sl.dataType.id,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:al,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Pm},ol={id:sl.id,type:r.ValueDescriptor,description:"A value that represents the ongoing process of the parent action",version:1,name:"Process",dataType:Am,required:!0,index:0,parent:null,parentRelationType:M.OngoingProcessExecution};var ee;(function(n){n.assertEqual=a=>a;function e(a){}n.assertIs=e;function t(a){throw new Error}n.assertNever=t,n.arrayToEnum=a=>{const s={};for(const o of a)s[o]=o;return s},n.getValidEnumValues=a=>{const s=n.objectKeys(a).filter(l=>typeof a[a[l]]!="number"),o={};for(const l of s)o[l]=a[l];return n.objectValues(o)},n.objectValues=a=>n.objectKeys(a).map(function(s){return a[s]}),n.objectKeys=typeof Object.keys=="function"?a=>Object.keys(a):a=>{const s=[];for(const o in a)Object.prototype.hasOwnProperty.call(a,o)&&s.push(o);return s},n.find=(a,s)=>{for(const o of a)if(s(o))return o},n.isInteger=typeof Number.isInteger=="function"?a=>Number.isInteger(a):a=>typeof a=="number"&&isFinite(a)&&Math.floor(a)===a;function i(a,s=" | "){return a.map(o=>typeof o=="string"?`'${o}'`:o).join(s)}n.joinValues=i,n.jsonStringifyReplacer=(a,s)=>typeof s=="bigint"?s.toString():s})(ee||(ee={}));var ll;(function(n){n.mergeShapes=(e,t)=>({...e,...t})})(ll||(ll={}));const $=ee.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),Cn=n=>{switch(typeof n){case"undefined":return $.undefined;case"string":return $.string;case"number":return isNaN(n)?$.nan:$.number;case"boolean":return $.boolean;case"function":return $.function;case"bigint":return $.bigint;case"symbol":return $.symbol;case"object":return Array.isArray(n)?$.array:n===null?$.null:n.then&&typeof n.then=="function"&&n.catch&&typeof n.catch=="function"?$.promise:typeof Map<"u"&&n instanceof Map?$.map:typeof Set<"u"&&n instanceof Set?$.set:typeof Date<"u"&&n instanceof Date?$.date:$.object;default:return $.unknown}},O=ee.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),WI=n=>JSON.stringify(n,null,2).replace(/"([^"]+)":/g,"$1:");class bt extends Error{constructor(e){super(),this.issues=[],this.addIssue=i=>{this.issues=[...this.issues,i]},this.addIssues=(i=[])=>{this.issues=[...this.issues,...i]};const t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}get errors(){return this.issues}format(e){const t=e||function(s){return s.message},i={_errors:[]},a=s=>{for(const o of s.issues)if(o.code==="invalid_union")o.unionErrors.map(a);else if(o.code==="invalid_return_type")a(o.returnTypeError);else if(o.code==="invalid_arguments")a(o.argumentsError);else if(o.path.length===0)i._errors.push(t(o));else{let l=i,p=0;for(;p<o.path.length;){const y=o.path[p];p===o.path.length-1?(l[y]=l[y]||{_errors:[]},l[y]._errors.push(t(o))):l[y]=l[y]||{_errors:[]},l=l[y],p++}}};return a(this),i}static assert(e){if(!(e instanceof bt))throw new Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,ee.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=t=>t.message){const t={},i=[];for(const a of this.issues)a.path.length>0?(t[a.path[0]]=t[a.path[0]]||[],t[a.path[0]].push(e(a))):i.push(e(a));return{formErrors:i,fieldErrors:t}}get formErrors(){return this.flatten()}}bt.create=n=>new bt(n);const xr=(n,e)=>{let t;switch(n.code){case O.invalid_type:n.received===$.undefined?t="Required":t=`Expected ${n.expected}, received ${n.received}`;break;case O.invalid_literal:t=`Invalid literal value, expected ${JSON.stringify(n.expected,ee.jsonStringifyReplacer)}`;break;case O.unrecognized_keys:t=`Unrecognized key(s) in object: ${ee.joinValues(n.keys,", ")}`;break;case O.invalid_union:t="Invalid input";break;case O.invalid_union_discriminator:t=`Invalid discriminator value. Expected ${ee.joinValues(n.options)}`;break;case O.invalid_enum_value:t=`Invalid enum value. Expected ${ee.joinValues(n.options)}, received '${n.received}'`;break;case O.invalid_arguments:t="Invalid function arguments";break;case O.invalid_return_type:t="Invalid function return type";break;case O.invalid_date:t="Invalid date";break;case O.invalid_string:typeof n.validation=="object"?"includes"in n.validation?(t=`Invalid input: must include "${n.validation.includes}"`,typeof n.validation.position=="number"&&(t=`${t} at one or more positions greater than or equal to ${n.validation.position}`)):"startsWith"in n.validation?t=`Invalid input: must start with "${n.validation.startsWith}"`:"endsWith"in n.validation?t=`Invalid input: must end with "${n.validation.endsWith}"`:ee.assertNever(n.validation):n.validation!=="regex"?t=`Invalid ${n.validation}`:t="Invalid";break;case O.too_small:n.type==="array"?t=`Array must contain ${n.exact?"exactly":n.inclusive?"at least":"more than"} ${n.minimum} element(s)`:n.type==="string"?t=`String must contain ${n.exact?"exactly":n.inclusive?"at least":"over"} ${n.minimum} character(s)`:n.type==="number"?t=`Number must be ${n.exact?"exactly equal to ":n.inclusive?"greater than or equal to ":"greater than "}${n.minimum}`:n.type==="date"?t=`Date must be ${n.exact?"exactly equal to ":n.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(n.minimum))}`:t="Invalid input";break;case O.too_big:n.type==="array"?t=`Array must contain ${n.exact?"exactly":n.inclusive?"at most":"less than"} ${n.maximum} element(s)`:n.type==="string"?t=`String must contain ${n.exact?"exactly":n.inclusive?"at most":"under"} ${n.maximum} character(s)`:n.type==="number"?t=`Number must be ${n.exact?"exactly":n.inclusive?"less than or equal to":"less than"} ${n.maximum}`:n.type==="bigint"?t=`BigInt must be ${n.exact?"exactly":n.inclusive?"less than or equal to":"less than"} ${n.maximum}`:n.type==="date"?t=`Date must be ${n.exact?"exactly":n.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(n.maximum))}`:t="Invalid input";break;case O.custom:t="Invalid input";break;case O.invalid_intersection_types:t="Intersection results could not be merged";break;case O.not_multiple_of:t=`Number must be a multiple of ${n.multipleOf}`;break;case O.not_finite:t="Number must be finite";break;default:t=e.defaultError,ee.assertNever(n)}return{message:t}};let Sm=xr;function HI(n){Sm=n}function Ya(){return Sm}const za=n=>{const{data:e,path:t,errorMaps:i,issueData:a}=n,s=[...t,...a.path||[]],o={...a,path:s};if(a.message!==void 0)return{...a,path:s,message:a.message};let l="";const p=i.filter(y=>!!y).slice().reverse();for(const y of p)l=y(o,{data:e,defaultError:l}).message;return{...a,path:s,message:l}},YI=[];function N(n,e){const t=Ya(),i=za({issueData:e,data:n.data,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,t,t===xr?void 0:xr].filter(a=>!!a)});n.common.issues.push(i)}class tt{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(e,t){const i=[];for(const a of t){if(a.status==="aborted")return q;a.status==="dirty"&&e.dirty(),i.push(a.value)}return{status:e.value,value:i}}static async mergeObjectAsync(e,t){const i=[];for(const a of t){const s=await a.key,o=await a.value;i.push({key:s,value:o})}return tt.mergeObjectSync(e,i)}static mergeObjectSync(e,t){const i={};for(const a of t){const{key:s,value:o}=a;if(s.status==="aborted"||o.status==="aborted")return q;s.status==="dirty"&&e.dirty(),o.status==="dirty"&&e.dirty(),s.value!=="__proto__"&&(typeof o.value<"u"||a.alwaysSet)&&(i[s.value]=o.value)}return{status:e.value,value:i}}}const q=Object.freeze({status:"aborted"}),kr=n=>({status:"dirty",value:n}),ut=n=>({status:"valid",value:n}),cl=n=>n.status==="aborted",dl=n=>n.status==="dirty",Ai=n=>n.status==="valid",Si=n=>typeof Promise<"u"&&n instanceof Promise;function Za(n,e,t,i){if(t==="a"&&!i)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?n!==e||!i:!e.has(n))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?i:t==="a"?i.call(n):i?i.value:e.get(n)}function Om(n,e,t,i,a){if(i==="m")throw new TypeError("Private method is not writable");if(i==="a"&&!a)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?n!==e||!a:!e.has(n))throw new TypeError("Cannot write private member to an object whose class did not declare it");return i==="a"?a.call(n,t):a?a.value=t:e.set(n,t),t}typeof SuppressedError=="function"&&SuppressedError;var F;(function(n){n.errToObj=e=>typeof e=="string"?{message:e}:e||{},n.toString=e=>typeof e=="string"?e:e==null?void 0:e.message})(F||(F={}));var Oi,Ci;class zt{constructor(e,t,i,a){this._cachedPath=[],this.parent=e,this.data=t,this._path=i,this._key=a}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const Cm=(n,e)=>{if(Ai(e))return{success:!0,data:e.value};if(!n.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const t=new bt(n.common.issues);return this._error=t,this._error}}};function z(n){if(!n)return{};const{errorMap:e,invalid_type_error:t,required_error:i,description:a}=n;if(e&&(t||i))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return e?{errorMap:e,description:a}:{errorMap:(o,l)=>{var p,y;const{message:f}=n;return o.code==="invalid_enum_value"?{message:f??l.defaultError}:typeof l.data>"u"?{message:(p=f??i)!==null&&p!==void 0?p:l.defaultError}:o.code!=="invalid_type"?{message:l.defaultError}:{message:(y=f??t)!==null&&y!==void 0?y:l.defaultError}},description:a}}class X{constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this)}get description(){return this._def.description}_getType(e){return Cn(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:Cn(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new tt,ctx:{common:e.parent.common,data:e.data,parsedType:Cn(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){const t=this._parse(e);if(Si(t))throw new Error("Synchronous parse encountered promise.");return t}_parseAsync(e){const t=this._parse(e);return Promise.resolve(t)}parse(e,t){const i=this.safeParse(e,t);if(i.success)return i.data;throw i.error}safeParse(e,t){var i;const a={common:{issues:[],async:(i=t==null?void 0:t.async)!==null&&i!==void 0?i:!1,contextualErrorMap:t==null?void 0:t.errorMap},path:(t==null?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:Cn(e)},s=this._parseSync({data:e,path:a.path,parent:a});return Cm(a,s)}async parseAsync(e,t){const i=await this.safeParseAsync(e,t);if(i.success)return i.data;throw i.error}async safeParseAsync(e,t){const i={common:{issues:[],contextualErrorMap:t==null?void 0:t.errorMap,async:!0},path:(t==null?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:Cn(e)},a=this._parse({data:e,path:i.path,parent:i}),s=await(Si(a)?a:Promise.resolve(a));return Cm(i,s)}refine(e,t){const i=a=>typeof t=="string"||typeof t>"u"?{message:t}:typeof t=="function"?t(a):t;return this._refinement((a,s)=>{const o=e(a),l=()=>s.addIssue({code:O.custom,...i(a)});return typeof Promise<"u"&&o instanceof Promise?o.then(p=>p?!0:(l(),!1)):o?!0:(l(),!1)})}refinement(e,t){return this._refinement((i,a)=>e(i)?!0:(a.addIssue(typeof t=="function"?t(i,a):t),!1))}_refinement(e){return new qt({schema:this,typeName:j.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}optional(){return Xt.create(this,this._def)}nullable(){return Mn.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return jt.create(this,this._def)}promise(){return Wr.create(this,this._def)}or(e){return Mi.create([this,e],this._def)}and(e){return Ni.create(this,e,this._def)}transform(e){return new qt({...z(this._def),schema:this,typeName:j.ZodEffects,effect:{type:"transform",transform:e}})}default(e){const t=typeof e=="function"?e:()=>e;return new Fi({...z(this._def),innerType:this,defaultValue:t,typeName:j.ZodDefault})}brand(){return new yl({typeName:j.ZodBranded,type:this,...z(this._def)})}catch(e){const t=typeof e=="function"?e:()=>e;return new Ui({...z(this._def),innerType:this,catchValue:t,typeName:j.ZodCatch})}describe(e){const t=this.constructor;return new t({...this._def,description:e})}pipe(e){return xi.create(this,e)}readonly(){return ki.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const zI=/^c[^\s-]{8,}$/i,ZI=/^[0-9a-z]+$/,XI=/^[0-9A-HJKMNP-TV-Z]{26}$/,QI=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,KI=/^[a-z0-9_-]{21}$/i,eD=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,tD=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,nD="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let ul;const rD=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,iD=/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/,aD=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,Bm="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",sD=new RegExp(`^${Bm}$`);function wm(n){let e="([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d";return n.precision?e=`${e}\\.\\d{${n.precision}}`:n.precision==null&&(e=`${e}(\\.\\d+)?`),e}function oD(n){return new RegExp(`^${wm(n)}$`)}function _m(n){let e=`${Bm}T${wm(n)}`;const t=[];return t.push(n.local?"Z?":"Z"),n.offset&&t.push("([+-]\\d{2}:?\\d{2})"),e=`${e}(${t.join("|")})`,new RegExp(`^${e}$`)}function lD(n,e){return!!((e==="v4"||!e)&&rD.test(n)||(e==="v6"||!e)&&iD.test(n))}class kt extends X{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==$.string){const s=this._getOrReturnCtx(e);return N(s,{code:O.invalid_type,expected:$.string,received:s.parsedType}),q}const i=new tt;let a;for(const s of this._def.checks)if(s.kind==="min")e.data.length<s.value&&(a=this._getOrReturnCtx(e,a),N(a,{code:O.too_small,minimum:s.value,type:"string",inclusive:!0,exact:!1,message:s.message}),i.dirty());else if(s.kind==="max")e.data.length>s.value&&(a=this._getOrReturnCtx(e,a),N(a,{code:O.too_big,maximum:s.value,type:"string",inclusive:!0,exact:!1,message:s.message}),i.dirty());else if(s.kind==="length"){const o=e.data.length>s.value,l=e.data.length<s.value;(o||l)&&(a=this._getOrReturnCtx(e,a),o?N(a,{code:O.too_big,maximum:s.value,type:"string",inclusive:!0,exact:!0,message:s.message}):l&&N(a,{code:O.too_small,minimum:s.value,type:"string",inclusive:!0,exact:!0,message:s.message}),i.dirty())}else if(s.kind==="email")tD.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"email",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="emoji")ul||(ul=new RegExp(nD,"u")),ul.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"emoji",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="uuid")QI.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"uuid",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="nanoid")KI.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"nanoid",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="cuid")zI.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"cuid",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="cuid2")ZI.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"cuid2",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="ulid")XI.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"ulid",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="url")try{new URL(e.data)}catch{a=this._getOrReturnCtx(e,a),N(a,{validation:"url",code:O.invalid_string,message:s.message}),i.dirty()}else s.kind==="regex"?(s.regex.lastIndex=0,s.regex.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"regex",code:O.invalid_string,message:s.message}),i.dirty())):s.kind==="trim"?e.data=e.data.trim():s.kind==="includes"?e.data.includes(s.value,s.position)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:{includes:s.value,position:s.position},message:s.message}),i.dirty()):s.kind==="toLowerCase"?e.data=e.data.toLowerCase():s.kind==="toUpperCase"?e.data=e.data.toUpperCase():s.kind==="startsWith"?e.data.startsWith(s.value)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:{startsWith:s.value},message:s.message}),i.dirty()):s.kind==="endsWith"?e.data.endsWith(s.value)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:{endsWith:s.value},message:s.message}),i.dirty()):s.kind==="datetime"?_m(s).test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:"datetime",message:s.message}),i.dirty()):s.kind==="date"?sD.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:"date",message:s.message}),i.dirty()):s.kind==="time"?oD(s).test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:"time",message:s.message}),i.dirty()):s.kind==="duration"?eD.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"duration",code:O.invalid_string,message:s.message}),i.dirty()):s.kind==="ip"?lD(e.data,s.version)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"ip",code:O.invalid_string,message:s.message}),i.dirty()):s.kind==="base64"?aD.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"base64",code:O.invalid_string,message:s.message}),i.dirty()):ee.assertNever(s);return{status:i.value,value:e.data}}_regex(e,t,i){return this.refinement(a=>e.test(a),{validation:t,code:O.invalid_string,...F.errToObj(i)})}_addCheck(e){return new kt({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...F.errToObj(e)})}url(e){return this._addCheck({kind:"url",...F.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...F.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...F.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...F.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...F.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...F.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...F.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...F.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...F.errToObj(e)})}datetime(e){var t,i;return typeof e=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:typeof(e==null?void 0:e.precision)>"u"?null:e==null?void 0:e.precision,offset:(t=e==null?void 0:e.offset)!==null&&t!==void 0?t:!1,local:(i=e==null?void 0:e.local)!==null&&i!==void 0?i:!1,...F.errToObj(e==null?void 0:e.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return typeof e=="string"?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:typeof(e==null?void 0:e.precision)>"u"?null:e==null?void 0:e.precision,...F.errToObj(e==null?void 0:e.message)})}duration(e){return this._addCheck({kind:"duration",...F.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...F.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:t==null?void 0:t.position,...F.errToObj(t==null?void 0:t.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...F.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...F.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...F.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...F.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...F.errToObj(t)})}nonempty(e){return this.min(1,F.errToObj(e))}trim(){return new kt({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new kt({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new kt({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>e.kind==="datetime")}get isDate(){return!!this._def.checks.find(e=>e.kind==="date")}get isTime(){return!!this._def.checks.find(e=>e.kind==="time")}get isDuration(){return!!this._def.checks.find(e=>e.kind==="duration")}get isEmail(){return!!this._def.checks.find(e=>e.kind==="email")}get isURL(){return!!this._def.checks.find(e=>e.kind==="url")}get isEmoji(){return!!this._def.checks.find(e=>e.kind==="emoji")}get isUUID(){return!!this._def.checks.find(e=>e.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(e=>e.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(e=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(e=>e.kind==="cuid2")}get isULID(){return!!this._def.checks.find(e=>e.kind==="ulid")}get isIP(){return!!this._def.checks.find(e=>e.kind==="ip")}get isBase64(){return!!this._def.checks.find(e=>e.kind==="base64")}get minLength(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}}kt.create=n=>{var e;return new kt({checks:[],typeName:j.ZodString,coerce:(e=n==null?void 0:n.coerce)!==null&&e!==void 0?e:!1,...z(n)})};function cD(n,e){const t=(n.toString().split(".")[1]||"").length,i=(e.toString().split(".")[1]||"").length,a=t>i?t:i,s=parseInt(n.toFixed(a).replace(".","")),o=parseInt(e.toFixed(a).replace(".",""));return s%o/Math.pow(10,a)}class Bn extends X{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==$.number){const s=this._getOrReturnCtx(e);return N(s,{code:O.invalid_type,expected:$.number,received:s.parsedType}),q}let i;const a=new tt;for(const s of this._def.checks)s.kind==="int"?ee.isInteger(e.data)||(i=this._getOrReturnCtx(e,i),N(i,{code:O.invalid_type,expected:"integer",received:"float",message:s.message}),a.dirty()):s.kind==="min"?(s.inclusive?e.data<s.value:e.data<=s.value)&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.too_small,minimum:s.value,type:"number",inclusive:s.inclusive,exact:!1,message:s.message}),a.dirty()):s.kind==="max"?(s.inclusive?e.data>s.value:e.data>=s.value)&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.too_big,maximum:s.value,type:"number",inclusive:s.inclusive,exact:!1,message:s.message}),a.dirty()):s.kind==="multipleOf"?cD(e.data,s.value)!==0&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.not_multiple_of,multipleOf:s.value,message:s.message}),a.dirty()):s.kind==="finite"?Number.isFinite(e.data)||(i=this._getOrReturnCtx(e,i),N(i,{code:O.not_finite,message:s.message}),a.dirty()):ee.assertNever(s);return{status:a.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,F.toString(t))}gt(e,t){return this.setLimit("min",e,!1,F.toString(t))}lte(e,t){return this.setLimit("max",e,!0,F.toString(t))}lt(e,t){return this.setLimit("max",e,!1,F.toString(t))}setLimit(e,t,i,a){return new Bn({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:i,message:F.toString(a)}]})}_addCheck(e){return new Bn({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:F.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:F.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:F.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:F.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:F.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:F.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:F.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:F.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:F.toString(e)})}get minValue(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind==="int"||e.kind==="multipleOf"&&ee.isInteger(e.value))}get isFinite(){let e=null,t=null;for(const i of this._def.checks){if(i.kind==="finite"||i.kind==="int"||i.kind==="multipleOf")return!0;i.kind==="min"?(t===null||i.value>t)&&(t=i.value):i.kind==="max"&&(e===null||i.value<e)&&(e=i.value)}return Number.isFinite(t)&&Number.isFinite(e)}}Bn.create=n=>new Bn({checks:[],typeName:j.ZodNumber,coerce:(n==null?void 0:n.coerce)||!1,...z(n)});class wn extends X{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce&&(e.data=BigInt(e.data)),this._getType(e)!==$.bigint){const s=this._getOrReturnCtx(e);return N(s,{code:O.invalid_type,expected:$.bigint,received:s.parsedType}),q}let i;const a=new tt;for(const s of this._def.checks)s.kind==="min"?(s.inclusive?e.data<s.value:e.data<=s.value)&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.too_small,type:"bigint",minimum:s.value,inclusive:s.inclusive,message:s.message}),a.dirty()):s.kind==="max"?(s.inclusive?e.data>s.value:e.data>=s.value)&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.too_big,type:"bigint",maximum:s.value,inclusive:s.inclusive,message:s.message}),a.dirty()):s.kind==="multipleOf"?e.data%s.value!==BigInt(0)&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.not_multiple_of,multipleOf:s.value,message:s.message}),a.dirty()):ee.assertNever(s);return{status:a.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,F.toString(t))}gt(e,t){return this.setLimit("min",e,!1,F.toString(t))}lte(e,t){return this.setLimit("max",e,!0,F.toString(t))}lt(e,t){return this.setLimit("max",e,!1,F.toString(t))}setLimit(e,t,i,a){return new wn({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:i,message:F.toString(a)}]})}_addCheck(e){return new wn({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:F.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:F.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:F.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:F.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:F.toString(t)})}get minValue(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}}wn.create=n=>{var e;return new wn({checks:[],typeName:j.ZodBigInt,coerce:(e=n==null?void 0:n.coerce)!==null&&e!==void 0?e:!1,...z(n)})};class Bi extends X{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==$.boolean){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.boolean,received:i.parsedType}),q}return ut(e.data)}}Bi.create=n=>new Bi({typeName:j.ZodBoolean,coerce:(n==null?void 0:n.coerce)||!1,...z(n)});class tr extends X{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==$.date){const s=this._getOrReturnCtx(e);return N(s,{code:O.invalid_type,expected:$.date,received:s.parsedType}),q}if(isNaN(e.data.getTime())){const s=this._getOrReturnCtx(e);return N(s,{code:O.invalid_date}),q}const i=new tt;let a;for(const s of this._def.checks)s.kind==="min"?e.data.getTime()<s.value&&(a=this._getOrReturnCtx(e,a),N(a,{code:O.too_small,message:s.message,inclusive:!0,exact:!1,minimum:s.value,type:"date"}),i.dirty()):s.kind==="max"?e.data.getTime()>s.value&&(a=this._getOrReturnCtx(e,a),N(a,{code:O.too_big,message:s.message,inclusive:!0,exact:!1,maximum:s.value,type:"date"}),i.dirty()):ee.assertNever(s);return{status:i.value,value:new Date(e.data.getTime())}}_addCheck(e){return new tr({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:F.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:F.toString(t)})}get minDate(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e!=null?new Date(e):null}get maxDate(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e!=null?new Date(e):null}}tr.create=n=>new tr({checks:[],coerce:(n==null?void 0:n.coerce)||!1,typeName:j.ZodDate,...z(n)});class Xa extends X{_parse(e){if(this._getType(e)!==$.symbol){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.symbol,received:i.parsedType}),q}return ut(e.data)}}Xa.create=n=>new Xa({typeName:j.ZodSymbol,...z(n)});class wi extends X{_parse(e){if(this._getType(e)!==$.undefined){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.undefined,received:i.parsedType}),q}return ut(e.data)}}wi.create=n=>new wi({typeName:j.ZodUndefined,...z(n)});class _i extends X{_parse(e){if(this._getType(e)!==$.null){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.null,received:i.parsedType}),q}return ut(e.data)}}_i.create=n=>new _i({typeName:j.ZodNull,...z(n)});class jr extends X{constructor(){super(...arguments),this._any=!0}_parse(e){return ut(e.data)}}jr.create=n=>new jr({typeName:j.ZodAny,...z(n)});class nr extends X{constructor(){super(...arguments),this._unknown=!0}_parse(e){return ut(e.data)}}nr.create=n=>new nr({typeName:j.ZodUnknown,...z(n)});class un extends X{_parse(e){const t=this._getOrReturnCtx(e);return N(t,{code:O.invalid_type,expected:$.never,received:t.parsedType}),q}}un.create=n=>new un({typeName:j.ZodNever,...z(n)});class Qa extends X{_parse(e){if(this._getType(e)!==$.undefined){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.void,received:i.parsedType}),q}return ut(e.data)}}Qa.create=n=>new Qa({typeName:j.ZodVoid,...z(n)});class jt extends X{_parse(e){const{ctx:t,status:i}=this._processInputParams(e),a=this._def;if(t.parsedType!==$.array)return N(t,{code:O.invalid_type,expected:$.array,received:t.parsedType}),q;if(a.exactLength!==null){const o=t.data.length>a.exactLength.value,l=t.data.length<a.exactLength.value;(o||l)&&(N(t,{code:o?O.too_big:O.too_small,minimum:l?a.exactLength.value:void 0,maximum:o?a.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:a.exactLength.message}),i.dirty())}if(a.minLength!==null&&t.data.length<a.minLength.value&&(N(t,{code:O.too_small,minimum:a.minLength.value,type:"array",inclusive:!0,exact:!1,message:a.minLength.message}),i.dirty()),a.maxLength!==null&&t.data.length>a.maxLength.value&&(N(t,{code:O.too_big,maximum:a.maxLength.value,type:"array",inclusive:!0,exact:!1,message:a.maxLength.message}),i.dirty()),t.common.async)return Promise.all([...t.data].map((o,l)=>a.type._parseAsync(new zt(t,o,t.path,l)))).then(o=>tt.mergeArray(i,o));const s=[...t.data].map((o,l)=>a.type._parseSync(new zt(t,o,t.path,l)));return tt.mergeArray(i,s)}get element(){return this._def.type}min(e,t){return new jt({...this._def,minLength:{value:e,message:F.toString(t)}})}max(e,t){return new jt({...this._def,maxLength:{value:e,message:F.toString(t)}})}length(e,t){return new jt({...this._def,exactLength:{value:e,message:F.toString(t)}})}nonempty(e){return this.min(1,e)}}jt.create=(n,e)=>new jt({type:n,minLength:null,maxLength:null,exactLength:null,typeName:j.ZodArray,...z(e)});function qr(n){if(n instanceof Ge){const e={};for(const t in n.shape){const i=n.shape[t];e[t]=Xt.create(qr(i))}return new Ge({...n._def,shape:()=>e})}else return n instanceof jt?new jt({...n._def,type:qr(n.element)}):n instanceof Xt?Xt.create(qr(n.unwrap())):n instanceof Mn?Mn.create(qr(n.unwrap())):n instanceof Zt?Zt.create(n.items.map(e=>qr(e))):n}class Ge extends X{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const e=this._def.shape(),t=ee.objectKeys(e);return this._cached={shape:e,keys:t}}_parse(e){if(this._getType(e)!==$.object){const y=this._getOrReturnCtx(e);return N(y,{code:O.invalid_type,expected:$.object,received:y.parsedType}),q}const{status:i,ctx:a}=this._processInputParams(e),{shape:s,keys:o}=this._getCached(),l=[];if(!(this._def.catchall instanceof un&&this._def.unknownKeys==="strip"))for(const y in a.data)o.includes(y)||l.push(y);const p=[];for(const y of o){const f=s[y],m=a.data[y];p.push({key:{status:"valid",value:y},value:f._parse(new zt(a,m,a.path,y)),alwaysSet:y in a.data})}if(this._def.catchall instanceof un){const y=this._def.unknownKeys;if(y==="passthrough")for(const f of l)p.push({key:{status:"valid",value:f},value:{status:"valid",value:a.data[f]}});else if(y==="strict")l.length>0&&(N(a,{code:O.unrecognized_keys,keys:l}),i.dirty());else if(y!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const y=this._def.catchall;for(const f of l){const m=a.data[f];p.push({key:{status:"valid",value:f},value:y._parse(new zt(a,m,a.path,f)),alwaysSet:f in a.data})}}return a.common.async?Promise.resolve().then(async()=>{const y=[];for(const f of p){const m=await f.key,b=await f.value;y.push({key:m,value:b,alwaysSet:f.alwaysSet})}return y}).then(y=>tt.mergeObjectSync(i,y)):tt.mergeObjectSync(i,p)}get shape(){return this._def.shape()}strict(e){return F.errToObj,new Ge({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(t,i)=>{var a,s,o,l;const p=(o=(s=(a=this._def).errorMap)===null||s===void 0?void 0:s.call(a,t,i).message)!==null&&o!==void 0?o:i.defaultError;return t.code==="unrecognized_keys"?{message:(l=F.errToObj(e).message)!==null&&l!==void 0?l:p}:{message:p}}}:{}})}strip(){return new Ge({...this._def,unknownKeys:"strip"})}passthrough(){return new Ge({...this._def,unknownKeys:"passthrough"})}extend(e){return new Ge({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new Ge({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:j.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new Ge({...this._def,catchall:e})}pick(e){const t={};return ee.objectKeys(e).forEach(i=>{e[i]&&this.shape[i]&&(t[i]=this.shape[i])}),new Ge({...this._def,shape:()=>t})}omit(e){const t={};return ee.objectKeys(this.shape).forEach(i=>{e[i]||(t[i]=this.shape[i])}),new Ge({...this._def,shape:()=>t})}deepPartial(){return qr(this)}partial(e){const t={};return ee.objectKeys(this.shape).forEach(i=>{const a=this.shape[i];e&&!e[i]?t[i]=a:t[i]=a.optional()}),new Ge({...this._def,shape:()=>t})}required(e){const t={};return ee.objectKeys(this.shape).forEach(i=>{if(e&&!e[i])t[i]=this.shape[i];else{let s=this.shape[i];for(;s instanceof Xt;)s=s._def.innerType;t[i]=s}}),new Ge({...this._def,shape:()=>t})}keyof(){return Mm(ee.objectKeys(this.shape))}}Ge.create=(n,e)=>new Ge({shape:()=>n,unknownKeys:"strip",catchall:un.create(),typeName:j.ZodObject,...z(e)}),Ge.strictCreate=(n,e)=>new Ge({shape:()=>n,unknownKeys:"strict",catchall:un.create(),typeName:j.ZodObject,...z(e)}),Ge.lazycreate=(n,e)=>new Ge({shape:n,unknownKeys:"strip",catchall:un.create(),typeName:j.ZodObject,...z(e)});class Mi extends X{_parse(e){const{ctx:t}=this._processInputParams(e),i=this._def.options;function a(s){for(const l of s)if(l.result.status==="valid")return l.result;for(const l of s)if(l.result.status==="dirty")return t.common.issues.push(...l.ctx.common.issues),l.result;const o=s.map(l=>new bt(l.ctx.common.issues));return N(t,{code:O.invalid_union,unionErrors:o}),q}if(t.common.async)return Promise.all(i.map(async s=>{const o={...t,common:{...t.common,issues:[]},parent:null};return{result:await s._parseAsync({data:t.data,path:t.path,parent:o}),ctx:o}})).then(a);{let s;const o=[];for(const p of i){const y={...t,common:{...t.common,issues:[]},parent:null},f=p._parseSync({data:t.data,path:t.path,parent:y});if(f.status==="valid")return f;f.status==="dirty"&&!s&&(s={result:f,ctx:y}),y.common.issues.length&&o.push(y.common.issues)}if(s)return t.common.issues.push(...s.ctx.common.issues),s.result;const l=o.map(p=>new bt(p));return N(t,{code:O.invalid_union,unionErrors:l}),q}}get options(){return this._def.options}}Mi.create=(n,e)=>new Mi({options:n,typeName:j.ZodUnion,...z(e)});const pn=n=>n instanceof $i?pn(n.schema):n instanceof qt?pn(n.innerType()):n instanceof Li?[n.value]:n instanceof _n?n.options:n instanceof Gi?ee.objectValues(n.enum):n instanceof Fi?pn(n._def.innerType):n instanceof wi?[void 0]:n instanceof _i?[null]:n instanceof Xt?[void 0,...pn(n.unwrap())]:n instanceof Mn?[null,...pn(n.unwrap())]:n instanceof yl||n instanceof ki?pn(n.unwrap()):n instanceof Ui?pn(n._def.innerType):[];class Ka extends X{_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==$.object)return N(t,{code:O.invalid_type,expected:$.object,received:t.parsedType}),q;const i=this.discriminator,a=t.data[i],s=this.optionsMap.get(a);return s?t.common.async?s._parseAsync({data:t.data,path:t.path,parent:t}):s._parseSync({data:t.data,path:t.path,parent:t}):(N(t,{code:O.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[i]}),q)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,i){const a=new Map;for(const s of t){const o=pn(s.shape[e]);if(!o.length)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(const l of o){if(a.has(l))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(l)}`);a.set(l,s)}}return new Ka({typeName:j.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:a,...z(i)})}}function pl(n,e){const t=Cn(n),i=Cn(e);if(n===e)return{valid:!0,data:n};if(t===$.object&&i===$.object){const a=ee.objectKeys(e),s=ee.objectKeys(n).filter(l=>a.indexOf(l)!==-1),o={...n,...e};for(const l of s){const p=pl(n[l],e[l]);if(!p.valid)return{valid:!1};o[l]=p.data}return{valid:!0,data:o}}else if(t===$.array&&i===$.array){if(n.length!==e.length)return{valid:!1};const a=[];for(let s=0;s<n.length;s++){const o=n[s],l=e[s],p=pl(o,l);if(!p.valid)return{valid:!1};a.push(p.data)}return{valid:!0,data:a}}else return t===$.date&&i===$.date&&+n==+e?{valid:!0,data:n}:{valid:!1}}class Ni extends X{_parse(e){const{status:t,ctx:i}=this._processInputParams(e),a=(s,o)=>{if(cl(s)||cl(o))return q;const l=pl(s.value,o.value);return l.valid?((dl(s)||dl(o))&&t.dirty(),{status:t.value,value:l.data}):(N(i,{code:O.invalid_intersection_types}),q)};return i.common.async?Promise.all([this._def.left._parseAsync({data:i.data,path:i.path,parent:i}),this._def.right._parseAsync({data:i.data,path:i.path,parent:i})]).then(([s,o])=>a(s,o)):a(this._def.left._parseSync({data:i.data,path:i.path,parent:i}),this._def.right._parseSync({data:i.data,path:i.path,parent:i}))}}Ni.create=(n,e,t)=>new Ni({left:n,right:e,typeName:j.ZodIntersection,...z(t)});class Zt extends X{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==$.array)return N(i,{code:O.invalid_type,expected:$.array,received:i.parsedType}),q;if(i.data.length<this._def.items.length)return N(i,{code:O.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),q;!this._def.rest&&i.data.length>this._def.items.length&&(N(i,{code:O.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());const s=[...i.data].map((o,l)=>{const p=this._def.items[l]||this._def.rest;return p?p._parse(new zt(i,o,i.path,l)):null}).filter(o=>!!o);return i.common.async?Promise.all(s).then(o=>tt.mergeArray(t,o)):tt.mergeArray(t,s)}get items(){return this._def.items}rest(e){return new Zt({...this._def,rest:e})}}Zt.create=(n,e)=>{if(!Array.isArray(n))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new Zt({items:n,typeName:j.ZodTuple,rest:null,...z(e)})};class Vi extends X{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==$.object)return N(i,{code:O.invalid_type,expected:$.object,received:i.parsedType}),q;const a=[],s=this._def.keyType,o=this._def.valueType;for(const l in i.data)a.push({key:s._parse(new zt(i,l,i.path,l)),value:o._parse(new zt(i,i.data[l],i.path,l)),alwaysSet:l in i.data});return i.common.async?tt.mergeObjectAsync(t,a):tt.mergeObjectSync(t,a)}get element(){return this._def.valueType}static create(e,t,i){return t instanceof X?new Vi({keyType:e,valueType:t,typeName:j.ZodRecord,...z(i)}):new Vi({keyType:kt.create(),valueType:e,typeName:j.ZodRecord,...z(t)})}}class es extends X{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==$.map)return N(i,{code:O.invalid_type,expected:$.map,received:i.parsedType}),q;const a=this._def.keyType,s=this._def.valueType,o=[...i.data.entries()].map(([l,p],y)=>({key:a._parse(new zt(i,l,i.path,[y,"key"])),value:s._parse(new zt(i,p,i.path,[y,"value"]))}));if(i.common.async){const l=new Map;return Promise.resolve().then(async()=>{for(const p of o){const y=await p.key,f=await p.value;if(y.status==="aborted"||f.status==="aborted")return q;(y.status==="dirty"||f.status==="dirty")&&t.dirty(),l.set(y.value,f.value)}return{status:t.value,value:l}})}else{const l=new Map;for(const p of o){const y=p.key,f=p.value;if(y.status==="aborted"||f.status==="aborted")return q;(y.status==="dirty"||f.status==="dirty")&&t.dirty(),l.set(y.value,f.value)}return{status:t.value,value:l}}}}es.create=(n,e,t)=>new es({valueType:e,keyType:n,typeName:j.ZodMap,...z(t)});class rr extends X{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==$.set)return N(i,{code:O.invalid_type,expected:$.set,received:i.parsedType}),q;const a=this._def;a.minSize!==null&&i.data.size<a.minSize.value&&(N(i,{code:O.too_small,minimum:a.minSize.value,type:"set",inclusive:!0,exact:!1,message:a.minSize.message}),t.dirty()),a.maxSize!==null&&i.data.size>a.maxSize.value&&(N(i,{code:O.too_big,maximum:a.maxSize.value,type:"set",inclusive:!0,exact:!1,message:a.maxSize.message}),t.dirty());const s=this._def.valueType;function o(p){const y=new Set;for(const f of p){if(f.status==="aborted")return q;f.status==="dirty"&&t.dirty(),y.add(f.value)}return{status:t.value,value:y}}const l=[...i.data.values()].map((p,y)=>s._parse(new zt(i,p,i.path,y)));return i.common.async?Promise.all(l).then(p=>o(p)):o(l)}min(e,t){return new rr({...this._def,minSize:{value:e,message:F.toString(t)}})}max(e,t){return new rr({...this._def,maxSize:{value:e,message:F.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}rr.create=(n,e)=>new rr({valueType:n,minSize:null,maxSize:null,typeName:j.ZodSet,...z(e)});class Jr extends X{constructor(){super(...arguments),this.validate=this.implement}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==$.function)return N(t,{code:O.invalid_type,expected:$.function,received:t.parsedType}),q;function i(l,p){return za({data:l,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,Ya(),xr].filter(y=>!!y),issueData:{code:O.invalid_arguments,argumentsError:p}})}function a(l,p){return za({data:l,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,Ya(),xr].filter(y=>!!y),issueData:{code:O.invalid_return_type,returnTypeError:p}})}const s={errorMap:t.common.contextualErrorMap},o=t.data;if(this._def.returns instanceof Wr){const l=this;return ut(async function(...p){const y=new bt([]),f=await l._def.args.parseAsync(p,s).catch(g=>{throw y.addIssue(i(p,g)),y}),m=await Reflect.apply(o,this,f);return await l._def.returns._def.type.parseAsync(m,s).catch(g=>{throw y.addIssue(a(m,g)),y})})}else{const l=this;return ut(function(...p){const y=l._def.args.safeParse(p,s);if(!y.success)throw new bt([i(p,y.error)]);const f=Reflect.apply(o,this,y.data),m=l._def.returns.safeParse(f,s);if(!m.success)throw new bt([a(f,m.error)]);return m.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new Jr({...this._def,args:Zt.create(e).rest(nr.create())})}returns(e){return new Jr({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,i){return new Jr({args:e||Zt.create([]).rest(nr.create()),returns:t||nr.create(),typeName:j.ZodFunction,...z(i)})}}class $i extends X{get schema(){return this._def.getter()}_parse(e){const{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}$i.create=(n,e)=>new $i({getter:n,typeName:j.ZodLazy,...z(e)});class Li extends X{_parse(e){if(e.data!==this._def.value){const t=this._getOrReturnCtx(e);return N(t,{received:t.data,code:O.invalid_literal,expected:this._def.value}),q}return{status:"valid",value:e.data}}get value(){return this._def.value}}Li.create=(n,e)=>new Li({value:n,typeName:j.ZodLiteral,...z(e)});function Mm(n,e){return new _n({values:n,typeName:j.ZodEnum,...z(e)})}class _n extends X{constructor(){super(...arguments),Oi.set(this,void 0)}_parse(e){if(typeof e.data!="string"){const t=this._getOrReturnCtx(e),i=this._def.values;return N(t,{expected:ee.joinValues(i),received:t.parsedType,code:O.invalid_type}),q}if(Za(this,Oi,"f")||Om(this,Oi,new Set(this._def.values),"f"),!Za(this,Oi,"f").has(e.data)){const t=this._getOrReturnCtx(e),i=this._def.values;return N(t,{received:t.data,code:O.invalid_enum_value,options:i}),q}return ut(e.data)}get options(){return this._def.values}get enum(){const e={};for(const t of this._def.values)e[t]=t;return e}get Values(){const e={};for(const t of this._def.values)e[t]=t;return e}get Enum(){const e={};for(const t of this._def.values)e[t]=t;return e}extract(e,t=this._def){return _n.create(e,{...this._def,...t})}exclude(e,t=this._def){return _n.create(this.options.filter(i=>!e.includes(i)),{...this._def,...t})}}Oi=new WeakMap,_n.create=Mm;class Gi extends X{constructor(){super(...arguments),Ci.set(this,void 0)}_parse(e){const t=ee.getValidEnumValues(this._def.values),i=this._getOrReturnCtx(e);if(i.parsedType!==$.string&&i.parsedType!==$.number){const a=ee.objectValues(t);return N(i,{expected:ee.joinValues(a),received:i.parsedType,code:O.invalid_type}),q}if(Za(this,Ci,"f")||Om(this,Ci,new Set(ee.getValidEnumValues(this._def.values)),"f"),!Za(this,Ci,"f").has(e.data)){const a=ee.objectValues(t);return N(i,{received:i.data,code:O.invalid_enum_value,options:a}),q}return ut(e.data)}get enum(){return this._def.values}}Ci=new WeakMap,Gi.create=(n,e)=>new Gi({values:n,typeName:j.ZodNativeEnum,...z(e)});class Wr extends X{unwrap(){return this._def.type}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==$.promise&&t.common.async===!1)return N(t,{code:O.invalid_type,expected:$.promise,received:t.parsedType}),q;const i=t.parsedType===$.promise?t.data:Promise.resolve(t.data);return ut(i.then(a=>this._def.type.parseAsync(a,{path:t.path,errorMap:t.common.contextualErrorMap})))}}Wr.create=(n,e)=>new Wr({type:n,typeName:j.ZodPromise,...z(e)});class qt extends X{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===j.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){const{status:t,ctx:i}=this._processInputParams(e),a=this._def.effect||null,s={addIssue:o=>{N(i,o),o.fatal?t.abort():t.dirty()},get path(){return i.path}};if(s.addIssue=s.addIssue.bind(s),a.type==="preprocess"){const o=a.transform(i.data,s);if(i.common.async)return Promise.resolve(o).then(async l=>{if(t.value==="aborted")return q;const p=await this._def.schema._parseAsync({data:l,path:i.path,parent:i});return p.status==="aborted"?q:p.status==="dirty"||t.value==="dirty"?kr(p.value):p});{if(t.value==="aborted")return q;const l=this._def.schema._parseSync({data:o,path:i.path,parent:i});return l.status==="aborted"?q:l.status==="dirty"||t.value==="dirty"?kr(l.value):l}}if(a.type==="refinement"){const o=l=>{const p=a.refinement(l,s);if(i.common.async)return Promise.resolve(p);if(p instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return l};if(i.common.async===!1){const l=this._def.schema._parseSync({data:i.data,path:i.path,parent:i});return l.status==="aborted"?q:(l.status==="dirty"&&t.dirty(),o(l.value),{status:t.value,value:l.value})}else return this._def.schema._parseAsync({data:i.data,path:i.path,parent:i}).then(l=>l.status==="aborted"?q:(l.status==="dirty"&&t.dirty(),o(l.value).then(()=>({status:t.value,value:l.value}))))}if(a.type==="transform")if(i.common.async===!1){const o=this._def.schema._parseSync({data:i.data,path:i.path,parent:i});if(!Ai(o))return o;const l=a.transform(o.value,s);if(l instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:l}}else return this._def.schema._parseAsync({data:i.data,path:i.path,parent:i}).then(o=>Ai(o)?Promise.resolve(a.transform(o.value,s)).then(l=>({status:t.value,value:l})):o);ee.assertNever(a)}}qt.create=(n,e,t)=>new qt({schema:n,typeName:j.ZodEffects,effect:e,...z(t)}),qt.createWithPreprocess=(n,e,t)=>new qt({schema:e,effect:{type:"preprocess",transform:n},typeName:j.ZodEffects,...z(t)});class Xt extends X{_parse(e){return this._getType(e)===$.undefined?ut(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}Xt.create=(n,e)=>new Xt({innerType:n,typeName:j.ZodOptional,...z(e)});class Mn extends X{_parse(e){return this._getType(e)===$.null?ut(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}Mn.create=(n,e)=>new Mn({innerType:n,typeName:j.ZodNullable,...z(e)});class Fi extends X{_parse(e){const{ctx:t}=this._processInputParams(e);let i=t.data;return t.parsedType===$.undefined&&(i=this._def.defaultValue()),this._def.innerType._parse({data:i,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}Fi.create=(n,e)=>new Fi({innerType:n,typeName:j.ZodDefault,defaultValue:typeof e.default=="function"?e.default:()=>e.default,...z(e)});class Ui extends X{_parse(e){const{ctx:t}=this._processInputParams(e),i={...t,common:{...t.common,issues:[]}},a=this._def.innerType._parse({data:i.data,path:i.path,parent:{...i}});return Si(a)?a.then(s=>({status:"valid",value:s.status==="valid"?s.value:this._def.catchValue({get error(){return new bt(i.common.issues)},input:i.data})})):{status:"valid",value:a.status==="valid"?a.value:this._def.catchValue({get error(){return new bt(i.common.issues)},input:i.data})}}removeCatch(){return this._def.innerType}}Ui.create=(n,e)=>new Ui({innerType:n,typeName:j.ZodCatch,catchValue:typeof e.catch=="function"?e.catch:()=>e.catch,...z(e)});class ts extends X{_parse(e){if(this._getType(e)!==$.nan){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.nan,received:i.parsedType}),q}return{status:"valid",value:e.data}}}ts.create=n=>new ts({typeName:j.ZodNaN,...z(n)});const dD=Symbol("zod_brand");class yl extends X{_parse(e){const{ctx:t}=this._processInputParams(e),i=t.data;return this._def.type._parse({data:i,path:t.path,parent:t})}unwrap(){return this._def.type}}class xi extends X{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.common.async)return(async()=>{const s=await this._def.in._parseAsync({data:i.data,path:i.path,parent:i});return s.status==="aborted"?q:s.status==="dirty"?(t.dirty(),kr(s.value)):this._def.out._parseAsync({data:s.value,path:i.path,parent:i})})();{const a=this._def.in._parseSync({data:i.data,path:i.path,parent:i});return a.status==="aborted"?q:a.status==="dirty"?(t.dirty(),{status:"dirty",value:a.value}):this._def.out._parseSync({data:a.value,path:i.path,parent:i})}}static create(e,t){return new xi({in:e,out:t,typeName:j.ZodPipeline})}}class ki extends X{_parse(e){const t=this._def.innerType._parse(e),i=a=>(Ai(a)&&(a.value=Object.freeze(a.value)),a);return Si(t)?t.then(a=>i(a)):i(t)}unwrap(){return this._def.innerType}}ki.create=(n,e)=>new ki({innerType:n,typeName:j.ZodReadonly,...z(e)});function Nm(n,e={},t){return n?jr.create().superRefine((i,a)=>{var s,o;if(!n(i)){const l=typeof e=="function"?e(i):typeof e=="string"?{message:e}:e,p=(o=(s=l.fatal)!==null&&s!==void 0?s:t)!==null&&o!==void 0?o:!0,y=typeof l=="string"?{message:l}:l;a.addIssue({code:"custom",...y,fatal:p})}}):jr.create()}const uD={object:Ge.lazycreate};var j;(function(n){n.ZodString="ZodString",n.ZodNumber="ZodNumber",n.ZodNaN="ZodNaN",n.ZodBigInt="ZodBigInt",n.ZodBoolean="ZodBoolean",n.ZodDate="ZodDate",n.ZodSymbol="ZodSymbol",n.ZodUndefined="ZodUndefined",n.ZodNull="ZodNull",n.ZodAny="ZodAny",n.ZodUnknown="ZodUnknown",n.ZodNever="ZodNever",n.ZodVoid="ZodVoid",n.ZodArray="ZodArray",n.ZodObject="ZodObject",n.ZodUnion="ZodUnion",n.ZodDiscriminatedUnion="ZodDiscriminatedUnion",n.ZodIntersection="ZodIntersection",n.ZodTuple="ZodTuple",n.ZodRecord="ZodRecord",n.ZodMap="ZodMap",n.ZodSet="ZodSet",n.ZodFunction="ZodFunction",n.ZodLazy="ZodLazy",n.ZodLiteral="ZodLiteral",n.ZodEnum="ZodEnum",n.ZodEffects="ZodEffects",n.ZodNativeEnum="ZodNativeEnum",n.ZodOptional="ZodOptional",n.ZodNullable="ZodNullable",n.ZodDefault="ZodDefault",n.ZodCatch="ZodCatch",n.ZodPromise="ZodPromise",n.ZodBranded="ZodBranded",n.ZodPipeline="ZodPipeline",n.ZodReadonly="ZodReadonly"})(j||(j={}));const pD=(n,e={message:`Input not instance of ${n.name}`})=>Nm(t=>t instanceof n,e),ns=kt.create,hl=Bn.create,yD=ts.create,hD=wn.create,fl=Bi.create,Vm=tr.create,fD=Xa.create,mD=wi.create,$m=_i.create,TD=jr.create,rs=nr.create,ED=un.create,RD=Qa.create,bD=jt.create,Lm=Ge.create,gD=Ge.strictCreate,vD=Mi.create,ID=Ka.create,DD=Ni.create,PD=Zt.create,Gm=Vi.create,AD=es.create,SD=rr.create,OD=Jr.create,CD=$i.create,BD=Li.create,Fm=_n.create,wD=Gi.create,_D=Wr.create,Um=qt.create,MD=Xt.create,ND=Mn.create,VD=qt.createWithPreprocess,$D=xi.create;var d=Object.freeze({__proto__:null,defaultErrorMap:xr,setErrorMap:HI,getErrorMap:Ya,makeIssue:za,EMPTY_PATH:YI,addIssueToContext:N,ParseStatus:tt,INVALID:q,DIRTY:kr,OK:ut,isAborted:cl,isDirty:dl,isValid:Ai,isAsync:Si,get util(){return ee},get objectUtil(){return ll},ZodParsedType:$,getParsedType:Cn,ZodType:X,datetimeRegex:_m,ZodString:kt,ZodNumber:Bn,ZodBigInt:wn,ZodBoolean:Bi,ZodDate:tr,ZodSymbol:Xa,ZodUndefined:wi,ZodNull:_i,ZodAny:jr,ZodUnknown:nr,ZodNever:un,ZodVoid:Qa,ZodArray:jt,ZodObject:Ge,ZodUnion:Mi,ZodDiscriminatedUnion:Ka,ZodIntersection:Ni,ZodTuple:Zt,ZodRecord:Vi,ZodMap:es,ZodSet:rr,ZodFunction:Jr,ZodLazy:$i,ZodLiteral:Li,ZodEnum:_n,ZodNativeEnum:Gi,ZodPromise:Wr,ZodEffects:qt,ZodTransformer:qt,ZodOptional:Xt,ZodNullable:Mn,ZodDefault:Fi,ZodCatch:Ui,ZodNaN:ts,BRAND:dD,ZodBranded:yl,ZodPipeline:xi,ZodReadonly:ki,custom:Nm,Schema:X,ZodSchema:X,late:uD,get ZodFirstPartyTypeKind(){return j},coerce:{string:n=>kt.create({...n,coerce:!0}),number:n=>Bn.create({...n,coerce:!0}),boolean:n=>Bi.create({...n,coerce:!0}),bigint:n=>wn.create({...n,coerce:!0}),date:n=>tr.create({...n,coerce:!0})},any:TD,array:bD,bigint:hD,boolean:fl,date:Vm,discriminatedUnion:ID,effect:Um,enum:Fm,function:OD,instanceof:pD,intersection:DD,lazy:CD,literal:BD,map:AD,nan:yD,nativeEnum:wD,never:ED,null:$m,nullable:ND,number:hl,object:Lm,oboolean:()=>fl().optional(),onumber:()=>hl().optional(),optional:MD,ostring:()=>ns().optional(),pipeline:$D,preprocess:VD,promise:_D,record:Gm,set:SD,strictObject:gD,string:ns,symbol:fD,transformer:Um,tuple:PD,undefined:mD,union:vD,unknown:rs,void:RD,NEVER:q,ZodIssueCode:O,quotelessJson:WI,ZodError:bt});function xm(n){var a,s,o;if(!(n!=null&&n.dataType))return rs();const e=n.dataType.isNullable||!1,t=n.dataType.isList||!1;let i=rs();if(((a=n.dataType.entity)==null?void 0:a.type)===r.PrimitiveEntity)switch(n.dataType.entity.name){case A.String:i=ns();break;case A.JSON:i=Gm(rs());break;case A.Number:i=hl();break;case A.Boolean:i=fl();break;case A.Date:i=Vm();break;case A.Enum:{const l=n.dataType.options||[];if(l.length===0)throw new Error(`Enum property ${n.name} has no options`);i=Fm(l);break}case A.Null:i=$m();break;case A.UUID:i=ns().uuid();break}else if(((s=n.dataType.entity)==null?void 0:s.type)===r.CustomEntity)i=km(n.dataType.entity);else throw new Error(`Unsupported data type validation: ${(o=n.dataType.entity)==null?void 0:o.type}`);return e&&(i=i.nullable()),t&&(i=i.array()),i}function km(n){const e=Lm({});for(const t of n.properties){const i=xm(t);e.shape[t.name]=i}return e}function jm(n){const e=n.rangeStart;return new Date(e.getTime()+Math.random()*(Date.now()-e.getTime()))}function qm(n){const e=n.rangeEnd;return new Date(Math.random()*e.getTime())}function Jm(n){const e=n.rangeStart,t=n.rangeEnd;return new Date(e.getTime()+Math.random()*(t.getTime()-e.getTime()))}function Wm(n){return n.rangeStart&&n.rangeEnd?Jm(n):n.rangeStart?jm(n):n.rangeEnd?qm(n):new Date}function LD(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var Hm={},is={},as={};Object.defineProperty(as,"__esModule",{value:!0}),as.default=FD;let ss;const GD=new Uint8Array(16);function FD(){if(!ss&&(ss=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!ss))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return ss(GD)}var Nn={},ir={},os={};Object.defineProperty(os,"__esModule",{value:!0}),os.default=void 0;var UD=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;os.default=UD,Object.defineProperty(ir,"__esModule",{value:!0}),ir.default=void 0;var xD=kD(os);function kD(n){return n&&n.__esModule?n:{default:n}}function jD(n){return typeof n=="string"&&xD.default.test(n)}var qD=jD;ir.default=qD,Object.defineProperty(Nn,"__esModule",{value:!0}),Nn.default=void 0,Nn.unsafeStringify=Ym;var JD=WD(ir);function WD(n){return n&&n.__esModule?n:{default:n}}const Qe=[];for(let n=0;n<256;++n)Qe.push((n+256).toString(16).slice(1));function Ym(n,e=0){return Qe[n[e+0]]+Qe[n[e+1]]+Qe[n[e+2]]+Qe[n[e+3]]+"-"+Qe[n[e+4]]+Qe[n[e+5]]+"-"+Qe[n[e+6]]+Qe[n[e+7]]+"-"+Qe[n[e+8]]+Qe[n[e+9]]+"-"+Qe[n[e+10]]+Qe[n[e+11]]+Qe[n[e+12]]+Qe[n[e+13]]+Qe[n[e+14]]+Qe[n[e+15]]}function HD(n,e=0){const t=Ym(n,e);if(!(0,JD.default)(t))throw TypeError("Stringified UUID is invalid");return t}var YD=HD;Nn.default=YD,Object.defineProperty(is,"__esModule",{value:!0}),is.default=void 0;var zD=XD(as),ZD=Nn;function XD(n){return n&&n.__esModule?n:{default:n}}let zm,ml,Tl=0,El=0;function QD(n,e,t){let i=e&&t||0;const a=e||new Array(16);n=n||{};let s=n.node||zm,o=n.clockseq!==void 0?n.clockseq:ml;if(s==null||o==null){const b=n.random||(n.rng||zD.default)();s==null&&(s=zm=[b[0]|1,b[1],b[2],b[3],b[4],b[5]]),o==null&&(o=ml=(b[6]<<8|b[7])&16383)}let l=n.msecs!==void 0?n.msecs:Date.now(),p=n.nsecs!==void 0?n.nsecs:El+1;const y=l-Tl+(p-El)/1e4;if(y<0&&n.clockseq===void 0&&(o=o+1&16383),(y<0||l>Tl)&&n.nsecs===void 0&&(p=0),p>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");Tl=l,El=p,ml=o,l+=122192928e5;const f=((l&268435455)*1e4+p)%4294967296;a[i++]=f>>>24&255,a[i++]=f>>>16&255,a[i++]=f>>>8&255,a[i++]=f&255;const m=l/4294967296*1e4&268435455;a[i++]=m>>>8&255,a[i++]=m&255,a[i++]=m>>>24&15|16,a[i++]=m>>>16&255,a[i++]=o>>>8|128,a[i++]=o&255;for(let b=0;b<6;++b)a[i+b]=s[b];return e||(0,ZD.unsafeStringify)(a)}var KD=QD;is.default=KD;var ls={},Vn={},ji={};Object.defineProperty(ji,"__esModule",{value:!0}),ji.default=void 0;var eP=tP(ir);function tP(n){return n&&n.__esModule?n:{default:n}}function nP(n){if(!(0,eP.default)(n))throw TypeError("Invalid UUID");let e;const t=new Uint8Array(16);return t[0]=(e=parseInt(n.slice(0,8),16))>>>24,t[1]=e>>>16&255,t[2]=e>>>8&255,t[3]=e&255,t[4]=(e=parseInt(n.slice(9,13),16))>>>8,t[5]=e&255,t[6]=(e=parseInt(n.slice(14,18),16))>>>8,t[7]=e&255,t[8]=(e=parseInt(n.slice(19,23),16))>>>8,t[9]=e&255,t[10]=(e=parseInt(n.slice(24,36),16))/1099511627776&255,t[11]=e/4294967296&255,t[12]=e>>>24&255,t[13]=e>>>16&255,t[14]=e>>>8&255,t[15]=e&255,t}var rP=nP;ji.default=rP,Object.defineProperty(Vn,"__esModule",{value:!0}),Vn.URL=Vn.DNS=void 0,Vn.default=lP;var iP=Nn,aP=sP(ji);function sP(n){return n&&n.__esModule?n:{default:n}}function oP(n){n=unescape(encodeURIComponent(n));const e=[];for(let t=0;t<n.length;++t)e.push(n.charCodeAt(t));return e}const Zm="6ba7b810-9dad-11d1-80b4-00c04fd430c8";Vn.DNS=Zm;const Xm="6ba7b811-9dad-11d1-80b4-00c04fd430c8";Vn.URL=Xm;function lP(n,e,t){function i(a,s,o,l){var p;if(typeof a=="string"&&(a=oP(a)),typeof s=="string"&&(s=(0,aP.default)(s)),((p=s)===null||p===void 0?void 0:p.length)!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let y=new Uint8Array(16+a.length);if(y.set(s),y.set(a,s.length),y=t(y),y[6]=y[6]&15|e,y[8]=y[8]&63|128,o){l=l||0;for(let f=0;f<16;++f)o[l+f]=y[f];return o}return(0,iP.unsafeStringify)(y)}try{i.name=n}catch{}return i.DNS=Zm,i.URL=Xm,i}var cs={};Object.defineProperty(cs,"__esModule",{value:!0}),cs.default=void 0;function cP(n){if(typeof n=="string"){const e=unescape(encodeURIComponent(n));n=new Uint8Array(e.length);for(let t=0;t<e.length;++t)n[t]=e.charCodeAt(t)}return dP(uP(pP(n),n.length*8))}function dP(n){const e=[],t=n.length*32,i="0123456789abcdef";for(let a=0;a<t;a+=8){const s=n[a>>5]>>>a%32&255,o=parseInt(i.charAt(s>>>4&15)+i.charAt(s&15),16);e.push(o)}return e}function Qm(n){return(n+64>>>9<<4)+14+1}function uP(n,e){n[e>>5]|=128<<e%32,n[Qm(e)-1]=e;let t=1732584193,i=-271733879,a=-1732584194,s=271733878;for(let o=0;o<n.length;o+=16){const l=t,p=i,y=a,f=s;t=nt(t,i,a,s,n[o],7,-680876936),s=nt(s,t,i,a,n[o+1],12,-389564586),a=nt(a,s,t,i,n[o+2],17,606105819),i=nt(i,a,s,t,n[o+3],22,-1044525330),t=nt(t,i,a,s,n[o+4],7,-176418897),s=nt(s,t,i,a,n[o+5],12,1200080426),a=nt(a,s,t,i,n[o+6],17,-1473231341),i=nt(i,a,s,t,n[o+7],22,-45705983),t=nt(t,i,a,s,n[o+8],7,1770035416),s=nt(s,t,i,a,n[o+9],12,-1958414417),a=nt(a,s,t,i,n[o+10],17,-42063),i=nt(i,a,s,t,n[o+11],22,-1990404162),t=nt(t,i,a,s,n[o+12],7,1804603682),s=nt(s,t,i,a,n[o+13],12,-40341101),a=nt(a,s,t,i,n[o+14],17,-1502002290),i=nt(i,a,s,t,n[o+15],22,1236535329),t=rt(t,i,a,s,n[o+1],5,-165796510),s=rt(s,t,i,a,n[o+6],9,-1069501632),a=rt(a,s,t,i,n[o+11],14,643717713),i=rt(i,a,s,t,n[o],20,-373897302),t=rt(t,i,a,s,n[o+5],5,-701558691),s=rt(s,t,i,a,n[o+10],9,38016083),a=rt(a,s,t,i,n[o+15],14,-660478335),i=rt(i,a,s,t,n[o+4],20,-405537848),t=rt(t,i,a,s,n[o+9],5,568446438),s=rt(s,t,i,a,n[o+14],9,-1019803690),a=rt(a,s,t,i,n[o+3],14,-187363961),i=rt(i,a,s,t,n[o+8],20,1163531501),t=rt(t,i,a,s,n[o+13],5,-1444681467),s=rt(s,t,i,a,n[o+2],9,-51403784),a=rt(a,s,t,i,n[o+7],14,1735328473),i=rt(i,a,s,t,n[o+12],20,-1926607734),t=it(t,i,a,s,n[o+5],4,-378558),s=it(s,t,i,a,n[o+8],11,-2022574463),a=it(a,s,t,i,n[o+11],16,1839030562),i=it(i,a,s,t,n[o+14],23,-35309556),t=it(t,i,a,s,n[o+1],4,-1530992060),s=it(s,t,i,a,n[o+4],11,1272893353),a=it(a,s,t,i,n[o+7],16,-155497632),i=it(i,a,s,t,n[o+10],23,-1094730640),t=it(t,i,a,s,n[o+13],4,681279174),s=it(s,t,i,a,n[o],11,-358537222),a=it(a,s,t,i,n[o+3],16,-722521979),i=it(i,a,s,t,n[o+6],23,76029189),t=it(t,i,a,s,n[o+9],4,-640364487),s=it(s,t,i,a,n[o+12],11,-421815835),a=it(a,s,t,i,n[o+15],16,530742520),i=it(i,a,s,t,n[o+2],23,-995338651),t=at(t,i,a,s,n[o],6,-198630844),s=at(s,t,i,a,n[o+7],10,1126891415),a=at(a,s,t,i,n[o+14],15,-1416354905),i=at(i,a,s,t,n[o+5],21,-57434055),t=at(t,i,a,s,n[o+12],6,1700485571),s=at(s,t,i,a,n[o+3],10,-1894986606),a=at(a,s,t,i,n[o+10],15,-1051523),i=at(i,a,s,t,n[o+1],21,-2054922799),t=at(t,i,a,s,n[o+8],6,1873313359),s=at(s,t,i,a,n[o+15],10,-30611744),a=at(a,s,t,i,n[o+6],15,-1560198380),i=at(i,a,s,t,n[o+13],21,1309151649),t=at(t,i,a,s,n[o+4],6,-145523070),s=at(s,t,i,a,n[o+11],10,-1120210379),a=at(a,s,t,i,n[o+2],15,718787259),i=at(i,a,s,t,n[o+9],21,-343485551),t=$n(t,l),i=$n(i,p),a=$n(a,y),s=$n(s,f)}return[t,i,a,s]}function pP(n){if(n.length===0)return[];const e=n.length*8,t=new Uint32Array(Qm(e));for(let i=0;i<e;i+=8)t[i>>5]|=(n[i/8]&255)<<i%32;return t}function $n(n,e){const t=(n&65535)+(e&65535);return(n>>16)+(e>>16)+(t>>16)<<16|t&65535}function yP(n,e){return n<<e|n>>>32-e}function ds(n,e,t,i,a,s){return $n(yP($n($n(e,n),$n(i,s)),a),t)}function nt(n,e,t,i,a,s,o){return ds(e&t|~e&i,n,e,a,s,o)}function rt(n,e,t,i,a,s,o){return ds(e&i|t&~i,n,e,a,s,o)}function it(n,e,t,i,a,s,o){return ds(e^t^i,n,e,a,s,o)}function at(n,e,t,i,a,s,o){return ds(t^(e|~i),n,e,a,s,o)}var hP=cP;cs.default=hP,Object.defineProperty(ls,"__esModule",{value:!0}),ls.default=void 0;var fP=Km(Vn),mP=Km(cs);function Km(n){return n&&n.__esModule?n:{default:n}}var TP=(0,fP.default)("v3",48,mP.default);ls.default=TP;var us={},ps={};Object.defineProperty(ps,"__esModule",{value:!0}),ps.default=void 0;var EP={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};ps.default=EP,Object.defineProperty(us,"__esModule",{value:!0}),us.default=void 0;var eT=tT(ps),RP=tT(as),bP=Nn;function tT(n){return n&&n.__esModule?n:{default:n}}function gP(n,e,t){if(eT.default.randomUUID&&!e&&!n)return eT.default.randomUUID();n=n||{};const i=n.random||(n.rng||RP.default)();if(i[6]=i[6]&15|64,i[8]=i[8]&63|128,e){t=t||0;for(let a=0;a<16;++a)e[t+a]=i[a];return e}return(0,bP.unsafeStringify)(i)}var vP=gP;us.default=vP;var ys={},hs={};Object.defineProperty(hs,"__esModule",{value:!0}),hs.default=void 0;function IP(n,e,t,i){switch(n){case 0:return e&t^~e&i;case 1:return e^t^i;case 2:return e&t^e&i^t&i;case 3:return e^t^i}}function Rl(n,e){return n<<e|n>>>32-e}function DP(n){const e=[1518500249,1859775393,2400959708,3395469782],t=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof n=="string"){const o=unescape(encodeURIComponent(n));n=[];for(let l=0;l<o.length;++l)n.push(o.charCodeAt(l))}else Array.isArray(n)||(n=Array.prototype.slice.call(n));n.push(128);const i=n.length/4+2,a=Math.ceil(i/16),s=new Array(a);for(let o=0;o<a;++o){const l=new Uint32Array(16);for(let p=0;p<16;++p)l[p]=n[o*64+p*4]<<24|n[o*64+p*4+1]<<16|n[o*64+p*4+2]<<8|n[o*64+p*4+3];s[o]=l}s[a-1][14]=(n.length-1)*8/Math.pow(2,32),s[a-1][14]=Math.floor(s[a-1][14]),s[a-1][15]=(n.length-1)*8&4294967295;for(let o=0;o<a;++o){const l=new Uint32Array(80);for(let g=0;g<16;++g)l[g]=s[o][g];for(let g=16;g<80;++g)l[g]=Rl(l[g-3]^l[g-8]^l[g-14]^l[g-16],1);let p=t[0],y=t[1],f=t[2],m=t[3],b=t[4];for(let g=0;g<80;++g){const I=Math.floor(g/20),P=Rl(p,5)+IP(I,y,f,m)+b+e[I]+l[g]>>>0;b=m,m=f,f=Rl(y,30)>>>0,y=p,p=P}t[0]=t[0]+p>>>0,t[1]=t[1]+y>>>0,t[2]=t[2]+f>>>0,t[3]=t[3]+m>>>0,t[4]=t[4]+b>>>0}return[t[0]>>24&255,t[0]>>16&255,t[0]>>8&255,t[0]&255,t[1]>>24&255,t[1]>>16&255,t[1]>>8&255,t[1]&255,t[2]>>24&255,t[2]>>16&255,t[2]>>8&255,t[2]&255,t[3]>>24&255,t[3]>>16&255,t[3]>>8&255,t[3]&255,t[4]>>24&255,t[4]>>16&255,t[4]>>8&255,t[4]&255]}var PP=DP;hs.default=PP,Object.defineProperty(ys,"__esModule",{value:!0}),ys.default=void 0;var AP=nT(Vn),SP=nT(hs);function nT(n){return n&&n.__esModule?n:{default:n}}var OP=(0,AP.default)("v5",80,SP.default);ys.default=OP;var fs={};Object.defineProperty(fs,"__esModule",{value:!0}),fs.default=void 0;var CP="00000000-0000-0000-0000-000000000000";fs.default=CP;var ms={};Object.defineProperty(ms,"__esModule",{value:!0}),ms.default=void 0;var BP=wP(ir);function wP(n){return n&&n.__esModule?n:{default:n}}function _P(n){if(!(0,BP.default)(n))throw TypeError("Invalid UUID");return parseInt(n.slice(14,15),16)}var MP=_P;ms.default=MP,function(n){Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"NIL",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(n,"parse",{enumerable:!0,get:function(){return y.default}}),Object.defineProperty(n,"stringify",{enumerable:!0,get:function(){return p.default}}),Object.defineProperty(n,"v1",{enumerable:!0,get:function(){return e.default}}),Object.defineProperty(n,"v3",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(n,"v4",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(n,"v5",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(n,"validate",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(n,"version",{enumerable:!0,get:function(){return o.default}});var e=f(is),t=f(ls),i=f(us),a=f(ys),s=f(fs),o=f(ms),l=f(ir),p=f(Nn),y=f(ji);function f(m){return m&&m.__esModule?m:{default:m}}}(Hm);function bl(n,e){if(!n||!e||!n.length||!e.length)throw new Error("Bad alphabet");this.srcAlphabet=n,this.dstAlphabet=e}bl.prototype.convert=function(n){var e,t,i,a={},s=this.srcAlphabet.length,o=this.dstAlphabet.length,l=n.length,p=typeof n=="string"?"":[];if(!this.isValid(n))throw new Error('Number "'+n+'" contains of non-alphabetic digits ('+this.srcAlphabet+")");if(this.srcAlphabet===this.dstAlphabet)return n;for(e=0;e<l;e++)a[e]=this.srcAlphabet.indexOf(n[e]);do{for(t=0,i=0,e=0;e<l;e++)t=t*s+a[e],t>=o?(a[i++]=parseInt(t/o,10),t=t%o):i>0&&(a[i++]=0);l=i,p=this.dstAlphabet.slice(t,t+1).concat(p)}while(i!==0);return p},bl.prototype.isValid=function(n){for(var e=0;e<n.length;++e)if(this.srcAlphabet.indexOf(n[e])===-1)return!1;return!0};var NP=bl,VP=NP;function qi(n,e){var t=new VP(n,e);return function(i){return t.convert(i)}}qi.BIN="01",qi.OCT="01234567",qi.DEC="0123456789",qi.HEX="0123456789abcdef";var $P=qi;const{v4:gl,validate:LP}=Hm,Ts=$P,vl={cookieBase90:"0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ!#$%&'()*+-./:<=>?@[]^_`{|}~",flickrBase58:"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ",uuid25Base36:"0123456789abcdefghijklmnopqrstuvwxyz"},GP={consistentLength:!0};let Il;const rT=(n,e,t)=>{const i=e(n.toLowerCase().replace(/-/g,""));return!t||!t.consistentLength?i:i.padStart(t.shortIdLength,t.paddingChar)},iT=(n,e)=>{const i=e(n).padStart(32,"0").match(/(\w{8})(\w{4})(\w{4})(\w{4})(\w{12})/);return[i[1],i[2],i[3],i[4],i[5]].join("-")},FP=n=>Math.ceil(Math.log(2**128)/Math.log(n));var UP=(()=>{const n=(e,t)=>{const i=e||vl.flickrBase58,a={...GP,...t};if([...new Set(Array.from(i))].length!==i.length)throw new Error("The provided Alphabet has duplicate characters resulting in unreliable results");const s=FP(i.length),o={shortIdLength:s,consistentLength:a.consistentLength,paddingChar:i[0]},l=Ts(Ts.HEX,i),p=Ts(i,Ts.HEX),y=()=>rT(gl(),l,o),m={alphabet:i,fromUUID:b=>rT(b,l,o),maxLength:s,generate:y,new:y,toUUID:b=>iT(b,p),uuid:gl,validate:(b,g=!1)=>{if(!b||typeof b!="string")return!1;const I=a.consistentLength?b.length===s:b.length<=s,P=b.split("").every(B=>i.includes(B));return g===!1?I&&P:I&&P&&LP(iT(b,p))}};return Object.freeze(m),m};return n.constants=vl,n.uuid=gl,n.generate=()=>(Il||(Il=n(vl.flickrBase58).generate),Il()),n})();const Es=LD(UP);function aT(){return Es().uuid()}function sT(n){return n.rangeStart+Math.random()}function oT(n){const e=n.rangeEnd;return Math.random()*e}function lT(n){const e=n.rangeStart,t=n.rangeEnd;return Math.random()*(t-e)+e}function cT(n){return n.rangeStart&&n.rangeEnd?lT(n):n.rangeStart?sT(n):n.rangeEnd?oT(n):Math.random()}function dT(n){const e=n.rangeStart;return Math.random().toString(36).substring(e)}function uT(n){const e=n.rangeEnd;return Math.random().toString(36).substring(0,e)}function pT(n){const e=n.rangeStart,t=n.rangeEnd;return Math.random().toString(36).substring(e,t)}function yT(n){return n.rangeStart&&n.rangeEnd?pT(n):n.rangeStart?dT(n):n.rangeEnd?uT(n):Math.random().toString(36)}function hT(n){return Math.random()>=.5}function xP(n){if(!n||!n.autogeneration)return null;switch(n.autogeneration.type){case qe.CurrentDateAndTime:if(n.name===A.Date)return new Date;case qe.Random:{if(n.name===A.Date)return Wm(n.autogeneration);if(n.name===A.Number)return cT(n.autogeneration);if(n.name===A.String)return yT(n.autogeneration);if(n.name===A.Boolean)return hT(n.autogeneration)}case qe.Unique:if(n.name===A.UUID)return aT();default:throw new Error(`Generating a ${n.autogeneration.type} value for a ${n.name} is not supported`)}}const Z="e7eb5382-3d99-44fd-972a-b8b1e819f6be",Dl="global-user-variable-id",fT="last-executed-timestamp-variable-id",kP={id:"alternative-relational-database-entity-identifier-property-data-type-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-identifier-property-data-type-id",entityType:r.DataType},jP={id:"alternative-relational-database-entity-identifier-property-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-identifier-property-id",entityType:r.Property},qP={like:!1,id:"alternative-relational-database-entity-identifier-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"alternative-relational-database-entity-identifier-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:null,parent:kP,autogeneration:{type:qe.Unique,rangeStart:null,rangeEnd:null},valueAsType:null},parent:jP},Rs={id:"alternative-relational-database-entity-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},JP={hidden:!1,required:!0,id:"alternative-relational-database-entity-identifier-property-id",name:"Identifier name",version:1,type:r.Property,private:!1,abstract:!1,implements:ja,static:!0,index:0,dataType:qP,description:"The name of the main database inside of the server instance where the data will be stored.",parent:Rs};r.GenericReference,r.DataType;const WP={id:"alternative-relational-database-entity-username-property-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-username-property-id",entityType:r.Property},HP={like:!1,id:"alternative-relational-database-entity-username-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:null,parent:WP},YP={hidden:!1,required:!0,id:"alternative-relational-database-entity-username-property-id",name:"Username",version:1,type:r.Property,private:!1,abstract:!1,implements:qa,static:!0,index:1,dataType:HP,description:"The username that will be used to connect to the database.",parent:Rs};r.GenericReference,r.DataType;const zP={id:"alternative-relational-database-entity-password-property-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-password-property-id",entityType:r.Property},ZP={like:!1,id:"alternative-relational-database-entity-password-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:null,parent:zP},XP={hidden:!1,required:!0,id:"alternative-relational-database-entity-password-property-id",name:"Password",version:1,type:r.Property,private:!1,abstract:!1,implements:Ja,static:!0,index:2,dataType:ZP,description:"The password that will be used to connect to the database.",parent:Rs},QP={id:"alternative-relational-database-entity-min-size-property-data-type-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-min-size-property-data-type-id",entityType:r.DataType},KP={id:"alternative-relational-database-entity-min-size-property-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-min-size-property-id",entityType:r.Property},eA={like:!1,id:"alternative-relational-database-entity-min-size-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ce,asType:!1,defaultValue:{id:"alternative-relational-database-entity-min-size-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.Number,value:6,parent:QP,autogeneration:null,valueAsType:null},parent:KP},tA={hidden:!1,required:!0,id:"alternative-relational-database-entity-min-size-property-id",name:"Minimum GB size",version:1,type:r.Property,private:!1,abstract:!1,implements:Wa,static:!0,index:3,dataType:eA,description:"The minimum size of the database in GB.",parent:Rs},nA={id:"alternative-relational-database-entity-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},mT={id:"alternative-relational-database-entity-id",type:r.CustomEntity,version:1,name:"Alternative relational Database",description:"A database that permanently stores the persisted entities attached to it.",abstract:!1,static:!0,properties:[JP,YP,XP,tA],methods:[],abstractMethods:[],extends:[],implements:[On],x:0,y:0,parent:nA},rA={id:"animal-prototype-database-property-ref-id",type:r.GenericReference,entityId:"animal-prototype-database-property-id",entityType:r.Property},iA={id:"animal-prototype-database-property-data-type-default-value-parent-ref-id",type:r.GenericReference,entityId:"animal-prototype-database-property-data-type-default-value-id",entityType:r.DataType},aA={like:!1,id:"animal-prototype-database-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:On,asType:!1,defaultValue:{id:"animal-prototype-database-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,value:null,name:A.EntityTemplate,valueAsType:mT,autogeneration:null,parent:iA},parent:rA},sA={id:"animal-prototype-database-property-parent-ref-id",type:r.GenericReference,entityId:"de67fc84-3719-46fd-9ab4-3fca3a3cc50d",entityType:r.CustomEntity},oA={hidden:!1,required:!0,id:"animal-prototype-database-property-id",name:"Database",version:1,type:r.Property,private:!1,abstract:!1,implements:Pi,static:!0,index:0,dataType:aA,description:"The database that the entity belongs to.",parent:sA},lA={type:r.GenericReference,id:"291e4d4f-01d8-40a0-90dc-5f1ac6636e9b",entityType:r.Property,entityId:"5cb617b0-92be-4dbe-a007-49093368d94f"},cA={like:!1,id:"c1930577-9e79-48a6-8905-be24611015c1",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:lA},dA={type:r.GenericReference,id:"e2b9e456-f2b3-4dc7-85a2-fbb68ed0c9c7",entityType:r.CustomEntity,entityId:"c9bc312a-10d3-48a7-9ab4-ea483a9e2416"},uA={hidden:!1,required:!0,type:r.Property,id:"5cb617b0-92be-4dbe-a007-49093368d94f",version:1,name:"Name",description:"The name of the animal",implements:null,static:!1,private:!1,index:0,dataType:cA,abstract:!1,parent:dA},pA={type:r.GenericReference,id:"abc565de-4c83-4936-bc48-4013bef213b8",entityType:r.Project,entityId:Z},yA={type:r.CustomEntity,id:"83eaa847-e62b-4192-84fb-3d8d6f5ea970",version:1,name:"Animal",description:"A living creature that is not human",abstract:!1,static:!1,abstractMethods:[],properties:[oA,uA],methods:[],extends:[],implements:[Le],x:0,y:0,parent:pA},hA={id:"default-relational-database-entity-identifier-property-data-type-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-identifier-property-data-type-id",entityType:r.DataType},fA={id:"default-relational-database-entity-identifier-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-identifier-property-id",entityType:r.Property},mA={like:!1,id:"default-relational-database-entity-identifier-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"default-relational-database-entity-identifier-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"main",parent:hA,autogeneration:{type:qe.Unique,rangeStart:null,rangeEnd:null},valueAsType:null},parent:fA},Hr={id:"default-relational-database-entity-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},TA={hidden:!1,required:!0,id:"default-relational-database-entity-identifier-property-id",name:"Identifier name",version:1,type:r.Property,private:!1,abstract:!1,implements:ja,static:!0,index:0,dataType:mA,description:"The name of the main database inside of the server instance where the data will be stored.",parent:Hr};r.GenericReference,r.DataType;const EA={id:"default-relational-database-entity-username-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-username-property-id",entityType:r.Property},RA={id:"default-relational-database-entity-username-property-default-value-parent-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-username-property-data-type-id",entityType:r.DataType},bA={like:!1,id:"default-relational-database-entity-username-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"default-relational-database-entity-username-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"root",parent:RA,autogeneration:null,valueAsType:null},parent:EA},gA={hidden:!1,required:!0,id:"default-relational-database-entity-username-property-id",name:"Username",version:1,type:r.Property,private:!1,abstract:!1,implements:qa,static:!0,index:1,dataType:bA,description:"The username that will be used to connect to the database.",parent:Hr};r.GenericReference,r.DataType;const vA={id:"default-relational-database-entity-password-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-password-property-id",entityType:r.Property},IA={id:"default-relational-database-entity-password-property-default-value-parent-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-password-property-data-type-id",entityType:r.DataType},DA={like:!1,id:"default-relational-database-entity-password-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"default-relational-database-entity-password-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"password",parent:IA,autogeneration:null,valueAsType:null},parent:vA},PA={hidden:!1,required:!0,id:"default-relational-database-entity-password-property-id",name:"Password",version:1,type:r.Property,private:!1,abstract:!1,implements:Ja,static:!0,index:2,dataType:DA,description:"The password that will be used to connect to the database.",parent:Hr},AA={id:"default-relational-database-entity-min-size-property-data-type-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-min-size-property-data-type-id",entityType:r.DataType},SA={id:"default-relational-database-entity-min-size-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-min-size-property-id",entityType:r.Property},OA={like:!1,id:"default-relational-database-entity-min-size-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ce,asType:!1,defaultValue:{id:"default-relational-database-entity-min-size-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.Number,value:6,parent:AA,autogeneration:null,valueAsType:null},parent:SA},CA={hidden:!1,required:!0,id:"default-relational-database-entity-min-size-property-id",name:"Minimum GB size",version:1,type:r.Property,private:!1,abstract:!1,implements:Wa,static:!0,index:3,dataType:OA,description:"The minimum size of the database in GB.",parent:Hr},BA={id:"default-relational-database-entity-default-property-data-type-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-default-property-data-type-id",entityType:r.DataType},wA={id:"default-relational-database-entity-default-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-default-property-id",entityType:r.Property},_A={like:!1,id:"default-relational-database-entity-default-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ce,asType:!1,defaultValue:{id:"default-relational-database-entity-default-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.Boolean,value:!0,parent:BA,autogeneration:null,valueAsType:null},parent:wA},MA={hidden:!0,required:!0,id:"default-relational-database-entity-default-property-id",name:"Default",version:1,type:r.Property,private:!1,abstract:!1,implements:Ko,static:!0,index:4,dataType:_A,description:"Whether this database is automatically picked by other entities as the default database.",parent:Hr},NA={id:"default-relational-database-entity-autoscaling-property-data-type-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-autoscaling-property-data-type-id",entityType:r.DataType},VA={id:"default-relational-database-entity-autoscaling-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-autoscaling-property-id",entityType:r.Property},$A={like:!1,id:"default-relational-database-entity-autoscaling-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ce,asType:!1,defaultValue:{id:"default-relational-database-entity-autoscaling-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.Boolean,value:!0,parent:NA,autogeneration:null,valueAsType:null},parent:VA},LA={hidden:!1,required:!0,id:"default-relational-database-entity-autoscaling-property-id",name:"Auto-scaling",version:1,type:r.Property,private:!1,abstract:!1,implements:el,static:!0,index:5,dataType:$A,description:"If true, this database will automatically scale up or down in memory size, based on the usage.s",parent:Hr},GA={id:"default-relational-database-entity-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},Pl={id:"default-relational-database-entity-id",type:r.CustomEntity,version:1,name:"Relational Database",description:"A database that permanently stores the persisted entities attached to it.",abstract:!1,static:!0,properties:[MA,LA,TA,gA,PA,CA],methods:[],abstractMethods:[],extends:[],implements:[On],x:0,y:0,parent:GA},FA={id:"user-prototype-database-property-data-type-ref-id",type:r.GenericReference,entityId:"user-prototype-database-property-data-type-id",entityType:r.DataType},UA={id:"user-prototype-database-property-ref-id",type:r.GenericReference,entityId:"user-prototype-database-property-id",entityType:r.Property},xA={like:!1,id:"user-prototype-database-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:On,asType:!1,defaultValue:{id:"user-prototype-database-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,value:null,name:A.EntityTemplate,valueAsType:Pl,autogeneration:null,parent:FA},parent:UA},kA={id:"user-prototype-database-property-parent-ref-id",type:r.GenericReference,entityId:"de67fc84-3719-46fd-9ab4-3fca3a3cc50d",entityType:r.CustomEntity},jA={hidden:!1,required:!0,id:"user-prototype-database-property-id",name:"Database",version:1,type:r.Property,private:!1,abstract:!1,implements:Pi,static:!0,index:0,dataType:xA,description:"The database that the entity belongs to.",parent:kA},qA={type:r.GenericReference,id:"user-prototype-parent-ref-id",entityType:r.Project,entityId:Z},Al={type:r.CustomEntity,id:"de67fc84-3719-46fd-9ab4-3fca3a3cc50d",version:1,name:"User",description:"A user of the application",implements:[Le],abstract:!1,static:!1,abstractMethods:[],extends:[],properties:[jA],methods:[],x:0,y:0,parent:qA},JA={type:r.GenericReference,id:"person-date-of-birth-property-data-type-parent-ref-id",entityType:r.Property,entityId:"person-date-of-birth-property-id"},WA={like:!1,id:"person-date-of-birth-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:cn,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:JA},HA={type:r.GenericReference,id:"person-date-of-birth-property-parent-ref-id",entityType:r.CustomEntity,entityId:"c9bc312a-10d3-48a7-9ab4-ea483a9e2416"},YA={hidden:!1,required:!0,type:r.Property,id:"person-date-of-birth-property-id",version:1,name:"Date of birth",description:"The date of birth of the person",implements:null,private:!1,static:!1,index:0,dataType:WA,abstract:!1,parent:HA},zA={type:r.GenericReference,id:"a2867827-2f8e-4c25-b18b-d91857d7f24e",entityType:r.Property,entityId:"cacfec92-46c3-4fca-a1d9-fd1ba94d78c7"},ZA={like:!1,id:"1d49f41b-17b9-4f48-87aa-3ce43498e5a9",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:zA},XA={type:r.GenericReference,id:"01cbe760-40a9-4f49-8e3d-194d2f57cb1e",entityType:r.CustomEntity,entityId:"c9bc312a-10d3-48a7-9ab4-ea483a9e2416"},QA={hidden:!1,required:!0,type:r.Property,id:"cacfec92-46c3-4fca-a1d9-fd1ba94d78c7",version:1,name:"Name",description:"The name of the person",implements:null,private:!1,static:!1,index:0,dataType:ZA,abstract:!1,parent:XA},KA={type:r.GenericReference,id:"3542b22a-3a2f-41c6-876e-24c885572498",entityType:r.Project,entityId:Z},pt={type:r.CustomEntity,id:"c9bc312a-10d3-48a7-9ab4-ea483a9e2416",version:1,name:"Person",description:"A entity to store more information about a person than the user entity does, to split the responsibilities and keep it the logic clean.",properties:[QA,YA],abstract:!1,static:!1,abstractMethods:[],methods:[],implements:[],extends:[Al],x:0,y:0,parent:KA},eS={type:r.GenericReference,id:"b59c80b7-b2e9-41e9-abcd-7c5652835efc",entityType:r.FunctionDeclaration,entityId:"36f29f96-c001-4b9a-b49c-83eff406a060"},tS={type:r.GenericReference,id:"1190b5a2-f25e-46db-884d-8a3dd1a44d94",entityType:r.ReturnStatement,entityId:"3ebc4342-c9e8-42e7-a61c-7937081e1d2e"},nS={type:r.GenericReference,id:"36c63126-7814-496f-a6cc-48662c2aabae",entityType:r.ArgumentDeclaration,entityId:"500dee3a-3435-4453-9699-0d053f646523"},rS={type:r.GenericReference,id:"c567e55d-ec12-4e4e-958e-f07522892b4b",entityType:r.ReturnDeclaration,entityId:"9e070523-7e07-4100-8637-960a187f5f14"},iS={like:!1,id:"3973c5a1-f0d8-49a0-a9a9-a0009bf3f0d8",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:rS},Sl={isError:!1,id:"9e070523-7e07-4100-8637-960a187f5f14",type:r.ReturnDeclaration,version:1,name:"Output Account Owner",description:null,dataType:iS,readsValue:nS,required:!0,index:0,parent:tS},aS={type:r.GenericReference,id:"567d923c-20da-4c1e-956d-962ea30c6d0b",entityType:r.FunctionDeclaration,entityId:"36f29f96-c001-4b9a-b49c-83eff406a060"},sS={type:r.GenericReference,id:"da85e620-59f3-42ab-88c8-b38d33c2c833",entityType:r.FunctionDeclaration,entityId:"36f29f96-c001-4b9a-b49c-83eff406a060"},TT={type:r.ReturnStatement,id:"3ebc4342-c9e8-42e7-a61c-7937081e1d2e",version:1,outputs:[Sl],calledByError:[],calledByEntry:[aS],calledBySuccess:[],throws:null,x:0,y:0,parent:sS},oS={type:r.GenericReference,id:"1c806bb7-4c25-4bad-963b-93dfbb7c8304",entityType:r.ArgumentDeclaration,entityId:"500dee3a-3435-4453-9699-0d053f646523"},lS={like:!1,id:"d90fcc18-642b-433c-8fcb-4094b9031cd5",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:oS},ET={id:"500dee3a-3435-4453-9699-0d053f646523",type:r.ArgumentDeclaration,version:1,name:"New Account Owner",description:null,dataType:lS,required:!0,writesValues:[Sl],index:0,parent:eS},cS={type:r.GenericReference,id:"83dceb60-f3c4-4085-824c-85f2003bfd27",entityType:r.CustomEntity,entityId:"506946aa-30da-48e6-918f-ffd9eac58813"},RT={type:r.FunctionDeclaration,id:"36f29f96-c001-4b9a-b49c-83eff406a060",version:1,name:"Change owner of bank account",description:null,implements:null,inputs:[ET],calls:[TT],returnStatements:[TT],index:0,collapsed:!1,private:!1,x:0,y:0,parent:cS},dS={type:r.GenericReference,id:"adbaf302-ffa9-49b6-a3c6-83f9a75068e3",entityType:r.VariableDeclaration,entityId:"8e36a476-766e-4cc2-a8a7-27a07dfb5a4b"},uS={like:!1,id:"79ee04aa-1ba4-4ae9-a406-ed45e5b03f7f",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:dS},pS={type:r.GenericReference,id:"55e212d1-f0ec-4bb6-acbe-60f741367daf",entityType:r.OutputMap,entityId:"dc9ddb8f-02a0-4a43-aea6-270ec7b7f8a4"},yS={type:r.GenericReference,id:"944e1171-3d9b-4559-9386-1d4974b15962",entityType:r.FunctionDeclaration,entityId:"15ee556d-681f-47de-a31f-16d4ba73cc4e"},hS={id:"8e36a476-766e-4cc2-a8a7-27a07dfb5a4b",type:r.VariableDeclaration,version:1,name:"Output Account Owner",description:null,dataType:uS,readsValue:pS,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:yS},fS={type:r.GenericReference,id:"b89ebc83-52cf-4447-a5ae-62241f713079",entityType:r.FunctionCall,entityId:"78f6dba8-bed8-44cd-8b0f-6dcc787d1e1e"},mS={id:"dc9ddb8f-02a0-4a43-aea6-270ec7b7f8a4",type:r.OutputMap,version:1,declaration:Sl,writesValues:[hS],index:0,parent:fS},TS={type:r.GenericReference,id:"c1b9e125-1aad-48b7-9687-95c57a6bc10d",entityType:r.FunctionDeclaration,entityId:"15ee556d-681f-47de-a31f-16d4ba73cc4e"},ES={type:r.GenericReference,id:"d2deaa02-e164-4425-905c-6dee47eb4eac",entityType:r.FunctionDeclaration,entityId:"15ee556d-681f-47de-a31f-16d4ba73cc4e"},RS={type:r.GenericReference,id:"1109a655-ac62-4110-a933-42a72106f4f0",entityType:r.VariableDeclaration,entityId:"8bea6986-8da2-487b-905d-2fb962db6728"},bS={like:!1,id:"7d9a1307-512e-42ec-9797-2f7229796b97",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:RS},gS={type:r.GenericReference,id:"bb61ebf7-57b3-4d14-905d-82ec907205b5",entityType:r.ArgumentDeclaration,entityId:"38f6b236-98ac-47b0-ab9c-d2f9610137b9"},vS={type:r.GenericReference,id:"6b8c7bf2-9fc8-4ea4-9ec0-f41679d513b1",entityType:r.FunctionDeclaration,entityId:"15ee556d-681f-47de-a31f-16d4ba73cc4e"},IS={type:r.GenericReference,id:"6163d1a1-7a94-49b1-95bb-aecd8d6d335c",entityType:r.FunctionCall,entityId:"78f6dba8-bed8-44cd-8b0f-6dcc787d1e1e"},DS={type:r.GenericReference,id:"1f900f62-4bd2-4246-94aa-b8f5aad384fd",entityType:r.VariableDeclaration,entityId:"8bea6986-8da2-487b-905d-2fb962db6728"},bT={id:"be8538be-e6f9-4b94-9314-a546003ebaa0",type:r.InputMap,version:1,declaration:ET,name:null,description:null,readsValue:DS,defaultValue:null,index:0,parent:IS},PS={type:r.VariableDeclaration,id:"8bea6986-8da2-487b-905d-2fb962db6728",version:1,name:"Changed Account Owner",description:null,dataType:bS,readsValue:gS,writesValues:[bT],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:vS},AS={type:r.FunctionCall,id:"78f6dba8-bed8-44cd-8b0f-6dcc787d1e1e",version:1,declaration:RT,inputs:[bT],outputs:[mS],process:null,successCalls:[],errorCalls:[],calledByError:[],calledByEntry:[TS],calledBySuccess:[],parent:ES,error:null,x:0,y:0},SS={type:r.GenericReference,id:"2d47aba1-a918-46a7-8db7-78809928654a",entityType:r.ArgumentDeclaration,entityId:"38f6b236-98ac-47b0-ab9c-d2f9610137b9"},OS={like:!1,id:"5583766c-e9a5-484c-8f43-f4b0a6a1876c",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:SS},CS={type:r.GenericReference,id:"3e2a81e4-55b2-49f5-94eb-39135e95c3d7",entityType:r.FunctionDeclaration,entityId:"15ee556d-681f-47de-a31f-16d4ba73cc4e"},BS={id:"38f6b236-98ac-47b0-ab9c-d2f9610137b9",type:r.ArgumentDeclaration,version:1,description:null,name:"New Company Owner",dataType:OS,required:!0,index:0,writesValues:[PS],parent:CS},wS={type:r.GenericReference,id:"30291b01-1b94-4d03-b434-dec122c2bc7d",entityType:r.CustomEntity,entityId:"506946aa-30da-48e6-918f-ffd9eac58813"},_S={type:r.FunctionDeclaration,id:"15ee556d-681f-47de-a31f-16d4ba73cc4e",version:1,description:null,name:"Change Account Owner",inputs:[BS],collapsed:!0,returnStatements:[],calls:[AS],private:!1,index:0,implements:null,x:0,y:0,parent:wS},MS={type:r.GenericReference,id:"72c7ac0a-886e-4e10-b7ed-2f5a819a0233",entityType:r.Property,entityId:"b8f4656a-2b77-43ab-af51-7c32ddede044"},NS={like:!1,id:"c09dd282-73f6-4077-a467-b66db20b9fc6",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:MS},VS={type:r.GenericReference,id:"8a950024-512c-4580-81db-a705410aeb99",entityType:r.CustomEntity,entityId:"506946aa-30da-48e6-918f-ffd9eac58813"},$S={hidden:!1,required:!0,type:r.Property,id:"b8f4656a-2b77-43ab-af51-7c32ddede044",version:1,name:"Account number",description:null,private:!0,implements:null,static:!1,index:0,dataType:NS,abstract:!1,parent:VS},LS={type:r.GenericReference,id:"b6704b6c-c3bd-49d0-8ebc-82d03e726cbb",entityType:r.Property,entityId:"733d06a6-b8c5-44f3-a1f7-a8c9bd9e44ea"},GS={like:!1,id:"c03e0b0a-88ab-401a-8833-4806738bdc37",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:LS},FS={type:r.GenericReference,id:"1ef999a7-e9ed-406a-866e-e58277fc985b",entityType:r.CustomEntity,entityId:"506946aa-30da-48e6-918f-ffd9eac58813"},US={hidden:!1,required:!0,type:r.Property,id:"733d06a6-b8c5-44f3-a1f7-a8c9bd9e44ea",version:1,description:null,name:"Account Owner",index:1,dataType:GS,implements:null,static:!1,private:!0,abstract:!1,parent:FS},xS={type:r.GenericReference,id:"d41d7f41-98b8-4f67-be92-c349fdda5156",entityType:r.Project,entityId:Z},Yr={type:r.CustomEntity,id:"506946aa-30da-48e6-918f-ffd9eac58813",version:1,name:"Bank Account",description:null,abstract:!1,static:!1,abstractMethods:[],properties:[$S,US],methods:[RT,_S],extends:[],implements:[Le],x:0,y:0,parent:xS},Ji="bitcoin-api-response-id",gT="time-property-id",vT="disclamer-property-id",IT="chart-name-property-id",DT="bpi-property-id",bs="bpi-entity-id",PT="usd-property-id",AT="gbp-property-id",ST="eur-property-id",zr="currency-entity-id",OT="currency-code-property-id",CT="currency-symbol-property-id",BT="currency-rate-property-id",wT="currency-description-property-id",_T="currency-rate-number-property-id",kS={type:r.GenericReference,id:"code-property-data-type-parent-ref-id",entityType:r.Property,entityId:OT},jS={like:!1,id:"code-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Sn,isList:!1,asType:!1,isNullable:!1,defaultValue:null,options:["USD","GBP","EUR"],constant:!1,parent:kS},qS={type:r.GenericReference,id:"code-property-parent-ref-id",entityType:r.CustomEntity,entityId:zr},JS={hidden:!1,required:!0,type:r.Property,id:OT,version:1,name:"code",description:null,dataType:jS,index:0,implements:null,static:!1,private:!1,abstract:!1,parent:qS},WS={type:r.GenericReference,id:"symbol-property-data-type-parent-ref-id",entityType:r.Property,entityId:CT},HS={like:!1,id:"symbol-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Sn,isList:!1,asType:!1,isNullable:!1,defaultValue:null,options:["$","£","€"],constant:!1,parent:WS},YS={type:r.GenericReference,id:"symbol-property-parent-ref-id",entityType:r.CustomEntity,entityId:zr},zS={hidden:!1,required:!0,type:r.Property,id:CT,version:1,name:"symbol",description:null,index:0,dataType:HS,implements:null,static:!1,private:!1,abstract:!1,parent:YS},ZS={type:r.GenericReference,id:"rate-property-data-type-parent-ref-id",entityType:r.Property,entityId:BT},XS={like:!1,id:"rate-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:ZS},QS={type:r.GenericReference,id:"rate-property-parent-ref-id",entityType:r.CustomEntity,entityId:zr},KS={hidden:!1,required:!0,type:r.Property,id:BT,version:1,name:"rate",description:null,index:0,dataType:XS,implements:null,static:!1,private:!1,abstract:!1,parent:QS},eO={type:r.GenericReference,id:"description-property-data-type-parent-ref-id",entityType:r.Property,entityId:wT},tO={like:!1,id:"description-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:eO},nO={type:r.GenericReference,id:"description-property-parent-ref-id",entityType:r.CustomEntity,entityId:zr},rO={hidden:!1,required:!0,type:r.Property,id:wT,version:1,name:"description",description:null,dataType:tO,implements:null,static:!1,index:0,private:!1,abstract:!1,parent:nO},iO={type:r.GenericReference,id:"rate-number-property-data-type-parent-ref-id",entityType:r.Property,entityId:_T},aO={like:!1,id:"rate-number-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:iO},sO={type:r.GenericReference,id:"rate-number-property-parent-ref-id",entityType:r.CustomEntity,entityId:zr},oO={hidden:!1,required:!0,type:r.Property,id:_T,version:1,name:"rate_float",description:null,dataType:aO,implements:null,static:!1,index:0,private:!1,abstract:!1,parent:sO},lO={type:r.GenericReference,id:"currency-prototype-parent-ref-id",entityType:r.Project,entityId:Z},gs={type:r.CustomEntity,id:zr,version:1,name:"Currency",description:"This entity describes a currency in the Bitcoin Price Index.",properties:[JS,zS,KS,rO,oO],static:!1,abstract:!1,abstractMethods:[],methods:[],extends:[],implements:[],x:0,y:0,parent:lO},cO={type:r.GenericReference,id:"usd-property-data-type-parent-ref-id",entityType:r.Property,entityId:PT},dO={like:!1,id:"usd-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gs,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:cO},uO={type:r.GenericReference,id:"usd-property-parent-ref-id",entityType:r.CustomEntity,entityId:bs},pO={hidden:!1,required:!0,id:PT,type:r.Property,version:1,name:"USD",description:null,index:0,dataType:dO,implements:null,static:!1,private:!1,abstract:!1,parent:uO},yO={type:r.GenericReference,id:"gbp-property-data-type-parent-ref-id",entityType:r.Property,entityId:AT},hO={like:!1,id:"gbp-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gs,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:yO},fO={type:r.GenericReference,id:"gbp-property-parent-ref-id",entityType:r.CustomEntity,entityId:bs},mO={hidden:!1,required:!0,id:AT,type:r.Property,version:1,name:"GBP",description:null,index:0,dataType:hO,implements:null,static:!1,private:!1,abstract:!1,parent:fO},TO={type:r.GenericReference,id:"eur-property-data-type-parent-ref-id",entityType:r.Property,entityId:ST},EO={like:!1,id:"eur-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gs,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:TO},RO={type:r.GenericReference,id:"eur-property-parent-ref-id",entityType:r.CustomEntity,entityId:bs},bO={hidden:!1,required:!0,id:ST,type:r.Property,version:1,name:"EUR",description:null,implements:null,static:!1,index:0,dataType:EO,private:!1,abstract:!1,parent:RO},gO={type:r.GenericReference,id:"bpi-prototype-parent-ref-id",entityType:r.Project,entityId:Z},MT={type:r.CustomEntity,id:bs,version:1,name:"BPI",description:"The Bitcoin Price Index",properties:[pO,mO,bO],abstract:!1,static:!1,abstractMethods:[],methods:[],extends:[],implements:[],x:0,y:0,parent:gO},vO={type:r.GenericReference,id:"time-property-data-type-parent-ref-id",entityType:r.Property,entityId:gT},IO={like:!1,id:"time-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:_o,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:vO},DO={type:r.GenericReference,id:"time-property-parent-ref-id",entityType:r.CustomEntity,entityId:Ji},PO={hidden:!1,required:!0,type:r.Property,id:gT,version:1,name:"time",description:null,index:0,dataType:IO,implements:null,static:!1,private:!1,abstract:!1,parent:DO},AO={type:r.GenericReference,id:"disclamer-property-data-type-parent-ref-id",entityType:r.Property,entityId:vT},SO={like:!1,id:"disclamer-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:AO},OO={type:r.GenericReference,id:"disclamer-property-parent-ref-id",entityType:r.CustomEntity,entityId:Ji},CO={hidden:!1,required:!0,type:r.Property,id:vT,version:1,name:"disclamer",description:null,index:0,dataType:SO,implements:null,static:!1,private:!1,abstract:!1,parent:OO},BO={type:r.GenericReference,id:"chart-name-property-data-type-parent-ref-id",entityType:r.Property,entityId:IT},wO={like:!1,id:"chart-name-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:BO},_O={type:r.GenericReference,id:"chart-name-property-parent-ref-id",entityType:r.CustomEntity,entityId:Ji},MO={hidden:!1,required:!0,type:r.Property,id:IT,version:1,name:"chartName",description:null,index:0,dataType:wO,implements:null,static:!1,private:!1,abstract:!1,parent:_O},NO={type:r.GenericReference,id:"bpi-property-data-type-parent-ref-id",entityType:r.Property,entityId:DT},VO={like:!1,id:"bpi-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:MT,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:NO},$O={type:r.GenericReference,id:"bpi-property-parent-ref-id",entityType:r.CustomEntity,entityId:Ji},LO={hidden:!1,required:!0,type:r.Property,id:DT,version:1,name:"bpi",description:null,implements:null,index:0,dataType:VO,static:!1,private:!1,abstract:!1,parent:$O},GO={type:r.GenericReference,id:"bitcoin-api-response-parent-ref-id",entityType:r.Project,entityId:Z},NT={type:r.CustomEntity,id:Ji,version:1,name:"Bitcoin API Response type",description:"The type of the data structure response from the Bitcoin API call",properties:[PO,CO,MO,LO],abstract:!1,static:!1,abstractMethods:[],methods:[],extends:[],implements:[],x:0,y:0,parent:GO},FO={type:r.GenericReference,id:"eefa0147-f873-484b-b4f3-9e6493aab183",entityType:r.ArgumentDeclaration,entityId:"f2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a"},UO={like:!1,id:"b9f35112-dcb2-4b7c-8fb9-f196b3fa37f9",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:FO},xO={type:r.GenericReference,id:"128770d6-5e3a-4aff-bca0-ad1f32ebefa8",entityType:r.ReturnStatement,entityId:"e4e05975-c277-471a-b869-f0aed316045c"},kO={type:r.GenericReference,id:"0be84bf9-6421-42b9-980f-6a03f30cb809",entityType:r.ReturnDeclaration,entityId:"a1ec31f0-25ca-42ac-a4c4-c9ec2255f55b"},jO={like:!1,id:"43daa02a-237b-4b7c-a6e9-2b8c167f6e22",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:kO},qO={type:r.GenericReference,id:"ad380383-4a47-43da-968e-75a2d603b230",entityType:r.ArgumentDeclaration,entityId:"f2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a"},VT={isError:!1,id:"a1ec31f0-25ca-42ac-a4c4-c9ec2255f55b",type:r.ReturnDeclaration,version:1,name:"New Company Owner",description:"The new owner of the company",dataType:jO,readsValue:qO,required:!0,index:0,parent:xO},JO={type:r.GenericReference,id:"4f24dc27-59a1-49bf-abcc-7d72b00926e4",entityType:r.FunctionDeclaration,entityId:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4"},WO={id:"f2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a",type:r.ArgumentDeclaration,version:1,name:"New Company Owner",description:null,dataType:UO,writesValues:[VT],required:!0,index:0,parent:JO},HO={type:r.GenericReference,id:"5c9a02f0-d2cf-4efc-828e-467f33a74dd3",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},YO={type:r.GenericReference,id:"2ff8f3da-e0c5-4f0f-b688-2c051c588786",entityType:r.FunctionDeclaration,entityId:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4"},zO={type:r.GenericReference,id:"195ae28c-159b-42de-80b1-2ebb8be3619f",entityType:r.FunctionDeclaration,entityId:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4"},$T={type:r.ReturnStatement,id:"e4e05975-c277-471a-b869-f0aed316045c",version:1,outputs:[VT],calledByError:[],calledByEntry:[YO],calledBySuccess:[],throws:null,x:0,y:0,parent:zO},ZO={type:r.FunctionDeclaration,id:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4",version:1,name:"Change owner of company",description:"Change the owner of the company to a new person",inputs:[WO],calls:[$T],index:0,collapsed:!1,implements:null,returnStatements:[$T],private:!1,x:0,y:0,parent:HO},XO={type:r.GenericReference,id:"e691026f-6db0-43ec-93cd-805ae7d713e3",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},QO={type:r.GenericReference,id:"29c4e3e0-1b66-4075-b559-45b27c5cf356",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},KO={type:r.GenericReference,id:"b1289358-b185-455d-8f58-7791b15cd52a",entityType:r.ReturnStatement,entityId:"9690cd1d-ea35-4e83-823d-0c7310265fee"},eC={type:r.GenericReference,id:"d847bb49-8789-4550-bb2d-e2d551993b28",entityType:r.VariableDeclaration,entityId:"e5a8b6d0-0e6f-4e9a-9b1e-8a2b5c7f0d5a"},tC={type:r.GenericReference,id:"06535500-c37c-4915-8398-1d4e184fa5e7",entityType:r.ReturnDeclaration,entityId:"e7a35277-a0c4-46d5-aca2-bddd0c26e931"},nC={like:!1,id:"d358dd91-35f7-4095-b728-3fb3c71dbc05",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:An,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:tC},Ol={isError:!1,id:"e7a35277-a0c4-46d5-aca2-bddd0c26e931",type:r.ReturnDeclaration,version:1,name:"Is name registered",description:"Whether the company name is already registered",dataType:nC,readsValue:eC,required:!0,index:0,parent:KO},rC={type:r.GenericReference,id:"gov-company-registry-return-statement-called-by-success-ref-id",entityType:r.VariableDeclaration,entityId:"e5a8b6d0-0e6f-4e9a-9b1e-8a2b5c7f0d5a"},Cl={type:r.ReturnStatement,id:"9690cd1d-ea35-4e83-823d-0c7310265fee",version:1,outputs:[Ol],calledByError:[],calledByEntry:[],calledBySuccess:[XO,rC],throws:null,x:0,y:0,parent:QO},iC={type:r.GenericReference,id:"b3126414-4c9b-495f-901e-59f5073c8d67",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},aC={type:r.GenericReference,id:"35115c48-618b-411b-a290-d746d22fdd10",entityType:r.VariableDeclaration,entityId:"83e12ebb-c958-4dee-b750-8ab9930f0f4e"},LT={id:"a0e7b4e5-2f5f-4d4c-8f5c-1e1f1e1a1b1a",type:r.InputMap,version:1,declaration:Wo,name:null,description:null,readsValue:aC,defaultValue:null,parent:iC,index:2},sC={type:r.GenericReference,id:"14f46eae-04a5-47d1-9c7f-28fb09b84d1d",entityType:r.VariableDeclaration,entityId:"e5a8b6d0-0e6f-4e9a-9b1e-8a2b5c7f0d5a"},oC={like:!1,id:"990bd5d1-07ea-4253-acc1-d03bedd22a38",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:An,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:sC},lC={type:r.GenericReference,id:"e4c3542a-8fb0-4b72-8d6e-3fdff812dd67",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},cC={type:r.GenericReference,id:"825f9f60-22a8-4cc6-9055-d7333f8e92f4",entityType:r.OutputMap,entityId:"8f30d787-9459-4d8d-98a2-b46fbc2006d5"},dC={type:r.GenericReference,id:"is-company-name-registered-var-called-by-ref",entityType:r.Operation,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},GT={type:r.VariableDeclaration,id:"e5a8b6d0-0e6f-4e9a-9b1e-8a2b5c7f0d5a",version:1,name:"Is name registered",description:"Whether the company name is registered with the government company registry",dataType:oC,readsValue:cC,writesValues:[Ol],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[dC],successCalls:[Cl],errorCalls:[],internalCalls:[],x:0,y:0,parent:lC},uC={type:r.GenericReference,id:"1aba021e-48ef-44ac-93d0-eaecac5895da",entityType:r.InputMap,entityId:"c3c8d6c1-3e0d-4e6c-9f9c-6b8c7d7f8e9a"},pC={type:r.GenericReference,id:"dffae7e0-0a5c-4c14-8ed2-8d680b4c4c86",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},yC={type:r.InputMap,id:"c3c8d6c1-3e0d-4e6c-9f9c-6b8c7d7f8e9a",version:1,declaration:$a,name:null,description:null,readsValue:null,defaultValue:{id:"gov-http-request-url-argument-default-value-id",type:r.PrimitiveValue,version:1,value:"https://api.publicapis.org/entries",name:A.String,valueAsType:null,parent:uC,autogeneration:null},index:1,parent:pC},hC={type:r.GenericReference,id:"64ae61f5-ace7-401b-926d-25f852daa60e",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},fC={id:"8f30d787-9459-4d8d-98a2-b46fbc2006d5",type:r.OutputMap,version:1,declaration:vi,index:2,writesValues:[GT],parent:hC},mC={type:r.GenericReference,id:"62a1a086-caea-4270-9c9f-a1695503e745",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},TC={id:"48cf7654-8f3e-4fcd-abc6-740876c310a0",type:r.InputMap,version:1,declaration:Va,name:null,description:null,readsValue:null,index:0,defaultValue:null,parent:mC},EC={type:r.GenericReference,id:"b0c9c79f-f525-428d-99e7-087d3237ad62",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},RC={id:"2c1dc406-4b71-4023-87b2-abede3a111d2",type:r.InputMap,version:1,name:null,description:null,declaration:La,index:3,readsValue:null,defaultValue:null,parent:EC},bC={type:r.GenericReference,id:"9887d6c9-d75b-4c97-b722-e2e60945ea20",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},gC={id:"3fef94b2-0278-43ae-b0c5-bc7083f0a111",type:r.InputMap,version:1,declaration:Ga,name:null,description:null,readsValue:null,index:4,defaultValue:null,parent:bC},vC={type:r.GenericReference,id:"561275b6-5056-45d8-bf7d-8abaa4645593",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},IC={id:"3efe20a7-4d63-411e-89ef-63e277f48d66",type:r.OutputMap,version:1,declaration:Fa,index:1,writesValues:[],parent:vC},DC={type:r.GenericReference,id:"3170ccc2-13de-4bfc-802a-a643be41cd42",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},PC={id:"40d34323-d7e6-440a-8016-67c05a3b66dd",type:r.OutputMap,version:1,declaration:vi,index:0,writesValues:[],parent:DC},AC={type:r.GenericReference,id:"7432fa82-f574-4c54-a8fa-4cc4376da3d5",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},SC={type:r.GenericReference,id:"8f518502-9eea-462c-8753-8bc3bf3e29a9",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},OC={type:r.GenericReference,id:"123b8f18-79d9-4166-a5f6-78ec4b461680",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},CC={type:r.GenericReference,id:"e691026f-6db0-43ec-93cd-805ae7d713e3",entityType:r.FunctionCall,entityId:"abb5d456-ee85-4800-bdd9-d409415f60d7"},BC={type:r.GenericReference,id:"a375eedf-4811-41aa-a998-4897c69c46b9",entityType:r.ReturnDeclaration,entityId:"024a9b77-c1cd-4b67-b3ba-1935046b590d"},wC={like:!1,id:"767cc5ed-20ec-4fd1-89b1-c8d19daa87d1",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:BC},_C={type:r.GenericReference,id:"e64b0c23-129d-4d74-8ab4-eec60e1e5b9b",entityType:r.ReturnStatement,entityId:"ea444a9e-6a5b-4138-b81f-0d5618c3c6f3"},FT={isError:!0,id:"024a9b77-c1cd-4b67-b3ba-1935046b590d",type:r.ReturnDeclaration,version:1,name:"Error",description:"The error that occurred during the HTTP request to the government company registry",dataType:wC,required:!0,readsValue:null,index:0,parent:_C},MC={type:r.ReturnStatement,id:"ea444a9e-6a5b-4138-b81f-0d5618c3c6f3",version:1,outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[CC],throws:FT,x:0,y:0,parent:OC},NC={type:r.GenericReference,id:"323814fb-9723-49ef-bbba-f882384f18e4",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},VC={id:"2f63f7ba-0ff0-458a-92bc-65d1dd4df8c3",type:r.OutputMap,declaration:Yo,version:1,writesValues:[FT],index:0,parent:NC},$C={type:r.Operation,id:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7",version:1,declaration:Ii,inputs:[TC,yC,LT,RC,gC],outputs:[PC,IC,fC],process:null,calledByError:[],calledByEntry:[AC],calledBySuccess:[],successCalls:[Cl,GT],errorCalls:[MC],error:VC,x:0,y:0,parent:SC},LC={type:r.GenericReference,id:"597b8aa2-f6f2-4f7d-bbb9-b703d02de96a",entityType:r.InputMap,entityId:"b0e7b4e5-2f5f-4d4c-8f5c-1e1f1e1a1b1a"},GC={type:r.GenericReference,id:"546d99b3-28c4-4186-93a0-ac53c1565e07",entityType:r.Operation,entityId:"8f2094c0-e27e-465e-9280-112da0de9019"},FC={id:"b0e7b4e5-2f5f-4d4c-8f5c-1e1f1e1a1b1a",type:r.InputMap,version:1,declaration:_a,name:null,description:null,readsValue:null,defaultValue:{id:"base-query-string-map-default-value-id",type:r.PrimitiveValue,version:1,value:"?name=",name:A.String,parent:LC,valueAsType:null,autogeneration:null},index:0,parent:GC},UC={type:r.GenericReference,id:"6a56fb22-82e1-47c9-bf85-41c4e5986c74",entityType:r.Operation,entityId:"8f2094c0-e27e-465e-9280-112da0de9019"},xC={type:r.GenericReference,id:"191c6a6d-9bcb-441e-bf98-de0da96f5f3a",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},kC={type:r.GenericReference,id:"d8fcbb76-dae2-40cf-847a-02364721b387",entityType:r.VariableDeclaration,entityId:"83e12ebb-c958-4dee-b750-8ab9930f0f4e"},jC={like:!1,id:"6a70c42b-024a-47c6-8a9d-af52be9c9b9a",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:kC},qC={type:r.GenericReference,id:"2282e2c0-ed9e-4c7b-86fc-1a364fa0fdb8",entityType:r.OutputMap,entityId:"f6c22cf8-63e4-4b2d-b649-b5ab884cf9a5"},JC={type:r.GenericReference,id:"assembled-query-string-called-by-ref",entityType:r.Operation,entityId:"8f2094c0-e27e-465e-9280-112da0de9019"},UT={type:r.VariableDeclaration,id:"83e12ebb-c958-4dee-b750-8ab9930f0f4e",version:1,name:"Query string",description:"The final, assembled query string that will be used in the HTTP request to the government company registry",dataType:jC,readsValue:qC,writesValues:[LT],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[JC],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:xC},WC={id:"f6c22cf8-63e4-4b2d-b649-b5ab884cf9a5",type:r.OutputMap,version:1,writesValues:[UT],declaration:bi,index:0,parent:UC},HC={type:r.GenericReference,id:"a1b48e7c-0301-4747-b4dd-b5af79956f7f",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},YC={type:r.GenericReference,id:"487c9235-be95-4c96-b9b5-2714b374a277",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},zC={type:r.GenericReference,id:"f6471f4f-b269-46fa-80ec-885e87a449c2",entityId:"a4106e8e-ec4f-4633-a636-09ae73135f69",entityType:r.ArgumentDeclaration},ZC={type:r.GenericReference,id:"62b4afb0-6c21-4b0f-abd3-cebef7b17c28",entityType:r.Operation,entityId:"8f2094c0-e27e-465e-9280-112da0de9019"},xT={id:"08f36e2b-bad2-425c-8129-93560bec8488",version:1,type:r.InputMap,declaration:Ma,name:null,description:null,readsValue:zC,defaultValue:null,index:1,parent:ZC},XC={type:r.Operation,id:"8f2094c0-e27e-465e-9280-112da0de9019",declaration:gi,version:1,inputs:[FC,xT],outputs:[WC],process:null,calledByError:[],calledByEntry:[HC],calledBySuccess:[],successCalls:[UT],errorCalls:[],error:null,x:0,y:0,parent:YC},QC={type:r.GenericReference,id:"c2e0e9b4-aa46-4974-bf8a-886b737b12fb",entityType:r.ArgumentDeclaration,entityId:"a4106e8e-ec4f-4633-a636-09ae73135f69"},KC={like:!1,id:"a4279518-3bf3-44b7-a2ac-65142ca37f1c",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:QC},eB={type:r.GenericReference,id:"dc273f24-164b-4943-82f9-589b237141e2",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},kT={id:"a4106e8e-ec4f-4633-a636-09ae73135f69",type:r.ArgumentDeclaration,version:1,name:"Company Name to check",description:"The name of the company to check in the government registry",dataType:KC,required:!1,writesValues:[xT],index:0,parent:eB},tB={type:r.GenericReference,id:"2178a10c-1cc0-4dad-97c3-0941be6c9738",entityType:r.Project,entityId:Z},jT={type:r.FunctionDeclaration,id:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d",version:1,name:"Check Gov Company Registry availability",description:"Check whether the company name is already registered in the government company registry, or it is available for a new company to use.",inputs:[kT],calls:[XC,$C],returnStatements:[Cl],implements:null,index:null,collapsed:!1,private:!1,x:0,y:0,parent:tB},nB={type:r.GenericReference,id:"4d66c53c-f0f7-496a-9955-1e6c8533c5e0",entityType:r.Condition,entityId:"a8f4b0f2-5e5e-4e8f-9d7b-1b5b9b6e9a4b"},rB={type:r.GenericReference,id:"6fa0c8e0-d104-4b4d-a035-d4f6e0c49f09",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},iB={type:r.GenericReference,id:"146408d5-5336-4877-941a-777dd5871926",entityType:r.ArgumentDeclaration,entityId:"c6cf620c-1eee-4919-8578-1a0b6c088551"},aB={type:r.GenericReference,id:"34ae8f8c-548d-4654-984a-6f36affdaf49",entityType:r.FunctionCall,entityId:"d2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a"},qT={id:"69b1215d-9ebf-4274-b9cb-d4a5888f5122",version:1,type:r.InputMap,declaration:kT,name:null,description:null,readsValue:iB,defaultValue:null,index:0,parent:aB},sB={type:r.GenericReference,id:"07540a94-dda1-40b3-8452-f209bdc87b88",entityType:r.FunctionCall,entityId:"d2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a"},oB={type:r.GenericReference,id:"eaddf12a-a995-429e-90a0-13bf06efeb28",entityType:r.VariableDeclaration,entityId:"faaf3bf6-917d-40d7-aee6-5164f6646c4b"},lB={like:!1,id:"7fdaf943-3ffb-48e0-b766-b86cc24090cf",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:An,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:oB},cB={type:r.GenericReference,id:"030fb5c5-af4d-4c85-8cf0-e99edd50d2bd",entityType:r.OutputMap,entityId:"c1ec31f0-25ca-42ac-a4c4-c9ec2255f55b"},dB={type:r.GenericReference,id:"a8b618e9-c68c-48c1-8bd6-ef47c87d699e",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},uB={type:r.GenericReference,id:"is-company-name-valid-var-called-by-ref",entityType:r.FunctionCall,entityId:"d2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a"},JT={type:r.VariableDeclaration,id:"faaf3bf6-917d-40d7-aee6-5164f6646c4b",version:1,name:"Is name valid",description:"Whether the company name is valid",dataType:lB,readsValue:cB,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[uB],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:dB},pB={id:"c1ec31f0-25ca-42ac-a4c4-c9ec2255f55b",type:r.OutputMap,version:1,declaration:Ol,writesValues:[JT],index:0,parent:sB},yB={type:r.FunctionCall,id:"d2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a",version:1,declaration:jT,inputs:[qT],outputs:[pB],calledByError:[],calledByEntry:[],process:null,calledBySuccess:[nB],successCalls:[JT],errorCalls:[],error:null,x:0,y:0,parent:rB},hB={type:r.GenericReference,id:"9d0b87b4-bfed-4e02-9e84-6831c21feae2",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},fB={type:r.GenericReference,id:"74345f4f-e80d-48be-adff-d12fcea25bec",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},mB={type:r.GenericReference,id:"b39279ea-969a-4efb-a9ec-353bfd13db65",entityType:r.ArgumentDeclaration,entityId:"c6cf620c-1eee-4919-8578-1a0b6c088551"},TB={type:r.GenericReference,id:"549db613-f225-4c5b-9634-7d096717f0ff",entityType:r.Condition,entityId:"a8f4b0f2-5e5e-4e8f-9d7b-1b5b9b6e9a4b"},WT={id:"358e242c-7448-442e-ab8b-fd7fa119ea71",version:1,type:r.InputMap,declaration:er.fixedArguments[0],name:null,description:null,readsValue:mB,defaultValue:null,index:0,parent:TB},EB={type:r.Condition,id:"a8f4b0f2-5e5e-4e8f-9d7b-1b5b9b6e9a4b",version:1,declaration:er,inputs:[WT],calledByError:[],calledByEntry:[hB],calledBySuccess:[],successCalls:[yB],errorCalls:[],x:0,y:0,parent:fB},RB={type:r.GenericReference,id:"43ba1e25-f805-488f-8ae8-c58bb6215b2f",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},bB={type:r.GenericReference,id:"eb091bed-507f-4a1e-93b5-7cd2fccfe002",entityType:r.VariableDeclaration,entityId:"9c928995-0dd5-4f97-9962-56b343bc8a45"},gB={like:!1,id:"d64152ea-831f-4426-9506-a39bfa170513",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Yr,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:bB},vB={type:r.GenericReference,id:"7e79c29f-f7bd-441a-a77e-c627604dae94",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},IB={type:r.GenericReference,id:"8995ce5f-d5cf-4341-a8b1-5c046cc78b89",entityType:r.ArgumentDeclaration,entityId:"7ed0f7bb-2df0-44e2-b0b3-0709dcca8071"},DB={type:r.GenericReference,id:"new-company-bank-account-var-decl-1-called-by-ref",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},HT={type:r.VariableDeclaration,id:"9c928995-0dd5-4f97-9962-56b343bc8a45",version:1,name:"New bank account",description:"The new entity value representing the new bank account of the company",dataType:gB,readsValue:IB,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[DB],calledBySuccess:[],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:vB},PB={type:r.GenericReference,id:"9a4887bf-d50d-43e4-bdd5-a5262f65f04b",entityType:r.ArgumentDeclaration,entityId:"7ed0f7bb-2df0-44e2-b0b3-0709dcca8071"},AB={like:!1,id:"ae148c06-3143-49e9-9614-c3aca3f6fa7b",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Yr,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:PB},SB={id:"7ed0f7bb-2df0-44e2-b0b3-0709dcca8071",type:r.ArgumentDeclaration,version:1,name:"New bank account",description:"The new bank account of the company",dataType:AB,required:!0,index:1,writesValues:[HT],parent:RB},OB={type:r.GenericReference,id:"caec9cf8-3133-48d4-a390-114fa71b2933",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},CB={type:r.GenericReference,id:"cebcbad8-ca87-4c4b-be8a-312293d49892",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},BB={type:r.GenericReference,id:"7b8ccfe5-f9cd-4776-a19b-80c689bbe3df",entityType:r.ArgumentDeclaration,entityId:"c6cf620c-1eee-4919-8578-1a0b6c088551"},wB={like:!1,id:"2a6b4703-ac8d-4d25-8abd-48a115577fec",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:BB},_B={id:"c6cf620c-1eee-4919-8578-1a0b6c088551",type:r.ArgumentDeclaration,version:1,name:"New company name",description:null,dataType:wB,required:!0,index:0,writesValues:[WT,qT],parent:CB},MB={type:r.FunctionDeclaration,id:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84",version:1,name:"Company changed event",description:"The event that is triggered when a company is changed",returnStatements:[],collapsed:!1,inputs:[_B,SB],calls:[EB,HT],index:1,private:!1,implements:null,x:0,y:0,parent:OB},NB={type:r.GenericReference,id:"employee-manager-property-data-type-entity-ref-id",entityType:r.CustomEntity,entityId:"employee-entity-id"},VB={type:r.GenericReference,id:"employee-manager-property-data-type-parent-ref-id",entityType:r.Property,entityId:"employee-manager-property-id"},$B={like:!1,id:"employee-manager-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:NB,isList:!1,isNullable:!0,asType:!1,defaultValue:null,constant:!1,parent:VB},LB={type:r.GenericReference,id:"employee-manager-property-parent-ref-id",entityType:r.CustomEntity,entityId:"employee-entity-id"},GB={hidden:!1,required:!0,type:r.Property,id:"employee-manager-property-id",version:1,name:"Manager",description:"The manager of the employee",index:0,implements:null,private:!1,static:!1,dataType:$B,abstract:!1,parent:LB},FB={type:r.GenericReference,id:"employee-start-date-property-data-type-parent-ref-id",entityType:r.Property,entityId:"employee-start-date-property-id"},UB={like:!1,id:"employee-start-date-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:cn,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:FB},xB={type:r.GenericReference,id:"employee-start-date-property-parent-ref-id",entityType:r.CustomEntity,entityId:"employee-entity-id"},kB={hidden:!1,required:!0,type:r.Property,id:"employee-start-date-property-id",version:1,name:"Start date",description:"The date the employee started working in the company",index:0,private:!1,static:!1,implements:null,dataType:UB,abstract:!1,parent:xB},jB={type:r.GenericReference,id:"employee-department-property-ref-id",entityType:r.Property,entityId:"employee-department-property-id"},qB={like:!1,id:"employee-department-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Sn,isList:!1,isNullable:!1,asType:!1,options:["Human Resources","Finance","IT","Sales","Marketing","Customer Service","Logistics","Product"],defaultValue:null,constant:!1,parent:jB},JB={type:r.GenericReference,id:"employee-department-property-parent-ref-id",entityType:r.CustomEntity,entityId:"employee-entity-id"},WB={hidden:!1,required:!0,type:r.Property,id:"employee-department-property-id",version:1,name:"Department",description:"The department the employee works in, from a list of departments in the company",index:0,implements:null,static:!1,private:!1,dataType:qB,abstract:!1,parent:JB},HB={type:r.GenericReference,id:"employee-prototype-parent-ref-id",entityType:r.Project,entityId:Z},Ct={type:r.CustomEntity,id:"employee-entity-id",version:1,name:"Employee",description:"A entity that represents an employee in the company",properties:[WB,kB,GB],abstract:!1,static:!1,abstractMethods:[],methods:[],implements:[],extends:[pt],x:0,y:0,parent:HB},YB={type:r.GenericReference,id:"dec8fbfe-9124-41fd-9f1c-5b2f07cfd6ba",entityType:r.Property,entityId:"4f52d044-f3dd-4bdf-927e-637c3b92e8bd"},zB={like:!1,id:"bc0b8979-6c43-4d47-a712-6742b89e3c00",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:YB},ZB={type:r.GenericReference,id:"4f8c0a05-466e-4672-b4c4-6bd408c0be9a",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},XB={hidden:!1,required:!0,type:r.Property,id:"4f52d044-f3dd-4bdf-927e-637c3b92e8bd",version:1,name:"Company Name",private:!1,static:!1,description:"The name of the company",index:0,implements:null,dataType:zB,abstract:!1,parent:ZB},QB={type:r.GenericReference,id:"95173fe0-a6e6-443c-94f3-f7c5cf171fcf",entityType:r.Property,entityId:"80c86e1b-caca-4ba5-9b1f-38f72d10e4a3"},KB={like:!1,id:"ddbb6f5c-0cf4-41fb-83b3-b6c47c0e338d",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Yr,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:QB},ew={type:r.GenericReference,id:"6a9a0b72-a05d-4169-b3f3-5afb01e8d0df",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},Bl={hidden:!1,required:!0,type:r.Property,id:"80c86e1b-caca-4ba5-9b1f-38f72d10e4a3",version:1,name:"Bank account",description:"The bank account of the company",index:1,implements:null,static:!1,private:!1,dataType:KB,abstract:!1,parent:ew},tw={type:r.GenericReference,id:"62892cc6-d227-4088-90d3-ae7c15ed4af4",entityType:r.Property,entityId:"19a31727-1fba-40a5-be25-18e0f149d5cb"},nw={like:!1,id:"1f7629df-dc29-4c89-8369-c6d043e97a9e",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:tw},rw={type:r.GenericReference,id:"89384206-fd5a-4f0a-849c-f777473e5773",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},iw={hidden:!1,required:!0,type:r.Property,id:"19a31727-1fba-40a5-be25-18e0f149d5cb",version:1,name:"Company Owner",description:"The person that owns the company",index:2,static:!1,implements:null,dataType:nw,private:!0,abstract:!1,parent:rw},aw={type:r.GenericReference,id:"4d2ffb6c-5f38-436e-8339-fb9878ac2b5e",entityType:r.Property,entityId:"f8310850-a87e-405c-b182-4f1d5fa49240"},sw={like:!1,id:"ad44250b-40c2-48f7-a480-381fa938f562",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ct,isList:!0,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:aw},ow={type:r.GenericReference,id:"aa5d4eee-6fac-4e72-bf21-9c8750024541",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},lw={hidden:!1,required:!0,type:r.Property,id:"f8310850-a87e-405c-b182-4f1d5fa49240",version:1,name:"Employees",description:null,index:3,dataType:sw,implements:null,private:!0,static:!1,abstract:!1,parent:ow},cw={type:r.GenericReference,id:"e3c03b6b-2ea0-4d99-865d-5e6a348672d0",entityType:r.Project,entityId:Z},gt={type:r.CustomEntity,id:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d",version:1,name:"Company",description:null,properties:[XB,Bl,iw,lw],static:!1,abstract:!1,abstractMethods:[],methods:[ZO,MB],extends:[],implements:[Le],x:0,y:0,parent:cw},dw={type:r.GenericReference,id:"ffcad334-138d-4b67-8fb3-5f0e6f5fefbd",entityType:r.Project,entityId:Z},wl={type:r.FunctionDeclaration,id:"0f89260c-8c58-4639-8629-d9ea5ab40ba7",version:1,name:"Show popup",description:null,inputs:[],calls:[],returnStatements:[],implements:null,collapsed:!1,private:!1,index:null,x:0,y:0,parent:dw};r.GenericReference,r.DataType;const uw={id:"cron-job-entity-expression-property-ref-id",type:r.GenericReference,entityId:"cron-job-entity-expression-property-id",entityType:r.Property},pw={like:!1,id:"cron-job-entity-expression-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:null,parent:uw},yw={id:"cron-job-entity-ref-id",type:r.GenericReference,entityId:"cron-job-entity-id",entityType:r.CustomEntity},hw={hidden:!1,required:!0,id:"cron-job-entity-expression-property-id",type:r.Property,version:1,name:"Cron expression",description:"The cron expression that defines when the cron job should be triggered",dataType:pw,implements:null,static:!0,private:!1,abstract:!1,index:0,parent:yw},fw={id:"cron-job-entity-trigger-show-popup-func-call-called-by-ref-one-id",type:r.GenericReference,entityId:"show-popup-func-decl-id",entityType:r.FunctionDeclaration},mw={id:"cron-job-entity-trigger-show-popup-func-call-parent-ref-id",type:r.GenericReference,entityId:"cron-job-entity-trigger-func-decl-id",entityType:r.FunctionDeclaration},Tw={id:"cron-job-entity-trigger-show-popup-func-call-id",version:1,type:r.FunctionCall,declaration:wl,inputs:[],outputs:[],process:null,successCalls:[],calledByError:[],calledByEntry:[fw],calledBySuccess:[],errorCalls:[],error:null,x:0,y:0,parent:mw},Ew={id:"cron-job-entity-trigger-func-decl-parent-ref-id",type:r.GenericReference,entityId:"cron-job-entity-id",entityType:r.CustomEntity},Rw={id:"cron-job-entity-trigger-func-decl-id",version:1,type:r.FunctionDeclaration,name:"Scheduled trigger",description:"The function that is called when the cron job is triggered",inputs:[],private:!1,implements:nl,calls:[Tw],collapsed:!1,returnStatements:[],index:0,x:0,y:0,parent:Ew},bw={id:"cron-job-entity-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},gw={id:"cron-job-entity-id",version:1,type:r.CustomEntity,name:"Run at 12pm on Christmas day",description:"A cron job that runs at 12pm on Christmas day",properties:[hw],static:!0,abstract:!1,abstractMethods:[],extends:[rl],implements:[],methods:[Rw],x:0,y:0,parent:bw},vw={type:r.GenericReference,id:"52dbd85c-48b1-462a-8205-2437d6fb1cb4",entityType:r.Project,entityId:Z},Iw={type:r.CustomEntity,id:"6f0908c2-09c6-4a8b-8f43-d2467fe6fb39",version:1,name:"Get bank all bank accounts",description:null,properties:[],static:!0,abstract:!1,abstractMethods:[],methods:[],extends:[],implements:[ka],x:0,y:0,parent:vw},YT="f558fbf8-67de-4545-9804-6ae621e0b2d4",Dw={id:"getCompanyByIdEndpointPathParamsVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointPathParamsVariableDataType"},Pw={id:"getCompanyByIdEndpointPathParamsArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"getCompanyByIdEndpointPathParamsArgumentDeclaration"},Aw={like:!1,id:"getCompanyByIdEndpointPathParamsVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:k,asType:!1,defaultValue:{id:"getCompanyByIdEndpointPathParamsVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:Dw,autogeneration:null,valueAsType:null},parent:Pw},Sw={id:"getCompanyByIdEndpointReachedEntityEventRef",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"getCompanyByIdEndpointReachedEntityEvent"},Ow={id:"getCompanyByIdEndpointRequestHeadersVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointRequestHeadersVariableDataType"},Cw={id:"getCompanyByIdEndpointRequestHeadersArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"getCompanyByIdEndpointRequestHeadersArgumentDeclaration"},Bw={like:!1,id:"getCompanyByIdEndpointRequestHeadersVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:et,asType:!1,defaultValue:{id:"getCompanyByIdEndpointRequestHeadersVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:Ow,autogeneration:null,valueAsType:null},parent:Cw},ww={id:"getCompanyByIdEndpointRequestHeadersArgumentDeclaration",version:1,description:"A set of any properties, with names and value that transmit metadata about the request.",type:r.ArgumentDeclaration,writesValues:[],name:"Request headers",dataType:Bw,required:!0,index:0,parent:Sw},_w={id:"getCompanyByIdEndpointReachedEntityEventRefTwo",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"getCompanyByIdEndpointReachedEntityEvent"},Mw={id:"getCompanyByIdEndpointPathParamsArgumentDeclaration",type:r.ArgumentDeclaration,description:"A standarized text, without spaces that is added at the end of the domain and routes the request to a specific resource within the target server. For example: /api/users/123, /api/users/123/:name, /api/users/123/:name/:age.",version:1,name:"Path parameters",writesValues:[],dataType:Aw,required:!0,index:1,parent:_w},Nw={id:"getCompanyByIdEndpointReachedEntityEventRefThree",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"getCompanyByIdEndpointReachedEntityEvent"},Vw={id:"getCompanyByIdEndpointRequestQueryParamsVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointRequestQueryParamsVariableDataType"},$w={id:"getCompanyByIdEndpointRequestQueryParamsArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"getCompanyByIdEndpointRequestQueryParamsArgumentDeclaration"},Lw={like:!1,id:"getCompanyByIdEndpointRequestQueryParamsVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,asType:!1,entity:k,defaultValue:{id:"getCompanyByIdEndpointRequestQueryParamsVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:Vw,autogeneration:null,valueAsType:null},parent:$w},Gw={id:"getCompanyByIdEndpointRequestQueryParamsArgumentDeclaration",version:1,description:"A text with standarized format, without spaces that is added at the end of the URL path, after the ? character. It contains data that might be used to process the request. For example: /api/users?name=John&age=30",type:r.ArgumentDeclaration,writesValues:[],name:"Request query params",dataType:Lw,required:!0,index:2,parent:Nw},Fw={id:"getCompanyByIdEndpointReachedEntityEventRefFour",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"getCompanyByIdEndpointReachedEntityEvent"},Uw={id:"getCompanyByIdEndpointRequestBodyArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"getCompanyByIdEndpointRequestBodyArgumentDeclaration"},xw={like:!1,id:"getCompanyByIdEndpointRequestBodyVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,asType:!1,constant:!1,entity:et,defaultValue:null,parent:Uw},kw={id:"getCompanyByIdEndpointRequestBodyArgumentDeclaration",version:1,description:"The main data payload of the request.",type:r.ArgumentDeclaration,writesValues:[],name:"Request body",dataType:xw,index:3,required:!0,parent:Fw},jw={id:"getCompanyByIdEndpointResponseCodeReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"getCompanyByIdEndpointResponseCodeReturnDeclaration"},qw={like:!1,id:"9ba575b0-6f8e-436d-a3de-3b843622aa17",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:jw},Jw={id:"getCompanyByIdEndpointReturnStatementRef",type:r.GenericReference,entityType:r.ReturnStatement,entityId:"getCompanyByIdEndpointReturnStatement"},Ww={isError:!1,id:"getCompanyByIdEndpointResponseCodeReturnDeclaration",version:1,description:"A standarized number that represents the status of the response. 200 for OK, 404 for not found, 500 for server error, etc.",type:r.ReturnDeclaration,name:"Response code",dataType:qw,readsValue:null,required:!0,index:0,parent:Jw},Hw={id:"getCompanyByIdEndpointResponseHeadersDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointResponseHeadersDataType"},Yw={id:"getCompanyByIdEndpointResponseHeadersReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"getCompanyByIdEndpointResponseHeadersReturnDeclaration"},zw={like:!1,id:"getCompanyByIdEndpointResponseHeadersDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:et,asType:!1,defaultValue:{id:"getCompanyByIdEndpointResponseHeadersDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:Hw,autogeneration:null,valueAsType:null},parent:Yw},Zw={id:"getCompanyByIdEndpointReturnStatementRefTwo",type:r.GenericReference,entityType:r.ReturnStatement,entityId:"getCompanyByIdEndpointReturnStatement"},Xw={isError:!1,id:"getCompanyByIdEndpointResponseHeadersReturnDeclaration",version:1,description:"A set of any properties, with names and value that transmit metadata about the response.",type:r.ReturnDeclaration,name:"Response headers",dataType:zw,readsValue:null,required:!0,index:1,parent:Zw},Qw={id:"getCompanyByIdEndpointResponseBodyReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"getCompanyByIdEndpointResponseBodyReturnDeclaration"},Kw={like:!1,id:"getCompanyByIdEndpointResponseBodyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,asType:!1,constant:!1,entity:et,defaultValue:null,parent:Qw},e_={id:"getCompanyByIdEndpointReturnStatementRefThree",type:r.GenericReference,entityType:r.ReturnStatement,entityId:"getCompanyByIdEndpointReturnStatement"},t_={isError:!1,id:"getCompanyByIdEndpointResponseBodyReturnDeclaration",version:1,description:"The main data payload of the response.",type:r.ReturnDeclaration,name:"Response body",dataType:Kw,readsValue:null,required:!0,index:2,parent:e_},n_={id:"getCompanyByIdEndpointReturnStatementCallerRef",type:r.GenericReference,entityId:"getCompanyByIdEndpointReachedEntityEvent",entityType:r.FunctionDeclaration},r_={id:"getCompanyByIdEndpointReachedEntityEventRefFive",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"getCompanyByIdEndpointReachedEntityEvent"},i_={id:"getCompanyByIdEndpointReturnStatement",type:r.ReturnStatement,version:1,outputs:[Ww,Xw,t_],calledByError:[],calledByEntry:[n_],calledBySuccess:[],throws:null,x:0,y:0,parent:r_},a_={id:"endpointBuiltInBaseEntityRefFour",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:YT},s_={id:"getCompanyByIdEndpointReachedEntityEvent",name:"Endpoint reached",version:1,type:r.FunctionDeclaration,inputs:[ww,Mw,Gw,kw],returnStatements:[i_],description:"Fired when the endpoint is reached.",calls:[],collapsed:!1,implements:Qo,index:0,private:!1,x:0,y:0,parent:a_},o_={id:"getCompanyByIdEndpointPathPropertyDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointPathPropertyDataType"},l_={id:"getCompanyByIdEndpointPathPropertyRef",type:r.GenericReference,entityType:r.Property,entityId:"getCompanyByIdEndpointPathProperty"},c_={like:!1,id:"getCompanyByIdEndpointPathPropertyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"getCompanyByIdEndpointPathPropertyDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.String,value:"/company/{id}",parent:o_,valueAsType:null,autogeneration:null},parent:l_},d_={id:"getCompanyByIdEndpointBaseEntityRefTwo",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},u_={hidden:!1,required:!0,id:"getCompanyByIdEndpointPathProperty",name:"Path",version:1,type:r.Property,private:!1,abstract:!1,static:!0,implements:Zo,dataType:c_,index:1,description:"Path to the endpoint, for example /api/users, or /api/users/{id}, or /api/users/{id}/:name. The path can contain parameters, which are defined by curly braces, and will be passed to the endpoint event as variables with the same name.",parent:d_},p_={id:"getCompanyByIdEndpointMethodPropertyDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointMethodPropertyDataType"},y_={id:"getCompanyByIdEndpointMethodPropertyRef",type:r.GenericReference,entityType:r.Property,entityId:"getCompanyByIdEndpointMethodProperty"},h_={like:!1,id:"getCompanyByIdEndpointMethodPropertyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:Sn,isList:!0,isNullable:!1,constant:!0,asType:!1,defaultValue:{id:"getCompanyByIdEndpointMethodPropertyDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,value:"GET",name:A.Enum,parent:p_,valueAsType:null,autogeneration:null},options:["GET","POST","PUT","DELETE","PATCH","OPTIONS","HEAD","TRACE","CONNECT","CUSTOM"],parent:y_},f_={id:"getCompanyByIdEndpointBaseEntityRefThree",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},m_={hidden:!1,required:!0,id:"getCompanyByIdEndpointMethodProperty",name:"Method",version:1,type:r.Property,private:!1,abstract:!1,static:!0,implements:Xo,index:0,dataType:h_,description:null,parent:f_},T_={type:r.GenericReference,id:"6a905153-8aa8-4424-bd7b-6415731a2725",entityType:r.Project,entityId:Z},E_={type:r.CustomEntity,id:YT,version:1,name:"Get given company data by id",description:null,properties:[u_,m_],methods:[s_],static:!0,abstract:!1,abstractMethods:[],extends:[],implements:[ka],x:0,y:0,parent:T_},R_={id:"product-prototype-database-property-ref-id",type:r.GenericReference,entityId:"product-prototype-database-property-id",entityType:r.Property},b_={id:"product-prototype-database-property-data-type-default-value-parent-ref-id",type:r.GenericReference,entityId:"product-prototype-database-property-data-type-default-value-id",entityType:r.DataType},g_={like:!1,id:"product-prototype-database-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:On,asType:!1,defaultValue:{id:"product-prototype-database-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,value:null,name:A.EntityTemplate,valueAsType:Pl,autogeneration:null,parent:b_},parent:R_},v_={id:"product-prototype-database-property-parent-ref-id",type:r.GenericReference,entityId:"de67fc84-3719-46fd-9ab4-3fca3a3cc50d",entityType:r.CustomEntity},I_={hidden:!1,required:!0,id:"product-prototype-database-property-id",name:"Database",version:1,type:r.Property,private:!1,abstract:!1,implements:Pi,static:!0,index:0,dataType:g_,description:"The database that the entity belongs to.",parent:v_},D_={type:r.GenericReference,id:"13a4045e-dcb0-4159-8d33-10a646078b5a",entityType:r.Property,entityId:"d519c26a-15b8-40d8-ad09-13fa9342e9ba"},P_={like:!1,id:"7449779e-1d4e-409c-81c6-4b611336ed18",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:D_},A_={type:r.GenericReference,id:"0969562f-d836-406f-8b48-dd9d417fbe72",entityType:r.CustomEntity,entityId:"a2d0ec83-72ce-4f54-b059-a39e018fa86c"},S_={hidden:!1,required:!0,type:r.Property,id:"d519c26a-15b8-40d8-ad09-13fa9342e9ba",version:1,name:"Name",description:"The name of the product",index:0,implements:null,static:!1,private:!1,dataType:P_,abstract:!1,parent:A_},O_={type:r.GenericReference,id:"833a5425-7bd0-41dd-9e97-e018acce9592",entityType:r.Project,entityId:Z},C_={type:r.CustomEntity,id:"a2d0ec83-72ce-4f54-b059-a39e018fa86c",version:1,name:"Product",description:"A product that can be sold",implements:[Le],extends:[],abstract:!1,static:!1,abstractMethods:[],properties:[I_,S_],methods:[],x:0,y:0,parent:O_},Wi="project-loaded-event-id",Qt="get-bitcoin-price-http-call-operation-id",zT="get-bitcoin-price-http-call-response-body-id",vs="validate-bitcoin-price-response-operation-ids",B_={type:r.GenericReference,id:"validate-bitcoin-data-to-validate-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:zT},w_={type:r.GenericReference,id:"validate-bitcoin-data-to-validate-input-map-parent-ref-id",entityType:r.Operation,entityId:vs},ZT={id:"validate-bitcoin-data-to-validate-input-map-id",type:r.InputMap,version:1,declaration:Qn.fixedArguments[1],name:null,description:null,readsValue:B_,defaultValue:null,index:0,parent:w_},__={type:r.GenericReference,id:"validate-bitcoin-type-to-match-input-map-default-value-parent-ref-id",entityType:r.InputMap,entityId:"validate-bitcoin-type-to-match-input-map-id"},M_={type:r.GenericReference,id:"validate-bitcoin-type-to-match-input-map-parent-ref-id",entityType:r.Operation,entityId:vs},N_={id:"validate-bitcoin-type-to-match-input-map-id",type:r.InputMap,version:1,declaration:Qn.fixedArguments[0],name:null,description:null,readsValue:null,defaultValue:{id:"validate-bitcoin-type-to-match-input-map-default-value-id",type:r.PrimitiveValue,version:1,name:A.EntityTemplate,valueAsType:NT,value:null,parent:__,autogeneration:null},index:0,parent:M_},V_={type:r.GenericReference,id:"validate-bitcoin-validated-entity-output-map-parent-ref-id",entityType:r.Operation,entityId:vs},$_={id:"validate-bitcoin-validated-entity-output-map-id",type:r.OutputMap,version:1,declaration:Qn.fixedReturns[0],writesValues:[],index:0,parent:V_},L_={type:r.GenericReference,id:"validate-bitcoin-price-response-operation-parent-ref-id",entityType:r.GlobalEvent,entityId:Wi},G_={type:r.GenericReference,id:"validate-bitcoin-price-response-operation-called-by-ref-id",entityType:r.Operation,entityId:Qt},F_={type:r.Operation,id:vs,version:1,declaration:Qn,inputs:[N_,ZT],outputs:[$_],process:null,successCalls:[],errorCalls:[],error:null,x:0,y:0,calledByError:[],calledByEntry:[],calledBySuccess:[G_],parent:L_},U_={type:r.GenericReference,id:"96edb661-3f36-406c-8921-f1679dd796a3",entityType:r.FunctionCall,entityId:Qt},x_={id:"c93e1393-9b5e-4de2-b8da-7eae647d715a",version:1,type:r.InputMap,declaration:Va,name:null,description:null,readsValue:null,defaultValue:null,index:0,parent:U_},k_={type:r.GenericReference,id:"40312b28-71b8-4b01-a654-58b87191939d",entityType:r.FunctionCall,entityId:Qt},j_={type:r.GenericReference,id:"6ea96c7d-02a7-4971-82ad-2f32a0fec8b4",entityType:r.InputMap,entityId:"9f21cbac-5a83-4983-8923-9224ffd3ba9f"},q_={id:"9f21cbac-5a83-4983-8923-9224ffd3ba9f",version:1,type:r.InputMap,declaration:$a,name:null,description:null,readsValue:null,defaultValue:{id:"get-bitcoin-price-http-request-url-argument-default-value-id",type:r.PrimitiveValue,version:1,value:"https://api.coindesk.com/v1/bpi/currentprice.json",name:A.String,parent:j_,valueAsType:null,autogeneration:null},index:1,parent:k_},J_={type:r.GenericReference,id:"2610bf4a-c8a2-4746-b6cc-eb15f7fa8e9c",entityType:r.FunctionCall,entityId:Qt},W_={id:"ffb3cd9d-c955-4104-bc7b-299120fe4ede",version:1,type:r.InputMap,declaration:La,name:null,description:null,readsValue:null,defaultValue:null,index:2,parent:J_},H_={type:r.GenericReference,id:"bfd29a6a-671a-448c-9f2f-f8c7e4ad8349",entityType:r.FunctionCall,entityId:Qt},Y_={id:"412bf1f3-1a8e-4665-a95f-82117540e34e",version:1,type:r.InputMap,declaration:Ga,name:null,description:null,readsValue:null,defaultValue:null,index:3,parent:H_},z_={type:r.GenericReference,id:"616a15f3-c224-4b11-b95c-63314edef409",entityType:r.FunctionCall,entityId:Qt},Z_={id:"4dd4651c-02e4-45f1-b50f-824f3bcb1648",version:1,type:r.OutputMap,declaration:Fa,writesValues:[],index:1,parent:z_},X_={type:r.GenericReference,id:"28793b68-4d7e-4826-aee1-f201a3499faf",entityType:r.FunctionCall,entityId:Qt},Q_={id:"94fe9d35-4dd4-4729-a50c-5283ccd7e661",version:1,type:r.OutputMap,declaration:Ho,writesValues:[],index:0,parent:X_},K_={type:r.GenericReference,id:"f13e04b2-49b4-4c69-85b8-cbbafafa3524",entityType:r.FunctionCall,entityId:Qt},eM={id:zT,type:r.OutputMap,version:1,declaration:vi,writesValues:[ZT],index:2,parent:K_},tM={type:r.GenericReference,id:"6148d6d0-caaa-45fc-b601-ff2493dfc60f",entityType:r.FunctionDeclaration,entityId:Qt},nM={type:r.GenericReference,id:"b115f084-807b-44b3-ae01-b69cc342f761",entityType:r.GlobalEvent,entityId:Wi},rM={type:r.Operation,id:Qt,version:1,declaration:Ii,inputs:[x_,q_,W_,Y_],outputs:[Q_,Z_,eM],process:null,parent:nM,calledByError:[],calledByEntry:[tM],calledBySuccess:[],successCalls:[F_],errorCalls:[],error:null,x:0,y:0},iM={type:r.GenericReference,id:"24e76019-3f94-475b-91ce-297f76bbc224",entityType:r.GlobalEvent,entityId:Wi},aM={type:r.GenericReference,id:"0eac8e29-cdf2-42f8-8ea7-ad76d4d79abe",entityType:r.GlobalEvent,entityId:Wi},sM={process:null,type:r.FunctionCall,id:"2d2e7593-bfbf-457c-a607-5fce18eef457",version:1,declaration:wl,inputs:[],outputs:[],calledByError:[],calledByEntry:[iM],calledBySuccess:[],parent:aM,successCalls:[],errorCalls:[],error:null,x:0,y:0},oM={id:"793b5999-a9da-47fb-9665-0c17ebc6d5c9",type:r.GenericReference,entityType:r.Project,entityId:"2e7eb5382-3d99-44fd-972a-b8b1e819f6be"},lM={type:r.GlobalEvent,id:Wi,version:1,name:on.PROJECT_PUBLICATION_COMPLETED,returnStatements:[],collapsed:!1,implements:Ha,parent:oM,inputs:[],calls:[sM,rM],x:0,y:0},$t="abort-execution-func-declaration-id",Hi="abort-execution-func-exec-var-declaration-id",Is="abort-execution-func-small-wait-op-id",_l="abort-execution-func-long-wait-op-id",XT="abort-execution-func-long-wait-process-output-id",QT="abort-execution-func-exec-var-instance-write-id",KT="abort-execution-func-long-wait-return-stmt-id",eE="abort-execution-func-small-wait-return-stmt-id",cM="abort-execution-func-exec-var-instance-abort-call-id",Ml="abort-execution-func-exec-var-instance-abort-internal-call-id",tE="abort-execution-func-exec-second-wait-op-id",dM={type:r.GenericReference,id:"short-wait-return-statement-returned-hello-string-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:"short-wait-return-statement-returned-hello-string-id"},uM={type:r.GenericReference,id:"short-wait-return-statement-returned-hello-string-data-type-default-value-parent-ref-id",entityType:r.DataType,entityId:"short-wait-return-statement-returned-hello-string-data-type-id"},pM={like:!1,id:"short-wait-return-statement-returned-hello-string-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:{id:"short-wait-return-statement-returned-hello-string-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"Hello 2",autogeneration:null,valueAsType:null,parent:uM},constant:!1,parent:dM},yM={type:r.GenericReference,id:"short-wait-return-statement-returned-hello-string-parent-ref-id",entityType:r.ReturnStatement,entityId:eE},hM={isError:!1,id:"short-wait-return-statement-returned-hello-string-id",type:r.ReturnDeclaration,version:1,name:"Return 1",description:"A random string that is returned by the function",dataType:pM,readsValue:null,required:!0,index:0,parent:yM},fM={type:r.GenericReference,id:"short-wait-return-statement-called-by-ref-id",entityType:r.Operation,entityId:Is},mM={type:r.GenericReference,id:"short-wait-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:$t},nE={type:r.ReturnStatement,id:eE,version:1,outputs:[hM],calledByError:[],calledByEntry:[],calledBySuccess:[fM],throws:null,x:0,y:0,parent:mM},TM={type:r.GenericReference,id:"second-wait-argument-default-value-parent-ref-id",entityType:r.InputMap,entityId:"second-wait-argument-map-id"},EM={type:r.GenericReference,id:"second-wait-argument-map-parent-ref-id",entityType:r.Operation,entityId:tE},RM={id:"second-wait-argument-map-id",type:r.InputMap,version:1,declaration:Zn,name:null,description:null,readsValue:null,defaultValue:{id:"second-wait-argument-default-value-id",type:r.PrimitiveValue,version:1,value:2e3,valueAsType:null,autogeneration:null,name:A.Number,parent:TM},index:0,parent:EM},bM={type:r.GenericReference,id:"small-wait-parent-ref-id",entityType:r.FunctionDeclaration,entityId:$t},gM={type:r.GenericReference,id:"small-wait-called-by-ref-one-id",entityType:r.InternalCall,entityId:Ml},vM={id:tE,type:r.Operation,version:1,declaration:dt,inputs:[RM],outputs:[],process:null,successCalls:[nE],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[],calledBySuccess:[gM],error:null,parent:bM},IM={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-abort-internal-call-called-by-ref-one-id",entityType:r.VariableInstance,entityId:QT},DM={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-abort-internal-call-called-by-ref-two-id",entityType:r.Operation,entityId:Is},PM={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-main-project-ref-id",entityType:r.FunctionDeclaration,entityId:$t},AM={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-declaration-ref-id",entityType:r.VariableDeclaration,entityId:Hi},SM={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-internal-call-ref-one-id",entityType:r.InternalCall,entityId:Ml},OM={id:cM,type:r.VariableInstance,version:1,declaration:AM,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],x:0,y:0,readsValue:null,writesValues:[],internalCalls:[SM],parent:PM},rE={id:Ml,type:r.InternalCall,version:1,inputs:[],outputs:[],declaration:il,process:null,calledByError:[],calledByEntry:[],calledBySuccess:[IM,DM],successCalls:[vM],errorCalls:[],error:null,index:0,parent:OM},CM={type:r.GenericReference,id:"abort-exec-func-var-write-instance-main-project-ref-id",entityType:r.FunctionDeclaration,entityId:$t},BM={type:r.GenericReference,id:"abort-exec-func-var-write-instance-called-by-ref-one-id",entityType:r.VariableDeclaration,entityId:Hi},wM={type:r.GenericReference,id:"abort-exec-func-var-write-instance-called-by-ref-two-id",entityType:r.FunctionDeclaration,entityId:$t},_M={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-declaration-ref-id",entityType:r.VariableDeclaration,entityId:Hi},MM={type:r.GenericReference,id:"abort-exec-func-var-write-instance-reads-value-ref-id",entityType:r.OutputMap,entityId:XT},Nl={id:QT,type:r.VariableInstance,version:1,declaration:_M,inputs:[],outputs:[],calledByError:[],calledByEntry:[wM],calledBySuccess:[BM],successCalls:[rE],errorCalls:[],x:0,y:0,readsValue:MM,writesValues:[],internalCalls:[],parent:CM},NM={type:r.GenericReference,id:"abort-exec-func-var-decl-datatype-parent-ref-id",entityType:r.VariableDeclaration,entityId:Hi};r.GenericReference,r.DataType;const VM={like:!1,id:"abort-exec-func-var-decl-datatype-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:al,version:1,asType:!1,isList:!1,isNullable:!1,constant:!1,parent:NM,defaultValue:null},$M={type:r.GenericReference,id:"abort-exec-func-var-decl-main-project-ref-id",entityType:r.FunctionDeclaration,entityId:$t},LM={type:r.GenericReference,id:"abort-exec-func-var-decl-called-by-ref-one-id",entityType:r.FunctionDeclaration,entityId:$t},GM={id:Hi,type:r.VariableDeclaration,version:1,name:"Execution in progress",description:"A variable that holds an ongoing execution to abort it if needed",dataType:VM,inputs:[],outputs:[],calledByError:[],calledByEntry:[LM],calledBySuccess:[],successCalls:[Nl],errorCalls:[],x:0,y:0,readsValue:null,writesValues:[],internalCalls:[],parent:$M},FM={type:r.GenericReference,id:"long-wait-return-statement-returned-hello-string-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:"long-wait-return-statement-returned-hello-string-id"},UM={type:r.GenericReference,id:"long-wait-return-statement-returned-hello-string-data-type-default-value-parent-ref-id",entityType:r.DataType,entityId:"long-wait-return-statement-returned-hello-string-data-type-id"},xM={like:!1,id:"long-wait-return-statement-returned-hello-string-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:{id:"long-wait-return-statement-returned-hello-string-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"Hello 1",autogeneration:null,valueAsType:null,parent:UM},constant:!1,parent:FM},kM={type:r.GenericReference,id:"long-wait-return-statement-returned-hello-string-parent-ref-id",entityType:r.ReturnStatement,entityId:KT},jM={isError:!1,id:"long-wait-return-statement-returned-hello-string-id",type:r.ReturnDeclaration,version:1,name:"Return 2",description:"A random string that is returned by the function",dataType:xM,readsValue:null,required:!0,index:0,parent:kM},qM={type:r.GenericReference,id:"long-wait-return-statement-called-by-ref-id",entityType:r.Operation,entityId:_l},JM={type:r.GenericReference,id:"long-wait-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:$t},iE={type:r.ReturnStatement,id:KT,version:1,outputs:[jM],calledByError:[],calledByEntry:[],calledBySuccess:[qM],throws:null,x:0,y:0,parent:JM},WM={type:r.GenericReference,id:"long-argument-default-value-parent-ref-id",entityType:r.InputMap,entityId:"long-argument-map-id"},aE={type:r.GenericReference,id:"long-argument-map-parent-ref-id",entityType:r.Operation,entityId:_l},HM={id:"long-argument-map-id",type:r.InputMap,version:1,declaration:Zn,name:null,description:null,readsValue:null,defaultValue:{id:"long-argument-default-value-id",type:r.PrimitiveValue,version:1,value:1500,valueAsType:null,autogeneration:null,name:A.Number,parent:WM},index:0,parent:aE},YM={type:r.GenericReference,id:"long-parent-ref-id",entityType:r.FunctionDeclaration,entityId:$t},zM={type:r.GenericReference,id:"long-called-by-ref-one-id",entityType:r.FunctionDeclaration,entityId:$t},ZM={id:XT,type:r.OutputMap,version:1,declaration:ol,writesValues:[Nl],index:0,parent:aE},XM={id:_l,type:r.Operation,version:1,declaration:dt,inputs:[HM],outputs:[],process:ZM,successCalls:[iE],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[zM],calledBySuccess:[],error:null,parent:YM},QM={type:r.GenericReference,id:"small-wait-argument-default-value-parent-ref-id",entityType:r.InputMap,entityId:"small-wait-argument-map-id"},KM={type:r.GenericReference,id:"small-wait-argument-map-parent-ref-id",entityType:r.Operation,entityId:Is},eN={id:"small-wait-argument-map-id",type:r.InputMap,version:1,declaration:Zn,name:null,description:null,readsValue:null,defaultValue:{id:"small-wait-argument-default-value-id",type:r.PrimitiveValue,version:1,value:500,valueAsType:null,autogeneration:null,name:A.Number,parent:QM},index:0,parent:KM},tN={type:r.GenericReference,id:"small-wait-parent-ref-id",entityType:r.FunctionDeclaration,entityId:$t},nN={type:r.GenericReference,id:"small-wait-called-by-ref-one-id",entityType:r.FunctionDeclaration,entityId:$t},rN={id:Is,type:r.Operation,version:1,declaration:dt,inputs:[eN],outputs:[],process:null,successCalls:[rE],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[nN],calledBySuccess:[],error:null,parent:tN},iN={type:r.GenericReference,id:"abort-execution-func-decl-parent-ref-id",entityType:r.Project,entityId:Z},sE={id:"abort-execution-func-decl-id",type:r.FunctionDeclaration,version:1,name:"Test aborting execution",description:"Executes a wait and then aborts the execution of that wait",inputs:[],returnStatements:[iE,nE],calls:[rN,GM,Nl,XM],implements:null,private:!1,collapsed:!1,index:null,x:0,y:0,parent:iN},aN={type:r.GenericReference,id:"call-execution-abort-func-parent-ref-id",entityType:r.Project,entityId:Z},sN={id:"call-execution-abort-func-id",type:r.FunctionCall,version:1,declaration:sE,inputs:[],process:null,outputs:[],successCalls:[],errorCalls:[],error:null,calledByError:[],calledByEntry:[],calledBySuccess:[],x:0,y:0,parent:aN},Vl="manual-hello-world-loop-func-decl-id",oE="manual-hello-world-loop-func-return-statement-id",Kt="manual-hello-world-loop-id",Yi="manual-hello-world-loop-body-id",$l="manual-hello-world-loop-break-statement-id",zi="manual-hello-world-loop-current-iteration-number-output-map-id",Ll="manual-hello-world-loop-previous-iterations-results-output-map-id",Gl="assembled-hello-world-text-output-id",lE="assembled-hello-world-list-output-id",Zi="iteration-number-is-equal-or-greater-than-10-condition-id",Ds="join-hello-world-and-number-operation-id",Ps="append-string-to-list-operation-id",cE="hello-world-loop-output-map-id",oN={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-output-declaration-parent-ref",entityType:r.ReturnStatement,entityId:oE},lN={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-output-declaration-data-type-parent-ref",entityType:r.ReturnDeclaration,entityId:"manual-hello-world-loop-function-declaration-output-declaration"},cN={like:!1,id:"manual-hello-world-loop-function-declaration-output-declaration-data-type",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!0,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:lN},dN={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-output-declaration-reads-value-ref",entityType:r.OutputMap,entityId:cE},dE={isError:!1,id:"manual-hello-world-loop-function-declaration-output-declaration",version:1,type:r.ReturnDeclaration,name:"Results",description:null,dataType:cN,readsValue:dN,required:!0,index:0,parent:oN},uN={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-return-statement-called-by-ref",entityType:r.Loop,entityId:Kt},pN={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-parent-ref",entityType:r.FunctionDeclaration,entityId:Vl},uE={type:r.ReturnStatement,id:oE,version:1,outputs:[dE],calledByError:[],calledByEntry:[],calledBySuccess:[uN],parent:pN,throws:null,x:0,y:0},yN={type:r.GenericReference,id:"hello-world-loop-break-statement-ref-id",entityType:r.BreakStatement,entityId:$l},hN={type:r.GenericReference,id:"hello-world-loop-break-statement-reads-value-ref-id",entityType:r.OutputMap,entityId:Gl},pE={isError:!1,id:"hello-world-loop-break-statement-output-id",version:1,type:r.ReturnDeclaration,name:"Iteration result",description:null,dataType:null,readsValue:hN,required:!0,index:0,parent:yN},fN={type:r.GenericReference,id:"hello-world-loop-break-statement-counter-reads-value-ref-id",entityType:r.ArgumentDeclaration,entityId:zi},mN={type:r.GenericReference,id:"hello-world-loop-break-statement-counter-ref-id",entityType:r.BreakStatement,entityId:$l},yE={isError:!1,id:"hello-world-loop-break-statement-counter-output-id",version:1,type:r.ReturnDeclaration,name:"Iteration counter",description:null,dataType:null,readsValue:fN,required:!0,index:1,parent:mN},TN={type:r.GenericReference,id:"hello-world-loop-break-statement-called-by-ref-id",entityType:r.Condition,entityId:Zi},EN={type:r.GenericReference,id:"hello-world-loop-break-statement-parent-ref-id",entityType:r.Loop,entityId:Kt},hE={type:r.BreakStatement,id:$l,version:1,outputs:[pE,yE],calledByError:[],calledByEntry:[],calledBySuccess:[TN],parent:EN,throws:null,x:0,y:0},RN={type:r.GenericReference,id:"hello-world-loop-continue-statement-ref-id",entityType:r.ContinueStatement,entityId:"hello-world-loop-continue-statement"},bN={type:r.GenericReference,id:"hello-world-loop-continue-statement-output-data-type-ref-id",entityType:r.ReturnDeclaration,entityId:"hello-world-loop-continue-statement-output-id"},gN={like:!1,id:"hello-world-loop-continue-statement-output-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:bN},vN={type:r.GenericReference,id:"hello-world-loop-continue-statement-reads-value-ref-id",entityType:r.OutputMap,entityId:Gl},fE={isError:!1,id:"hello-world-loop-continue-statement-output-id",version:1,type:r.ReturnDeclaration,name:"Iteration result",description:null,dataType:gN,readsValue:vN,required:!0,index:0,parent:RN},IN={type:r.GenericReference,id:"hello-world-loop-continue-statement-called-by-ref-id",entityType:r.Condition,entityId:Zi},DN={type:r.GenericReference,id:"hello-world-loop-continue-statement-parent-ref-id",entityType:r.Loop,entityId:Kt},mE={type:r.ContinueStatement,id:"hello-world-loop-continue-statement",version:1,outputs:[fE],calledBySuccess:[],calledByError:[IN],calledByEntry:[],parent:DN,throws:null,x:0,y:0};r.GenericReference,r.InputMap;const PN={type:r.GenericReference,id:"append-string-to-list-base-string-map-parent-ref-id",entityType:r.Operation,entityId:Ps},AN={type:r.GenericReference,id:"base-string-map-reads-value-ref-id",entityType:r.OutputMap,entityId:Ll},TE={id:"append-string-to-list-base-string-map-id",type:r.InputMap,version:1,declaration:Uo,name:null,description:null,readsValue:AN,defaultValue:null,index:0,parent:PN},SN={type:r.GenericReference,id:"assembly-string-map-parent-ref-id",entityType:r.Operation,entityId:Ps},ON={id:lE,type:r.OutputMap,version:1,writesValues:[pE],declaration:bi,index:0,parent:SN},CN={type:r.GenericReference,id:"append-string-to-list-called-by-ref-id",entityType:r.Condition,entityId:Zi},BN={type:r.GenericReference,id:"latest-string-to-add-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:lE},wN={type:r.GenericReference,id:"62b4afb0-6c21-4b0f-abd3-cebef7b17c28",entityType:r.Operation,entityId:Ps},EE={id:"latest-string-to-add-input-map-id",version:1,type:r.InputMap,declaration:xo,name:null,description:null,readsValue:BN,defaultValue:null,index:1,parent:wN},_N={type:r.GenericReference,id:"append-string-to-list-parent-ref-id",entityType:r.FunctionDeclaration,entityId:Kt},MN={type:r.Operation,id:Ps,declaration:Na,version:1,inputs:[TE,EE],outputs:[ON],calledByError:[],process:null,calledByEntry:[],calledBySuccess:[CN],successCalls:[],errorCalls:[],error:null,x:0,y:0,parent:_N},NN={type:r.GenericReference,id:"iteration-number-is-equal-or-greater-than-10-condition-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:Yi},VN={type:r.GenericReference,id:"iteration-number-is-equal-or-greater-than-10-condition-parent-ref-id",entityType:r.Loop,entityId:Kt},$N={type:r.GenericReference,id:"current-iteration-number-to-check-map-reads-value-ref-id",entityType:r.OutputMap,entityId:zi},RE={type:r.GenericReference,id:"iteration-number-is-equal-or-greater-than-10-condition-ref-two-id",entityType:r.Condition,entityId:Zi},LN={id:"current-iteration-number-to-check-map-id",version:1,type:r.InputMap,declaration:Ur.fixedArguments[0],name:null,description:null,readsValue:$N,index:1,defaultValue:null,parent:RE},GN={type:r.GenericReference,id:"max-num-iterations-value-map-default-value-parent-ref-id",entityType:r.InputMap,entityId:"max-num-iterations-value-map-id"},FN={id:"max-num-iterations-value-map-id",version:1,type:r.InputMap,declaration:Ur.fixedArguments[1],name:null,description:null,readsValue:null,index:0,defaultValue:{id:"max-num-iterations-value-map-default-value-id",type:r.PrimitiveValue,version:1,name:A.Number,value:10,autogeneration:null,valueAsType:null,parent:GN},parent:RE},UN={type:r.Condition,id:Zi,version:1,declaration:Ur,inputs:[FN,LN],calledByError:[],calledByEntry:[NN],calledBySuccess:[],successCalls:[hE,MN],errorCalls:[mE],x:0,y:0,parent:VN},xN={type:r.GenericReference,id:"base-string-map-ref-id",entityType:r.InputMap,entityId:"join-hello-world-and-number-base-string-map-id"},kN={type:r.GenericReference,id:"join-hello-world-and-number-base-string-map-parent-ref-id",entityType:r.Operation,entityId:Ds},jN={id:"join-hello-world-and-number-base-string-map-id",type:r.InputMap,version:1,declaration:_a,name:null,description:null,readsValue:null,defaultValue:{id:"join-hello-world-and-number-base-string-map-default-value-id",type:r.PrimitiveValue,version:1,value:"Hello world ",name:A.String,parent:xN,valueAsType:null,autogeneration:null},index:0,parent:kN},qN={type:r.GenericReference,id:"assembly-string-map-parent-ref-id",entityType:r.Operation,entityId:Ds},JN={id:Gl,type:r.OutputMap,version:1,writesValues:[EE,fE],declaration:bi,index:0,parent:qN},WN={type:r.GenericReference,id:"join-hello-world-and-number-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:Yi},HN={type:r.GenericReference,id:"current-iteration-number-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:zi},YN={type:r.GenericReference,id:"62b4afb0-6c21-4b0f-abd3-cebef7b17c28",entityType:r.Operation,entityId:Ds},bE={id:"current-iteration-number-input-map-id",version:1,type:r.InputMap,declaration:Ma,name:null,description:null,readsValue:HN,defaultValue:null,index:1,parent:YN},zN={type:r.GenericReference,id:"join-hello-world-and-number-parent-ref-id",entityType:r.FunctionDeclaration,entityId:Kt},ZN={type:r.Operation,id:Ds,declaration:gi,version:1,inputs:[jN,bE],outputs:[JN],process:null,calledByError:[],calledByEntry:[WN],calledBySuccess:[],successCalls:[],errorCalls:[],error:null,x:0,y:0,parent:zN},XN={id:"manual-hello-world-loop-iterations-results-declaration-data-type-parent-ref-id",type:r.GenericReference,entityId:Ll,entityType:r.ArgumentDeclaration},QN={like:!1,id:"manual-hello-world-loop-iterations-results-declaration-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,isList:!0,isNullable:!1,constant:!1,entity:null,asType:!1,defaultValue:null,parent:XN},KN={id:"manual-hello-world-loop-previous-iterations-results-output-map-parent-ref-id",type:r.GenericReference,entityId:Yi,entityType:r.FunctionDeclaration},e0={id:Ll,type:r.ArgumentDeclaration,version:1,name:"Previous iterations results",description:"The results of the previous iterations of the loop.",required:!0,dataType:QN,writesValues:[TE],index:1,parent:KN},t0={id:"manual-hello-world-loop-current-iteration-number-output-map-parent-ref-id",type:r.GenericReference,entityId:Yi,entityType:r.FunctionDeclaration},n0={id:"manual-flow-loop-current-iteration-number-declaration-data-type-parent-ref-id",type:r.GenericReference,entityId:zi,entityType:r.ArgumentDeclaration};r.DataType;const r0={id:zi,type:r.ArgumentDeclaration,version:1,name:"Current iteration number",description:"The number of the current iteration of the loop. Starts at 1.",required:!0,dataType:null,writesValues:[bE,yE],index:0,parent:t0},i0={id:"manual-flow-loop-body-parent-ref-id",type:r.GenericReference,entityId:Kt,entityType:r.Loop},a0={id:Yi,type:r.FunctionDeclaration,version:1,name:"Iteration logic trigger",description:"This function is called multiple times, once for each iteration of the loop.",inputs:[r0,e0],calls:[UN,ZN],implements:null,collapsed:!1,returnStatements:[],private:!1,index:0,x:0,y:0,parent:i0},s0={type:r.GenericReference,id:"hello-world-loop-iteration-result-inline-output-declaration-parent-ref-id",entityType:r.Loop,entityId:Kt},gE={id:"hello-world-loop-iteration-result-inline-output-declaration-id",version:1,type:r.ValueDescriptor,name:"Iteration result",description:null,dataType:null,required:!0,index:0,parent:s0},o0={type:r.GenericReference,id:"hello-world-loop-break-statement-output-map-parent-ref-id",entityType:r.Loop,entityId:Kt},l0={type:r.OutputMap,id:cE,version:1,declaration:gE,writesValues:[dE],index:0,parent:o0},c0={id:"manual-hello-world-loop-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},d0={id:"manual-hello-world-loop-called-by-ref-id",type:r.GenericReference,entityId:Vl,entityType:r.FunctionDeclaration},u0={id:Kt,type:r.Loop,version:1,declaration:zo,inputs:[],outputsDeclarations:[gE],outputs:[l0],body:a0,successCalls:[uE],errorCalls:[],process:null,error:null,calledByError:[],calledByEntry:[d0],calledBySuccess:[],breakStatements:[hE],continueStatements:[mE],x:0,y:0,parent:c0},p0={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-parent-ref-id",entityType:r.Project,entityId:Z},vE={type:r.FunctionDeclaration,id:Vl,version:1,name:"Manual hello world loop",description:null,inputs:[],calls:[u0],returnStatements:[uE],implements:null,collapsed:!1,private:!1,index:null,x:0,y:0,parent:p0},y0={type:r.GenericReference,id:"call-hello-world-loop-parent-ref-id",entityType:r.Project,entityId:Z},h0={id:"call-hello-world-loop-id",type:r.FunctionCall,version:1,declaration:vE,inputs:[],outputs:[],process:null,successCalls:[],errorCalls:[],error:null,calledByError:[],calledByEntry:[],calledBySuccess:[],x:0,y:0,parent:y0},yn="company-dto-function-declaration-id",Fl="company-dto-func-declaration-argument-dcl-id",en="company-dto-function-company-variable-id",Ln="company-dto-function-company-dto-variable-id",Zr="iterate-over-employee-list-loop-id",IE="iterate-over-employee-list-loop-employee-dto-output-map-id",Ul="iterate-over-employee-list-loop-body-current-employee-argument-declaration-id",Xi="iterate-over-employee-list-loop-body-map-employee-dto-function-call-id",DE="iterate-over-employee-list-continue-statement-employee-dto-output-decl-id",f0="iterate-over-employee-list-loop-body-map-employee-dto-function-call-employee-dto-output-map-id",PE="iterate-over-employee-list-continue-statement-id",As="iterate-over-employee-list-loop-body-id",AE="company-dto-func-declaration-return-statement-id",SE="company-dto-func-declaration-return-decl-id",OE="company-dto-func-declaration-company-variable-id-output-map-id",CE="company-dto-func-declaration-company-variable-employess-output-map-id",BE="company-dto-func-declaration-company-variable-name-output-map-id",m0="company-dto-func-declaration-company-dto-variable-input-map-id",T0="company-dto-func-declaration-company-dto-variable-employess-input-map-id",E0="company-dto-func-declaration-company-dto-variable-name-input-map-id",Ss="company-dto-func-declaration-owner-variable-id",R0="company-dto-func-declaration-company-dto-variable-owner-input-map-id",wE="company-dto-func-declaration-company-variable-owner-output-map-id",_E="company-dto-func-declaration-owner-variable-id-output-map-id",Os="company-dto-func-declaration-bank-account-variable-id",b0="company-dto-func-declaration-company-dto-variable-bank-account-input-map-id",ME="company-dto-func-declaration-company-variable-bank-account-output-map-id",NE="company-dto-func-declaration-bank-account-variable-id-output-map-id",g0={type:r.GenericReference,id:"company-dto-func-returned-company-dto-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:SE},v0={like:!1,id:"company-dto-func-returned-company-dto-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:g0},I0={type:r.GenericReference,id:"company-dto-func-returned-company-dto-parent-ref-id",entityType:r.ReturnStatement,entityId:AE},D0={type:r.GenericReference,id:"company-dto-func-returned-company-dto-reads-value-ref-id",entityType:r.VariableDeclaration,entityId:Ln},VE={isError:!1,id:SE,type:r.ReturnDeclaration,version:1,name:"Company DTO",description:"Output the company data in the format that it will be sent through an HTTP request.",dataType:v0,readsValue:D0,required:!0,index:0,parent:I0},P0={type:r.GenericReference,id:"company-dto-func-return-statement-called-by-ref-id",entityType:r.Operation,entityId:Ln},A0={type:r.GenericReference,id:"company-dto-func-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yn},xl={type:r.ReturnStatement,id:AE,version:1,outputs:[VE],calledByError:[],calledByEntry:[],calledBySuccess:[P0],throws:null,x:0,y:0,parent:A0},S0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-owner-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:_E},O0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-owner-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ln},$E={id:R0,type:r.InputMap,version:1,declaration:null,name:"owner_id",description:null,defaultValue:null,index:5,readsValue:S0,parent:O0},C0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-bank-account-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:NE},B0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-bank-account-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ln},LE={id:b0,type:r.InputMap,version:1,declaration:null,name:"bank_account_id",description:null,defaultValue:null,index:4,readsValue:C0,parent:B0},w0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-name-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:BE},_0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-name-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ln},GE={id:E0,type:r.InputMap,version:1,declaration:null,name:"name",description:null,defaultValue:null,index:3,readsValue:w0,parent:_0},M0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-employess-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:IE},N0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-employess-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ln},FE={id:T0,type:r.InputMap,version:1,declaration:null,name:"employees",description:null,defaultValue:null,index:2,readsValue:M0,parent:N0},V0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-id-output-map-reads-value-ref-id",entityType:r.OutputMap,entityId:OE},$0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ln},UE={id:m0,type:r.InputMap,version:1,declaration:null,name:"id",description:"The ID of the company",defaultValue:null,index:1,readsValue:V0,parent:$0},L0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yn},G0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-called-by-ref-one-id",entityType:r.VariableDeclaration,entityId:Os},F0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-called-by-ref-two-id",entityType:r.VariableDeclaration,entityId:Ss},U0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-called-by-ref-three-id",entityType:r.VariableDeclaration,entityId:Zr},kl={id:Ln,type:r.VariableDeclaration,version:1,name:"Company DTO",dataType:null,description:"A variable holding the data of a mapped company DTO",calledByError:[],calledByEntry:[],calledBySuccess:[G0,F0,U0],successCalls:[xl],errorCalls:[],readsValue:null,writesValues:[VE],inputs:[UE,GE,LE,$E,FE],outputs:[],internalCalls:[],parent:L0,x:0,y:0},ar="employee-dto-func-declaration-id",jl="employee-dto-func-declaration-argument-dcl-id",xE="employee-dto-func-declaration-return-statement-id",kE="employee-dto-func-declaration-return-decl-id",sr="employee-dto-func-declaration-employee-variable-id",or="employee-dto-func-declaration-employee-dto-variable-id",Cs="employee-dto-func-declaration-manager-variable-id",jE="employee-dto-func-declaration-employee-variable-id-output-map-id",qE="employee-dto-func-declaration-employee-variable-birth-date-output-map-id",JE="employee-dto-func-declaration-employee-variable-department-output-map-id",WE="employee-dto-func-declaration-employee-variable-manager-output-map-id",HE="employee-dto-func-declaration-manager-variable-id-output-map-id",x0="employee-dto-func-declaration-employee-dto-variable-input-map-id",k0="employee-dto-func-declaration-employee-dto-variable-birth-date-input-map-id",j0="employee-dto-func-declaration-employee-dto-variable-department-input-map-id",q0="employee-dto-func-declaration-employee-dto-variable-manager-input-map-id",J0={type:r.GenericReference,id:"employee-dto-func-returned-employee-dto-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:kE},W0={like:!1,id:"employee-dto-func-returned-employee-dto-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:J0},H0={type:r.GenericReference,id:"employee-dto-func-returned-employee-dto-parent-ref-id",entityType:r.ReturnStatement,entityId:xE},Y0={type:r.GenericReference,id:"employee-dto-func-returned-employee-dto-reads-value-ref-id",entityType:r.VariableDeclaration,entityId:or},YE={isError:!1,id:kE,type:r.ReturnDeclaration,version:1,name:"Employee DTO",description:"Output the employee data in the format that it will be sent through an HTTP request.",dataType:W0,readsValue:Y0,required:!0,index:0,parent:H0},z0={type:r.GenericReference,id:"employee-dto-func-return-statement-called-by-ref-id",entityType:r.Operation,entityId:or},Z0={type:r.GenericReference,id:"employee-dto-func-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ar},ql={type:r.ReturnStatement,id:xE,version:1,outputs:[YE],calledByError:[],calledByEntry:[],calledBySuccess:[z0],throws:null,x:0,y:0,parent:Z0},X0={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-manager-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:HE},Q0={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-manager-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:or},zE={id:q0,type:r.InputMap,version:1,declaration:null,name:"manager_id",description:null,defaultValue:null,index:4,readsValue:X0,parent:Q0},K0={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-department-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:JE},e1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-department-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:or},ZE={id:j0,type:r.InputMap,version:1,declaration:null,name:"department_name",description:null,defaultValue:null,index:3,readsValue:K0,parent:e1},t1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-birth-date-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:qE},n1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-birth-date-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:or},XE={id:k0,type:r.InputMap,version:1,declaration:null,name:"birth_date",description:null,defaultValue:null,index:2,readsValue:t1,parent:n1},r1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-id-output-map-reads-value-ref-id",entityType:r.OutputMap,entityId:jE},i1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:or},QE={id:x0,type:r.InputMap,version:1,declaration:null,name:"id",description:"The ID of the employee",defaultValue:null,index:1,readsValue:r1,parent:i1},a1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ar},s1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-called-by-ref-id",entityType:r.VariableDeclaration,entityId:Cs},o1={id:or,type:r.VariableDeclaration,version:1,name:"Employee DTO",dataType:null,description:"A variable holding the data of a mapped employee DTO",calledByError:[],calledByEntry:[],calledBySuccess:[s1],successCalls:[ql],errorCalls:[],readsValue:null,writesValues:[YE],inputs:[QE,XE,ZE,zE],outputs:[],internalCalls:[],parent:a1,x:0,y:0},l1={type:r.GenericReference,id:"employee-dto-func-manager-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Cs},c1={id:HE,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[zE],parent:l1},d1={type:r.GenericReference,id:"employee-dto-func-manager-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:Cs},u1={like:!1,id:"employee-dto-func-manager-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ct,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:d1,defaultValue:null},p1={type:r.GenericReference,id:"employee-dto-func-manager-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:WE},y1={type:r.GenericReference,id:"employee-dto-func-manager-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ar};r.GenericReference,r.VariableDeclaration;const KE={id:Cs,type:r.VariableDeclaration,version:1,name:"Manager",dataType:u1,description:"A variable holding an inherited manager",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[o1],errorCalls:[],readsValue:p1,writesValues:[],inputs:[],outputs:[c1],internalCalls:[],parent:y1,x:0,y:0},h1={type:r.GenericReference,id:"employee-dto-func-employee-variable-manager-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:sr},f1={id:WE,type:r.OutputMap,version:1,declaration:Ct.properties[2],index:3,writesValues:[KE],parent:h1},m1={type:r.GenericReference,id:"employee-dto-func-employee-variable-department-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:sr},T1={id:JE,type:r.OutputMap,version:1,declaration:Ct.properties[0],index:2,writesValues:[ZE],parent:m1},E1={type:r.GenericReference,id:"employee-dto-func-employee-variable-birth-date-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:sr},R1={id:qE,type:r.OutputMap,version:1,declaration:pt.properties[1],index:1,writesValues:[XE],parent:E1},b1={type:r.GenericReference,id:"employee-dto-func-employee-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:sr},g1={id:jE,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[QE],parent:b1},v1={type:r.GenericReference,id:"employee-dto-func-employee-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:sr},I1={like:!1,id:"employee-dto-func-employee-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ct,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:v1,defaultValue:null},D1={type:r.GenericReference,id:"employee-dto-func-employee-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ar},P1={type:r.GenericReference,id:"employee-dto-func-employee-variable-reads-value-ref-id",entityType:r.ArgumentDeclaration,entityId:jl},A1={type:r.GenericReference,id:"employee-dto-func-employee-variable-called-by-id",entityType:r.FunctionDeclaration,entityId:ar},eR={id:sr,type:r.VariableDeclaration,version:1,name:"Company employee",dataType:I1,description:"A variable holding a company employee",calledByError:[],calledByEntry:[A1],calledBySuccess:[],successCalls:[KE],errorCalls:[],readsValue:P1,writesValues:[],inputs:[],outputs:[g1,R1,T1,f1],internalCalls:[],parent:D1,x:0,y:0},S1={type:r.GenericReference,id:"employee-dto-func-declaration-employee-input-declaration-data-type-parent-ref-id",entityId:jl,entityType:r.ArgumentDeclaration},O1={type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,id:"employee-dto-func-declaration-employee-input-declaration-data-type-id",version:1,entity:Ct,asType:!1,isList:!1,isNullable:!1,constant:!1,like:!1,parent:S1,defaultValue:null},C1={type:r.GenericReference,id:"employee-dto-func-declaration-employee-input-declaration-parent-ref-id",entityId:ar,entityType:r.FunctionDeclaration},B1={type:r.ArgumentDeclaration,id:jl,version:1,name:"Employee",description:"The employee to create a DTO for",required:!0,dataType:O1,index:0,writesValues:[eR],parent:C1},w1={type:r.GenericReference,id:"employee-dto-function-declaration-parent-ref-id",entityType:r.Project,entityId:Z},Jl={type:r.FunctionDeclaration,id:ar,version:1,name:"Employee DTO",description:"Takes a employee and returns a DTO of that employee",index:null,inputs:[B1],calls:[eR],implements:null,returnStatements:[ql],collapsed:!1,private:!1,x:0,y:0,parent:w1},_1={id:"iterate-over-employee-list-continue-statement-employee-dto-output-decl-data-type-parent-ref-id",type:r.GenericReference,entityId:DE,entityType:r.ReturnDeclaration},M1={like:!1,id:"iterate-over-employee-list-continue-statement-employee-dto-output-decl-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,defaultValue:null,entity:Ct,isList:!1,isNullable:!1,asType:!1,constant:!1,parent:_1},N1={id:"iterate-over-employee-list-continue-statement-employee-dto-output-decl-reads-value-ref-id",type:r.GenericReference,entityId:Xi,entityType:r.OutputMap},V1={id:"iterate-over-employee-list-continue-statement-employee-dto-output-decl-parent-ref-id",type:r.GenericReference,entityId:PE,entityType:r.ContinueStatement},tR={isError:!1,id:DE,type:r.ReturnDeclaration,version:1,name:"Employee DTO",description:"The DTO of the employee entity.",readsValue:N1,dataType:M1,required:!0,index:0,parent:V1},$1={id:"iterate-over-employee-list-continue-statement-called-by-ref-id",type:r.GenericReference,entityId:Xi,entityType:r.FunctionCall},L1={id:"iterate-over-employee-list-continue-statement-parent-ref-id",type:r.GenericReference,entityId:Zr,entityType:r.Loop},nR={id:PE,type:r.ContinueStatement,version:1,calledByError:[],calledByEntry:[],calledBySuccess:[$1],outputs:[tR],throws:null,x:0,y:0,parent:L1},G1={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-employee-dto-output-map-parent-ref-id",type:r.GenericReference,entityId:Xi,entityType:r.FunctionCall},F1={id:f0,type:r.OutputMap,version:1,declaration:ql.outputs[0],writesValues:[tR],index:0,parent:G1},U1={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-employee-input-map-reads-value-ref-id",type:r.GenericReference,entityId:Ul,entityType:r.ArgumentDeclaration},x1={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-employee-input-map-parent-ref-id",type:r.GenericReference,entityId:Xi,entityType:r.FunctionCall},rR={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-employee-input-map-id",type:r.InputMap,version:1,name:null,description:null,declaration:Jl.inputs[0],readsValue:U1,index:0,defaultValue:null,parent:x1},k1={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-called-by-ref-id",type:r.GenericReference,entityId:As,entityType:r.FunctionDeclaration},j1={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-parent-ref-id",type:r.GenericReference,entityId:As,entityType:r.FunctionDeclaration},q1={id:Xi,type:r.FunctionCall,version:1,declaration:Jl,inputs:[rR],process:null,outputs:[F1],calledByError:[],calledByEntry:[k1],calledBySuccess:[],successCalls:[nR],errorCalls:[],error:null,x:0,y:0,parent:j1},J1={type:r.GenericReference,id:"iterate-over-employee-list-loop-body-current-employee-argument-declaration-data-type-parent-ref-id",entityId:Ul,entityType:r.ArgumentDeclaration},W1={like:!1,id:"iterate-over-employee-list-loop-body-current-employee-argument-declaration-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,defaultValue:null,entity:Ct,isList:!1,isNullable:!1,asType:!1,constant:!1,parent:J1},H1={id:"iterate-over-employee-list-loop-body-current-employee-argument-declaration-parent-ref-id",type:r.GenericReference,entityId:As,entityType:r.FunctionDeclaration},Y1={id:Ul,type:r.ArgumentDeclaration,version:1,name:"Current employee",description:"The current employee entity being processed.",dataType:W1,required:!0,index:0,writesValues:[rR],parent:H1},z1={id:"iterate-over-employee-list-loop-body-parent-ref-id",type:r.GenericReference,entityId:Zr,entityType:r.Loop},Z1={id:As,type:r.FunctionDeclaration,version:1,name:"Iteration logic trigger",description:"This function is called once for each entity in the list.",inputs:[Y1],calls:[q1],implements:null,collapsed:!1,returnStatements:[],private:!1,index:0,x:0,y:0,parent:z1},X1={id:"iterate-over-employee-list-loop-iteration-list-input-map-parent-ref-id",type:r.GenericReference,entityId:Zr,entityType:r.Loop},Q1={id:"iterate-over-employee-list-loop-iteration-list-input-map-reads-value-ref-id",type:r.GenericReference,entityId:CE,entityType:r.OutputMap},iR={id:"iterate-over-employee-list-loop-iteration-list-input-map-id",type:r.InputMap,version:1,name:null,description:null,declaration:Kn.fixedArguments[0],defaultValue:null,readsValue:Q1,index:0,parent:X1},K1={id:"iterate-over-employee-list-loop-parent-ref-id",type:r.GenericReference,entityId:yn,entityType:r.FunctionDeclaration},eV={id:"iterate-over-employee-list-loop-employee-dto-output-map-parent-ref-id",type:r.GenericReference,entityId:Zr,entityType:r.Loop},tV={id:IE,type:r.OutputMap,version:1,declaration:Kn.fixedReturns[0],writesValues:[FE],index:0,parent:eV},nV={type:r.GenericReference,id:"iterate-over-employee-list-loop-called-by-ref-id",entityType:r.VariableDeclaration,entityId:en},rV={id:Zr,type:r.Loop,version:1,declaration:Kn,inputs:[iR],successCalls:[kl],errorCalls:[],outputsDeclarations:[],outputs:[tV],body:Z1,process:null,calledByError:[],calledByEntry:[],calledBySuccess:[nV],breakStatements:[],continueStatements:[nR],error:null,x:0,y:0,parent:K1},iV={type:r.GenericReference,id:"company-dto-func-bank-account-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Os},aV={id:NE,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[LE],parent:iV},sV={type:r.GenericReference,id:"company-dto-func-bank-account-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:Os},oV={like:!1,id:"company-dto-func-bank-account-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:sV,defaultValue:null},lV={type:r.GenericReference,id:"company-dto-func-bank-account-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:ME},cV={type:r.GenericReference,id:"company-dto-func-bank-account-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yn};r.GenericReference,r.VariableDeclaration;const aR={id:Os,type:r.VariableDeclaration,version:1,name:"Bank account",dataType:oV,description:"A variable holding an inherited bank account",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[kl],errorCalls:[],readsValue:lV,writesValues:[],inputs:[],outputs:[aV],internalCalls:[],parent:cV,x:0,y:0},dV={type:r.GenericReference,id:"company-dto-func-owner-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ss},uV={id:_E,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[$E],parent:dV},pV={type:r.GenericReference,id:"company-dto-func-owner-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ss},yV={like:!1,id:"company-dto-func-owner-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:pV,defaultValue:null},hV={type:r.GenericReference,id:"company-dto-func-owner-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:wE},fV={type:r.GenericReference,id:"company-dto-func-owner-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yn};r.GenericReference,r.VariableDeclaration;const sR={id:Ss,type:r.VariableDeclaration,version:1,name:"Owner",dataType:yV,description:"A variable holding an inherited owner",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[kl],errorCalls:[],readsValue:hV,writesValues:[],inputs:[],outputs:[uV],internalCalls:[],parent:fV,x:0,y:0},mV={type:r.GenericReference,id:"company-dto-func-company-variable-owner-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},TV={id:wE,type:r.OutputMap,version:1,declaration:gt.properties[2],index:4,writesValues:[sR],parent:mV},EV={type:r.GenericReference,id:"company-dto-func-company-variable-bank-account-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},RV={id:ME,type:r.OutputMap,version:1,declaration:gt.properties[2],index:3,writesValues:[aR],parent:EV},bV={type:r.GenericReference,id:"company-dto-func-company-variable-name-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},gV={id:BE,type:r.OutputMap,version:1,declaration:gt.properties[0],index:2,writesValues:[GE],parent:bV},vV={type:r.GenericReference,id:"company-dto-func-company-variable-employess-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},IV={id:CE,type:r.OutputMap,version:1,declaration:gt.properties[3],index:1,writesValues:[iR],parent:vV},DV={type:r.GenericReference,id:"company-dto-func-company-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},PV={id:OE,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[UE],parent:DV},AV={type:r.GenericReference,id:"company-dto-func-company-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},SV={like:!1,id:"company-dto-func-company-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:AV,defaultValue:null},OV={type:r.GenericReference,id:"company-dto-func-company-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yn},CV={type:r.GenericReference,id:"company-dto-func-company-variable-reads-value-ref-id",entityType:r.ArgumentDeclaration,entityId:Fl},BV={type:r.GenericReference,id:"company-dto-func-company-variable-called-by-id",entityType:r.FunctionDeclaration,entityId:yn},oR={id:en,type:r.VariableDeclaration,version:1,name:"Company",dataType:SV,description:"A variable holding a company",calledByError:[],calledByEntry:[BV],calledBySuccess:[],successCalls:[aR,sR,rV],errorCalls:[],readsValue:CV,writesValues:[],inputs:[],outputs:[PV,IV,gV,RV,TV],internalCalls:[],parent:OV,x:0,y:0},wV={type:r.GenericReference,id:"company-dto-func-declaration-company-input-declaration-data-type-parent-ref-id",entityId:Fl,entityType:r.ArgumentDeclaration},_V={type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,id:"company-dto-func-declaration-company-input-declaration-data-type-id",version:1,entity:gt,asType:!1,isList:!1,isNullable:!1,constant:!1,like:!1,parent:wV,defaultValue:null},MV={type:r.GenericReference,id:"company-dto-func-declaration-company-input-declaration-parent-ref-id",entityId:yn,entityType:r.FunctionDeclaration},NV={type:r.ArgumentDeclaration,id:Fl,version:1,name:"Company",description:"The company to create a DTO for",required:!0,dataType:_V,index:0,writesValues:[oR],parent:MV},VV={type:r.GenericReference,id:"company-dto-function-declaration-parent-ref-id",entityType:r.Project,entityId:Z},Wl={type:r.FunctionDeclaration,id:yn,version:1,name:"Company DTO",description:"Takes a company and returns a DTO of that company",inputs:[NV],calls:[oR],implements:null,index:null,returnStatements:[xl],collapsed:!1,private:!1,x:0,y:0,parent:VV},Qi="exec-in-parallel-operation-call-id",Ki="exec-sequentially-operation-call-id",yt="concurrency-and-wait-function-declaration-id",lR="concurrency-and-wait-return-statement-id",cR="concurrency-and-wait-return-declaration-id",Hl="exec-in-parallel-argument-map-id",dR="exec-sequentially-argument-map-id",Yl="wait-for-2-seconds-operation-id",uR="wait-for-2-seconds-argument-map-id",zl="map-company-dto-function-call-id",pR="map-company-dto-function-call-company-dto-output-map-id",ea="company-dto-variable-one-id",Zl="company-dto-variable-one-instance-id",$V="company-dto-variable-two-id",LV={type:r.GenericReference,id:"returned-company-dto-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:cR},GV={like:!1,id:"returned-company-dto-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:LV},FV={type:r.GenericReference,id:"returned-company-dto-parent-ref-id",entityType:r.ReturnStatement,entityId:lR},UV={type:r.GenericReference,id:"returned-company-dto-reads-value-ref-id",entityType:r.VariableDeclaration,entityId:ea},yR={isError:!1,id:cR,type:r.ReturnDeclaration,version:1,name:"Company DTO",description:"Output the company data in the format that it will be sent through an HTTP request.",dataType:GV,readsValue:UV,required:!0,index:0,parent:FV},xV={type:r.GenericReference,id:"concurrency-and-wait-return-statement-called-by-ref-id",entityType:r.Operation,entityId:Yl},kV={type:r.GenericReference,id:"concurrency-and-wait-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},hR={type:r.ReturnStatement,id:lR,version:1,outputs:[yR],calledByError:[],calledByEntry:[],calledBySuccess:[xV],throws:null,x:0,y:0,parent:kV},jV={type:r.GenericReference,id:"company-dto-variable-two-called-by-ref-id",entityType:r.VariableInstance,entityId:Zl},qV={type:r.GenericReference,id:"company-dto-variable-two-reads-value-ref-id",entityType:r.VariableInstance,entityId:Zl},JV={type:r.GenericReference,id:"company-dto-variable-two-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},fR={id:$V,type:r.VariableDeclaration,version:1,name:"Company DTO",description:null,dataType:null,inputs:[],outputs:[],successCalls:[],errorCalls:[],calledByError:[],calledByEntry:[],calledBySuccess:[jV],internalCalls:[],writesValues:[yR],readsValue:qV,x:0,y:0,parent:JV},WV={type:r.GenericReference,id:"company-dto-variable-one-instance-called-by-ref-id",entityType:r.VariableDeclaration,entityId:ea},HV={type:r.GenericReference,id:"company-dto-variable-one-instance-reads-value-ref-id",entityType:r.VariableDeclaration,entityId:ea},YV={type:r.GenericReference,id:"company-dto-variable-one-instance-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},zV={type:r.GenericReference,id:"company-dto-variable-one-instance-declaration-ref-id",entityType:r.VariableDeclaration,entityId:ea},mR={id:Zl,type:r.VariableInstance,version:1,declaration:zV,inputs:[],outputs:[],successCalls:[fR],errorCalls:[],calledByError:[],calledByEntry:[],calledBySuccess:[WV],internalCalls:[],writesValues:[fR],readsValue:HV,x:0,y:0,parent:YV},ZV={type:r.GenericReference,id:"company-dto-variable-one-called-by-ref-id",entityType:r.FunctionCall,entityId:zl},XV={type:r.GenericReference,id:"company-dto-variable-one-reads-value-ref-id",entityType:r.OutputMap,entityId:pR},QV={type:r.GenericReference,id:"company-dto-variable-one-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},TR={id:ea,type:r.VariableDeclaration,version:1,name:"Company DTO",description:null,dataType:null,inputs:[],outputs:[],successCalls:[mR],errorCalls:[],calledByError:[],calledByEntry:[],calledBySuccess:[ZV],internalCalls:[],writesValues:[mR],readsValue:XV,x:0,y:0,parent:QV},ER={type:r.GenericReference,id:"map-company-dto-function-call-company-input-map-parent-ref-id",entityType:r.FunctionCall,entityId:zl},KV={id:"map-company-dto-function-call-company-input-map-id",type:r.InputMap,version:1,declaration:Wl.inputs[0],name:null,description:null,defaultValue:null,index:0,readsValue:null,parent:ER},e$={id:pR,type:r.OutputMap,version:1,declaration:xl.outputs[0],writesValues:[TR],index:0,parent:ER},t$={id:"map-company-dto-function-call-called-by-ref-id",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:yt},n$={id:"map-company-dto-function-call-parent-ref-id",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:yt},r$={id:zl,type:r.FunctionCall,version:1,declaration:Wl,successCalls:[TR],process:null,errorCalls:[],inputs:[KV],outputs:[e$],calledByError:[],calledByEntry:[t$],calledBySuccess:[],parent:n$,x:0,y:0,error:null},i$={type:r.GenericReference,id:"last-timestamp-variable-datatype-parent-ref-id",entityType:r.VariableDeclaration,entityId:fT},a$={type:r.GenericReference,id:"last-timestamp-variable-default-value-parent-ref-id",entityType:r.DataType,entityId:"last-timestamp-variable-datatype-id"},s$={like:!1,id:"last-timestamp-variable-datatype-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:cn,version:1,asType:!1,isList:!1,isNullable:!1,constant:!1,parent:i$,defaultValue:{id:"last-timestamp-variable-default-value-id",type:r.PrimitiveValue,version:1,name:A.Date,value:null,autogeneration:{type:qe.CurrentDateAndTime,rangeStart:null,rangeEnd:null},parent:a$,valueAsType:null}},o$={type:r.GenericReference,id:"last-timestamp-variable-main-project-ref-id",entityType:r.Project,entityId:Z},Xl={id:fT,type:r.VariableDeclaration,version:1,name:"Last registered current time",description:"A test variable that holds the last current date and time that was registered.",dataType:s$,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],x:0,y:0,readsValue:null,writesValues:[],internalCalls:[],parent:o$},l$={type:r.GenericReference,id:"wait-for-2-seconds-argument-default-value-parent-ref-id",entityType:r.InputMap,entityId:uR},c$={type:r.GenericReference,id:"wait-for-2-seconds-argument-map-parent-ref-id",entityType:r.Operation,entityId:Yl},d$={id:uR,type:r.InputMap,version:1,declaration:Zn,name:null,description:null,readsValue:null,defaultValue:{id:"wait-for-2-seconds-argument-default-value-id",type:r.PrimitiveValue,version:1,value:2e3,valueAsType:null,autogeneration:null,name:A.Number,parent:l$},index:0,parent:c$},u$={type:r.GenericReference,id:"wait-for-2-seconds-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},p$={type:r.GenericReference,id:"wait-for-2-seconds-called-by-ref-one-id",entityType:r.FunctionDeclaration,entityId:Ki},y$={type:r.GenericReference,id:"wait-for-2-seconds-called-by-ref-two-id",entityType:r.FunctionDeclaration,entityId:Qi},RR={id:Yl,type:r.Operation,version:1,declaration:xt,inputs:[d$],outputs:[],process:null,successCalls:[hR],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[p$,y$],calledBySuccess:[],error:null,parent:u$},h$={type:r.GenericReference,id:"wait-for-random-amount-argument-default-value-parent-ref-id",entityType:r.InputMap,entityId:"wait-for-random-amount-input-map-id"},f$={type:r.GenericReference,id:"wait-for-random-amount-argument-map-parent-ref-id",entityType:r.Operation,entityId:"wait-for-random-amount-id"},m$={id:"wait-for-random-amount-input-map-id",type:r.InputMap,version:1,declaration:Zn,name:null,description:null,readsValue:null,defaultValue:{id:"wait-for-random-amount-argument-default-value-id",type:r.PrimitiveValue,version:1,value:null,valueAsType:null,autogeneration:{type:qe.Random,rangeStart:1e3,rangeEnd:4e3},name:A.Number,parent:h$},index:0,parent:f$},T$={type:r.GenericReference,id:"wait-for-random-amount-parent-ref-id",entityType:r.Project,entityId:Z},Xr={id:"wait-for-random-amount-id",type:r.Operation,version:1,declaration:xt,inputs:[m$],process:null,outputs:[],successCalls:[],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[],calledBySuccess:[],error:null,parent:T$},bR="list-of-functions-variable-id",E$={type:r.GenericReference,id:"list-of-functions-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:bR},R$={id:"list-of-functions-variable-action-descriptor-id",type:r.ActionDescriptor,version:1,name:"Action to execute",description:"An action of any type, to be executed. It can contain any number of inputs and outputs.",argumentsType:U.Dynamic,dynamicArgumentTypes:null,fixedArguments:[],returnsType:U.Dynamic,error:null,dynamicReturnTypes:null,fixedReturns:[],parent:null},b$={type:r.GenericReference,id:"list-of-functions-variable-data-type-default-parent-ref-id",entityType:r.DataType,entityId:"list-of-functions-variable-data-type-id"},g$={like:!1,id:"list-of-functions-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:R$,asType:!1,isList:!0,isNullable:!1,defaultValue:{id:"list-of-functions-variable-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.ActionDescriptor,value:null,valueAsType:[Xr,Xr,Xr,Xr,Xr],autogeneration:null,parent:b$},constant:!1,parent:E$},v$={type:r.GenericReference,id:"list-of-functions-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt};r.GenericReference,r.InputMap;const I$={type:r.GenericReference,id:"list-of-functions-variable-writes-value-one-ref-id",entityType:r.InputMap,entityId:dR},D$={type:r.GenericReference,id:"list-of-functions-variable-writes-value-two-ref-id",entityType:r.InputMap,entityId:Hl},gR={id:bR,type:r.VariableDeclaration,version:1,name:"List of functions to execute",description:"A list of functions to be executed in parallel",dataType:g$,parent:v$,readsValue:null,writesValues:[I$,D$],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],inputs:[],outputs:[],internalCalls:[],x:0,y:0},P$={type:r.GenericReference,id:"exec-in-parallel-return-map-parent-ref-id",entityType:r.Operation,entityId:Qi},A$={type:r.GenericReference,id:"exec-in-parallel-result-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},S$={type:r.GenericReference,id:"exec-in-parallel-result-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:"exec-in-parallel-return-map-id"},O$={type:r.GenericReference,id:"exec-in-parallel-result-variable-called-by-ref-id",entityType:r.Operation,entityId:Qi},vR={id:"exec-in-parallel-result-variable-id",type:r.VariableInstance,version:1,declaration:Xl,readsValue:S$,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[O$],successCalls:[],errorCalls:[],internalCalls:[],parent:A$,x:0,y:0},C$={id:"exec-in-parallel-return-map-id",type:r.OutputMap,version:1,declaration:jo,writesValues:[vR],index:0,parent:P$},B$={type:r.GenericReference,id:"exec-in-parallel-argument-map-parent-ref-id",entityType:r.Operation,entityId:Qi},w$={id:Hl,type:r.InputMap,version:1,declaration:ko,name:null,description:null,readsValue:gR,defaultValue:null,index:0,parent:B$},_$={type:r.GenericReference,id:"exec-in-parallel-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},M$={type:r.GenericReference,id:"exec-in-parallel-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:yt},N$={process:null,id:Qi,type:r.Operation,version:1,declaration:xt,inputs:[w$],outputs:[C$],successCalls:[RR,vR],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[M$],calledBySuccess:[],error:null,parent:_$},V$={type:r.GenericReference,id:"exec-sequentially-return-map-parent-ref-id",entityType:r.Operation,entityId:Ki},$$={type:r.GenericReference,id:"exec-sequentially-result-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},L$={type:r.GenericReference,id:"exec-sequentially-result-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:"exec-sequentially-return-map-id"},G$={type:r.GenericReference,id:"exec-sequentially-result-variable-called-by-ref-id",entityType:r.Operation,entityId:Ki},IR={id:"exec-sequentially-result-variable-id",type:r.VariableInstance,version:1,declaration:Xl,readsValue:L$,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[G$],successCalls:[],errorCalls:[],internalCalls:[],parent:$$,x:0,y:0},F$={id:"exec-sequentially-return-map-id",type:r.OutputMap,version:1,declaration:Jo,writesValues:[IR],index:0,parent:V$},U$={type:r.GenericReference,id:"exec-sequentially-argument-map-parent-ref-id",entityType:r.Operation,entityId:Ki},x$={id:dR,type:r.InputMap,version:1,declaration:qo,name:null,description:null,readsValue:gR,defaultValue:null,index:0,parent:U$},k$={type:r.GenericReference,id:"exec-sequentially-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},j$={type:r.GenericReference,id:"exec-sequentially-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:yt},q$={id:Ki,type:r.Operation,version:1,declaration:dn,inputs:[x$],process:null,outputs:[F$],successCalls:[RR,IR],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[j$],calledBySuccess:[],error:null,parent:k$},J$={type:r.GenericReference,id:"concurrency-and-wait-parent-ref-id",entityType:r.Project,entityId:Z},W$={type:r.FunctionDeclaration,id:yt,version:1,name:"Execute with concurrency and wait",description:"Executes a hardcoded list of actions in parallel and waits for some time before ending the logic with some unrelated data payload as the result.",inputs:[],calls:[q$,N$,r$],returnStatements:[hR],implements:null,index:null,collapsed:!1,private:!1,x:0,y:0,parent:J$},H$={type:r.GenericReference,id:"3521f2c8-a5c0-419c-8808-4fc6a73d0b78",entityType:r.ReturnDeclaration,entityId:"e1ec31f0-25ca-42ac-a4c4-c9ec2255f55b"},Y$={like:!1,id:"ce8b9a30-afe9-4d4f-879f-1677efca2c47",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:H$},z$={type:r.GenericReference,id:"8ee66e38-b060-474e-a503-594063a8ec24",entityType:r.ReturnStatement,entityId:"40a23a98-d3b2-42b1-9652-b33779ad15aa"},Z$={isError:!1,id:"e1ec31f0-25ca-42ac-a4c4-c9ec2255f55b",type:r.ReturnDeclaration,version:1,name:"Created company",description:"The new company that was created",dataType:Y$,readsValue:null,required:!0,index:0,parent:z$},X$={type:r.GenericReference,id:"9cb3c1e4-7250-4be6-be2a-69c2dd366d6f",entityType:r.FunctionDeclaration,entityId:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4"},Q$={type:r.GenericReference,id:"c065fcdd-e054-4f95-941c-7eaa65c35d04",entityType:r.FunctionDeclaration,entityId:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4"},DR={type:r.ReturnStatement,id:"40a23a98-d3b2-42b1-9652-b33779ad15aa",version:1,outputs:[Z$],calledByError:[],calledByEntry:[Q$],calledBySuccess:[],throws:null,x:0,y:0,parent:X$},K$={type:r.GenericReference,id:"312ef836-9e40-4d57-b177-03b7145ed074",entityType:r.Project,entityId:Z},eL={type:r.FunctionDeclaration,id:"5059c093-eda2-4efc-b7b4-aaaadd4d44de",version:1,name:"Create new company",description:null,inputs:[],calls:[DR],index:null,implements:null,returnStatements:[DR],collapsed:!1,private:!1,x:0,y:0,parent:K$},Ql="get-current-date-and-time-func-decl-id",PR="get-current-date-and-time-return-statement-id",AR="get-current-date-and-time-return-declaration-id",SR="get-current-date-and-time-return-declaration-data-type-id",tL={type:r.GenericReference,id:"get-current-date-and-time-return-declaration-data-type-value-parent-ref-id",entityType:r.DataType,entityId:SR},nL={type:r.GenericReference,id:"get-current-date-and-time-return-declaration-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:AR},rL={type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,id:SR,version:1,entity:cn,asType:!1,isList:!1,isNullable:!1,like:!1,defaultValue:{id:"last-timestamp-variable-default-value-id",type:r.PrimitiveValue,version:1,value:null,name:A.Date,valueAsType:null,autogeneration:{type:qe.CurrentDateAndTime,rangeStart:null,rangeEnd:null},parent:tL},constant:!1,parent:nL},iL={type:r.GenericReference,id:"get-current-date-and-time-return-declaration-parent-ref-id",entityType:r.ReturnStatement,entityId:PR};r.ReturnDeclaration;const aL={type:r.GenericReference,id:"get-current-date-and-time-return-statement-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:Ql},sL={type:r.GenericReference,id:"get-current-date-and-time-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:Ql};r.ReturnStatement;const oL={type:r.GenericReference,id:"concurrency-and-wait-parent-ref-id",entityType:r.Project,entityId:Z},lL={type:r.FunctionDeclaration,id:Ql,version:1,name:"Get current date and time",description:"Generates and returns the current date and time at the time of the execution",inputs:[],calls:[],returnStatements:[],implements:null,index:null,collapsed:!1,private:!1,x:0,y:0,parent:oL},OR="do-math-return-statement-id",CR="do-math-return-declaration-id",cL={type:r.GenericReference,id:"do-math-func-var-to-return-one-ref-id",entityType:r.VariableDeclaration,entityId:"do-math-func-var-to-return-one-id"},dL={like:!1,id:"do-math-func-var-to-return-one-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:cL},uL={type:r.GenericReference,id:"do-math-func-decl-ref-two-id",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},pL={type:r.GenericReference,id:"do-math-func-var-to-return-one-map-ref-id",entityType:r.ReturnDeclaration,entityId:CR},yL={type:r.VariableDeclaration,id:"do-math-func-var-to-return-one-id",version:1,description:null,name:"Fixed result",dataType:dL,readsValue:null,writesValues:[pL],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:uL},hL={type:r.GenericReference,id:"96ec244e-594b-45f7-802b-6dc3056920f6",entityType:r.ReturnStatement,entityId:OR},fL={type:r.GenericReference,id:"d120c0cc-9d13-4e45-90e2-4e1ee825ca46",entityType:r.ReturnDeclaration,entityId:"873a3556-4911-4141-b2a0-49c677b56fb4"},mL={like:!1,id:"da91aa23-9985-49ac-a8bf-9d623ba1ba8f",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:fL},TL={isError:!1,id:CR,version:1,type:r.ReturnDeclaration,name:"Result",description:null,dataType:mL,readsValue:yL,required:!0,index:0,parent:hL},EL={type:r.GenericReference,id:"57fd93e4-93a1-484e-82eb-4dd15d2d0e24",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},RL={type:r.GenericReference,id:"0a86e8d5-ab21-476e-a482-b928cbf351e3",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},BR={type:r.ReturnStatement,id:OR,version:1,outputs:[TL],calledByError:[],calledByEntry:[],calledBySuccess:[EL],parent:RL,throws:null,x:0,y:0},bL={type:r.GenericReference,id:"a2db26be-57f2-48e5-9769-cdbf0d95dc7c",entityType:r.VariableDeclaration,entityId:"d0e9f1f3-7e9f-4e1f-8d8e-7b4b3e6c6a6a"},gL={like:!1,id:"c3e9d5f0-204f-45f9-85f7-e1b56b468388",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:bL},vL={type:r.GenericReference,id:"692122c5-610a-4504-90dd-f5a5202d116c",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},IL={type:r.GenericReference,id:"do-math-func-return-one-called-by",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},DL={type:r.GenericReference,id:"6dceb501-be5b-4252-afb4-3c0d08abba33",entityType:r.OutputMap,entityId:"64752080-ee0f-4cfe-9897-a0668f2b2aca"},wR={type:r.VariableDeclaration,id:"d0e9f1f3-7e9f-4e1f-8d8e-7b4b3e6c6a6a",version:1,name:"Result",dataType:gL,description:null,readsValue:DL,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[IL],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:vL},PL={type:r.GenericReference,id:"5440f523-af38-4981-8035-89d162fe8041",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},AL={type:r.GenericReference,id:"8c482c35-e674-4713-a1dd-63c3d13b611c",entityType:r.OutputMap,entityId:"64752080-ee0f-4cfe-9897-a0668f2b2aca"},SL={type:r.GenericReference,id:"c0a299cd-5869-4930-8cf0-90e3ceb8a903",entityType:r.VariableDeclaration,entityId:"46b2fe23-b417-4887-a35d-09b186679172"},OL={like:!1,id:"51c0c1df-2ee3-41df-ae52-ac512d8cf795",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:SL},CL={type:r.GenericReference,id:"do-math-func-return-two-called-by",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},_R={type:r.VariableDeclaration,id:"46b2fe23-b417-4887-a35d-09b186679172",version:1,name:"Total",description:null,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[CL],successCalls:[],errorCalls:[],dataType:OL,readsValue:AL,writesValues:[],internalCalls:[],parent:PL,x:0,y:0},MR={type:r.GenericReference,id:"6e4d776e-6af2-4321-b630-c78110fd677c",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},BL={type:r.GenericReference,id:"5b60955b-2486-40b6-bb24-ffd97ccd8902",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},wL={type:r.GenericReference,id:"1a49923f-bc6f-453f-a438-e74e5475c2a9",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},_L={type:r.GenericReference,id:"02bfde0a-b757-4072-9613-6e9c7c9a424a",entityType:r.ArgumentDeclaration,entityId:"d8895765-f705-457e-85fa-25d130926769"},NR={id:"928953b0-0e3f-4d8c-ae5a-84620b4b8c68",version:1,type:r.InputMap,declaration:Mo,name:null,description:null,readsValue:_L,defaultValue:null,index:0,parent:wL},ML={id:"64752080-ee0f-4cfe-9897-a0668f2b2aca",type:r.OutputMap,version:1,declaration:Vo,writesValues:[wR,_R],index:0,parent:BL},NL={type:r.GenericReference,id:"d235a7f6-07ff-4f35-98d2-8f42dd59cf9f",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},VL={id:"8827e8e9-9381-4ad7-8f61-5419c23c9136",type:r.GenericReference,entityType:r.VariableDeclaration,entityId:"72a338d8-0183-4ca2-8760-227517854595"},VR={id:"a5525249-0eb5-472b-97bc-5e4cc0d75aee",version:1,type:r.InputMap,declaration:No,name:null,description:null,readsValue:VL,defaultValue:null,index:1,parent:NL},$L={type:r.Operation,id:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e",declaration:wa,version:1,inputs:[NR,VR],outputs:[ML],calledByError:[],calledByEntry:[MR],calledBySuccess:[],process:null,successCalls:[BR,wR,_R],errorCalls:[],parent:MR,error:null,x:0,y:0},LL={type:r.GenericReference,id:"a2c40226-2270-4963-a865-c777ba79c551",entityType:r.DataType,entityId:"a350a9e9-25ee-477f-a83d-9e98ed2451662"},GL={id:"f47731b3-f278-4ab5-aeb2-24519c1119fb",type:r.GenericReference,entityId:"72a338d8-0183-4ca2-8760-227517854595",entityType:r.ArgumentDeclaration},$R={like:!1,id:"a350a9e9-25ee-477f-a83d-9e98ed2451662",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,isNullable:!1,asType:!1,defaultValue:{id:"do-math-func-argument-two-default-value-id",type:r.PrimitiveValue,version:1,value:1,name:A.Number,parent:LL,valueAsType:null,autogeneration:null},constant:!1,parent:GL},FL={type:r.GenericReference,id:"5f5d8dd0-7f3b-40cd-9f84-83d976887eaf",entityType:r.ArgumentDeclaration,entityId:"649bf0a4-6532-44aa-9818-a03d1c6564e9"},UL={type:r.GenericReference,id:"ca018d0f-a8b3-4c7e-a408-c8b372d04aff",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},xL={type:r.GenericReference,id:"do-math-func-var-called-by-ref",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},LR={type:r.VariableDeclaration,id:"72a338d8-0183-4ca2-8760-227517854595",version:1,name:"Z",description:null,dataType:$R,inputs:[],outputs:[],calledByError:[],calledByEntry:[xL],calledBySuccess:[],successCalls:[],errorCalls:[],readsValue:FL,writesValues:[VR],internalCalls:[],x:0,y:0,parent:UL},kL={entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b",type:r.GenericReference,id:"af0cf105-4075-425f-aecc-b25d3600fcc4"},jL={id:"649bf0a4-6532-44aa-9818-a03d1c6564e9",type:r.ArgumentDeclaration,version:1,name:"Z",description:"The number to add",dataType:$R,writesValues:[LR],required:!0,index:1,parent:kL},qL={type:r.GenericReference,id:"56953b5d-3e43-4dea-a62c-f3e868ba81bb",entityType:r.Project,entityId:Z},JL={id:"868defc8-5c95-48ed-942d-257e8b9b9b00",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},WL={type:r.GenericReference,id:"35167664-a793-49f1-9eaf-fb57eac30897",entityType:r.DataType,entityId:"55b12914-91b1-48b7-9a3e-9c5d0d2a2ec2"},HL={id:"d47ceef6-be6f-40f1-a7b3-c73c8d8a6c6a",type:r.GenericReference,entityId:"d8895765-f705-457e-85fa-25d130926769",entityType:r.ArgumentDeclaration},YL={like:!1,id:"55b12914-91b1-48b7-9a3e-9c5d0d2a2ec2",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,isNullable:!1,asType:!1,defaultValue:{id:"do-math-func-argument-one-default-value-id",type:r.PrimitiveValue,version:1,value:5,name:A.Number,parent:WL,valueAsType:null,autogeneration:null},constant:!1,parent:HL},zL={id:"d8895765-f705-457e-85fa-25d130926769",type:r.ArgumentDeclaration,version:1,name:"N",dataType:YL,description:"The number to add",writesValues:[NR],required:!0,index:0,parent:JL},ZL={type:r.FunctionDeclaration,id:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b",version:1,name:"Do math",description:"This function does math",inputs:[zL,jL],calls:[$L,LR],implements:null,index:null,collapsed:!1,returnStatements:[BR],private:!1,x:0,y:0,parent:qL},ht="replace-bank-account-in-company-func-declaration-id",Kl="company-entity-to-modify-arg-declaration-id",ec="account-number-to-create-arg-decl-id",Qr="company-variable-id",Kr="search-person-by-id-id",GR="new-bank-account-owner-arg-decl-id",FR="search-person-by-id-output-declaration-id",tc="search-person-by-id-output-entity-map-id",ta="person-not-empty-condition-id",Bs="create-new-bank-account-instance-operation-id",UR="create-new-bank-account-instance-operation-output-entity-map-id",xR="company-bank-account-output-map-id",nc="old-bank-account-var-declaration-id",kR="old-bank-account-var-instance-id",jR="company-variable-instance-id",rc="delete-bank-account-internal-call-id",na="new-bank-account-data-variable-declaration-id",XL={type:r.GenericReference,id:"company-variable-instance-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},QL={type:r.GenericReference,id:"company-variable-instance-called-by-ref-id",entityType:r.InternalCall,entityId:rc},KL={type:r.GenericReference,id:"company-variable-instance-declaration-ref-id",entityType:r.VariableDeclaration,entityId:Qr},eG={type:r.GenericReference,id:"bank-account-input-map-parent-ref-id",entityType:r.VariableInstance,entityId:jR},tG={type:r.GenericReference,id:"bank-account-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:UR},qR={type:r.InputMap,id:"bank-account-input-map-id",version:1,readsValue:tG,declaration:Bl,name:null,description:null,index:0,defaultValue:null,parent:eG},nG={type:r.VariableInstance,id:jR,version:1,declaration:KL,inputs:[qR],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[QL],successCalls:[],errorCalls:[],internalCalls:[],parent:XL,readsValue:null,writesValues:[],x:0,y:0},rG={type:r.GenericReference,id:"bank-account-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:Qr},iG={type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,id:"bank-account-variable-data-type-id",version:1,entity:Yr,asType:!1,isList:!1,isNullable:!1,constant:!1,like:!1,defaultValue:null,parent:rG},aG={type:r.GenericReference,id:"bank-account-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:xR},sG={type:r.GenericReference,id:"bank-account-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},oG={type:r.GenericReference,id:"bank-account-variable-called-by-ref-id",entityType:r.VariableDeclaration,entityId:Qr},lG={type:r.GenericReference,id:"delete-bank-account-internal-call-called-by-ref-id",entityType:r.Operation,entityId:Bs};r.GenericReference,r.VariableInstance;const cG={type:r.GenericReference,id:"delete-bank-account-internal-call-called-by-ref-two-id",entityType:r.VariableDeclaration,entityId:nc},dG={type:r.GenericReference,id:"old-bank-account-variable-trigger-delete-decl-ref-id",entityType:r.VariableDeclaration,entityId:nc},uG={type:r.GenericReference,id:"bank-account-variable-parent-ref-two-id",entityType:r.FunctionDeclaration,entityId:ht},pG={type:r.GenericReference,id:"old-bank-account-variable-trigger-delete-internal-call-ref-id",entityType:r.InternalCall,entityId:rc},yG={type:r.VariableInstance,id:kR,version:1,declaration:dG,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],internalCalls:[pG],errorCalls:[],parent:uG,readsValue:null,writesValues:[],x:0,y:0},JR={process:null,type:r.InternalCall,id:rc,version:1,declaration:tl,index:0,successCalls:[nG],errorCalls:[],inputs:[],outputs:[],error:null,calledByError:[],calledByEntry:[],calledBySuccess:[lG,cG],parent:yG},WR={type:r.VariableDeclaration,id:nc,version:1,name:"Old bank account",description:"The existing bank account that needs to be replaced in the company entity",dataType:iG,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[oG],successCalls:[JR],internalCalls:[],errorCalls:[],parent:sG,readsValue:aG,writesValues:[],x:0,y:0},hG={type:r.GenericReference,id:"company-variable-declaration-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:Qr},fG={type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,id:"company-variable-declaration-data-type-id",version:1,entity:gt,asType:!1,isList:!1,isNullable:!1,like:!1,constant:!1,defaultValue:null,parent:hG},mG={type:r.GenericReference,id:"company-variable-declaration-reads-value-ref-id",entityType:r.ArgumentDeclaration,entityId:Kl},TG={type:r.GenericReference,id:"company-variable-declaration-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},EG={type:r.GenericReference,id:"company-variable-declaration-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:ht},RG={type:r.GenericReference,id:"company-bank-account-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Qr},bG={id:xR,version:1,type:r.OutputMap,declaration:Bl,index:0,parent:RG,writesValues:[WR]},HR={type:r.VariableDeclaration,id:Qr,version:1,name:"Company",description:"The company entity that was passed as an argument to the parent function",dataType:fG,inputs:[],outputs:[bG],calledByError:[],calledByEntry:[EG],calledBySuccess:[],successCalls:[WR],errorCalls:[],parent:TG,internalCalls:[],readsValue:mG,writesValues:[],x:0,y:0},gG={type:r.GenericReference,id:"create-new-bank-account-account-owner-dynamic-input-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:na},vG={id:"create-new-bank-account-account-owner-dynamic-input-map-reads-value-ref-id",type:r.GenericReference,entityType:r.OutputMap,entityId:tc},YR={id:"create-new-bank-account-account-owner-dynamic-input-map-id",version:1,type:r.InputMap,declaration:null,name:"Account owner",description:null,readsValue:vG,index:1,defaultValue:null,parent:gG},IG={id:"create-new-bank-account-account-number-dynamic-input-map-reads-value-ref-id",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:ec},DG={type:r.GenericReference,id:"create-new-bank-account-account-number-dynamic-input-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:na},zR={id:"create-new-bank-account-account-number-dynamic-input-map-id",version:1,type:r.InputMap,declaration:null,name:"Account number",description:null,readsValue:IG,defaultValue:null,index:0,parent:DG},ZR={type:r.GenericReference,id:"create-new-bank-account-instance-operation-entity-to-create-input-map-parent-ref-id",entityType:r.Operation,entityId:Bs},PG={id:"create-new-bank-account-instance-operation-entity-to-create-input-map-id",version:1,type:r.InputMap,declaration:Xn.fixedArguments[0],name:null,description:null,index:0,readsValue:null,defaultValue:{type:r.PrimitiveValue,name:A.EntityTemplate,value:null,valueAsType:Yr,autogeneration:null},parent:ZR},AG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-entity-data-input-map-reads-value-ref-id",entityType:r.VariableDeclaration,entityId:na},XR={id:"create-new-bank-account-instance-operation-entity-data-input-map-id",version:1,type:r.InputMap,declaration:Xn.fixedArguments[1],name:null,description:null,index:1,readsValue:AG,defaultValue:null,parent:ZR},SG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-output-entity-map-parent-ref-id",entityType:r.Operation,entityId:Bs},OG={id:UR,version:1,type:r.OutputMap,declaration:Xn.fixedReturns[0],index:0,writesValues:[qR],parent:SG},CG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-called-by-ref-id",entityType:r.Condition,entityId:ta},BG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-called-by-ref-id",entityType:r.VariableDeclaration,entityId:na},wG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},QR={process:null,id:Bs,type:r.Operation,version:1,declaration:Xn,inputs:[PG,XR],error:null,outputs:[OG],successCalls:[JR],errorCalls:[],calledByError:[],calledByEntry:[],calledBySuccess:[BG,CG],parent:wG,x:0,y:0},_G={type:r.GenericReference,id:"new-bank-account-data-variable-declaration-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},MG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-called-by-ref-id",entityType:r.Condition,entityId:ta},NG={id:na,type:r.VariableDeclaration,version:1,inputs:[zR,YR],dataType:null,name:"New bank Account's data",description:null,readsValue:null,outputs:[],writesValues:[XR],successCalls:[QR],errorCalls:[],internalCalls:[],calledByError:[],calledBySuccess:[MG],calledByEntry:[],x:0,y:0,parent:_G},VG={id:"person-not-found-thrown-error-datatype-default-value-parent-ref-id",type:r.GenericReference,entityId:"person-not-found-thrown-error-datatype-id",entityType:r.DataType},$G={id:"person-not-found-thrown-error-datatype-parent-ref-id",type:r.GenericReference,entityId:"person-not-found-thrown-error-id",entityType:r.ReturnDeclaration};r.DataType,r.PrimitiveValue,A.String;const LG={id:"person-not-found-thrown-error-parent-ref-id",type:r.GenericReference,entityId:"person-not-found-error-return-statement-id",entityType:r.ReturnStatement},GG={isError:!0,id:"person-not-found-thrown-error-id",type:r.ReturnDeclaration,version:1,dataType:null,name:"Person not found error",description:"If the person entity was not found this error is outputted",parent:LG,required:!0,index:0,readsValue:null},FG={id:"person-not-found-error-return-statement-called-by-ref-id",type:r.GenericReference,entityId:ta,entityType:r.Condition},UG={id:"person-not-found-error-return-statement-parent-ref-id",type:r.GenericReference,entityId:ht,entityType:r.FunctionDeclaration},xG={id:"person-not-found-error-return-statement-id",type:r.ReturnStatement,version:1,throws:GG,outputs:[],calledBySuccess:[],calledByError:[FG],calledByEntry:[],x:0,y:0,parent:UG},kG={type:r.GenericReference,id:"person-not-empty-condition-called-by-ref-id",entityType:r.Search,entityId:Kr},jG={type:r.GenericReference,id:"person-not-empty-condition-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},qG={type:r.GenericReference,id:"person-entity-to-check-map-reads-value-ref-id",entityType:r.OutputMap,entityId:tc},JG={type:r.GenericReference,id:"person-not-empty-condition-ref-two-id",entityType:r.Condition,entityId:ta},KR={id:"person-entity-to-check-map-id",version:1,type:r.InputMap,declaration:er.fixedArguments[0],name:null,description:null,readsValue:qG,index:0,defaultValue:null,parent:JG},WG={type:r.Condition,id:ta,version:1,declaration:er,inputs:[KR],calledByError:[],calledByEntry:[],calledBySuccess:[kG],successCalls:[NG,QR],errorCalls:[xG],x:0,y:0,parent:jG},HG={type:r.GenericReference,id:"search-person-by-id-output-entity-declaration-datatype-parent-ref-id",entityType:r.ValueDescriptor,entityId:FR},YG={like:!1,id:"search-person-by-id-output-entity-declaration-datatype-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,isList:!1,constant:!1,asType:!1,isNullable:!1,entity:pt,defaultValue:null,parent:HG},zG={type:r.GenericReference,id:"search-person-by-id-output-entity-declaration-parent-ref-id",entityType:r.Search,entityId:Kr},eb={id:FR,type:r.ValueDescriptor,version:1,dataType:YG,name:"Found person",description:"The person entity that was found",parent:zG,required:!0,index:0},ZG={type:r.GenericReference,id:"search-person-by-id-output-entity-map-parent-ref-id",entityType:r.Search,entityId:Kr},XG={type:r.OutputMap,id:tc,version:1,declaration:eb,parent:ZG,writesValues:[KR,YR],index:0},QG={id:"search-person-by-id-input-declaration-datatype-parent-ref-id",type:r.GenericReference,entityId:"search-person-by-id-input-declaration-id",entityType:r.ArgumentDeclaration};r.DataType;const KG={type:r.GenericReference,id:"search-person-by-id-input-declaration-parent-ref-id",entityType:r.Search,entityId:Kr},tb={id:"search-person-by-id-input-declaration-id",type:r.ArgumentDeclaration,version:1,dataType:null,name:"Person ID",description:"The unique identifier (ID) property of the person entity",index:0,required:!0,parent:KG,writesValues:[]},eF={type:r.GenericReference,id:"search-person-by-id-input-map-parent-ref-id",entityType:r.Search,entityId:Kr},tF={id:"search-person-by-id-input-map-reads-value-ref-id",type:r.GenericReference,entityId:GR,entityType:r.ArgumentDeclaration},nb={type:r.InputMap,id:"search-person-by-id-input-map",version:1,declaration:tb,name:null,description:null,readsValue:tF,defaultValue:null,parent:eF,index:0},nF={from:{name:"c9bc312a-10d3-48a7-9ab4-ea483a9e2416"},items:[{name:"*"}],where:[{name:"id",value:"{{dynamic_value_1}}"}]},rF={type:r.GenericReference,id:"search-person-by-id-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},iF={type:r.GenericReference,id:"search-person-by-id-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:ht},aF={type:r.Search,id:Kr,version:1,name:"Search person by ID",description:"Searches for a person entity given the UUID",query:nF,inputsDeclarations:[tb],inputs:[nb],outputsDeclarations:[eb],outputs:[XG],calledByError:[],calledByEntry:[iF],calledBySuccess:[],error:null,successCalls:[WG],errorCalls:[],parent:rF,x:0,y:0};r.GenericReference,r.DataType;const sF={id:"account-number-to-create-arg-decl-data-type-parent-ref-id",type:r.GenericReference,entityId:ec,entityType:r.ArgumentDeclaration},oF={like:!1,id:"account-number-to-create-arg-decl-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:sF},lF={entityType:r.FunctionDeclaration,entityId:ht,type:r.GenericReference,id:"account-number-to-create-arg-decl-parent-ref-id"},cF={id:ec,type:r.ArgumentDeclaration,version:1,name:"Account number",description:"The account number of the new bank account entity",dataType:oF,writesValues:[zR],required:!0,index:1,parent:lF};r.GenericReference,r.DataType;const dF={id:"new-bank-account-owner-arg-decl-data-type-parent-ref-id",type:r.GenericReference,entityId:"new-bank-account-owner-arg-decl-id",entityType:r.ArgumentDeclaration},uF={like:!1,id:"new-bank-account-owner-arg-decl-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ba,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:dF},pF={entityType:r.FunctionDeclaration,entityId:ht,type:r.GenericReference,id:"new-bank-account-owner-arg-decl-parent-ref-id"},yF={id:GR,type:r.ArgumentDeclaration,version:1,name:"New account owner ID",description:"If it has changed, this is the new person entity, that owns of the bank account",dataType:uF,writesValues:[nb],required:!1,index:1,parent:pF},hF={type:r.GenericReference,id:"replace-bank-account-in-company-parent-ref",entityType:r.Project,entityId:Z},fF={type:r.GenericReference,id:"company-entity-to-modify-parent-ref",entityType:r.FunctionDeclaration,entityId:ht};r.GenericReference,r.DataType;const mF={id:"d47ceef6-be6f-40f1-a7b3-c73c8d8a6c6a",type:r.GenericReference,entityId:Kl,entityType:r.ArgumentDeclaration},TF={like:!1,id:"company-entity-to-modify-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:mF},EF={id:Kl,type:r.ArgumentDeclaration,version:1,name:"Company",dataType:TF,description:"The company to replace the bank account for",writesValues:[HR],required:!0,index:0,parent:fF},RF={type:r.FunctionDeclaration,id:ht,version:1,name:"Replace bank account",description:"This action takes an existing company and data to create a new bank account entity. It then creates a bank account, deletes the old one, and updates the company with the new bank account",inputs:[EF,cF,yF],index:null,implements:null,calls:[aF,HR],collapsed:!1,returnStatements:[],private:!1,x:0,y:0,parent:hF},bF={type:r.GenericReference,id:"e0a937bd-3a85-4037-a973-916985b9f94b",entityType:r.Project,entityId:"7268bc97-c0e6-4d88-b37e-d3241b5f77a6"},gF={type:r.FunctionDeclaration,version:1,id:"6bedb217-f844-4332-af72-9626b2a32511",name:"Some library main function",description:null,inputs:[],calls:[],implements:null,collapsed:!0,index:null,returnStatements:[],private:!1,parent:bF,x:0,y:0},vF={type:r.GenericReference,id:"948e6869-ae5b-4914-bea0-b9f02ad6a014",entityType:r.Project,entityId:"23b23d8b-1929-4505-a350-745c8550e731"},IF={type:r.GenericReference,id:"f3d6f2c6-1b3e-4e9d-8c9d-5b5b9f0b8d9c",entityType:r.Project,entityId:"7268bc97-c0e6-4d88-b37e-d3241b5f77a6"},DF={type:r.InstalledProject,version:1,id:"7268bc97-c0e6-4d88-b37e-d3241b5f77a6",name:"Third Party Installed Project",description:null,functions:[gF],events:[],implements:IF,parent:vF,x:0,y:0},ic="iterate-over-list-loop-id",rb="iterate-over-list-loop-body-id",ib="iterate-over-list-loop-body-current-iteration-argument-declaration-id",PF={type:r.GenericReference,id:"iterate-over-list-loop-body-current-iteration-argument-declaration-data-type-parent-ref-id",entityId:ib,entityType:r.ArgumentDeclaration},AF={like:!1,id:"iterate-over-list-loop-body-current-iteration-argument-declaration-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,defaultValue:null,entity:null,isList:!1,isNullable:!1,asType:!1,constant:!1,parent:PF},SF={id:"iterate-over-list-loop-body-current-iteration-argument-declaration-parent-ref-id",type:r.GenericReference,entityId:rb,entityType:r.FunctionDeclaration},OF={id:ib,type:r.ArgumentDeclaration,version:1,name:"Current value",description:"The current value being processed.",dataType:AF,required:!0,index:0,writesValues:[],parent:SF},CF={id:"iterate-over-list-loop-body-parent-ref-id",type:r.GenericReference,entityId:ic,entityType:r.Loop},BF={id:rb,type:r.FunctionDeclaration,version:1,name:"Iteration logic trigger",description:"This function is called once for each entity in the list.",inputs:[OF],calls:[],implements:null,collapsed:!1,returnStatements:[],private:!1,index:0,x:0,y:0,parent:CF},wF={id:"iterate-over-list-loop-iteration-list-input-map-parent-ref-id",type:r.GenericReference,entityId:ic,entityType:r.Loop},_F={id:"iterate-over-list-loop-iteration-list-input-map-id",type:r.InputMap,version:1,name:null,description:null,declaration:Kn.fixedArguments[0],defaultValue:null,readsValue:null,index:0,parent:wF},MF={id:"iterate-over-list-loop-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},NF={id:ic,type:r.Loop,version:1,declaration:Kn,inputs:[_F],successCalls:[],errorCalls:[],outputsDeclarations:[],outputs:[],process:null,body:BF,calledByError:[],calledByEntry:[],calledBySuccess:[],breakStatements:[],continueStatements:[],error:null,x:0,y:0,parent:MF};var ac=(n=>(n.EQ="eq",n.NEQ="neq",n.GT="gt",n.GTE="gte",n.LT="lt",n.LTE="lte",n.LIKE="like",n.ILIKE="ilike",n))(ac||{}),ab=(n=>(n.COUNT="count",n.SUM="sum",n.AVG="avg",n.MIN="min",n.MAX="max",n))(ab||{});const VF={from:{name:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},items:{from:{name:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},items:[{function:{name:ab.COUNT,items:["f8310850-a87e-405c-b182-4f1d5fa49240"]},alias:"employee_count"}],where:[{name:"80c86e1b-caca-4ba5-9b1f-38f72d10e4a3",operation:ac.NEQ,value:null}]},where:[{name:"employee_count",operation:ac.GT,value:1}]},$F={id:"find-companies-with-multiple-employees-and-bank-account-search-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},LF={id:"find-companies-with-multiple-employees-and-bank-account-search-companies-list-output-declaration-parent-ref-id",type:r.GenericReference,entityId:"find-companies-with-multiple-employees-and-bank-account",entityType:r.Search},sb={id:"find-companies-with-multiple-employees-and-bank-account-search-companies-list-output-declaration-id",type:r.ValueDescriptor,version:1,name:"companies",description:"List of companies with multiple employees and an existing bank account",dataType:null,required:!0,index:0,parent:LF},GF={id:"find-companies-with-multiple-employees-and-bank-account-search-companies-list-output-parent-ref-id",type:r.GenericReference,entityId:"find-companies-with-multiple-employees-and-bank-account",entityType:r.Search},FF={id:"find-companies-with-multiple-employees-and-bank-account-search-companies-list-output-id",type:r.OutputMap,version:1,declaration:sb,writesValues:[],index:0,parent:GF},UF={id:"find-companies-with-multiple-employees-and-bank-account",type:r.Search,version:1,name:"Find companies with multiple employees and a bank account",description:"This search statement finds companies with multiple employees and an existing bank account",inputsDeclarations:[],outputsDeclarations:[sb],inputs:[],outputs:[FF],query:VF,successCalls:[],errorCalls:[],error:null,calledByError:[],calledByEntry:[],calledBySuccess:[],x:0,y:0,parent:$F},ei="random-company-employee-test-variable-id",sc="manager-global-variable-id",ob="global-user-instance-id",lr="employee-mapped-dto-variable-id",oc="employee-mapped-dto-variable-instance-id",lb="random-employee-id-output-map-id",cb="random-employee-birth-date-output-map-id",db="random-employee-department-output-map-id",ub="random-employee-manager-output-map-id",pb="manager-global-id-output-map-id",yb="global-user-instance-id-output-map-id",xF="employee-mapped-dto-requester-id-input-map-id",hb="employee-mapped-dto-now-timestamp-input-map-id",kF="employee-mapped-dto-id-input-map-id",jF="employee-mapped-dto-birth-date-input-map-id",qF="employee-mapped-dto-department-input-map-id",JF="employee-mapped-dto-manager-input-map-id",WF={type:r.GenericReference,id:"employee-mapped-dto-manager-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:pb},HF={type:r.GenericReference,id:"employee-mapped-dto-manager-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:lr},fb={id:JF,type:r.InputMap,version:1,declaration:null,name:"manager_id",description:null,defaultValue:null,index:4,readsValue:WF,parent:HF},YF={type:r.GenericReference,id:"employee-mapped-dto-department-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:db},zF={type:r.GenericReference,id:"employee-mapped-dto-department-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:lr},mb={id:qF,type:r.InputMap,version:1,declaration:null,name:"department_name",description:null,defaultValue:null,index:3,readsValue:YF,parent:zF},ZF={type:r.GenericReference,id:"employee-mapped-dto-birth-date-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:cb},XF={type:r.GenericReference,id:"employee-mapped-dto-birth-date-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:lr},Tb={id:jF,type:r.InputMap,version:1,declaration:null,name:"birth_date",description:null,defaultValue:null,index:2,readsValue:ZF,parent:XF},QF={type:r.GenericReference,id:"employee-mapped-dto-id-output-map-reads-value-ref-id",entityType:r.OutputMap,entityId:lb},KF={type:r.GenericReference,id:"employee-mapped-dto-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:lr},Eb={id:kF,type:r.InputMap,version:1,declaration:null,name:"id",description:"The ID of the employee",defaultValue:null,index:1,readsValue:QF,parent:KF},e4={type:r.GenericReference,id:"employee-mapped-dto-requester-id-output-map-reads-value-ref-id",entityType:r.OutputMap,entityId:yb},t4={type:r.GenericReference,id:"employee-mapped-dto-requester-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:lr},Rb={id:xF,type:r.InputMap,version:1,declaration:null,name:"requester_id",description:"The ID of the current user making the request",defaultValue:null,index:0,readsValue:e4,parent:t4},n4={type:r.GenericReference,id:"manager-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:sc},r4={id:pb,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[fb],parent:n4},i4={type:r.GenericReference,id:"manager-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:sc},a4={like:!1,id:"manager-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ct,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:i4,defaultValue:null},s4={type:r.GenericReference,id:"manager-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:ub},o4={type:r.GenericReference,id:"manager-variable-parent-ref-id",entityType:r.Project,entityId:Z},bb={id:sc,type:r.VariableDeclaration,version:1,name:"Manager",dataType:a4,description:"A variable holding an inherited manager for testing purposes",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],readsValue:s4,writesValues:[],inputs:[],outputs:[r4],internalCalls:[],parent:o4,x:0,y:0},l4={type:r.GenericReference,id:"random-company-employee-manager-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:ei},c4={id:ub,type:r.OutputMap,version:1,declaration:Ct.properties[2],index:3,writesValues:[bb],parent:l4},d4={type:r.GenericReference,id:"random-company-employee-department-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:ei},u4={id:db,type:r.OutputMap,version:1,declaration:Ct.properties[0],index:2,writesValues:[mb],parent:d4},p4={type:r.GenericReference,id:"random-company-employee-birth-date-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:ei},y4={id:cb,type:r.OutputMap,version:1,declaration:pt.properties[1],index:1,writesValues:[Tb],parent:p4},h4={type:r.GenericReference,id:"random-company-employee-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:ei},f4={id:lb,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[Eb],parent:h4},m4={type:r.GenericReference,id:"random-company-employee-test-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:ei},T4={like:!1,id:"random-company-employee-test-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ct,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:m4,defaultValue:null},E4={type:r.GenericReference,id:"random-company-employee-test-variable-parent-ref-id",entityType:r.Project,entityId:Z},R4={id:ei,type:r.VariableDeclaration,version:1,name:"Company employee",dataType:T4,description:"A variable holding a random company employee for testing purposes",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],readsValue:null,writesValues:[],inputs:[],outputs:[f4,y4,u4,c4],internalCalls:[],parent:E4,x:0,y:0},b4={type:r.GenericReference,id:"employee-mapped-dto-variable-instance-now-timestamp-input-map-default-value-parent-ref-id",entityType:r.InputMap,entityId:hb},g4={type:r.PrimitiveValue,id:"employee-mapped-dto-variable-instance-now-timestamp-input-map-default-value-id",name:A.Date,version:1,valueAsType:null,value:null,autogeneration:{type:qe.CurrentDateAndTime,rangeStart:null,rangeEnd:null},parent:b4},v4={type:r.GenericReference,id:"employee-mapped-dto-variable-instance-now-timestamp-input-map-parent-ref-id",entityType:r.VariableInstance,entityId:oc},I4={id:hb,type:r.InputMap,version:1,declaration:null,name:"now",description:"The current timestamp when the operation is executed",defaultValue:g4,index:5,readsValue:null,parent:v4},D4={type:r.GenericReference,id:"employee-mapped-dto-variable-instance-decl-ref-id",entityType:r.VariableDeclaration,entityId:lr},P4={type:r.GenericReference,id:"employee-mapped-dto-variable-instance-called-by-success-ref-id",entityType:r.VariableDeclaration,entityId:oc},A4={type:r.GenericReference,id:"employee-mapped-dto-variable-instance-parent-ref-id",entityType:r.Project,entityId:Z},S4={id:oc,type:r.VariableInstance,version:1,declaration:D4,calledByError:[],calledByEntry:[],calledBySuccess:[P4],successCalls:[],errorCalls:[],readsValue:null,writesValues:[],inputs:[I4],outputs:[],internalCalls:[],parent:A4,x:0,y:0},O4={type:r.GenericReference,id:"employee-mapped-dto-variable-parent-ref-id",entityType:r.Project,entityId:Z},C4={id:lr,type:r.VariableDeclaration,version:1,name:"Employee DTO",dataType:null,description:"A variable holding the data of a mapped employee DTO",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[S4],errorCalls:[],readsValue:null,writesValues:[],inputs:[Rb,Eb,Tb,mb,fb],outputs:[],internalCalls:[],parent:O4,x:0,y:0},B4={type:r.GenericReference,id:"0e63e617-f9d3-42e8-bde0-1bb0b1df7034",entityType:r.VariableDeclaration,entityId:Dl},w4={like:!1,id:"e75645ce-d3df-4f07-a897-ae9ef4d917fd",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:Al,version:1,asType:!1,isList:!1,isNullable:!1,constant:!1,parent:B4,defaultValue:null},_4={type:r.GenericReference,id:"e92a8ff5-3fef-4e0c-8d8f-92c930b2890b",entityType:r.Project,entityId:Z},gb={id:Dl,type:r.VariableDeclaration,version:1,name:"Current user",description:"The user that is currently logged in",dataType:w4,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],x:0,y:0,readsValue:null,writesValues:[],internalCalls:[],parent:_4},M4={type:r.GenericReference,id:"manager-variable-id-output-map-parent-ref-id",entityType:r.VariableInstance,entityId:ob},N4={id:yb,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[Rb],parent:M4},V4={type:r.GenericReference,id:"global-user-instance-parent-ref-id",entityType:r.Project,entityId:Z},$4={id:ob,type:r.VariableInstance,version:1,declaration:gb,calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],readsValue:null,writesValues:[],inputs:[],outputs:[N4],internalCalls:[],parent:V4,x:0,y:0},L4={type:r.GenericReference,id:"is-test-environment-variable-dcl-datatype-parent-ref-id",entityType:r.VariableDeclaration,entityId:Dl},G4={type:r.GenericReference,id:"is-test-environment-variable-dcl-datatype-default-value-parent-ref-id",entityType:r.DataType,entityId:"is-test-environment-variable-dcl-datatype-id"},F4={like:!1,id:"is-test-environment-variable-dcl-datatype-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:An,version:1,asType:!1,isList:!1,isNullable:!1,constant:!0,parent:L4,defaultValue:{id:"is-test-environment-variable-dcl-datatype-default-value-id",name:A.Boolean,version:1,value:null,type:r.PrimitiveValue,autogeneration:{type:qe.Random,rangeStart:null,rangeEnd:null},valueAsType:null,parent:G4}},U4={type:r.GenericReference,id:"is-test-environment-variable-dcl-main-project-ref-id",entityType:r.Project,entityId:Z},vb={id:"is-test-environment-variable-dcl-id",type:r.VariableDeclaration,version:1,name:"Is test envrioment",description:"Indicates whether the current environment is a test environment or not.",dataType:F4,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],x:0,y:0,readsValue:null,writesValues:[],internalCalls:[],parent:U4},x4={type:r.GenericReference,id:"is-test-environment-variable-instance-parent-ref-id",entityType:r.Project,entityId:Z},k4={id:"is-test-environment-variable-instance-id",type:r.VariableInstance,version:1,declaration:vb,calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],readsValue:null,writesValues:[],inputs:[],outputs:[],internalCalls:[],parent:x4,x:0,y:0},Ib={type:r.Project,id:Z,version:1,name:"Mocked project to compile",description:"This project is used to test all sorts of features and edge cases. It is not meant to be used in production. Or to have any functionality that makes sense",projects:[DF],entities:[Pl,Al,pt,C_,Ct,gs,MT,NT,Yr,Iw,gt,E_,mT,yA,gw],functions:[W$,sE,Jl,eL,lL,vE,Wl,wl,RF,jT,ZL],events:[lM],variableDeclarations:[vb,gb,Xl,R4,bb,C4],variableInstances:[k4,$4],conditions:[],operations:[Xr],functionCalls:[sN,h0],loops:[NF],searches:[UF]};var T=(n=>(n.Error="error",n.Warning="warning",n))(T||{}),D=(n=>(n.InvalidObjectStructure="invalid-object-structure",n.NameNotUniqueInScope="name-not-unique-in-scope",n.EmptyName="empty-name",n.MissingCaller="missing-caller",n.PropertyOverwrite="property-overwrite",n.MethodOverwrite="method-overwrite",n.NoOverlapWithImplementedSignature="no-overlap-with-implemented-signature",n.ReaderWriterIncompatibleDataType="reader-writer-incompatible-data-type",n.UnreachableEntity="unreachable-entity",n.InternalCallParentMissingDataType="internal-call-parent-missing-data-type",n.InternalCallParentDeclarationEntityInvalidType="internal-call-parent-declaration-entity-invalid-type",n.InternalCallDeclarationNotFoundInParentDatatypeEntity="internal-call-declaration-not-found-in-parent-datatype-entity",n.InternalCallDeclarationIsNotFunctionDeclaration="internal-call-declaration-is-not-function-declaration",n.InternalCallDeclarationNotInParentDatatypeEntity="internal-call-declaration-not-in-parent-datatype-entity",n))(D||{}),h=(n=>(n.RootReference="root-reference",n.ReferencedEntityNotFound="referenced-entity-not-found",n.EntityIdNotUnique="entity-id-not-unique",n.BuiltInEntityGenerated="built-in-entity-generated",n.BuiltInEntityUpdated="built-in-entity-updated",n.BuiltInEntityDeleted="built-in-entity-deleted",n.UnknownEntityType="unknown-entity-type",n.MissingTypeProperty="missing-type-property",n.MissingIdProperty="missing-id-property",n.BuiltInEntityParent="built-in-entity-parent",n.InvalidBuiltInEntityReference="invalid-built-in-entity-reference",n.RecommendedImplementAbstractEntityAction="recommended-implement-abstract-entity-action",n.RecommendedImplementOperationAction="recommended-implement-operation-action",n.RecommendedImplementFunctionCallAction="recommended-implement-function-call-action",n.RecommendedImplementVariableDeclarationAction="recommended-implement-variable-declaration-action",n.RecommendedImplementVariableInstanceAction="recommended-implement-variable-instance-action",n.RecommendedImplementConditionAction="recommended-implement-condition-action",n.InvalidReferenceObjectStructure="invalid-reference-object-structure",n.ContainsSingleButShouldBeReferenceList="contains-single-but-should-be-reference-list",n.ContainsListButShouldReferenceSingle="contains-list-but-should-reference-single",n.InvalidParentReference="invalid-parent-reference",n.InvalidImplementsReference="invalid-implements-reference",n.InvalidExtendsReference="invalid-extends-reference",n.InvalidGenerationActionPayload="invalid-generation-action-payload",n.InvalidReference="invalid-reference",n.InvalidInternalCallParentRelation="invalid-internal-call-parent-relation",n.InvalidUpdateEntityOperation="invalid-update-entity-operation",n.NewEntityWouldOverriteExisting="new-entity-would-overrite-existing",n.InvalidDownstreamPropertyOverride="invalid-downstream-property-override",n.UnrecognizedProperty="unrecognized-property",n.SelfReference="self-reference",n.DuplicateReference="duplicate-reference",n.CallerWithIncompatibleScope="caller-with-incompatible-scope",n.InvalidFunctionDeclarationForFunctionCall="invalid-function-declaration-for-function-call",n.InvalidInputMapDeclaration="invalid-input-map-declaration",n.InvalidActionDescriptorForOperation="invalid-action-descriptor-for-operation",n.InvalidActionDescriptorForCondition="invalid-action-descriptor-for-condition",n.InvalidActionDescriptorForLoop="invalid-action-descriptor-for-loop",n.InvalidInmutablePropertyOverride="invalid-inmutable-property-override",n.OutputOverwrite="output-overwrite",n.InputOverwrite="input-overwrite",n.IncompatibleScope="incompatible-scope",n.InvalidParentUpdate="invalid-parent-update",n.NonInteractiveEntityReferenced="non-interactive-entity-referenced",n.InvalidParentRelationType="invalid-parent-relation-type",n))(h||{}),_=(n=>(n.ScopeWithoutLogic="scope-without-logic",n.ExtendingAbstractEntity="extending-abstract-entity",n.ImplementingNonAbstractEntity="implementing-non-abstract-entity",n.AbstractEntityWithNonAbstractMethods="abstract-entity-with-non-abstract-methods",n.AbstractEntityWithNonAbstractProperties="abstract-entity-with-non-abstract-properties",n.StaticEntityWithNonStaticProperties="static-entity-with-non-static-properties",n.NonStaticPropertyInStaticEntity="non-static-property-in-static-entity",n.AbstractPropertyInNonAbstractEntity="abstract-property-in-non-abstract-entity",n.AbstractMethodInNonAbstractEntity="abstract-method-in-non-abstract-entity",n.IncorrectEntityImplementation="incorrect-entity-implementation",n.IncorrectMethodImplementation="incorrect-method-implementation",n.IncorrectPropertyImplementation="incorrect-property-implementation",n.PropertyImplementsNonAbstact="property-implements-non-abstract",n.NonStaticPropertyImplementsStatic="non-static-property-implements-static",n.StaticPropertyImplementsNonStatic="static-property-implements-non-static",n.PropertyImplementsIncompatibleType="property-implements-incompatible-type",n.MissingPropertyImplementation="missing-property-implementation",n.MissingMethodImplementation="missing-method-implementation",n.NoProperties="no-properties",n.ReadingFromIncompatibleType="reading-from-incompatible-type",n.WritingToIncompatibleType="writing-to-incompatible-type",n.InvalidPropertiesCombination="invalid-properties-combination",n.DisconnectedCallableEntity="disconnected-callable-entity",n.VariableReadsValueAndInternalCall="variable-reads-value-and-internal-call",n.VariableWritesValuesAndInternalCall="variable-writes-values-and-internal-call",n.VariableHasInputsAndInternalCall="variable-has-inputs-and-internal-calls",n.VariableHasOutputsAndInternalCall="variable-has-outputs-and-internal-call",n.VariableIsCalledAndHasInternalCall="variable-is-called-and-has-internal-call",n.VariableCallsOthersAndHasInternalCall="variable-calls-others-and-has-internal-call",n))(_||{});class E{constructor(e){c(this,"id");c(this,"message");c(this,"issue");c(this,"severity");c(this,"code");this.id=e.id,this.message=e.message,this.issue=e.issue,this.severity=e.severity,this.code=e.code}toEntityError(e){return this.code in D?new cr({id:this.id,message:this.message,issue:this.issue,severity:this.severity,code:this.code,entity:e}):null}}class cr{constructor(e){c(this,"id");c(this,"message");c(this,"issue");c(this,"severity");c(this,"code");c(this,"entity");this.id=e.id,this.message=e.message,this.issue=e.issue,this.severity=e.severity,this.code=e.code,this.entity=e.entity}clone(){return new cr({id:this.id,message:this.message,issue:this.issue,severity:this.severity,code:this.code,entity:this.entity})}}function j4(n){const e=new Set;return n.filter(t=>e.has(t.id)?!1:(e.add(t.id),!0))}function H(n){const e=n.entity.errors.find(i=>i.id===n.id);return e?{new:!1,error:e}:{new:!0,error:new cr(n)}}function q4(n,e){const t=new Map;return n.forEach(i=>{t.set(i.id,i)}),e.forEach(i=>{t.set(i.id,i)}),Array.from(t.values())}function ne(n,e){const t=[];return e.forEach(i=>{const a=n.find(s=>s.id===i.id);a?t.push(a):t.push(i)}),t}const ra=d.union([d.string(),d.number(),d.boolean(),d.date()]),Db=d.enum([qe.CurrentDateAndTime,qe.Random,qe.Unique]),ws=d.object({type:Db,rangeStart:ra.nullable(),rangeEnd:ra.nullable()}),ia=ws.extend({type:d.literal(qe.Random),rangeStart:ra,rangeEnd:ra}),lc=ws.extend({type:d.literal(qe.Unique),rangeStart:d.null(),rangeEnd:d.null()}),Pb=ws.extend({type:d.literal(qe.CurrentDateAndTime),rangeStart:d.null(),rangeEnd:d.null()}),_s=ia.extend({rangeStart:d.number().nullable(),rangeEnd:d.number().nullable()}),Ab=_s.extend({rangeStart:d.number(),rangeEnd:d.null()}),Sb=_s.extend({rangeStart:d.null(),rangeEnd:d.number()}),Ob=_s.extend({rangeStart:d.number(),rangeEnd:d.number()}),Ms=ia.extend({rangeStart:d.number().nullable(),rangeEnd:d.number().nullable()}),Cb=Ms.extend({rangeStart:d.number(),rangeEnd:d.null()}),Bb=Ms.extend({rangeStart:d.null(),rangeEnd:d.number()}),wb=Ms.extend({rangeStart:d.number(),rangeEnd:d.number()}),Ns=ia.extend({rangeStart:d.date().nullable(),rangeEnd:d.date().nullable()}),_b=Ns.extend({rangeStart:d.date(),rangeEnd:d.null()}),Mb=Ns.extend({rangeStart:d.null(),rangeEnd:d.date()}),Nb=Ns.extend({rangeStart:d.date(),rangeEnd:d.date()}),cc=ia.extend({rangeStart:d.null(),rangeEnd:d.null()}),dc=d.union([Cb,Bb,wb]),uc=d.union([Ab,Sb,Ob]),pc=d.union([_b,Mb,Nb,Pb]),yc=d.union([dc,uc,pc,lc,cc]);function aa(){return d.union([d.object({type:d.literal(r.ValueDescriptor)}),d.record(d.string(),d.any())])}function Vb(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ValueDescriptor)})}function hc(){return d.object({id:d.string(),type:d.literal(r.ValueDescriptor),name:d.string(),required:d.boolean()})}function J4(){return hc().merge(d.object({version:d.number(),index:d.number()}))}function W4(){return hc().merge(d.object({}))}function H4(){return d.object({dataType:mn(),parent:Gn()})}function Y4(){return J4().merge(H4())}function Vs(){return d.union([d.object({type:d.literal(r.PrimitiveEntity)}),d.record(d.string(),d.any())])}function $s(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.PrimitiveEntity)})}function Ls(){return d.object({id:d.string(),type:d.literal(r.PrimitiveEntity),name:d.string(),description:d.string().nullable(),static:d.boolean(),abstract:d.boolean()})}function z4(){return Ls().merge(d.object({version:d.number()}))}function Z4(){return Ls().merge(d.object({}))}function X4(){return d.object({properties:d.array(dr()),methods:d.array(Bt()),abstractMethods:d.array(tn()),extends:d.array(d.union([Vs(),ti()]))})}function Q4(){return z4().merge(X4())}function dr(){return d.union([d.object({type:d.literal(r.Property)}),d.record(d.string(),d.any())])}function $b(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.Property)})}function fc(){return d.object({id:d.string(),type:d.literal(r.Property),name:d.string(),description:d.string().nullable(),private:d.boolean(),static:d.boolean(),required:d.boolean(),abstract:d.boolean()})}function K4(){return fc().merge(d.object({version:d.number(),index:d.number()}))}function eU(){return fc().merge(d.object({}))}function tU(){return d.object({dataType:mn(),implements:dr().nullable(),parent:d.union([hr(),$s(),Gs()])})}function nU(){return K4().merge(tU())}function rU(){return d.enum([V.CRON_JOB,V.EXECUTION,V.HTTP_ENDPOINT,V.PERSISTED_ENTITY,V.RELATIONAL_DATABASE])}function ti(){return d.union([d.object({type:d.literal(r.BuiltInBaseEntity)}),d.record(d.string(),d.any())])}function Gs(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.BuiltInBaseEntity)})}function mc(){return d.object({id:d.string(),version:d.number(),type:d.literal(r.BuiltInBaseEntity),name:rU(),description:d.string().nullable(),abstract:d.boolean(),static:d.boolean()})}function iU(){return mc()}function aU(){return mc().merge(d.object({}))}function sU(){return d.object({properties:d.array(dr()),methods:d.array(Bt()),abstractMethods:d.array(tn()),extends:d.array(d.union([ti(),Vs()]))})}function oU(){return iU().merge(sU())}function Lb(){return d.enum([U.Dynamic,U.Fixed,U.None])}function tn(){return d.union([d.object({type:d.literal(r.ActionDescriptor)}),d.record(d.string(),d.any())])}function Gn(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ActionDescriptor)})}function Fs(){return d.object({id:d.string(),type:d.literal(r.ActionDescriptor),name:d.string(),description:d.string().nullable(),argumentsType:Lb(),returnsType:Lb()})}function lU(){return Fs().merge(d.object({version:d.number()}))}function cU(){return Fs().merge(d.object({}))}function dU(){return d.object({fixedArguments:d.array(aa()),fixedReturns:d.array(aa()),dynamicArgumentTypes:mn().nullable(),dynamicReturnTypes:mn().nullable(),parent:d.union([vt(),hr(),Gs(),$s()]).nullable()})}function Gb(){return lU().merge(dU())}function ni(){return d.union([d.object({type:d.literal(r.Loop)}),d.record(d.string(),d.any())])}function nn(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.Loop)})}function Fb(){return d.object({id:d.string(),type:d.literal(r.Loop)})}function uU(){return Fb().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function pU(){return Fb().merge(d.object({declaration:d.union([d.string(),Bt()])}))}function yU(){return d.object({calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),declaration:tn(),inputs:d.array(Jt()),outputs:d.array(ft()),outputsDeclarations:d.array(aa()),successCalls:d.array(We()),errorCalls:d.array(We()),error:ft(),body:Bt(),parent:d.union([En(),vt()]),breakStatements:d.array(si()),continueStatements:d.array(ri())})}function hU(){return uU().merge(yU())}function ri(){return d.union([d.object({type:d.literal(r.ContinueStatement)}),d.record(d.string(),d.any())])}function ii(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ContinueStatement)})}function Tc(){return d.object({id:d.string(),type:d.literal(r.ContinueStatement)})}function fU(){return Tc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function mU(){return Tc().merge(d.object({}))}function TU(){return d.object({calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),outputs:d.array(hn()),throws:d.optional(hn()),parent:nn()})}function EU(){return fU().merge(TU())}function ur(){return d.union([d.object({type:d.literal(r.ReturnStatement)}),d.record(d.string(),d.any())])}function ai(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ReturnStatement)})}function Ec(){return d.object({id:d.string(),type:d.literal(r.ReturnStatement)})}function RU(){return Ec().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function bU(){return Ec().merge(d.object({}))}function gU(){return d.object({calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),outputs:d.array(hn()),throws:d.optional(hn()),parent:En()})}function vU(){return RU().merge(gU())}function hn(){return d.union([d.object({type:d.literal(r.ReturnDeclaration)}),d.record(d.string(),d.any())])}function Ub(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ReturnDeclaration)})}function Rc(){return d.object({id:d.string(),type:d.literal(r.ReturnDeclaration),name:d.string(),description:d.string().nullable(),isError:d.boolean()})}function IU(){return Rc().merge(d.object({version:d.number(),index:d.number()}))}function DU(){return Rc().merge(d.object({}))}function PU(){return d.object({dataType:mn().nullable(),readsValue:ua().nullable(),parent:d.union([ai(),Gn(),fn(),ii()])})}function AU(){return IU().merge(PU())}function si(){return d.union([d.object({type:d.literal(r.BreakStatement)}),d.record(d.string(),d.any())])}function fn(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.BreakStatement)})}function bc(){return d.object({id:d.string(),type:d.literal(r.BreakStatement)})}function SU(){return bc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function OU(){return bc().merge(d.object({}))}function CU(){return d.object({calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),outputs:d.array(hn()),throws:d.optional(hn()),parent:nn()})}function BU(){return SU().merge(CU())}function ft(){return d.union([d.object({type:d.literal(r.OutputMap)}),d.record(d.string(),d.any())])}function gc(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.OutputMap)})}function vc(){return d.object({id:d.string(),type:d.literal(r.OutputMap)})}function wU(){return vc().merge(d.object({version:d.number(),index:d.number()}))}function _U(){return vc().merge(d.object({}))}function MU(){return d.object({writesValues:d.array(Tn()),declaration:d.union([hn(),dr()]),parent:d.union([de(),nn(),fn()])})}function NU(){return wU().merge(MU())}function oi(){return d.union([d.object({type:d.literal(r.FunctionCall)}),d.record(d.string(),d.any())])}function sa(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.FunctionCall)})}function Ic(){return d.object({id:d.string(),type:d.literal(r.FunctionCall)})}function VU(){return Ic().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function $U(){return Ic().merge(d.object({}))}function LU(){return d.object({successCalls:d.array(We()),errorCalls:d.array(We()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),writesValues:d.array(Tn()),declaration:Bt(),inputs:d.array(Jt()),outputs:d.array(ft()),error:d.optional(ft()),parent:d.union([En(),vt()])})}function GU(){return VU().merge(LU())}function FU(){return d.enum([_e.Equal,_e.NotEqual,_e.MoreThan,_e.MoreThanOrEqual,_e.LessThan,_e.LessThanOrEqual,_e.And,_e.Or,Nt.Empty,Nt.NotEmpty])}function oa(){return d.union([d.object({type:d.literal(r.Condition)}),d.record(d.string(),d.any())])}function Us(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.Condition)})}function Dc(){return d.object({id:d.string(),type:d.literal(r.Condition)})}function UU(){return Dc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function xU(){return Dc().merge(d.object({}))}function kU(){return d.object({successCalls:d.array(We()),errorCalls:d.array(We()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),leftValue:Jt(),rightValue:Jt().nullable(),operator:FU(),parent:d.union([En(),vt()])})}function jU(){return UU().merge(kU())}function la(){return d.union([d.object({type:d.literal(r.Search)}),d.record(d.string(),d.any())])}function ca(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.Search)})}function Pc(){return d.object({id:d.string(),type:d.literal(r.Search),name:d.string(),query:d.any(),description:d.string().nullable()})}function qU(){return Pc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function JU(){return Pc().merge(d.object({}))}function WU(){return d.object({successCalls:d.array(We()),errorCalls:d.array(We()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),inputsDeclarations:d.array(yr()),inputs:d.array(Jt()),outputsDeclarations:d.array(aa()),outputs:d.array(ft()),parent:d.union([En(),vt()]),error:ft().nullable()})}function HU(){return qU().merge(WU())}function da(){return d.union([d.object({type:d.literal(r.InternalCall)}),d.record(d.string(),d.any())])}function Ac(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.InternalCall)})}function Sc(){return d.object({id:d.string(),type:d.literal(r.InternalCall),index:d.number()})}function YU(){return Sc().merge(d.object({version:d.number(),index:d.number()}))}function zU(){return Sc().merge(d.object({declaration:d.union([d.string(),Bt()])}))}function ZU(){return d.object({successCalls:d.array(We()),errorCalls:d.array(We()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),writesValues:d.array(Tn()),declaration:Bt(),inputs:d.array(Jt()),outputs:d.array(ft()),parent:Fn(),error:d.optional(ft())})}function XU(){return YU().merge(ZU())}function Jt(){return d.union([d.object({type:d.literal(r.InputMap)}),d.record(d.string(),d.any())])}function xs(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.InputMap)})}function Oc(){return d.object({id:d.string(),type:d.literal(r.InputMap),name:d.string().nullable().optional(),description:d.string().nullable().optional()})}function QU(){return Oc().merge(d.object({version:d.number(),index:d.number()}))}function KU(){return Oc().merge(d.object({}))}function ex(){return d.object({defaultValue:Cc().nullable(),declaration:d.union([yr(),dr()]).nullable(),readsValue:ua().nullable(),parent:d.union([de(),xs(),nn(),fn()])})}function tx(){return QU().merge(ex())}function li(){return d.union([d.object({type:d.literal(r.Operation)}),d.record(d.string(),d.any())])}function ci(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.Operation)})}function ks(){return d.object({id:d.string(),type:d.literal(r.Operation)})}function nx(){return ks().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function rx(){return ks().merge(d.object({}))}function ix(){return ks().merge(d.object({successCalls:d.array(We()),errorCalls:d.array(We()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),writesValues:d.array(Tn()),declaration:tn(),inputs:d.array(Jt()),outputs:d.array(ft()),error:d.array(ft()),parent:d.union([En(),vt()])}))}function ax(){return nx().merge(ix())}function js(){return d.union([d.string(),d.number(),d.boolean(),d.null(),d.date()])}function xb(){return d.record(d.string(),js())}function sx(){return d.array(d.union([js(),xb()]))}function kb(){return d.union([js(),xb(),sx()])}function jb(){return d.union([js(),kb()])}function qb(){return d.enum([A.String,A.Number,A.Boolean,A.Null,A.Date,A.JSON,A.Enum,A.File,A.UUID,A.EntityTemplate,A.ActionDescriptor])}function ox(){return d.union([hr(),ci(),pa()])}function lx(){return d.object({id:d.string(),name:qb(),type:d.literal(r.PrimitiveValue),value:jb(),autogeneration:yc.nullable()})}function cx(){return lx().merge(d.object({}))}function Wt(){return d.object({id:d.string(),version:d.number(),name:qb(),type:d.literal(r.PrimitiveValue),value:jb(),valueAsType:ox().nullable(),autogeneration:yc.nullable(),parent:d.union([Bc(),xs()])})}function dx(){return Wt().extend({name:d.literal(A.String),value:d.string(),autogeneration:dc.nullable()})}function ux(){return Wt().extend({name:d.literal(A.Number),value:d.number(),autogeneration:uc.nullable()})}function px(){return Wt().extend({name:d.literal(A.Boolean),value:d.boolean(),autogeneration:cc.nullable()})}function yx(){return Wt().extend({name:d.literal(A.Null),value:d.null(),autogeneration:d.null()})}function hx(){return Wt().extend({name:d.literal(A.Date),value:d.date(),autogeneration:pc.nullable()})}function fx(){return Wt().extend({name:d.literal(A.JSON),value:kb(),autogeneration:d.null()})}function mx(){return Wt().extend({name:d.literal(A.Enum),value:d.string(),autogeneration:d.null()})}function Tx(){return Wt().extend({name:d.literal(A.File),value:d.string(),autogeneration:d.null()})}function Ex(){return Wt().extend({name:d.literal(A.UUID),value:d.string(),autogeneration:lc.nullable()})}function Rx(){return Wt().extend({name:d.literal(A.EntityTemplate),value:hr(),autogeneration:d.null()})}function bx(){return Wt().extend({name:d.literal(A.ActionDescriptor),value:pa(),autogeneration:d.null()})}function Cc(){return d.union([dx(),ux(),px(),yx(),hx(),fx(),mx(),Tx(),Ex(),Rx(),bx()])}function mn(){return d.union([d.object({type:d.literal(r.DataType)}),d.record(d.string(),d.any())])}function Bc(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.DataType)})}function wc(){return d.object({id:d.string(),type:d.literal(r.DataType),isNullable:d.boolean(),isList:d.boolean(),constant:d.boolean(),asType:d.boolean(),options:d.array(d.string()).optional()})}function gx(){return wc().merge(d.object({version:d.number()}))}function vx(){return wc().merge(d.object({}))}function Ix(){return d.object({defaultValue:Cc().nullable(),entity:d.union([di(),ti(),Vs(),tn()]).nullable(),parent:d.union([$b(),Hb(),Gn(),Vb()])})}function Dx(){return gx().merge(Ix())}function _c(){return d.union([d.object({type:d.literal(r.VariableDeclaration)}),d.record(d.string(),d.any())])}function Px(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.VariableDeclaration)})}function Mc(){return d.object({id:d.string(),type:d.literal(r.VariableDeclaration),name:d.string(),description:d.string().nullable()})}function Ax(){return Mc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function Sx(){return Mc().merge(d.object({}))}function Ox(){return d.object({dataType:mn().nullable(),readsValue:ua().nullable(),writesValues:d.array(Tn()),inputs:d.array(Jt()),outputs:d.array(ft()),successCalls:d.array(We()),errorCalls:d.array(We()),internalCalls:d.array(da()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),parent:d.union([En(),vt()])})}function Cx(){return Ax().merge(Ox())}function Jb(){return d.union([d.object({type:d.literal(r.VariableInstance)}),d.record(d.string(),d.any())])}function Bx(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.VariableInstance)})}function Nc(){return d.object({id:d.string(),type:d.literal(r.VariableInstance)})}function wx(){return Nc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function _x(){return Nc().merge(d.object({}))}function Mx(){return d.object({declaration:_c(),dataType:mn().nullable(),readsValue:ua().nullable(),writesValues:d.array(Tn()),inputs:d.array(Jt()),outputs:d.array(ft()),successCalls:d.array(We()),errorCalls:d.array(We()),internalCalls:d.array(da()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),parent:d.union([En(),vt()])})}function Nx(){return wx().merge(Mx())}function Vc(){return d.union([d.object({type:d.literal(r.InstalledProject)}),d.record(d.string(),d.any())])}function qs(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.InstalledProject)})}function Vx(){return d.object({id:d.string(),type:d.literal(r.InstalledProject)})}function $x(){return d.object({version:d.number(),x:d.number(),y:d.number()})}function Lx(){return d.object({})}function Gx(){return d.object({implements:vt(),description:d.string().nullable(),functions:d.array(Bt()),events:d.array($c()),parent:vt()})}function Fx(){return $x().merge(Gx())}function $c(){return d.union([d.object({type:d.literal(r.GlobalEvent)}),d.record(d.string(),d.any())])}function Ux(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.GlobalEvent)})}function Js(){return d.object({id:d.string(),type:d.literal(r.GlobalEvent),name:d.string(),collapsed:d.boolean()})}function xx(){return Js().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function kx(){return Js().merge(d.object({}))}function jx(){return Js().merge(d.object({returnStatements:d.array(ur()),implements:d.array(Gb()),inputs:d.array(yr()),calls:d.array(We()),parent:d.union([vt(),qs()])}))}function qx(){return xx().merge(jx())}function pr(){return d.union([_c(),Jb()])}function Fn(){return d.union([Px(),Bx()])}function Tn(){return d.union([pr(),Jt(),hn()])}function Wb(){return d.union([Fn(),xs(),Ub()])}function ua(){return d.union([pr(),yr(),ft(),li(),da(),oi()])}function Jx(){return d.union([Fn(),Lc(),gc(),ci(),Ac(),sa()])}function Wx(){return d.union([yr(),ft(),Tn()])}function Hb(){return d.union([Lc(),gc(),Wb()])}function Ws(){return $c()}function Hs(){return Ux()}function Ys(){return d.union([li(),oi(),oa(),la(),pr(),da(),ni()])}function de(){return d.union([ci(),sa(),Us(),ca(),Fn(),Ac(),nn()])}function zs(){return d.union([li(),oi(),oa(),la(),pr(),ni()])}function Zs(){return d.union([ci(),sa(),Us(),ca(),Fn(),nn()])}function Yb(){return d.union([Ys(),ur(),si(),ri()])}function We(){return d.union([de(),ai(),fn(),ii()])}function zb(){return d.union([zs(),ur(),si(),ri()])}function Zb(){return d.union([Zs(),ai(),fn(),ii()])}function Un(){return d.union([Bt(),Ws()])}function Je(){return d.union([pa(),Hs()])}function Hx(){return d.union([Ys(),Un()])}function Yx(){return d.union([de(),Je()])}function zx(){return d.union([zs(),Un()])}function Zx(){return d.union([Zs(),Je()])}function Xx(){return d.union([Yb(),Un()])}function Qx(){return d.union([We(),Je()])}function Kx(){return d.union([zb(),Un()])}function e8(){return d.union([Zb(),Je()])}function t8(){return d.union([Un(),ni()])}function En(){return d.union([Je(),nn()])}function n8(){return d.union([Ys(),Un()])}function r8(){return d.union([de(),Je()])}function i8(){return d.union([zs(),Un()])}function a8(){return d.union([Zs(),Je()])}function s8(){return d.union([ur(),si(),ri()])}function o8(){return d.union([ai(),fn(),ii()])}function l8(){return d.union([ti(),b8(),Vc(),di(),Bt(),Ws(),pr(),Jt(),ft(),oa(),li(),oi(),hn(),yr(),Vs(),mn(),dr(),tn(),ur(),ri(),si(),ni(),la(),tn(),tn(),aa(),da()])}function c8(){return d.union([Gs(),vt(),qs(),hr(),pa(),Hs(),Fn(),xs(),gc(),Us(),ci(),sa(),Ub(),Lc(),$s(),Bc(),$b(),Gn(),ai(),ii(),fn(),nn(),ca(),Gn(),Gn(),Vb(),Ac()])}function d8(){return d.union([Vc(),di(),Bt(),Ws(),pr(),oa(),li(),oi(),ur(),ri(),si(),ni(),la()])}function u8(){return d.union([qs(),hr(),pa(),Hs(),Fn(),Us(),ci(),sa(),ai(),ii(),fn(),nn(),ca()])}function yr(){return d.union([d.object({type:d.literal(r.ArgumentDeclaration)}),d.record(d.string(),d.any())])}function Lc(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ArgumentDeclaration)})}function Gc(){return d.object({id:d.string(),type:d.literal(r.ArgumentDeclaration)})}function p8(){return Gc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function y8(){return Gc().merge(d.object({}))}function h8(){return d.object({dataType:mn().nullable(),writesValues:d.array(Tn()),parent:d.union([Je(),Gn(),Gn(),ca(),fn()])})}function f8(){return p8().merge(h8())}function Bt(){return d.union([d.object({type:d.literal(r.FunctionDeclaration)}),d.record(d.string(),d.any())])}function pa(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.FunctionDeclaration)})}function Fc(){return d.object({id:d.string(),type:d.literal(r.FunctionDeclaration),name:d.string(),description:d.string().nullable()})}function m8(){return Fc().merge(d.object({version:d.number(),x:d.number(),y:d.number(),index:d.number().nullable()}))}function T8(){return Fc()}function E8(){return d.object({inputs:d.array(yr()),implements:tn().nullable(),returnStatements:d.array(ur()),parent:d.union([vt(),qs(),hr(),nn(),Gs(),$s()])})}function R8(){return m8().merge(E8())}function b8(){return d.union([d.object({type:d.literal(r.Project)}),d.record(d.string(),d.any())])}function vt(){return d.object({entityType:d.literal(r.Project),entityId:d.string(),id:d.string(),type:d.literal(r.GenericReference)})}function Uc(){return d.object({id:d.string(),type:d.literal(r.Project),name:d.string(),description:d.string().nullable()})}function g8(){return Uc().merge(d.object({version:d.number()}))}function v8(){return Uc()}function I8(){return d.object({entities:d.array(di()),functions:d.array(Bt()),events:d.array($c()),projects:d.array(Vc()),variableDeclarations:d.array(_c()),variableInstances:d.array(Jb()),conditions:d.array(oa()),operations:d.array(li()),functionCalls:d.array(oi()),loops:d.array(ni()),searches:d.array(la())})}function D8(){return g8().merge(I8())}function di(){return d.union([d.object({type:d.literal(r.CustomEntity)}),d.record(d.string(),d.any())])}function hr(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.CustomEntity)})}function xc(){return d.object({id:d.string(),type:d.literal(r.CustomEntity),name:d.string(),description:d.string().nullable(),static:d.boolean(),abstract:d.boolean()})}function P8(){return xc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function A8(){return xc().merge(d.object({}))}function S8(){return d.union([vt(),Bc()])}function O8(){return d.object({properties:d.array(dr()),methods:d.array(Bt()),abstractMethods:d.array(tn()),extends:d.array(d.union([di(),ti()])),implements:d.array(d.union([di(),ti()])),parent:S8()})}function C8(){return P8().merge(O8())}function B8(n){const e=C8(),t=n.toJSON();e.safeParse(t).success;const a=n.implements.flatMap(f=>M8(n,f)),s=n.extends.flatMap(f=>N8(n,f)),o=$8(n),l=V8(n);n.methods.flatMap(f=>f.validate());const p=[...a,...s,...o,...l];return ne(n.errors,p)}function w8(n,e){const t=e.properties.filter(s=>s.abstract),i=[];let a=[...n.properties];return t.forEach(s=>{const o=a.find(l=>{var p;return((p=l.implements)==null?void 0:p.id)===s.id});o?a=a.filter(l=>l.id!==o.id):i.push(s)}),i}function _8(n,e){const t=e.abstractMethods,i=[];let a=[...n.methods];return t.forEach(s=>{const o=a.find(l=>{var p;return((p=l.implements)==null?void 0:p.id)===s.id});o?a=a.filter(l=>l.id!==o.id):i.push(s)}),i}function M8(n,e){const t=[];if(!e.abstract){const f=H({id:n.id+"--"+_.ImplementingNonAbstractEntity,message:`Entity "${n.name}" with id "${n.id}" is implementing a non-abstract entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:_.ImplementingNonAbstractEntity,entity:n});return t.push(f.error),t}const i=e.properties.filter(f=>f.abstract),a=[];let s=[...n.properties];i.forEach(f=>{const m=s.find(b=>{var g;return((g=b.implements)==null?void 0:g.id)===f.id});m?s=s.filter(b=>b.id!==m.id):a.push(f)}),a.length&&a.forEach(f=>{const m=H({id:n.id+"--"+_.MissingPropertyImplementation+"--"+f.id,message:`Property "${f.name}" with id "${f.id}" of entity "${e.name}" with id "${e.id}" is not implemented when entity "${n.name}" with id "${n.id}" implements it`,issue:null,severity:T.Error,code:_.MissingPropertyImplementation,entity:n});t.push(m.error)});const o=[];let l=[...n.methods];e.abstractMethods.forEach(f=>{const m=l.find(b=>{var g;return((g=b.implements)==null?void 0:g.id)===f.id});m?l=l.filter(b=>b.id!==m.id):o.push(f)}),o.length&&o.forEach(f=>{const m=H({id:n.id+"--"+_.MissingMethodImplementation+"--"+f.id,message:`Method "${f.name}" with id "${f.id}" of entity "${e.name}" with id "${e.id}" is not implemented when entity "${n.name}" with id "${n.id}" implements it`,issue:null,severity:T.Error,code:_.MissingMethodImplementation,entity:n});t.push(m.error)});const p=[];e.properties.forEach(f=>{const m=s.find(b=>b.name===f.name);m&&p.push([m,f])}),p.length&&p.forEach(([f])=>{const m=H({id:n.id+"--"+D.PropertyOverwrite+"--"+f.id,message:`Property "${f.name}" with id "${f.id}" of entity "${n.name}" with id "${n.id}" overwrites the property with the same name from the base entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:D.PropertyOverwrite,entity:n});t.push(m.error)});const y=[];return e.methods.forEach(f=>{const m=l.find(b=>b.name===f.name);m&&y.push([m,f])}),y.length&&y.forEach(([f])=>{const m=H({id:n.id+"--"+D.MethodOverwrite+"--"+f.id,message:`Method "${f.name}" with id "${f.id}" of entity "${n.name}" with id "${n.id}" overwrites the method with the same name from the base entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:D.MethodOverwrite,entity:n});t.push(m.error)}),t}function N8(n,e){const t=[],i=[];if(e.abstract){const s=H({id:n.id+"--"+_.ExtendingAbstractEntity,message:`Entity "${n.name}" with id "${n.id}" is extending an abstract entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:_.ExtendingAbstractEntity,entity:n});return t.push(s.error),t}n.properties.forEach(s=>{var l;const o=e.properties.find(p=>p.name===s.name);((l=s.implements)==null?void 0:l.id)!==(o==null?void 0:o.id)&&o&&i.push(s)}),i.length&&i.forEach(s=>{const o=H({id:n.id+"--"+D.PropertyOverwrite,message:`Property "${s.name}" with id "${s.id}" of entity "${n.name}" with id "${n.id}" overwrites the property with the same name from the extended entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:D.PropertyOverwrite,entity:n});t.push(o.error)});const a=[];return n.methods.forEach(s=>{var l;const o=e.methods.find(p=>p.name===s.name);((l=s.implements)==null?void 0:l.id)!==(o==null?void 0:o.id)&&o&&a.push(s)}),a.length&&a.forEach(s=>{const o=H({id:n.id+"--"+D.MethodOverwrite,message:`Method "${s.name}" with id "${s.id}" of entity "${n.name}" with id "${n.id}" overwrites the method with the same name from the extended entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:D.MethodOverwrite,entity:n});t.push(o.error)}),t}function V8(n){const e=[];if(!n.properties.length){const t=H({id:n.id+"--"+_.NoProperties,message:"No properties implemented",issue:null,severity:T.Warning,code:_.NoProperties,entity:n});e.push(t.error)}return n.properties.forEach(t=>{t.validate()}),e}function $8(n){const e=[];if(n.abstract){if(n.methods.length){const t=H({id:n.id+"--"+_.AbstractEntityWithNonAbstractMethods,message:`Entity "${n.name}" with id "${n.id}" is marked as abstract but has non-abstract methods`,issue:null,severity:T.Error,code:_.AbstractEntityWithNonAbstractMethods,entity:n});e.push(t.error)}if(n.properties.some(t=>!t.abstract)){const t=H({id:n.id+"--"+_.AbstractEntityWithNonAbstractProperties,message:`Entity "${n.name}" with id "${n.id}" is marked as abstract but has non-abstract properties`,issue:null,severity:T.Error,code:_.AbstractEntityWithNonAbstractProperties,entity:n});e.push(t.error),n.properties.forEach(i=>{if(!i.abstract){const a=H({id:n.id+"--"+_.StaticEntityWithNonStaticProperties+"--"+i.id,message:`Property "${i.name}" with id "${i.id}" of entity "${n.name}" with id "${n.id}" is not marked as abstract but the entity is marked as abstract`,issue:null,severity:T.Error,code:_.StaticEntityWithNonStaticProperties,entity:n});e.push(a.error)}})}}else{if(n.abstractMethods.length){const t=H({id:n.id+"--"+_.AbstractPropertyInNonAbstractEntity,message:`Entity "${n.name}" with id "${n.id}" is not marked as abstract but has abstract methods`,issue:null,severity:T.Error,code:_.AbstractPropertyInNonAbstractEntity,entity:n});e.push(t.error)}if(n.properties.some(t=>t.abstract)){const t=H({id:n.id+"--"+_.AbstractMethodInNonAbstractEntity,message:`Entity "${n.name}" with id "${n.id}" is not marked as abstract but has abstract properties`,issue:null,severity:T.Error,code:_.AbstractMethodInNonAbstractEntity,entity:n});e.push(t.error),n.properties.forEach(i=>{if(i.abstract){const a=H({id:n.id+"--"+_.AbstractMethodInNonAbstractEntity+"--"+i.id,message:`Property "${i.name}" with id "${i.id}" of entity "${n.name}" with id "${n.id}" is marked as abstract but the entity is not marked as abstract`,issue:null,severity:T.Error,code:_.AbstractMethodInNonAbstractEntity,entity:n});e.push(a.error)}})}}if(n.static&&n.properties.some(t=>!t.static)){const t=H({id:n.id+"--"+_.StaticEntityWithNonStaticProperties,message:`Entity "${n.name}" with id "${n.id}" is marked as static but has non-static properties`,issue:null,severity:T.Error,code:_.StaticEntityWithNonStaticProperties,entity:n});e.push(t.error),n.properties.forEach(i=>{if(!i.static){const a=H({id:n.id+"--"+_.NonStaticPropertyInStaticEntity+"--"+i.id,message:`Property "${i.name}" with id "${i.id}" of entity "${n.name}" with id "${n.id}" is not marked as static but the entity is marked as static`,issue:null,severity:T.Error,code:_.NonStaticPropertyInStaticEntity,entity:n});e.push(a.error)}})}return e}function L8(n){return n instanceof Error&&n.name==="ZodError"&&"issues"in n&&Array.isArray(n.issues)}var G8=class extends Error{constructor(e,t){super(e,t);c(this,"name");c(this,"details");this.name="ZodValidationError",this.details=F8(t)}toString(){return this.message}};function F8(n){if(n){const e=n.cause;if(L8(e))return e.issues}return[]}var U8="; ",Xb="Validation error",x8=": ",k8=", or ";function j8(n,e,t){return e!==null?n.length>0?[e,n].join(t):e:n.length>0?n:Xb}var q8=/[$_\p{ID_Start}][$\u200c\u200d\p{ID_Continue}]*/u;function J8(n){return n.length===1?n[0].toString():n.reduce((e,t)=>{if(typeof t=="number")return e+"["+t.toString()+"]";if(t.includes('"'))return e+'["'+W8(t)+'"]';if(!q8.test(t))return e+'["'+t+'"]';const i=e.length===0?"":".";return e+i+t},"")}function W8(n){return n.replace(/"/g,'\\"')}function H8(n){return n.length!==0}function Xs(n){const{issue:e,issueSeparator:t,unionSeparator:i,includePath:a}=n;if(e.code==="invalid_union")return e.unionErrors.reduce((s,o)=>{const l=o.issues.map(p=>Xs({issue:p,issueSeparator:t,unionSeparator:i,includePath:a})).join(t);return s.includes(l)||s.push(l),s},[]).join(i);if(e.code==="invalid_arguments")return[e.message,...e.argumentsError.issues.map(s=>Xs({issue:s,issueSeparator:t,unionSeparator:i,includePath:a}))].join(t);if(e.code==="invalid_return_type")return[e.message,...e.returnTypeError.issues.map(s=>Xs({issue:s,issueSeparator:t,unionSeparator:i,includePath:a}))].join(t);if(a&&H8(e.path)){if(e.path.length===1){const s=e.path[0];if(typeof s=="number")return`${e.message} at index ${s}`}return`${e.message} at "${J8(e.path)}"`}return e.message}function Y8(n,e={}){const{issueSeparator:t=U8,unionSeparator:i=k8,prefixSeparator:a=x8,prefix:s=Xb,includePath:o=!0}=e,l=Xs({issue:n,issueSeparator:t,unionSeparator:i,includePath:o}),p=j8(l,s,a);return new G8(p,{cause:new bt([n])})}var Qb="1.13.7",Kb=typeof self=="object"&&self.self===self&&self||typeof global=="object"&&global.global===global&&global||Function("return this")()||{},Qs=Array.prototype,kc=Object.prototype,eg=typeof Symbol<"u"?Symbol.prototype:null,z8=Qs.push,ya=Qs.slice,ha=kc.toString,Z8=kc.hasOwnProperty,tg=typeof ArrayBuffer<"u",X8=typeof DataView<"u",Q8=Array.isArray,ng=Object.keys,rg=Object.create,ig=tg&&ArrayBuffer.isView,K8=isNaN,e6=isFinite,ag=!{toString:null}.propertyIsEnumerable("toString"),sg=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],t6=Math.pow(2,53)-1;function It(n,e){return e=e==null?n.length-1:+e,function(){for(var t=Math.max(arguments.length-e,0),i=Array(t),a=0;a<t;a++)i[a]=arguments[a+e];switch(e){case 0:return n.call(this,i);case 1:return n.call(this,arguments[0],i);case 2:return n.call(this,arguments[0],arguments[1],i)}var s=Array(e+1);for(a=0;a<e;a++)s[a]=arguments[a];return s[e]=i,n.apply(this,s)}}function xn(n){var e=typeof n;return e==="function"||e==="object"&&!!n}function n6(n){return n===null}function og(n){return n===void 0}function lg(n){return n===!0||n===!1||ha.call(n)==="[object Boolean]"}function r6(n){return!!(n&&n.nodeType===1)}function st(n){var e="[object "+n+"]";return function(t){return ha.call(t)===e}}const jc=st("String"),cg=st("Number"),i6=st("Date"),a6=st("RegExp"),s6=st("Error"),dg=st("Symbol"),ug=st("ArrayBuffer");var pg=st("Function"),o6=Kb.document&&Kb.document.childNodes;typeof/./!="function"&&typeof Int8Array!="object"&&typeof o6!="function"&&(pg=function(n){return typeof n=="function"||!1});const mt=pg,yg=st("Object");var hg=X8&&(!/\[native code\]/.test(String(DataView))||yg(new DataView(new ArrayBuffer(8)))),qc=typeof Map<"u"&&yg(new Map),l6=st("DataView");function c6(n){return n!=null&&mt(n.getInt8)&&ug(n.buffer)}const Ks=hg?c6:l6,fr=Q8||st("Array");function kn(n,e){return n!=null&&Z8.call(n,e)}var Jc=st("Arguments");(function(){Jc(arguments)||(Jc=function(n){return kn(n,"callee")})})();const Wc=Jc;function d6(n){return!dg(n)&&e6(n)&&!isNaN(parseFloat(n))}function fg(n){return cg(n)&&K8(n)}function mg(n){return function(){return n}}function Tg(n){return function(e){var t=n(e);return typeof t=="number"&&t>=0&&t<=t6}}function Eg(n){return function(e){return e==null?void 0:e[n]}}const eo=Eg("byteLength"),u6=Tg(eo);var p6=/\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/;function y6(n){return ig?ig(n)&&!Ks(n):u6(n)&&p6.test(ha.call(n))}const Rg=tg?y6:mg(!1),Dt=Eg("length");function h6(n){for(var e={},t=n.length,i=0;i<t;++i)e[n[i]]=!0;return{contains:function(a){return e[a]===!0},push:function(a){return e[a]=!0,n.push(a)}}}function bg(n,e){e=h6(e);var t=sg.length,i=n.constructor,a=mt(i)&&i.prototype||kc,s="constructor";for(kn(n,s)&&!e.contains(s)&&e.push(s);t--;)s=sg[t],s in n&&n[s]!==a[s]&&!e.contains(s)&&e.push(s)}function Ye(n){if(!xn(n))return[];if(ng)return ng(n);var e=[];for(var t in n)kn(n,t)&&e.push(t);return ag&&bg(n,e),e}function fa(n){if(n==null)return!0;var e=Dt(n);return typeof e=="number"&&(fr(n)||jc(n)||Wc(n))?e===0:Dt(Ye(n))===0}function gg(n,e){var t=Ye(e),i=t.length;if(n==null)return!i;for(var a=Object(n),s=0;s<i;s++){var o=t[s];if(e[o]!==a[o]||!(o in a))return!1}return!0}function re(n){if(n instanceof re)return n;if(!(this instanceof re))return new re(n);this._wrapped=n}re.VERSION=Qb,re.prototype.value=function(){return this._wrapped},re.prototype.valueOf=re.prototype.toJSON=re.prototype.value,re.prototype.toString=function(){return String(this._wrapped)};function vg(n){return new Uint8Array(n.buffer||n,n.byteOffset||0,eo(n))}var Ig="[object DataView]";function Hc(n,e,t,i){if(n===e)return n!==0||1/n===1/e;if(n==null||e==null)return!1;if(n!==n)return e!==e;var a=typeof n;return a!=="function"&&a!=="object"&&typeof e!="object"?!1:Dg(n,e,t,i)}function Dg(n,e,t,i){n instanceof re&&(n=n._wrapped),e instanceof re&&(e=e._wrapped);var a=ha.call(n);if(a!==ha.call(e))return!1;if(hg&&a=="[object Object]"&&Ks(n)){if(!Ks(e))return!1;a=Ig}switch(a){case"[object RegExp]":case"[object String]":return""+n==""+e;case"[object Number]":return+n!=+n?+e!=+e:+n==0?1/+n===1/e:+n==+e;case"[object Date]":case"[object Boolean]":return+n==+e;case"[object Symbol]":return eg.valueOf.call(n)===eg.valueOf.call(e);case"[object ArrayBuffer]":case Ig:return Dg(vg(n),vg(e),t,i)}var s=a==="[object Array]";if(!s&&Rg(n)){var o=eo(n);if(o!==eo(e))return!1;if(n.buffer===e.buffer&&n.byteOffset===e.byteOffset)return!0;s=!0}if(!s){if(typeof n!="object"||typeof e!="object")return!1;var l=n.constructor,p=e.constructor;if(l!==p&&!(mt(l)&&l instanceof l&&mt(p)&&p instanceof p)&&"constructor"in n&&"constructor"in e)return!1}t=t||[],i=i||[];for(var y=t.length;y--;)if(t[y]===n)return i[y]===e;if(t.push(n),i.push(e),s){if(y=n.length,y!==e.length)return!1;for(;y--;)if(!Hc(n[y],e[y],t,i))return!1}else{var f=Ye(n),m;if(y=f.length,Ye(e).length!==y)return!1;for(;y--;)if(m=f[y],!(kn(e,m)&&Hc(n[m],e[m],t,i)))return!1}return t.pop(),i.pop(),!0}function f6(n,e){return Hc(n,e)}function ma(n){if(!xn(n))return[];var e=[];for(var t in n)e.push(t);return ag&&bg(n,e),e}function Yc(n){var e=Dt(n);return function(t){if(t==null)return!1;var i=ma(t);if(Dt(i))return!1;for(var a=0;a<e;a++)if(!mt(t[n[a]]))return!1;return n!==Sg||!mt(t[zc])}}var zc="forEach",Pg="has",Zc=["clear","delete"],Ag=["get",Pg,"set"],m6=Zc.concat(zc,Ag),Sg=Zc.concat(Ag),T6=["add"].concat(Zc,zc,Pg);const E6=qc?Yc(m6):st("Map"),R6=qc?Yc(Sg):st("WeakMap"),b6=qc?Yc(T6):st("Set"),g6=st("WeakSet");function ui(n){for(var e=Ye(n),t=e.length,i=Array(t),a=0;a<t;a++)i[a]=n[e[a]];return i}function v6(n){for(var e=Ye(n),t=e.length,i=Array(t),a=0;a<t;a++)i[a]=[e[a],n[e[a]]];return i}function Og(n){for(var e={},t=Ye(n),i=0,a=t.length;i<a;i++)e[n[t[i]]]=t[i];return e}function Xc(n){var e=[];for(var t in n)mt(n[t])&&e.push(t);return e.sort()}function Qc(n,e){return function(t){var i=arguments.length;if(e&&(t=Object(t)),i<2||t==null)return t;for(var a=1;a<i;a++)for(var s=arguments[a],o=n(s),l=o.length,p=0;p<l;p++){var y=o[p];(!e||t[y]===void 0)&&(t[y]=s[y])}return t}}const Cg=Qc(ma),to=Qc(Ye),Bg=Qc(ma,!0);function I6(){return function(){}}function wg(n){if(!xn(n))return{};if(rg)return rg(n);var e=I6();e.prototype=n;var t=new e;return e.prototype=null,t}function D6(n,e){var t=wg(n);return e&&to(t,e),t}function P6(n){return xn(n)?fr(n)?n.slice():Cg({},n):n}function A6(n,e){return e(n),n}function _g(n){return fr(n)?n:[n]}re.toPath=_g;function Ta(n){return re.toPath(n)}function Kc(n,e){for(var t=e.length,i=0;i<t;i++){if(n==null)return;n=n[e[i]]}return t?n:void 0}function Mg(n,e,t){var i=Kc(n,Ta(e));return og(i)?t:i}function S6(n,e){e=Ta(e);for(var t=e.length,i=0;i<t;i++){var a=e[i];if(!kn(n,a))return!1;n=n[a]}return!!t}function ed(n){return n}function Ea(n){return n=to({},n),function(e){return gg(e,n)}}function td(n){return n=Ta(n),function(e){return Kc(e,n)}}function Ra(n,e,t){if(e===void 0)return n;switch(t??3){case 1:return function(i){return n.call(e,i)};case 3:return function(i,a,s){return n.call(e,i,a,s)};case 4:return function(i,a,s,o){return n.call(e,i,a,s,o)}}return function(){return n.apply(e,arguments)}}function Ng(n,e,t){return n==null?ed:mt(n)?Ra(n,e,t):xn(n)&&!fr(n)?Ea(n):td(n)}function nd(n,e){return Ng(n,e,1/0)}re.iteratee=nd;function Pt(n,e,t){return re.iteratee!==nd?re.iteratee(n,e):Ng(n,e,t)}function O6(n,e,t){e=Pt(e,t);for(var i=Ye(n),a=i.length,s={},o=0;o<a;o++){var l=i[o];s[l]=e(n[l],l,n)}return s}function Vg(){}function C6(n){return n==null?Vg:function(e){return Mg(n,e)}}function B6(n,e,t){var i=Array(Math.max(0,n));e=Ra(e,t,1);for(var a=0;a<n;a++)i[a]=e(a);return i}function rd(n,e){return e==null&&(e=n,n=0),n+Math.floor(Math.random()*(e-n+1))}const ba=Date.now||function(){return new Date().getTime()};function $g(n){var e=function(s){return n[s]},t="(?:"+Ye(n).join("|")+")",i=RegExp(t),a=RegExp(t,"g");return function(s){return s=s==null?"":""+s,i.test(s)?s.replace(a,e):s}}const Lg={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},w6=$g(Lg),_6=Og(Lg),M6=$g(_6),N6=re.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var id=/(.)^/,V6={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},$6=/\\|'|\r|\n|\u2028|\u2029/g;function L6(n){return"\\"+V6[n]}var G6=/^\s*(\w|\$)+\s*$/;function F6(n,e,t){!e&&t&&(e=t),e=Bg({},e,re.templateSettings);var i=RegExp([(e.escape||id).source,(e.interpolate||id).source,(e.evaluate||id).source].join("|")+"|$","g"),a=0,s="__p+='";n.replace(i,function(y,f,m,b,g){return s+=n.slice(a,g).replace($6,L6),a=g+y.length,f?s+=`'+
|
|
1
|
+
(function(u,r){typeof exports=="object"&&typeof module<"u"?r(exports):typeof define=="function"&&define.amd?define(["exports"],r):(u=typeof globalThis<"u"?globalThis:u||self,r(u["@elyx-code/project-logic-tree"]={}))})(this,function(u){"use strict";var y5=Object.defineProperty;var h5=(u,r,V)=>r in u?y5(u,r,{enumerable:!0,configurable:!0,writable:!0,value:V}):u[r]=V;var c=(u,r,V)=>(h5(u,typeof r!="symbol"?r+"":r,V),V);var r=(n=>(n.CustomEntity="custom-entity",n.BuiltInBaseEntity="built-in-base-entity",n.Project="project",n.InstalledProject="installed-project",n.GlobalEvent="global-event",n.DataType="data-type",n.FunctionCall="function-call",n.FunctionDeclaration="function-declaration",n.ActionDescriptor="action-descriptor",n.ValueDescriptor="value-descriptor",n.ArgumentDeclaration="argument-declaration",n.InputMap="input-map",n.ReturnStatement="return-statement",n.BreakStatement="break-statement",n.ContinueStatement="continue-statement",n.ReturnDeclaration="return-declaration",n.OutputMap="output-map",n.PrimitiveEntity="primitive-entity",n.PrimitiveValue="primitive-value",n.Property="property",n.Operation="operation",n.Condition="condition",n.VariableDeclaration="variable-declaration",n.VariableInstance="variable-instance",n.Search="search",n.Loop="loop",n.InternalCall="internal-call",n.GenericReference="generic-reference",n))(r||{}),V=(n=>(n.HTTP_ENDPOINT="BUILT_IN_HTTP_ENDPOINT_ENTITY",n.RELATIONAL_DATABASE="BUILT_IN_RELATIONAL_DATABASE_ENTITY",n.PERSISTED_ENTITY="BUILT_IN_PERSISTED_ENTITY_ENTITY",n.CRON_JOB="BUILT_IN_CRON_JOB_ENTITY",n.EXECUTION="BUILT_IN_EXECUTION_ENTITY",n.KEY_VALUE_PARAM="BUILT_IN_KEY_VALUE_PARAM_ENTITY",n))(V||{}),qe=(n=>(n.CurrentDateAndTime="current-date-and-time",n.Unique="unique",n.Random="random",n))(qe||{}),Ot=(n=>(n.DeletePersistedEntity="base-delete-persisted-entity",n.SoftDeletePersistedEntity="base-soft-delete-persisted-entity",n.AbortExecution="base-abort-execution",n))(Ot||{}),U=(n=>(n.Fixed="fixed",n.None="none",n.Dynamic="dynamic",n))(U||{}),M=(n=>(n.FixedArguments="fixed-arguments",n.FixedReturns="fixed-returns",n.ReturnedError="returned-error",n.OngoingProcessExecution="ongoing-process-execution",n))(M||{}),A=(n=>(n.EntityTemplate="entity-template",n.ActionDescriptor="action-descriptor",n.String="string",n.Number="number",n.Boolean="boolean",n.Null="null",n.Enum="enum",n.JSON="json",n.Date="date",n.UUID="uuid",n.File="file",n))(A||{}),lt=(n=>(n.Addition="addition",n.Substraction="substraction",n.Multiplication="multiplication",n.Division="division",n.Remainder="remainder",n.Exponentiation="exponentiation",n))(lt||{}),Ae=(n=>(n.Join="string-join",n.Split="stringSsplit",n.DeleteLast="string-delete-last",n.DeleteFirst="string-delete-first",n.DeleteIndex="string-delete-index",n.AddIndex="string-add-index",n.ReplaceFirst="string-replace-first",n.ReplaceLast="string-replace-last",n.ReplaceIndex="string-replace-index",n.ReplaceSingleMatch="string-replace-single-match",n.ReplaceAllMatches="string-replace-all-matches",n.GetIndex="string-get-index",n.GetFirst="string-get-first",n.GetLast="string-get-last",n.Append="string-append",n.Prepend="string-prepend",n))(Ae||{}),W=(n=>(n.Join="list-join",n.Split="list-split",n.DeleteLast="list-delete-last",n.DeleteFirst="list-delete-first",n.DeleteIndex="list-delete-index",n.AddIndex="list-add-index",n.ReplaceFirst="list-replace-first",n.ReplaceLast="list-replace-last",n.ReplaceIndex="list-replace-index",n.ReplaceSingleMatch="list-replace-single-match",n.ReplaceAllMatches="list-replace-all-matches",n.GetIndex="list-get-index",n.GetFirst="list-get-first",n.GetLast="list-get-last",n.Append="list-append",n.Prepend="list-prepend",n))(W||{}),Oe=(n=>(n.Parallel="parallel",n.Sequential="sequential",n.Wait="wait",n))(Oe||{}),Ze=(n=>(n.CreateNewInstance="create-new-instance",n.Validate="validate",n))(Ze||{}),Xe=(n=>(n.HttpRequest="base-http-request",n))(Xe||{}),_e=(n=>(n.Equal="equal",n.NotEqual="not-equal",n.And="and",n.Or="or",n.LessThan="less-than",n.MoreThan="more-than",n.LessThanOrEqual="less-than-or-equal",n.MoreThanOrEqual="more-than-or-equal",n))(_e||{}),Nt=(n=>(n.Empty="empty",n.NotEmpty="not-empty",n))(Nt||{}),Q=(n=>(n.ManualFlow="manual-flow-loop",n.Counted="counted-loop",n.List="list-loop",n.ObjectKeys="object-keys-loop",n.ObjectValues="object-values-loop",n.String="string-loop",n))(Q||{}),Ue=(n=>(n.OrDataTypeGroup="or-data-type-group",n.AndDataTypeGroup="and-data-type-group",n.DynamicArgumentTypes="dynamic-argument-types",n.DynamicReturnTypes="dynamic-return-types",n))(Ue||{}),on=(n=>(n.PROJECT_PUBLICATION_COMPLETED="GLOBAL_EVENT_PROJECT_PUBLICATION_COMPLETED",n))(on||{}),Hd=(n=>(n.Error="error",n.Task="task",n.Return="return",n))(Hd||{});const zn=[r.VariableDeclaration,r.VariableInstance,r.InputMap,r.ReturnDeclaration],fI=[r.VariableDeclaration,r.VariableInstance,r.InputMap,r.ReturnDeclaration],Ve=[r.VariableDeclaration,r.VariableInstance,r.ArgumentDeclaration,r.OutputMap],mI=[r.VariableDeclaration,r.VariableInstance,r.ArgumentDeclaration,r.OutputMap],Yd=[...zn,...Ve],xe=[r.VariableDeclaration,r.VariableInstance],Lr=[r.GlobalEvent],$e=[r.Operation,r.FunctionCall,r.Condition,r.Search,r.VariableDeclaration,r.VariableInstance,r.InternalCall,r.Loop],Oo=[r.Operation,r.FunctionCall,r.Condition,r.Search,r.VariableDeclaration,r.VariableInstance,r.Loop],Me=[r.FunctionDeclaration,...Lr],Pn=[...$e,r.ReturnStatement,r.BreakStatement,r.ContinueStatement],Co=[...Oo,r.ReturnStatement,r.BreakStatement,r.ContinueStatement],ln=[...$e,...Me],zd=[...Oo,...Me],TI=[...Pn,...Me],EI=[...Co,...Me],ct=[...Me,r.Loop],Ne=[r.ReturnStatement,r.BreakStatement,r.ContinueStatement],RI=[r.CustomEntity,r.BuiltInBaseEntity,r.Project,r.InstalledProject,r.GlobalEvent,r.DataType,r.FunctionCall,r.FunctionDeclaration,r.ActionDescriptor,r.ValueDescriptor,r.ArgumentDeclaration,r.InputMap,r.ReturnStatement,r.BreakStatement,r.ContinueStatement,r.ReturnDeclaration,r.OutputMap,r.PrimitiveEntity,r.PrimitiveValue,r.Property,r.Operation,r.Condition,r.VariableDeclaration,r.VariableInstance,r.Search,r.Loop,r.InternalCall],Bo=[r.CustomEntity,r.GlobalEvent,r.FunctionDeclaration,r.FunctionCall,r.VariableDeclaration,r.VariableInstance,r.Operation,r.Condition,r.ReturnStatement,r.BreakStatement,r.ContinueStatement,r.InstalledProject,r.Loop,r.Search],Zd=[r.CustomEntity,r.FunctionDeclaration,r.ArgumentDeclaration,r.ReturnDeclaration,r.Property,r.VariableDeclaration,r.Search,r.Project,r.InstalledProject,r.ActionDescriptor,r.ValueDescriptor],Gr=[r.BuiltInBaseEntity,r.PrimitiveEntity],bI=[r.CustomEntity,r.FunctionDeclaration,r.ArgumentDeclaration,r.ReturnDeclaration,r.Property,r.VariableDeclaration,r.GlobalEvent,r.Search,r.Project,r.InstalledProject,r.ActionDescriptor,r.ValueDescriptor,r.InputMap,r.OutputMap,r.FunctionCall,r.Operation,r.Condition,r.ReturnStatement,r.BreakStatement,r.ContinueStatement,r.VariableInstance,r.PrimitiveValue,r.InternalCall];var wo=(n=>(n.ActionOngoingProcessOutputValue="action-ongoing-process-output-value-descriptor-id",n))(wo||{});const x={[r.PrimitiveEntity]:{[A.String]:{id:"8b5fbe15-4c2b-48c0-9fd8-e5efbe3978dc",properties:{}},[A.Boolean]:{id:"f596545d-1565-4faa-9969-d95fa5edfea4",properties:{}},[A.Number]:{id:"ecb84c29-6153-4b82-86a5-fce2b5f92002",properties:{}},[A.JSON]:{id:"b6f3c3c4-9c3d-4f9d-9e9e-1c0f6a3c8c6b",properties:{}},[A.Enum]:{id:"9542b8b4-2642-4eee-9db9-def7963a17a0",properties:{options:{id:"00ccfcae-2104-45ef-bf6c-50ddccd74286",dataType:{id:"7dd59b70-f97b-43a7-a051-fde1842ce5d6",defaultValue:{id:"enum-options-property-data-type-default-value-id"}}}}},[A.UUID]:{id:"4a6234aa-c0f6-4731-b4dd-750388029226",properties:{}},[A.Date]:{id:"dc58f38b-d574-4956-aac6-32ce9529b937",properties:{}}},[r.ValueDescriptor]:{"action-ongoing-process-output-value-descriptor-id":{id:"action-ongoing-process-output-value-descriptor-id",dataType:{id:"process-output-value-data-type-id"}}},[r.BuiltInBaseEntity]:{[V.KEY_VALUE_PARAM]:{id:V.KEY_VALUE_PARAM},[V.HTTP_ENDPOINT]:{id:V.HTTP_ENDPOINT,properties:{method:{id:"http-endpoint-built-in-method-property-id"},path:{id:"http-endpoint-built-in-path-property-id"},cors:{id:"http-endpoint-built-in-cors-property-id"}}},[V.PERSISTED_ENTITY]:{id:V.PERSISTED_ENTITY,properties:{database:{id:"persisted-built-in-base-entity-database-property-id"},identifier:{id:"persisted-built-in-base-entity-identifier-property-id"}}},[V.RELATIONAL_DATABASE]:{id:V.RELATIONAL_DATABASE,properties:{identifier:{id:"relational-database-built-in-base-entity-identifier-property-id"},username:{id:"relational-database-built-in-base-entity-username-property-id"},password:{id:"relational-database-built-in-base-entity-password-property-id"},minSize:{id:"relational-database-built-in-base-entity-min-size-property-id"},default:{id:"relational-database-built-in-base-entity-default-property-id"},autoscaling:{id:"relational-database-built-in-base-entity-autoscaling-property-id"}}},[V.CRON_JOB]:{id:V.CRON_JOB,properties:{expression:{id:"cron-job-built-in-base-entity-expression-property-id"}}}},[r.Operation]:{[Ae.Join]:{id:Ae.Join,inputs:{first:{id:"join-string-first-string-input-id"},second:{id:"join-string-second-string-input-id"}},outputs:{result:{id:"join-string-result-string-return-delaration-id"},error:{id:"join-string-error-return-delaration-id"}}},[Xe.HttpRequest]:{id:Xe.HttpRequest,inputs:{url:{id:"http-request-url-input-id"},query:{id:"http-request-query-input-id"},method:{id:"http-request-method-input-id"},headers:{id:"http-request-headers-input-id"},body:{id:"http-request-body-string-input-id"}},outputs:{code:{id:"http-response-code-return-delaration-id"},body:{id:"http-response-body-return-delaration-id"},headers:{id:"http-response-headers-return-delaration-id"},error:{id:"http-request-error-return-delaration-id"}}}},[r.Loop]:{[Q.List]:{id:Q.List,inputs:{list:{id:"iterate-over-list-loop-list-input-id"}},outputs:{results:{id:"iterate-over-list-loop-output-id"}}},[Q.String]:{id:Q.String,inputs:{string:{id:"iterate-over-string-loop-string-input-id"}},outputs:{results:{id:"iterate-over-string-loop-output-id"}}},[Q.ObjectKeys]:{id:Q.ObjectKeys,inputs:{object:{id:"iterate-over-object-keys-loop-object-input-id"}},outputs:{results:{id:"iterate-over-object-keys-loop-output-id"}}},[Q.ObjectValues]:{id:Q.ObjectValues,inputs:{object:{id:"iterate-over-object-values-loop-object-input-id"}},outputs:{results:{id:"iterate-over-object-values-loop-output-id"}}},[Q.ManualFlow]:{id:Q.ManualFlow,inputs:{},outputs:{results:{id:"manual-flow-loop-output-id"}}},[Q.Counted]:{id:Q.Counted,inputs:{number:{id:"iterate-over-counted-loop-number-input-id"}},outputs:{results:{id:"iterate-over-counted-loop-output-id"}}}},[r.Condition]:{[_e.MoreThanOrEqual]:{id:_e.MoreThanOrEqual,inputs:{leftHand:{id:"condition-more-than-or-equal-left-hand-input-id"},rightHand:{id:"condition-more-than-or-equal-right-hand-input-id"}}},[Nt.NotEmpty]:{id:Nt.NotEmpty,inputs:{leftHand:{id:"condition-not-empty-input-id"}}}},[r.GlobalEvent]:{[on.PROJECT_PUBLICATION_COMPLETED]:{id:on.PROJECT_PUBLICATION_COMPLETED}}},Yt=x["primitive-entity"],k={type:r.PrimitiveEntity,id:Yt.string.id,description:"A string of characters.",version:1,name:A.String,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]},An={type:r.PrimitiveEntity,id:Yt.boolean.id,description:"A 'true' or 'false' value.",version:1,name:A.Boolean,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]},Ce={type:r.PrimitiveEntity,id:Yt.number.id,description:"A number value.",version:1,name:A.Number,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]},et={type:r.PrimitiveEntity,id:"730e8ea9-8498-439a-9001-b07de55aaa7d",description:"A complex data structure with any combination of properties with names and values.",version:1,name:A.JSON,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]},Xd={id:"c2f52f01-8f2e-490e-8083-72289c8189c1",type:r.GenericReference,entityId:"7dd59b70-f97b-43a7-a051-fde1842ce5d6",entityType:r.DataType},Qd={id:"4e803941-2e6a-4227-b803-b8877c0d7fee",type:r.GenericReference,entityId:"00ccfcae-2104-45ef-bf6c-50ddccd74286",entityType:r.Property},Kd={like:!1,id:Yt.enum.properties.options.dataType.id,version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:k,asType:!1,defaultValue:{id:Yt.enum.properties.options.dataType.defaultValue.id,type:r.PrimitiveValue,version:1,name:A.JSON,autogeneration:null,value:[],valueAsType:null,parent:Xd},parent:Qd},eu={id:"a2983c4c-0286-4ef1-8b5c-5a52904d3200",type:r.GenericReference,entityId:"9542b8b4-2642-4eee-9db9-def7963a17a0",entityType:r.PrimitiveEntity},tu={hidden:!1,required:!0,id:Yt.enum.properties.options.id,name:"Options",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:0,dataType:Kd,description:"Options for the enum. Each option is a text value.",parent:eu},Sn={type:r.PrimitiveEntity,id:Yt.enum.id,description:"A set of text options to choose from.",version:1,name:A.Enum,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[tu],methods:[]},cn={type:r.PrimitiveEntity,id:Yt.date.id,description:"A date and time value.",version:1,name:A.Date,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]},Ba={type:r.PrimitiveEntity,id:Yt.uuid.id,description:"A unique identifier in the form of a 36-character string.",version:1,name:A.UUID,static:!1,abstract:!1,abstractMethods:[],extends:[k],properties:[],methods:[]},_o={type:r.PrimitiveEntity,id:Yt.json.id,description:"A complex data structure with any combination of properties with names and values.",version:1,name:A.JSON,static:!1,abstract:!1,abstractMethods:[],extends:[],properties:[],methods:[]};var nu=(n=>(n.FirstInputNumber="number-addition-first-number-argument-declaration",n.SecondInputNumber="number-addition-second-number-argument-declaration",n))(nu||{}),ru=(n=>(n.ResultNumber="number-addition-result-number-return-delaration",n.Error="number-addition-error-return-delaration",n))(ru||{});const iu={type:r.GenericReference,id:"3bd4aeb2-e3b7-4120-b289-011ebb03dba5",entityId:"number-addition-first-number-argument-declaration",entityType:r.ValueDescriptor},au={like:!1,id:"number-addition-first-number-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:iu},su={type:r.GenericReference,id:"9f486db2-a983-4293-9eef-81d4fc8d2d3e",entityId:"number-addition-second-number-argument-declaration",entityType:r.ValueDescriptor},ou={like:!1,id:"1d4abe83-3e87-4f74-99be-c1fd8c2f8d2d",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:su},lu={type:r.GenericReference,id:"da5e9fe9-f18a-49e3-98e5-c1bf7b9b3153",entityId:"number-addition-result-number-return-delaration",entityType:r.ValueDescriptor},cu={like:!1,id:"b761acec-0755-4582-a68b-76267038bbe1",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:lu},du={type:r.GenericReference,id:"a6c14305-d4f7-43ae-9d5e-b7dbacdc830a",entityId:lt.Addition,entityType:r.ActionDescriptor},Mo={id:"number-addition-first-number-argument-declaration",type:r.ValueDescriptor,version:1,name:"First value",description:"The first number to add",dataType:au,required:!0,parentRelationType:M.FixedArguments,index:0,parent:du},uu={type:r.GenericReference,id:"c5015128-4a65-462c-9da0-1c86e83ef897",entityId:lt.Addition,entityType:r.ActionDescriptor},No={id:"number-addition-second-number-argument-declaration",type:r.ValueDescriptor,description:"The second number to add",version:1,name:"Second value",dataType:ou,required:!0,parentRelationType:M.FixedArguments,index:1,parent:uu},pu={type:r.GenericReference,id:"caac2bc7-c23c-4f01-9581-a515c2e4637f",entityId:lt.Addition,entityType:r.ActionDescriptor},Vo={parentRelationType:M.FixedReturns,id:"number-addition-result-number-return-delaration",type:r.ValueDescriptor,description:"The result number of the addition",version:1,name:"Result",dataType:cu,required:!0,index:0,parent:pu},yu={type:r.GenericReference,id:"number-addition-operation-error-parent-ref",entityId:lt.Addition,entityType:r.ActionDescriptor},hu={parentRelationType:M.FixedReturns,id:"number-addition-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:yu},wa={id:lt.Addition,type:r.ActionDescriptor,description:"Add two numbers together",version:1,name:lt.Addition,fixedArguments:[Mo,No],error:hu,fixedReturns:[Vo],argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},fu={[lt.Addition]:wa};var mu=(n=>(n.FirstInputString="join-string-first-string-argument-declaration",n.SecondInputString="join-string-second-string-argument-declaration",n))(mu||{}),Tu=(n=>(n.ResultString="join-string-result-string-return-delaration",n.Error="join-string-error-return-delaration",n))(Tu||{});const Eu={type:r.GenericReference,id:"join-string-first-string-argument-declaration",entityId:"join-string-first-string-argument-declaration",entityType:r.ValueDescriptor},Ru={like:!1,id:"join-string-first-string-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Eu},bu={type:r.GenericReference,id:"join-string-second-string-argument-declaration",entityId:"join-string-second-string-argument-declaration",entityType:r.ValueDescriptor},gu={like:!1,id:"join-string-second-string-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:bu},vu={type:r.GenericReference,id:"join-string-result-string-return-delaration",entityId:"join-string-result-string-return-delaration",entityType:r.ValueDescriptor},Iu={like:!1,id:"join-string-result-string-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:vu},Du={type:r.GenericReference,id:"join-string-operation-first-string-argument-parent-ref",entityId:Ae.Join,entityType:r.ActionDescriptor},_a={id:"join-string-first-string-argument-declaration",type:r.ValueDescriptor,version:1,name:"First value",description:"The first text to join to the second one. Its value will be at the beginning of the resulting text.",dataType:Ru,parentRelationType:M.FixedArguments,required:!0,index:0,parent:Du},Pu={type:r.GenericReference,id:"join-string-operation-second-string-argument-parent-ref",entityId:Ae.Join,entityType:r.ActionDescriptor},Ma={id:"join-string-second-string-argument-declaration",type:r.ValueDescriptor,version:1,name:"Second value",description:"The second text to join to the first one. Its value will be at the end of the resulting text.",dataType:gu,parentRelationType:M.FixedArguments,required:!0,index:1,parent:Pu},Au={type:r.GenericReference,id:"join-string-operation-result-string-return-parent-ref",entityId:Ae.Join,entityType:r.ActionDescriptor},bi={parentRelationType:M.FixedReturns,id:"join-string-result-string-return-delaration",type:r.ValueDescriptor,version:1,name:"Result",description:"The resulting text value.",dataType:Iu,required:!0,index:0,parent:Au},Su={type:r.GenericReference,id:"join-string-operation-error-parent-ref",entityId:Ae.Join,entityType:r.ActionDescriptor},Ou={parentRelationType:M.FixedReturns,id:"join-string-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Su},gi={id:Ae.Join,type:r.ActionDescriptor,version:1,name:Ae.Join,description:"Join two text together, to form a single resulting text value.",fixedArguments:[_a,Ma],fixedReturns:[bi],error:Ou,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},Cu={[Ae.Join]:gi};var Bu=(n=>(n.FirstInputList="join-list-first-list-argument-declaration",n.SecondInputList="join-list-second-list-argument-declaration",n))(Bu||{}),wu=(n=>(n.ResultList="join-list-result-list-return-delaration",n.Error="join-list-error-return-delaration",n))(wu||{});const _u={type:r.GenericReference,id:"join-list-operation-first-list-argument-ref",entityId:"join-list-first-list-argument-declaration",entityType:r.ValueDescriptor},Mu={like:!1,id:"join-list-first-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:_u},Nu={type:r.GenericReference,id:"join-list-operation-second-list-argument-ref",entityId:"join-list-second-list-argument-declaration",entityType:r.ValueDescriptor},Vu={like:!1,id:"join-list-second-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Nu},$u={type:r.GenericReference,id:"join-list-operation-result-list-return-ref",entityId:"join-list-result-list-return-delaration",entityType:r.ValueDescriptor},Lu={like:!1,id:"join-list-result-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:$u},Gu={type:r.GenericReference,id:"join-list-operation-first-list-argument-parent-ref",entityId:W.Join,entityType:r.ActionDescriptor},Fu={id:"join-list-first-list-argument-declaration",type:r.ValueDescriptor,version:1,name:"First value",description:"The first list to join to the second one. Its values will be at the beginning of the resulting list.",dataType:Mu,parentRelationType:M.FixedArguments,required:!0,index:0,parent:Gu},Uu={type:r.GenericReference,id:"join-list-operation-second-list-argument-parent-ref",entityId:W.Join,entityType:r.ActionDescriptor},xu={id:"join-list-second-list-argument-declaration",type:r.ValueDescriptor,version:1,name:"Second value",description:"The second list to join to the first one. Its values will be at the end of the resulting list.",dataType:Vu,parentRelationType:M.FixedArguments,required:!0,index:1,parent:Uu},ku={type:r.GenericReference,id:"join-list-operation-result-list-return-parent-ref",entityId:W.Join,entityType:r.ActionDescriptor},ju={parentRelationType:M.FixedReturns,id:"join-list-result-list-return-delaration",type:r.ValueDescriptor,version:1,name:"Result",description:"The resulting list value.",dataType:Lu,required:!0,index:0,parent:ku},qu={type:r.GenericReference,id:"join-list-operation-error-parent-ref",entityId:W.Join,entityType:r.ActionDescriptor},Ju={parentRelationType:M.FixedReturns,id:"join-list-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:qu},$o={id:W.Join,type:r.ActionDescriptor,version:1,name:W.Join,description:"Join two lists together, to form a single resulting list value.",fixedArguments:[Fu,xu],error:Ju,fixedReturns:[ju],argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null};var Wu=(n=>(n.InputList="list-to-split-argument-declaration",n.SplitIndex="split-list-index-argument-declaration",n))(Wu||{}),Hu=(n=>(n.FirstOutputList="split-list-first-output-list-return-delaration",n.SecondOutputList="split-list-second-output-list-return-delaration",n.Error="split-list-error-return-delaration",n))(Hu||{});const Yu={type:r.GenericReference,id:"split-list-operation-input-list-argument-ref",entityId:"list-to-split-argument-declaration",entityType:r.ValueDescriptor},zu={like:!1,id:"split-list-operation-input-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Yu},Zu={type:r.GenericReference,id:"split-list-operation-split-index-argument-ref",entityId:"split-list-index-argument-declaration",entityType:r.ValueDescriptor},Xu={like:!1,id:"split-list-operation-split-index-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Zu},Lo={type:r.GenericReference,id:"split-list-operation-first-output-list-return-ref",entityId:"split-list-first-output-list-return-delaration",entityType:r.ValueDescriptor},Qu={like:!1,id:"split-list-operation-first-output-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Lo},Ku={type:r.GenericReference,id:"split-list-operation-input-list-argument-parent-ref",entityId:W.Split,entityType:r.ActionDescriptor},ep={id:"list-to-split-argument-declaration",type:r.ValueDescriptor,version:1,name:"List to split",description:"The list to split at the given index",dataType:zu,parentRelationType:M.FixedArguments,required:!0,index:0,parent:Ku},tp={type:r.GenericReference,id:"split-list-operation-split-index-argument-parent-ref",entityId:W.Split,entityType:r.ActionDescriptor},np={id:"split-list-index-argument-declaration",type:r.ValueDescriptor,version:1,name:"Split location",description:"The index at which to split the list. The value at this index will be the first value of the second list.",dataType:Xu,parentRelationType:M.FixedArguments,required:!0,index:1,parent:tp},rp={type:r.GenericReference,id:"split-list-operation-first-output-list-return-parent-ref",entityId:W.Split,entityType:r.ActionDescriptor},ip={parentRelationType:M.FixedReturns,id:"split-list-first-output-list-return-delaration",type:r.ValueDescriptor,version:1,name:"First list",description:"The list of values up to the split index",dataType:Qu,required:!0,index:0,parent:rp},ap={like:!1,id:"split-list-operation-second-output-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Lo},sp={type:r.GenericReference,id:"split-list-operation-second-output-list-return-parent-ref",entityId:W.Split,entityType:r.ActionDescriptor},op={parentRelationType:M.FixedReturns,id:"split-list-second-output-list-return-delaration",type:r.ValueDescriptor,version:1,name:"Second list",description:"The list of values up to the split index",dataType:ap,required:!0,index:0,parent:sp},lp={type:r.GenericReference,id:"split-list-operation-error-parent-ref",entityId:W.Split,entityType:r.ActionDescriptor},cp={parentRelationType:M.FixedReturns,id:"split-list-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:lp},Go={id:W.Split,type:r.ActionDescriptor,version:1,name:W.Split,description:"Splits a given list at the given index, and returns two lists, one with the values up to the index, and the other with the values after the index",fixedArguments:[ep,np],fixedReturns:[ip,op],error:cp,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null};var dp=(n=>(n.InputList="get-last-in-list-input-list-argument-declaration",n))(dp||{}),up=(n=>(n.OutputElement="get-last-in-list-output-element-return-delaration",n.Error="get-last-in-list-error-return-delaration",n))(up||{});const pp={type:r.GenericReference,id:"get-last-in-list-operation-input-list-argument-ref",entityId:"get-last-in-list-input-list-argument-declaration",entityType:r.ValueDescriptor},yp={like:!1,id:"get-last-in-list-input-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:pp},hp={type:r.GenericReference,id:"get-last-in-list-operation-output-element-return-ref",entityId:"get-last-in-list-output-element-return-delaration",entityType:r.ValueDescriptor},fp={like:!1,id:"get-last-in-list-output-element-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:hp},mp={type:r.GenericReference,id:"get-last-in-list-operation-input-list-argument-parent-ref",entityId:W.GetLast,entityType:r.ActionDescriptor},Tp={id:"get-last-in-list-input-list-argument-declaration",type:r.ValueDescriptor,version:1,name:"List",description:"The list to get the last element from.",dataType:yp,parentRelationType:M.FixedArguments,required:!0,index:0,parent:mp},Ep={type:r.GenericReference,id:"get-last-in-list-operation-output-element-return-parent-ref",entityId:W.GetLast,entityType:r.ActionDescriptor},Rp={parentRelationType:M.FixedReturns,id:"get-last-in-list-output-element-return-delaration",type:r.ValueDescriptor,version:1,name:"Last element",description:"The last element of the given list.",dataType:fp,required:!0,index:0,parent:Ep},bp={type:r.GenericReference,id:"get-last-in-list-operation-error-parent-ref",entityId:W.GetLast,entityType:r.ActionDescriptor},gp={parentRelationType:M.FixedReturns,id:"get-last-in-list-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:bp},Fo={id:W.GetLast,type:r.ActionDescriptor,version:1,name:W.GetLast,description:"Outputs the last element of a given list.",fixedArguments:[Tp],fixedReturns:[Rp],error:gp,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null};var vp=(n=>(n.List="append-to-list-lsit-argument-declaration",n.ElementToAppend="append-to-list-element-to-append-argument-declaration",n))(vp||{}),Ip=(n=>(n.ResultList="append-to-list-result-list-return-delaration",n.Error="append-to-list-error-return-delaration",n))(Ip||{});const Dp={type:r.GenericReference,id:"append-to-list-operation-lsit-argument-ref",entityId:"append-to-list-lsit-argument-declaration",entityType:r.ValueDescriptor},Pp={like:!1,id:"append-to-list-lsit-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Dp},Ap={type:r.GenericReference,id:"append-to-list-operation-second-list-argument-ref",entityId:"append-to-list-element-to-append-argument-declaration",entityType:r.ValueDescriptor},Sp={like:!1,id:"append-to-list-second-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Ap},Op={type:r.GenericReference,id:"append-to-list-operation-result-list-return-ref",entityId:"append-to-list-result-list-return-delaration",entityType:r.ValueDescriptor},Cp={like:!1,id:"append-to-list-result-list-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Op},Bp={type:r.GenericReference,id:"append-to-list-operation-lsit-argument-parent-ref",entityId:W.Append,entityType:r.ActionDescriptor},Uo={id:"append-to-list-lsit-argument-declaration",type:r.ValueDescriptor,version:1,name:"List value",description:"The list to which the element will be appended",dataType:Pp,parentRelationType:M.FixedArguments,required:!0,index:0,parent:Bp},wp={type:r.GenericReference,id:"append-to-list-operation-second-list-argument-parent-ref",entityId:W.Append,entityType:r.ActionDescriptor},xo={id:"append-to-list-element-to-append-argument-declaration",type:r.ValueDescriptor,version:1,name:"Element",description:"The element that will be added at the end of the list",dataType:Sp,parentRelationType:M.FixedArguments,required:!0,index:1,parent:wp},_p={type:r.GenericReference,id:"append-to-list-operation-result-list-return-parent-ref",entityId:W.Append,entityType:r.ActionDescriptor},Mp={parentRelationType:M.FixedReturns,id:"append-to-list-result-list-return-delaration",type:r.ValueDescriptor,version:1,name:"Result",description:"The resulting list value.",dataType:Cp,required:!0,index:0,parent:_p},Np={type:r.GenericReference,id:"append-to-list-operation-error-parent-ref",entityId:W.Append,entityType:r.ActionDescriptor},Vp={parentRelationType:M.FixedReturns,id:"append-to-list-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Np},Na={id:W.Append,type:r.ActionDescriptor,version:1,name:W.Append,description:"Adds a given element to the end of a list value.",fixedArguments:[Uo,xo],error:Vp,fixedReturns:[Mp],argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},$p={[W.Join]:$o,[W.Split]:Go,[W.GetLast]:Fo,[W.Append]:Na};var Lp=(n=>(n.ListOfFunctions="parallel-execution-list-of-functions-argument-declaration",n))(Lp||{}),Gp=(n=>(n.ListOfExecutionResults="parallel-execution-result-return-delaration",n.Error="parallel-execution-error-return-delaration",n))(Gp||{});const Fp={id:"parallel-execution-list-of-functions-blueprint-id",type:r.ActionDescriptor,version:1,name:"Action to execute",description:"An action of any type, to be executed. It can contain any number of inputs and outputs.",argumentsType:U.Dynamic,dynamicArgumentTypes:null,fixedArguments:[],returnsType:U.Dynamic,dynamicReturnTypes:null,fixedReturns:[],error:null,parent:null},Up={type:r.GenericReference,id:"3bd4aeb2-e3b7-4120-b289-011ebb03dba5",entityId:"parallel-execution-list-of-functions-argument-declaration",entityType:r.ValueDescriptor},xp={like:!1,id:"parallel-execution-list-of-functions-argument-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Fp,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Up},kp={type:r.GenericReference,id:"da5e9fe9-f18a-49e3-98e5-c1bf7b9b3153",entityId:"parallel-execution-result-return-delaration",entityType:r.ValueDescriptor},jp={like:!1,id:"b761acec-0755-4582-a68b-76267038bbe1",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:kp},qp={type:r.GenericReference,id:"a6c14305-d4f7-43ae-9d5e-b7dbacdc830a",entityId:Oe.Parallel,entityType:r.ActionDescriptor},ko={id:"parallel-execution-list-of-functions-argument-declaration",type:r.ValueDescriptor,version:1,name:"Actions to execute",description:"A value, of a list of actions to be executed in parallel",dataType:xp,required:!0,index:0,parent:qp,parentRelationType:M.FixedArguments},Jp={type:r.GenericReference,id:"caac2bc7-c23c-4f01-9581-a515c2e4637f",entityId:Oe.Parallel,entityType:r.ActionDescriptor},jo={id:"parallel-execution-result-return-delaration",type:r.ValueDescriptor,version:1,name:"List of execution results",description:"Each execution result, in the same order as the input list of actions. One item on this list for each executed action.",dataType:jp,required:!0,index:0,parent:Jp,parentRelationType:M.FixedReturns},Wp={type:r.GenericReference,id:"parallel-execution-operation-error-parent-ref",entityId:Oe.Parallel,entityType:r.ActionDescriptor},Hp={id:"parallel-execution-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Wp,parentRelationType:M.ReturnedError},xt={id:Oe.Parallel,type:r.ActionDescriptor,description:"Execute a list of actions in parallel",version:1,name:Oe.Parallel,fixedArguments:[ko],fixedReturns:[jo],argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,error:Hp,parent:null};var Yp=(n=>(n.MillisecondsNumber="wait-milliseconds-number-argument-declaration",n))(Yp||{}),zp=(n=>(n.Error="wait-operation-error-return-delaration",n))(zp||{});const Zp={type:r.GenericReference,id:"3bd4aeb2-e3b7-4120-b289-011ebb03dba5",entityType:r.ValueDescriptor,entityId:"wait-milliseconds-number-argument-declaration"},Xp={like:!1,id:"wait-milliseconds-number-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Zp},Qp={type:r.GenericReference,id:"a6c14305-d4f7-43ae-9d5e-b7dbacdc830a",entityType:r.ActionDescriptor,entityId:Oe.Wait},Zn={id:"wait-milliseconds-number-argument-declaration",type:r.ValueDescriptor,version:1,name:"Milliseconds to wait",description:"The amount of milliseconds to wait before calling the next entity",dataType:Xp,required:!0,index:0,parent:Qp,parentRelationType:M.FixedArguments},Kp={type:r.GenericReference,id:"wait-operation-error-parent-ref",entityId:Oe.Wait,entityType:r.ActionDescriptor},ey={id:"wait-operation-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Kp,parentRelationType:M.ReturnedError},dt={id:Oe.Wait,type:r.ActionDescriptor,description:"Wait for the given amount of milliseconds before calling the next entity",version:1,name:Oe.Wait,fixedArguments:[Zn],fixedReturns:[],error:ey,argumentsType:U.Fixed,returnsType:U.None,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null};var ty=(n=>(n.ListOfFunctions="sequential-execution-list-of-functions-argument-declaration",n))(ty||{}),ny=(n=>(n.ListOfExecutionResults="sequential-execution-result-return-delaration",n.Error="sequential-execution-error-return-delaration",n))(ny||{});const ry={id:"sequential-execution-list-of-functions-blueprint-id",type:r.ActionDescriptor,version:1,name:"Action to execute",description:"An action of any type, to be executed. It can contain any number of inputs and outputs.",argumentsType:U.Dynamic,dynamicArgumentTypes:null,fixedArguments:[],returnsType:U.Dynamic,dynamicReturnTypes:null,fixedReturns:[],error:null,parent:null},iy={type:r.GenericReference,id:"parallel-execution-list-of-functions-argument-declaration-id",entityId:"sequential-execution-list-of-functions-argument-declaration",entityType:r.ValueDescriptor},ay={like:!1,id:"sequential-execution-list-of-functions-argument-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:ry,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:iy},sy={type:r.GenericReference,id:"sequential-execution-list-of-execution-results-return-declaration-id",entityId:"sequential-execution-result-return-delaration",entityType:r.ValueDescriptor},oy={like:!1,id:"sequential-execution-list-of-execution-results-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!0,isNullable:!1,defaultValue:null,constant:!1,parent:sy},ly={type:r.GenericReference,id:"parallel-execution-operation-list-of-functions-argument-parent-ref",entityId:Oe.Sequential,entityType:r.ActionDescriptor},qo={id:"sequential-execution-list-of-functions-argument-declaration",type:r.ValueDescriptor,version:1,name:"Actions to execute",description:"A value, of a list of actions to be executed in parallel",dataType:ay,required:!0,index:0,parent:ly,parentRelationType:M.FixedArguments},cy={type:r.GenericReference,id:"parallel-execution-operation-list-of-execution-results-return-parent-ref",entityId:Oe.Sequential,entityType:r.ActionDescriptor},Jo={id:"sequential-execution-result-return-delaration",type:r.ValueDescriptor,version:1,name:"List of execution results",description:"Each execution result, in the same order as the input list of actions. One item on this list for each executed action.",dataType:oy,required:!0,index:0,parent:cy,parentRelationType:M.FixedReturns},dy={type:r.GenericReference,id:"sequential-execution-operation-error-parent-ref",entityId:Oe.Sequential,entityType:r.ActionDescriptor},uy={id:"sequential-execution-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:dy,parentRelationType:M.ReturnedError},dn={id:Oe.Sequential,type:r.ActionDescriptor,description:"Execute a list of actions one after the other",version:1,name:Oe.Sequential,fixedArguments:[qo],fixedReturns:[Jo],error:uy,returnsType:U.Fixed,argumentsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},py={[Oe.Parallel]:xt,[Oe.Wait]:dt,[Oe.Sequential]:dn};var yy=(n=>(n.EntityToInstanciate="entity-to-instanciate-argument-declaration",n.NewEntityData="new-entity-data-argument-declaration",n))(yy||{}),hy=(n=>(n.Error="create-new-instance-error-return-delaration",n))(hy||{});const fy={type:r.GenericReference,id:"new-entity-data-argument-declaration-parent-ref",entityId:Ze.CreateNewInstance,entityType:r.ActionDescriptor},my={type:r.GenericReference,id:"new-entity-data-argument-data-type-parent-ref",entityId:"new-entity-data-argument-declaration",entityType:r.ValueDescriptor},Ty={like:!1,id:"new-entity-data-argument-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:my},Ey={id:"new-entity-data-argument-declaration",type:r.ValueDescriptor,version:1,name:"Data for new entity",description:"The data to be used to create the new entity, with all the required properties",dataType:Ty,required:!0,parentRelationType:M.FixedArguments,index:1,parent:fy},Ry={type:r.GenericReference,id:"entity-to-instanciate-argument-declaration-ref",entityType:r.ValueDescriptor,entityId:"entity-to-instanciate-argument-declaration"},by={like:!1,id:"entity-to-instanciate-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,isList:!1,asType:!0,isNullable:!1,defaultValue:null,constant:!1,parent:Ry},gy={type:r.GenericReference,id:"create-new-instance-operation-ref",entityType:r.ActionDescriptor,entityId:Ze.CreateNewInstance},vy={id:"entity-to-instanciate-argument-declaration",type:r.ValueDescriptor,version:1,name:"Entity to create a new copy of",description:"The entity of which a new copy will to be created",dataType:by,required:!0,parentRelationType:M.FixedArguments,index:0,parent:gy},Iy={type:r.GenericReference,id:"create-new-instance-output-entity-declaration-parent-ref",entityId:Ze.CreateNewInstance,entityType:r.ActionDescriptor},Dy={parentRelationType:M.FixedReturns,id:"create-new-instance-output-entity-declaration",type:r.ValueDescriptor,version:1,dataType:null,name:"Created entity",description:"The entity that was created",parent:Iy,required:!0,index:0},Py={type:r.GenericReference,id:"create-new-instance-error-parent-ref",entityId:Ze.CreateNewInstance,entityType:r.ActionDescriptor},Ay={parentRelationType:M.FixedReturns,id:"create-new-instance-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Py},Xn={id:Ze.CreateNewInstance,type:r.ActionDescriptor,description:"Creates a new copy of a given entity, with the given values for each property, or default values if a value is not provided",version:1,name:Ze.CreateNewInstance,fixedArguments:[vy,Ey],fixedReturns:[Dy],error:Ay,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null};var Sy=(n=>(n.EntityToMatchType="validate-data-operation-entity-to-match-type-argument-declaration",n.DataToValidate="validate-data-operation-data-to-validate-argument-declaration",n))(Sy||{}),Oy=(n=>(n.Error="validate-data-error-return-delaration",n.OutputEntity="validate-data-output-entity-declaration",n))(Oy||{});const Cy={type:r.GenericReference,id:"validate-data-operation-data-to-validate-argument-declaration-ref",entityType:r.ValueDescriptor,entityId:"validate-data-operation-data-to-validate-argument-declaration"},By={like:!1,id:"validate-data-operation-data-to-validate-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Cy},wy={type:r.GenericReference,id:"validate-data-operation-data-to-validate-argument-parent-ref",entityType:r.ActionDescriptor,entityId:Ze.Validate},_y={id:"validate-data-operation-data-to-validate-argument-declaration",type:r.ValueDescriptor,version:1,name:"Data to validate",description:"The value to validate against the given entity type",dataType:By,required:!0,parentRelationType:M.FixedArguments,index:0,parent:wy},My={type:r.GenericReference,id:"validate-data-operation-entity-to-match-type-argument-declaration-ref",entityType:r.ValueDescriptor,entityId:"validate-data-operation-entity-to-match-type-argument-declaration"},Ny={like:!1,id:"validate-data-operation-entity-to-match-type-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,isList:!1,asType:!0,isNullable:!1,defaultValue:null,constant:!1,parent:My},Vy={type:r.GenericReference,id:"validate-data-operation-entity-to-match-type-argument-parent-ref",entityType:r.ActionDescriptor,entityId:Ze.Validate},$y={id:"validate-data-operation-entity-to-match-type-argument-declaration",type:r.ValueDescriptor,version:1,name:"Entity to match",description:"The entity to match the data against",dataType:Ny,required:!0,index:0,parentRelationType:M.FixedArguments,parent:Vy},Ly={type:r.GenericReference,id:"validate-data-operation-output-entity-declaration-parent-ref",entityId:Ze.Validate,entityType:r.ActionDescriptor},Gy={id:"validate-data-output-entity-declaration",type:r.ValueDescriptor,version:1,dataType:null,name:"Output value",description:"A value with the type of the entity that was validated",parent:Ly,required:!0,index:0,parentRelationType:M.FixedReturns},Fy={type:r.GenericReference,id:"wait-operation-error-parent-ref",entityId:Ze.Validate,entityType:r.ActionDescriptor},Uy={id:"validate-data-error-return-delaration",type:r.ValueDescriptor,version:1,name:"Error",description:"An error that occurred during the operation.",dataType:null,required:!0,index:1,parent:Fy,parentRelationType:M.ReturnedError},Qn={id:Ze.Validate,type:r.ActionDescriptor,description:"Validates the given data to see if it matches the structure of a given type/entity",version:1,name:Ze.Validate,fixedArguments:[$y,_y],fixedReturns:[Gy],error:Uy,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},xy={[Ze.CreateNewInstance]:Xn,[Ze.Validate]:Qn},He=x[r.Operation]["base-http-request"],ky={type:r.GenericReference,id:"d87cf943-57e1-4d19-9f05-190fa8c8ebc4",entityType:r.DataType,entityId:"0deb4ef7-d739-4ddc-a4d6-50bd6fababe3"},jy={id:"http-request-url-default-value-id",type:r.PrimitiveValue,version:1,value:"https://some-url.com",name:A.String,valueAsType:null,parent:ky,autogeneration:null},qy={type:r.GenericReference,id:"aed50d73-eab5-42ce-b00e-7f5c45a9026f",entityId:He.inputs.url.id,entityType:r.ValueDescriptor},Jy={like:!1,id:"0deb4ef7-d739-4ddc-a4d6-50bd6fababe3",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:jy,constant:!1,parent:qy},Wy={type:r.GenericReference,id:"c3145af6-3387-464a-8887-272e483c856d",entityId:He.inputs.query.id,entityType:r.ValueDescriptor},Hy={like:!1,id:"2a5ba737-6335-4cc4-a2c0-16dca4052fac",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Wy},Yy={type:r.GenericReference,id:"075556b7-e468-48f7-8485-7159eaf389b2",entityType:r.DataType,entityId:"6df7ec2b-5dbd-44af-896b-17b314e88560"},zy={id:"http-request-method-default-value-id",type:r.PrimitiveValue,version:1,value:"GET",name:A.Enum,valueAsType:null,parent:Yy,autogeneration:null},Zy={type:r.GenericReference,id:"aed647c8-a1b5-4cfc-9a3d-97887a567a80",entityId:He.inputs.method.id,entityType:r.ValueDescriptor},Xy={like:!1,id:"6df7ec2b-5dbd-44af-896b-17b314e88560",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Sn,isList:!1,asType:!1,isNullable:!1,defaultValue:zy,options:["GET","POST","PUT","DELETE","PATCH","OPTIONS","HEAD","TRACE","CONNECT","CUSTOM"],constant:!1,parent:Zy},Qy={type:r.GenericReference,id:"77203dfa-d2f6-4804-9556-e1cce46228f3",entityId:He.inputs.headers.id,entityType:r.ValueDescriptor},Ky={like:!1,id:"2c8a2a07-69c6-40ad-b5c9-f0dc4d5955ce",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Qy},eh={type:r.GenericReference,id:"03db68a0-7ab6-4c6a-85b6-f4b95ebb53ff",entityId:He.inputs.body.id,entityType:r.ValueDescriptor},th={like:!1,id:"0397876c-ed54-4ee9-85a4-04fd16dad973",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:eh},nh={type:r.GenericReference,id:"182f767f-50e8-4394-ba5f-43e78c232733",entityType:r.ValueDescriptor,entityId:He.outputs.code.id},rh={like:!1,id:"45e6d0bc-0c0e-4059-a7a1-6bee925d73d0",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:nh},ih={type:r.GenericReference,id:"2baaa53a-9aef-4bd1-b06d-967c17b7b627",entityType:r.DataType,entityId:"dac63bfa-640d-4f4e-ba0f-86c2401bcfbe"},ah={type:r.GenericReference,id:"69f34d6c-c686-4165-b6ff-70dae8e1778b",entityType:r.ValueDescriptor,entityId:He.outputs.headers.id},sh={like:!1,id:"dac63bfa-640d-4f4e-ba0f-86c2401bcfbe",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,isList:!1,isNullable:!1,asType:!1,defaultValue:{id:"http-response-headers-default-value-id",type:r.PrimitiveValue,version:1,value:{},name:A.JSON,parent:ih,valueAsType:null,autogeneration:null},constant:!1,parent:ah},oh={type:r.GenericReference,id:"744334e0-5135-4214-85d0-809437cb620b",entityType:r.DataType,entityId:"05fc1a5d-151a-479a-9c4e-4063f3456177"},lh={type:r.GenericReference,id:"0e0e20df-1a46-432c-ba01-fd96508a6a61",entityType:r.ValueDescriptor,entityId:He.outputs.body.id},ch={like:!1,id:"05fc1a5d-151a-479a-9c4e-4063f3456177",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,isList:!1,isNullable:!1,asType:!1,defaultValue:{id:"http-response-body-default-value-id",type:r.PrimitiveValue,version:1,value:{},name:A.JSON,parent:oh,valueAsType:null,autogeneration:null},constant:!1,parent:lh},dh={type:r.GenericReference,id:"26911792-f707-4bf1-b6f7-03d04a84232c",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Va={id:He.inputs.method.id,type:r.ValueDescriptor,description:"A single word that represents the type of request you want to make. For example: GET, POST, PUT, DELETE, PATCH, OPTIONS, HEAD, TRACE, CONNECT, CUSTOM",version:1,name:"Method",dataType:Xy,required:!1,index:0,parentRelationType:M.FixedArguments,parent:dh},uh={type:r.GenericReference,id:"eee0c501-0ae6-4448-b914-aada76d63163",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},$a={id:He.inputs.url.id,type:r.ValueDescriptor,description:"The base domain, or address where the request is being sent to. For example: https://some-url.com",version:1,name:"URL",dataType:Jy,required:!1,index:1,parentRelationType:M.FixedArguments,parent:uh},ph={type:r.GenericReference,id:"670091a4-21b1-4223-ad4c-b6dada0aec49",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Wo={id:He.inputs.query.id,type:r.ValueDescriptor,description:"A text with standarized format, without spaces that is added at the end of the URL path, after the ? character. It contains data that might be used to process the request. For example: /api/users?name=John&age=30",version:1,name:"Query Params",dataType:Hy,required:!1,index:2,parentRelationType:M.FixedArguments,parent:ph},yh={type:r.GenericReference,id:"85aad3eb-22fe-45f9-b68c-1dc7061f41e0",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},La={id:He.inputs.headers.id,type:r.ValueDescriptor,description:"A set of any properties, with names and values that represent metadata about the request, such as the server, date, content type, and more, that you want to send alongside your request data.",version:1,name:"Headers",dataType:Ky,required:!1,index:3,parent:yh,parentRelationType:M.FixedArguments},hh={type:r.GenericReference,id:"c3e2a4af-9b84-4574-8b30-5044ffc51776",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Ga={id:He.inputs.body.id,type:r.ValueDescriptor,description:"The main data payload of the request. This is the data that you want to send to the server. It could be anything, but it is usually a JSON data structure or a text value.",version:1,name:"Body",dataType:th,required:!1,index:4,parentRelationType:M.FixedArguments,parent:hh},fh={type:r.GenericReference,id:"92e04dc7-2145-4a31-908e-03810f7235e8",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Ho={id:He.outputs.code.id,type:r.ValueDescriptor,description:'A standardized status code of the response. It is a 3-digit number that represents the response status. For example, 200 means "OK", 404 means "Not Found", and 500 means "Internal Server Error".',version:1,name:"Code",dataType:rh,required:!0,index:0,parentRelationType:M.FixedReturns,parent:fh},mh={type:r.GenericReference,id:"86aca556-bbf1-4679-9909-31db61b288e2",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Fa={parentRelationType:M.FixedReturns,id:He.outputs.headers.id,type:r.ValueDescriptor,description:"A set of any properties, with names and value that the server sent back to you. It represents metadata about the response, such as the server, date, content type, and more.",version:1,name:"Headers",dataType:sh,required:!0,index:1,parent:mh},Th={type:r.GenericReference,id:"ccf3d1be-04e4-4d03-99fd-5bc1e1919f90",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},vi={parentRelationType:M.FixedReturns,id:He.outputs.body.id,type:r.ValueDescriptor,description:"The main data payload of the response. This is the data that the server sent back to you. It could be anything, but it is usually a JSON data structure or a text value.",version:1,name:"Body",dataType:ch,required:!0,index:2,parent:Th},Eh={type:r.GenericReference,id:"21487ffc-82b9-473d-bc19-6e7d7c480ed7",entityType:r.ActionDescriptor,entityId:Xe.HttpRequest},Rh={type:r.GenericReference,id:"ad69861b-32f7-4461-b7f7-aa84a82578d9",entityType:r.ValueDescriptor,entityId:He.outputs.error.id},bh={like:!1,id:"5da68b15-57bc-40c1-b79f-a9075e0f22c1",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,isList:!1,asType:!1,isNullable:!1,constant:!1,defaultValue:null,parent:Rh},Yo={parentRelationType:M.ReturnedError,id:He.outputs.error.id,type:r.ValueDescriptor,description:"Http request error, if any. Contains a payload describing what went wrong.",version:1,name:"Error",dataType:bh,required:!0,index:0,parent:Eh},Ii={type:r.ActionDescriptor,id:Xe.HttpRequest,name:Xe.HttpRequest,description:"Make an HTTP request, out to the internet, to a given URL with the specified method, query parameters, headers, and body.",version:1,fixedArguments:[Va,$a,Wo,La,Ga],fixedReturns:[Ho,Fa,vi],argumentsType:U.Fixed,returnsType:U.Fixed,error:Yo,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},gh={[Xe.HttpRequest]:Ii},gI={...Cu,...fu,...$p,...py,...xy,...gh},vh=x[r.Loop]["list-loop"],Ih={id:"iterate-over-list-loop-return-declaration-parent-ref-id",type:r.GenericReference,entityId:Q.List,entityType:r.ActionDescriptor},Dh={id:vh.outputs.results.id,type:r.ValueDescriptor,version:1,name:"Results",description:"List of results from the loop. One item in the list for each iteration of the loop.",dataType:null,required:!0,index:0,parent:Ih,parentRelationType:M.FixedReturns},Ph={id:"iterate-over-list-loop-list-argument-declaration-data-type-parent-ref-id",type:r.GenericReference,entityId:"iterate-over-list-loop-list-argument-declaration-id",entityType:r.ArgumentDeclaration},Ah={like:!1,id:"iterate-over-list-loop-list-argument-declaration-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,isList:!0,isNullable:!1,constant:!1,entity:null,asType:!1,defaultValue:null,parent:Ph},Sh={id:"iterate-over-list-loop-list-argument-declaration-parent-ref-id",type:r.GenericReference,entityId:Q.List,entityType:r.ActionDescriptor},Oh={id:vh.inputs.list.id,type:r.ValueDescriptor,version:1,name:"List",description:"The list to iterate over",required:!0,dataType:Ah,index:0,parent:Sh,parentRelationType:M.FixedArguments},Kn={id:Q.List,type:r.ActionDescriptor,version:1,name:Q.List,description:"Iterates over a list of entities",fixedArguments:[Oh],fixedReturns:[Dh],error:null,argumentsType:U.Fixed,returnsType:U.Fixed,dynamicArgumentTypes:null,dynamicReturnTypes:null,parent:null},vI=x[r.Loop]["list-loop"],Ch={id:"manual-flow-loop-previous-iterations-results-declaration-data-type-parent-ref-id",type:r.GenericReference,entityId:"manual-flow-loop-previous-iterations-results-declaration-id",entityType:r.ReturnDeclaration},Bh={like:!1,id:"manual-flow-loop-previous-iterations-results-declaration-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,isList:!0,isNullable:!1,constant:!1,entity:null,asType:!1,defaultValue:null,parent:Ch},wh={id:"manual-flow-loop-previous-iterations-results-declaration-parent-ref-id",type:r.GenericReference,entityId:Q.ManualFlow,entityType:r.ActionDescriptor},_h={id:vI.outputs.results.id,type:r.ValueDescriptor,version:1,name:"Results",description:"List of results from the loop. One item in the list for each iteration of the loop.",dataType:Bh,required:!0,index:1,parentRelationType:M.FixedReturns,parent:wh},zo={id:Q.ManualFlow,type:r.ActionDescriptor,version:1,name:Q.ManualFlow,description:"A loop that is manually controlled by the continue and break statements. It runs until the break statement is called, and it can skip to the next iteration with the continue statement.",fixedArguments:[],dynamicArgumentTypes:null,dynamicReturnTypes:null,fixedReturns:[_h],argumentsType:U.None,returnsType:U.Fixed,error:null,parent:null},Ua=x[r.BuiltInBaseEntity][V.KEY_VALUE_PARAM],II={id:"key-value-param-built-in-base-entity-name-property-data-type-ref",type:r.GenericReference,entityId:"key-value-param-built-in-base-entity-name-property-data-type",entityType:r.DataType},Mh={id:"key-value-param-built-in-base-entity-name-property-ref",type:r.GenericReference,entityId:"key-value-param-built-in-base-entity-name-property",entityType:r.Property},DI={like:!1,id:"key-value-param-built-in-base-entity-name-property-data-type",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:k,asType:!1,defaultValue:null,parent:Mh},Nh={id:"key-value-param-built-in-base-entity-name-property-parent-ref",type:r.GenericReference,entityId:Ua.id,entityType:r.BuiltInBaseEntity},Vh={hidden:!1,required:!0,id:"key-value-param-built-in-base-entity-name-property",name:"Parameter name",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:0,dataType:DI,description:"The name of the path parameter",parent:Nh},PI={id:"key-value-param-built-in-base-entity-value-property-data-type-ref",type:r.GenericReference,entityId:"key-value-param-built-in-base-entity-value-property-data-type",entityType:r.DataType},$h={id:"key-value-param-built-in-base-entity-value-property-ref",type:r.GenericReference,entityId:"key-value-param-built-in-base-entity-value-property",entityType:r.Property},AI={like:!1,id:"key-value-param-built-in-base-entity-value-property-data-type",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:k,asType:!1,defaultValue:null,parent:$h},Lh={id:"key-value-param-built-in-base-entity-value-property-parent-ref",type:r.GenericReference,entityId:Ua.id,entityType:r.BuiltInBaseEntity},Gh={hidden:!1,required:!0,id:"key-value-param-built-in-base-entity-value-property",name:"Parameter Value",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:1,dataType:AI,description:"The value of the path parameter",parent:Lh},xa={id:Ua.id,version:1,description:'An entity with a "name" and "value" property representing a breakdown of a key-value pair.',name:Ua.id,type:r.BuiltInBaseEntity,abstract:!1,static:!1,interactive:!0,properties:[Vh,Gh],abstractMethods:[],methods:[],extends:[]},Di=x[r.BuiltInBaseEntity][V.HTTP_ENDPOINT].properties,Fh={id:"endpointBuiltInCorsPropertyDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointBuiltInCorsPropertyDataType"},Uh={id:"endpointBuiltInCorsPropertyRef",type:r.GenericReference,entityType:r.Property,entityId:Di.cors.id},xh={like:!1,id:"endpointBuiltInCorsPropertyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"endpointBuiltInCorsPropertyDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:["*"],parent:Fh,autogeneration:null,valueAsType:null},parent:Uh},kh={id:"endpointBuiltInBaseEntityRef",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},jh={hidden:!0,required:!0,id:Di.cors.id,name:"Allowed origins",version:1,type:r.Property,private:!1,abstract:!0,implements:null,static:!0,index:0,dataType:xh,description:"The origins that are allowed to access this endpoint, use * for all origins, or http://example.com/* to be as specific as you need.",parent:kh},qh={id:"endpointBuiltInPathPropertyDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointBuiltInPathPropertyDataType"},Jh={id:"endpointBuiltInPathPropertyRef",type:r.GenericReference,entityType:r.Property,entityId:Di.path.id},Wh={like:!1,id:"endpointBuiltInPathPropertyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"endpointBuiltInPathPropertyDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.String,value:"/",parent:qh,autogeneration:null,valueAsType:null},parent:Jh},Hh={id:"endpointBuiltInBaseEntityRefTwo",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},Zo={hidden:!1,required:!0,id:Di.path.id,name:"Path",version:1,type:r.Property,private:!1,abstract:!0,implements:null,static:!0,index:1,dataType:Wh,description:"Path to the endpoint, for example /api/users, or /api/users/{id}, or /api/users/{id}/:name. The path can contain parameters, which are defined by curly braces, and will be passed to the endpoint event as variables with the same name.",parent:Hh},Yh={id:"endpointBuiltInMethodPropertyDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointBuiltInMethodPropertyDataType"},zh={id:"endpointBuiltInMethodPropertyRef",type:r.GenericReference,entityType:r.Property,entityId:"endpointBuiltInMethodProperty"},Zh={like:!1,id:"endpointBuiltInMethodPropertyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:Sn,isList:!0,isNullable:!1,constant:!0,asType:!1,defaultValue:{id:"endpointBuiltInMethodPropertyDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,value:"GET",name:A.Enum,parent:Yh,autogeneration:null,valueAsType:null},options:["GET","POST","PUT","DELETE","PATCH","OPTIONS","HEAD","TRACE","CONNECT","CUSTOM"],parent:zh},Xh={id:"endpointBuiltInBaseEntityRefThree",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},Xo={hidden:!1,required:!0,id:Di.method.id,name:"Method",version:1,type:r.Property,private:!1,index:2,implements:null,abstract:!0,static:!0,dataType:Zh,description:"The HTTP method that this endpoint will respond to, for example GET, POST, PUT, DELETE, etc.",parent:Xh},Qh={id:"endpointRequestHeadersVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointRequestHeadersVariableDataType"},Kh={id:"endpointRequestHeadersArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"endpointRequestHeadersArgumentDeclaration"},ef={like:!1,id:"endpointRequestHeadersVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:et,asType:!1,defaultValue:{id:"endpointRequestHeadersVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:Qh,autogeneration:null,valueAsType:null},parent:Kh},tf={id:"endpointRequestBodyArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"endpointRequestBodyArgumentDeclaration"},nf={like:!1,id:"endpointRequestBodyVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,asType:!1,constant:!1,entity:et,defaultValue:null,parent:tf},rf={id:"endpointRequestQueryParamsVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointRequestQueryParamsVariableDataType"},af={id:"endpointRequestQueryParamsArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"endpointRequestQueryParamsArgumentDeclaration"},sf={like:!1,id:"endpointRequestQueryParamsVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,asType:!1,entity:xa,defaultValue:{id:"endpointRequestQueryParamsVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:[],parent:rf,autogeneration:null,valueAsType:null},parent:af},of={id:"endpointPathParamsVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointPathParamsVariableDataType"},lf={id:"endpointPathParamsArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"endpointPathParamsArgumentDeclaration"},cf={like:!1,id:"endpointPathParamsVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:xa,asType:!1,defaultValue:{id:"endpointPathParamsVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:[],parent:of,autogeneration:null,valueAsType:null},parent:lf},df={id:"endpointReachedTriggerActionDescriptorRef",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReachedTriggerActionDescriptor"},uf={id:"endpointRequestHeadersArgumentDeclaration",version:1,description:"A set of any properties, with names and value that transmit metadata about the request.",type:r.ValueDescriptor,name:"Request headers",dataType:ef,required:!0,index:0,parentRelationType:M.FixedArguments,parent:df},pf={id:"endpointReachedTriggerActionDescriptorRefTwo",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReachedTriggerActionDescriptor"},yf={id:"endpointPathParamsArgumentDeclaration",type:r.ValueDescriptor,description:"A standarized text, without spaces that is added at the end of the domain and routes the request to a specific resource within the target server. For example: /api/users/123, /api/users/123/:name, /api/users/123/:name/:age.",version:1,name:"Path parameters",dataType:cf,required:!0,index:1,parentRelationType:M.FixedArguments,parent:pf},hf={id:"endpointReachedTriggerActionDescriptorRefThree",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReachedTriggerActionDescriptor"},ff={id:"endpointRequestQueryParamsArgumentDeclaration",version:1,description:"A text with standarized format, without spaces that is added at the end of the URL path, after the ? character. It contains data that might be used to process the request. For example: /api/users?name=John&age=30",type:r.ValueDescriptor,name:"Request query params",dataType:sf,required:!0,index:2,parentRelationType:M.FixedArguments,parent:hf},mf={id:"endpointReachedTriggerActionDescriptorRefFour",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReachedTriggerActionDescriptor"},Tf={id:"endpointRequestBodyArgumentDeclaration",version:1,description:"The main data payload of the request.",type:r.ValueDescriptor,name:"Request body",dataType:nf,index:3,required:!0,parentRelationType:M.FixedArguments,parent:mf},Ef={id:"endpointResponseCodeReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"endpointResponseCodeReturnDeclaration"},Rf={like:!1,id:"9ba575b0-6f8e-436d-a3de-3b843622aa17",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Ef},bf={id:"endpointReturnStatementRef",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReturnStatement"},gf={id:"endpointResponseCodeReturnDeclaration",version:1,description:"A standarized number that represents the status of the response. 200 for OK, 404 for not found, 500 for server error, etc.",type:r.ValueDescriptor,name:"Response code",dataType:Rf,required:!0,index:0,parentRelationType:M.FixedReturns,parent:bf},vf={id:"endpointResponseHeadersDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"endpointResponseHeadersDataType"},If={id:"endpointResponseHeadersReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"endpointResponseHeadersReturnDeclaration"},Df={like:!1,id:"endpointResponseHeadersDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:et,asType:!1,defaultValue:{id:"endpointResponseHeadersDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:vf,autogeneration:null,valueAsType:null},parent:If},Pf={id:"endpointReturnStatementRefTwo",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReturnStatement"},Af={id:"endpointResponseHeadersReturnDeclaration",version:1,description:"A set of any properties, with names and value that transmit metadata about the response.",type:r.ValueDescriptor,name:"Response headers",dataType:Df,required:!1,index:1,parentRelationType:M.FixedReturns,parent:Pf},Sf={id:"endpointResponseBodyReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"endpointResponseBodyReturnDeclaration"},Of={like:!1,id:"endpointResponseBodyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,asType:!1,constant:!1,entity:et,defaultValue:null,parent:Sf},Cf={id:"endpointReturnStatementRefThree",type:r.GenericReference,entityType:r.ActionDescriptor,entityId:"endpointReturnStatement"},Bf={id:"endpointResponseBodyReturnDeclaration",version:1,description:"The main data payload of the response.",type:r.ValueDescriptor,name:"Response body",dataType:Of,required:!1,index:2,parentRelationType:M.FixedReturns,parent:Cf},wf={id:"endpointBuiltInBaseEntityRefFour",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},Qo={id:"endpointReachedTriggerActionDescriptor",type:r.ActionDescriptor,version:1,name:"Endpoint reached",description:"Fired when the endpoint is reached.",argumentsType:U.Fixed,dynamicArgumentTypes:null,fixedArguments:[uf,yf,ff,Tf],returnsType:U.Fixed,fixedReturns:[gf,Af,Bf],error:null,dynamicReturnTypes:null,parent:wf},ka={id:V.HTTP_ENDPOINT,version:1,description:"An HTTP endpoint that can be reached by a client from the internet.",name:V.HTTP_ENDPOINT,type:r.BuiltInBaseEntity,interactive:!1,abstract:!0,static:!0,properties:[jh,Zo,Xo],abstractMethods:[Qo],extends:[],methods:[]},Vt=x[r.BuiltInBaseEntity].BUILT_IN_RELATIONAL_DATABASE_ENTITY,_f={id:"relational-database-built-in-base-entity-identifier-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-identifier-property-data-type-id",entityType:r.DataType},Mf={id:"relational-database-built-in-base-entity-identifier-property-ref-id",type:r.GenericReference,entityId:Vt.properties.identifier.id,entityType:r.Property},SI={like:!1,id:"relational-database-built-in-base-entity-identifier-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"relational-database-built-in-base-entity-identifier-property-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:null,parent:_f,autogeneration:{type:qe.Unique,rangeStart:null,rangeEnd:null},valueAsType:null},parent:Mf},Fr={id:"relational-database-built-in-base-entity-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},ja={hidden:!1,required:!0,id:Vt.properties.identifier.id,name:"Identifier name",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:0,dataType:SI,description:"The name of the main database inside of the server instance where the data will be stored.",parent:Fr},OI={id:"relational-database-built-in-base-entity-username-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-username-property-data-type-idd",entityType:r.DataType},Nf={id:"relational-database-built-in-base-entity-username-property-ref-id",type:r.GenericReference,entityId:Vt.properties.username.id,entityType:r.Property},CI={like:!1,id:"relational-database-built-in-base-entity-username-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"relational-database-built-in-base-entity-username-property-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"postgres",parent:{id:"relational-database-built-in-base-entity-username-property-data-type-default-value-parent-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-username-property-data-type-id",entityType:r.DataType},autogeneration:null,valueAsType:null},parent:Nf},qa={hidden:!1,required:!0,id:Vt.properties.username.id,name:"Username",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:1,dataType:CI,description:"The username that will be used to connect to the database.",parent:Fr},BI={id:"relational-database-built-in-base-entity-password-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-password-property-data-type-id",entityType:r.DataType},Vf={id:"relational-database-built-in-base-entity-password-property-ref-id",type:r.GenericReference,entityId:Vt.properties.password.id,entityType:r.Property},wI={like:!1,id:"relational-database-built-in-base-entity-password-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:null,parent:Vf},Ja={hidden:!1,required:!0,id:Vt.properties.password.id,name:"Password",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:2,dataType:wI,description:"The password that will be used to connect to the database.",parent:Fr},$f={id:"relational-database-built-in-base-entity-min-size-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-min-size-property-data-type-id",entityType:r.DataType},Lf={id:"relational-database-built-in-base-entity-min-size-property-ref-id",type:r.GenericReference,entityId:Vt.properties.minSize.id,entityType:r.Property},_I={like:!1,id:"relational-database-built-in-base-entity-min-size-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ce,asType:!1,defaultValue:{id:"relational-database-built-in-base-entity-min-size-property-default-value-id",type:r.PrimitiveValue,version:1,name:A.Number,value:6,parent:$f,autogeneration:null,valueAsType:null},parent:Lf},Wa={hidden:!0,required:!0,id:Vt.properties.minSize.id,name:"Minimum GB size",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:3,dataType:_I,description:"The minimum size of the database in GB.",parent:Fr},Gf={id:"relational-database-built-in-base-entity-default-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-default-property-data-type-id",entityType:r.DataType},Ff={id:"relational-database-built-in-base-entity-default-property-ref-id",type:r.GenericReference,entityId:Vt.properties.default.id,entityType:r.Property},MI={like:!1,id:"relational-database-built-in-base-entity-default-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:An,asType:!1,defaultValue:{id:"relational-database-built-in-base-entity-default-property-default-value-id",type:r.PrimitiveValue,version:1,name:A.Boolean,value:!1,parent:Gf,autogeneration:null,valueAsType:null},parent:Ff},Ko={hidden:!0,required:!0,id:Vt.properties.default.id,name:"Default",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:4,dataType:MI,description:"If true, this database will be the default database for the server instance and all the new entities.",parent:Fr},Uf={id:"relational-database-built-in-base-entity-autoscaling-property-ref-id",type:r.GenericReference,entityId:Vt.properties.autoscaling.id,entityType:r.Property},xf={id:"relational-database-built-in-base-entity-autoscaling-property-data-type-ref-id",type:r.GenericReference,entityId:"relational-database-built-in-base-entity-autoscaling-property-data-type-id",entityType:r.DataType},NI={like:!1,id:"relational-database-built-in-base-entity-autoscaling-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:An,asType:!1,defaultValue:{id:"relational-database-built-in-base-entity-autoscaling-property-default-value-id",type:r.PrimitiveValue,version:1,name:A.Boolean,value:!1,parent:xf,autogeneration:null,valueAsType:null},parent:Uf},kf={id:"relational-database-built-in-base-entity-autoscaling-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},el={hidden:!0,required:!0,id:Vt.properties.autoscaling.id,name:"Auto-scaling",version:1,type:r.Property,private:!1,abstract:!0,static:!0,implements:null,index:4,dataType:NI,description:"If true, this database will automatically scale up or down in memory size, based on the usage.",parent:kf},On={id:V.RELATIONAL_DATABASE,version:1,description:"This entity provisions a relational database in the cloud.",name:V.RELATIONAL_DATABASE,type:r.BuiltInBaseEntity,abstract:!0,static:!0,interactive:!1,properties:[ja,qa,Ja,Wa,Ko,el],abstractMethods:[],methods:[],extends:[]},jf={type:r.GenericReference,entityId:"persisted-built-in-base-entity-ref-id",entityType:r.BuiltInBaseEntity,id:Ot.DeletePersistedEntity},tl={type:r.FunctionDeclaration,id:Ot.DeletePersistedEntity,name:Ot.DeletePersistedEntity,description:"Permanently deletes the current copy of an entity from the database",version:1,parent:jf,inputs:[],calls:[],implements:null,collapsed:!1,returnStatements:[],index:0,private:!1,x:0,y:0},qf={type:r.GenericReference,entityId:"persisted-built-in-base-entity-ref-id",entityType:r.BuiltInBaseEntity,id:Ot.SoftDeletePersistedEntity},Jf={type:r.FunctionDeclaration,id:Ot.SoftDeletePersistedEntity,name:Ot.SoftDeletePersistedEntity,description:"Designates the entity as deleted, but does not remove it from the database.",version:1,parent:qf,inputs:[],calls:[],implements:null,collapsed:!1,returnStatements:[],index:0,private:!1,x:0,y:0},Wf=x[r.BuiltInBaseEntity][V.PERSISTED_ENTITY].properties,VI={id:"persisted-built-in-base-entity-database-property-data-type-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-database-property-data-type-id",entityType:r.DataType},Hf={id:"persisted-built-in-base-entity-database-property-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-database-property-id",entityType:r.Property},$I={like:!1,id:"persisted-built-in-base-entity-database-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:On,asType:!1,defaultValue:null,parent:Hf},Yf={id:"persisted-built-in-base-entity-database-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},Pi={hidden:!0,required:!0,id:Wf.database.id,name:"Database",version:1,type:r.Property,private:!1,abstract:!0,implements:null,static:!0,index:0,dataType:$I,description:"The database that the entity belongs to.",parent:Yf},zf={id:"persisted-built-in-base-entity-identifier-property-data-type-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-identifier-property-data-type-id",entityType:r.DataType},Zf={id:"persisted-built-in-base-entity-identifier-property-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-identifier-property-id",entityType:r.Property},LI={like:!1,id:"persisted-built-in-base-entity-identifier-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ba,asType:!1,defaultValue:{id:"persisted-built-in-base-entity-identifier-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.UUID,value:null,parent:zf,autogeneration:{type:qe.Unique,rangeStart:null,rangeEnd:null},valueAsType:null},parent:Zf},Xf={id:"persisted-built-in-base-entity-identifier-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},Qf={hidden:!1,required:!0,id:Wf.identifier.id,name:"Identifier",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:0,dataType:LI,description:"Auto-generated unique identifier for the entity, can be used to identify the entity among other entities of the same type.",parent:Xf},GI={id:"persisted-built-in-base-entity-deleted-at-property-data-type-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-deleted-at-property-data-type-id",entityType:r.DataType},Kf={id:"persisted-built-in-base-entity-deleted-at-property-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-deleted-at-property-id",entityType:r.Property},em={like:!1,id:"persisted-built-in-base-entity-deleted-at-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!0,constant:!1,entity:cn,asType:!1,defaultValue:null,parent:Kf},tm={id:"persisted-built-in-base-entity-deleted-at-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},nm={hidden:!1,required:!0,id:"persisted-built-in-base-entity-deleted-at-property-id",name:"Deleted at",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:0,dataType:em,description:"The date and time when the entity was deleted.",parent:tm},FI={id:"persisted-built-in-base-entity-created-at-property-data-type-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-created-at-property-data-type-id",entityType:r.DataType},rm={id:"persisted-built-in-base-entity-created-at-property-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-created-at-property-id",entityType:r.Property},im={like:!1,id:"persisted-built-in-base-entity-created-at-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:cn,asType:!1,defaultValue:null,parent:rm},am={id:"persisted-built-in-base-entity-created-at-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},sm={hidden:!1,required:!0,id:"persisted-built-in-base-entity-created-at-property-id",name:"Created at",version:1,type:r.Property,private:!1,abstract:!1,implements:null,static:!1,index:0,dataType:im,description:"The date and time when the entity was created.",parent:am},UI={id:"persisted-built-in-base-entity-updated-at-property-data-type-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-updated-at-property-data-type-id",entityType:r.DataType},om={id:"persisted-built-in-base-entity-updated-at-property-ref-id",type:r.GenericReference,entityId:"persisted-built-in-base-entity-updated-at-property-id",entityType:r.Property},lm={like:!1,id:"persisted-built-in-base-entity-updated-at-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:cn,asType:!1,defaultValue:null,parent:om},cm={id:"persisted-built-in-base-entity-updated-at-property-parent-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},dm={hidden:!1,required:!0,id:"persisted-built-in-base-entity-updated-at-property-id",name:"Updated at",version:1,type:r.Property,private:!1,implements:null,abstract:!1,static:!1,index:0,dataType:lm,description:"The date and time when the entity was last updated.",parent:cm},Le={id:V.PERSISTED_ENTITY,version:1,description:"An entity that is permanently stored in the database and can be accessed at any point.",name:V.PERSISTED_ENTITY,type:r.BuiltInBaseEntity,abstract:!0,static:!1,interactive:!0,abstractMethods:[],properties:[Pi,Qf,nm,sm,dm],methods:[tl,Jf],extends:[]},um={id:"cron-job-triggered-function-declaration-blueprint-parent-ref-id",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},nl={id:"cron-job-triggered-function-declaration-blueprint-id",name:"Cron job triggered",version:1,type:r.ActionDescriptor,argumentsType:U.None,returnsType:U.None,description:"Executed when the cron job is triggered",fixedArguments:[],dynamicArgumentTypes:null,error:null,fixedReturns:[],dynamicReturnTypes:null,parent:um},pm=x[r.BuiltInBaseEntity].BUILT_IN_CRON_JOB_ENTITY,xI={id:"cron-job-built-in-base-entity-expression-property-data-type-ref",type:r.GenericReference,entityId:"cron-job-built-in-base-entity-expression-property-data-type",entityType:r.DataType},ym={id:"cron-job-built-in-base-entity-expression-property-ref",type:r.GenericReference,entityId:pm.properties.expression.id,entityType:r.Property},kI={like:!1,id:"cron-job-built-in-base-entity-expression-property-data-type",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:null,parent:ym},hm={id:"cron-job-built-in-base-entity-ref",type:r.GenericReference,entityId:V.CRON_JOB,entityType:r.BuiltInBaseEntity},fm={hidden:!1,required:!0,id:pm.properties.expression.id,name:"Cron expression",version:1,type:r.Property,private:!1,abstract:!0,implements:null,static:!0,index:0,dataType:kI,description:"The cron-job expression that defines when the cron-job job should be triggered. The expression should be in the format of a cron-job expression.",parent:hm},rl={id:V.CRON_JOB,version:1,description:"This entity represents a scheduled trigger. The action on this entity will be executed one the time set by the cron-job expression is reached.",name:V.CRON_JOB,type:r.BuiltInBaseEntity,abstract:!0,static:!0,interactive:!1,properties:[fm],methods:[],abstractMethods:[nl],extends:[]},mm={type:r.GenericReference,id:"execution-built-in-entity-abort-method-parent-ref-id",entityType:r.BuiltInBaseEntity,entityId:"execution-built-in-entity-id"},il={id:"execution-built-in-entity-abort-method-id",type:r.FunctionDeclaration,version:1,name:Ot.AbortExecution,description:"Aborts the execution of the entity",inputs:[],returnStatements:[],calls:[],implements:null,private:!1,collapsed:!1,index:null,x:0,y:0,parent:mm},al={id:V.EXECUTION,type:r.BuiltInBaseEntity,version:1,name:V.EXECUTION,description:"A reference to an ongoing execution of any entity that can be called. Eg: Operations, custom trigger calls, etc.",static:!1,abstract:!1,interactive:!0,extends:[],properties:[],methods:[il],abstractMethods:[]},jI=x[r.Condition]["not-empty"],Tm={type:r.GenericReference,id:"not-empty-condition-ref",entityType:r.ActionDescriptor,entityId:Nt.NotEmpty},Em={id:jI.inputs.leftHand.id,type:r.ValueDescriptor,version:1,name:"Value",description:"The value to check if it is not empty",dataType:null,required:!0,parentRelationType:M.FixedArguments,index:0,parent:Tm},er={type:r.ActionDescriptor,id:Nt.NotEmpty,version:1,name:Nt.NotEmpty,description:"Checks if the value is not empty",parent:null,fixedArguments:[Em],fixedReturns:[],dynamicArgumentTypes:null,dynamicReturnTypes:null,argumentsType:U.Fixed,returnsType:U.None,error:null},Rm={[Nt.NotEmpty]:er},bm=x[r.Condition]["more-than-or-equal"],gm={type:r.GenericReference,id:"more-than-or-equal-condition-left-hand-argument-parent-ref",entityType:r.ActionDescriptor,entityId:_e.MoreThanOrEqual},vm={id:bm.inputs.leftHand.id,type:r.ValueDescriptor,version:1,name:"First value",description:"The first value to compare",dataType:null,required:!0,parentRelationType:M.FixedArguments,index:0,parent:gm},Im={type:r.GenericReference,id:"more-than-or-equal-condition-right-hand-argument-parent-ref",entityType:r.ActionDescriptor,entityId:_e.MoreThanOrEqual},Dm={id:bm.inputs.rightHand.id,type:r.ValueDescriptor,version:1,name:"Second value",description:"The second value to compare",dataType:null,required:!0,parentRelationType:M.FixedArguments,index:1,parent:Im},Ur={type:r.ActionDescriptor,id:_e.MoreThanOrEqual,version:1,name:_e.MoreThanOrEqual,description:"Checks if the value is not empty",parent:null,fixedArguments:[vm,Dm],fixedReturns:[],dynamicArgumentTypes:null,dynamicReturnTypes:null,argumentsType:U.Fixed,returnsType:U.None,error:null},Pm={[_e.MoreThanOrEqual]:Ur},qI={...Rm,...Pm},Ha={type:r.ActionDescriptor,id:on.PROJECT_PUBLICATION_COMPLETED,version:1,name:on.PROJECT_PUBLICATION_COMPLETED,description:"The event that is triggered when the project has completed its publication and all its code and resurces are now deployed and ready to be used by the users",parent:null,fixedArguments:[],fixedReturns:[],dynamicArgumentTypes:null,dynamicReturnTypes:null,argumentsType:U.None,returnsType:U.None,error:null},JI={[on.PROJECT_PUBLICATION_COMPLETED]:Ha},sl=x[r.ValueDescriptor][wo.ActionOngoingProcessOutputValue],Am={type:r.GenericReference,id:"182f767f-50e8-4394-ba5f-43e78c232733",entityType:r.ValueDescriptor,entityId:sl.id},Sm={like:!1,id:sl.dataType.id,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:al,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:Am},ol={id:sl.id,type:r.ValueDescriptor,description:"A value that represents the ongoing process of the parent action",version:1,name:"Process",dataType:Sm,required:!0,index:0,parent:null,parentRelationType:M.OngoingProcessExecution};var ee;(function(n){n.assertEqual=a=>a;function e(a){}n.assertIs=e;function t(a){throw new Error}n.assertNever=t,n.arrayToEnum=a=>{const s={};for(const o of a)s[o]=o;return s},n.getValidEnumValues=a=>{const s=n.objectKeys(a).filter(l=>typeof a[a[l]]!="number"),o={};for(const l of s)o[l]=a[l];return n.objectValues(o)},n.objectValues=a=>n.objectKeys(a).map(function(s){return a[s]}),n.objectKeys=typeof Object.keys=="function"?a=>Object.keys(a):a=>{const s=[];for(const o in a)Object.prototype.hasOwnProperty.call(a,o)&&s.push(o);return s},n.find=(a,s)=>{for(const o of a)if(s(o))return o},n.isInteger=typeof Number.isInteger=="function"?a=>Number.isInteger(a):a=>typeof a=="number"&&isFinite(a)&&Math.floor(a)===a;function i(a,s=" | "){return a.map(o=>typeof o=="string"?`'${o}'`:o).join(s)}n.joinValues=i,n.jsonStringifyReplacer=(a,s)=>typeof s=="bigint"?s.toString():s})(ee||(ee={}));var ll;(function(n){n.mergeShapes=(e,t)=>({...e,...t})})(ll||(ll={}));const $=ee.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),Cn=n=>{switch(typeof n){case"undefined":return $.undefined;case"string":return $.string;case"number":return isNaN(n)?$.nan:$.number;case"boolean":return $.boolean;case"function":return $.function;case"bigint":return $.bigint;case"symbol":return $.symbol;case"object":return Array.isArray(n)?$.array:n===null?$.null:n.then&&typeof n.then=="function"&&n.catch&&typeof n.catch=="function"?$.promise:typeof Map<"u"&&n instanceof Map?$.map:typeof Set<"u"&&n instanceof Set?$.set:typeof Date<"u"&&n instanceof Date?$.date:$.object;default:return $.unknown}},O=ee.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),WI=n=>JSON.stringify(n,null,2).replace(/"([^"]+)":/g,"$1:");class bt extends Error{constructor(e){super(),this.issues=[],this.addIssue=i=>{this.issues=[...this.issues,i]},this.addIssues=(i=[])=>{this.issues=[...this.issues,...i]};const t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}get errors(){return this.issues}format(e){const t=e||function(s){return s.message},i={_errors:[]},a=s=>{for(const o of s.issues)if(o.code==="invalid_union")o.unionErrors.map(a);else if(o.code==="invalid_return_type")a(o.returnTypeError);else if(o.code==="invalid_arguments")a(o.argumentsError);else if(o.path.length===0)i._errors.push(t(o));else{let l=i,p=0;for(;p<o.path.length;){const y=o.path[p];p===o.path.length-1?(l[y]=l[y]||{_errors:[]},l[y]._errors.push(t(o))):l[y]=l[y]||{_errors:[]},l=l[y],p++}}};return a(this),i}static assert(e){if(!(e instanceof bt))throw new Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,ee.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=t=>t.message){const t={},i=[];for(const a of this.issues)a.path.length>0?(t[a.path[0]]=t[a.path[0]]||[],t[a.path[0]].push(e(a))):i.push(e(a));return{formErrors:i,fieldErrors:t}}get formErrors(){return this.flatten()}}bt.create=n=>new bt(n);const xr=(n,e)=>{let t;switch(n.code){case O.invalid_type:n.received===$.undefined?t="Required":t=`Expected ${n.expected}, received ${n.received}`;break;case O.invalid_literal:t=`Invalid literal value, expected ${JSON.stringify(n.expected,ee.jsonStringifyReplacer)}`;break;case O.unrecognized_keys:t=`Unrecognized key(s) in object: ${ee.joinValues(n.keys,", ")}`;break;case O.invalid_union:t="Invalid input";break;case O.invalid_union_discriminator:t=`Invalid discriminator value. Expected ${ee.joinValues(n.options)}`;break;case O.invalid_enum_value:t=`Invalid enum value. Expected ${ee.joinValues(n.options)}, received '${n.received}'`;break;case O.invalid_arguments:t="Invalid function arguments";break;case O.invalid_return_type:t="Invalid function return type";break;case O.invalid_date:t="Invalid date";break;case O.invalid_string:typeof n.validation=="object"?"includes"in n.validation?(t=`Invalid input: must include "${n.validation.includes}"`,typeof n.validation.position=="number"&&(t=`${t} at one or more positions greater than or equal to ${n.validation.position}`)):"startsWith"in n.validation?t=`Invalid input: must start with "${n.validation.startsWith}"`:"endsWith"in n.validation?t=`Invalid input: must end with "${n.validation.endsWith}"`:ee.assertNever(n.validation):n.validation!=="regex"?t=`Invalid ${n.validation}`:t="Invalid";break;case O.too_small:n.type==="array"?t=`Array must contain ${n.exact?"exactly":n.inclusive?"at least":"more than"} ${n.minimum} element(s)`:n.type==="string"?t=`String must contain ${n.exact?"exactly":n.inclusive?"at least":"over"} ${n.minimum} character(s)`:n.type==="number"?t=`Number must be ${n.exact?"exactly equal to ":n.inclusive?"greater than or equal to ":"greater than "}${n.minimum}`:n.type==="date"?t=`Date must be ${n.exact?"exactly equal to ":n.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(n.minimum))}`:t="Invalid input";break;case O.too_big:n.type==="array"?t=`Array must contain ${n.exact?"exactly":n.inclusive?"at most":"less than"} ${n.maximum} element(s)`:n.type==="string"?t=`String must contain ${n.exact?"exactly":n.inclusive?"at most":"under"} ${n.maximum} character(s)`:n.type==="number"?t=`Number must be ${n.exact?"exactly":n.inclusive?"less than or equal to":"less than"} ${n.maximum}`:n.type==="bigint"?t=`BigInt must be ${n.exact?"exactly":n.inclusive?"less than or equal to":"less than"} ${n.maximum}`:n.type==="date"?t=`Date must be ${n.exact?"exactly":n.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(n.maximum))}`:t="Invalid input";break;case O.custom:t="Invalid input";break;case O.invalid_intersection_types:t="Intersection results could not be merged";break;case O.not_multiple_of:t=`Number must be a multiple of ${n.multipleOf}`;break;case O.not_finite:t="Number must be finite";break;default:t=e.defaultError,ee.assertNever(n)}return{message:t}};let Om=xr;function HI(n){Om=n}function Ya(){return Om}const za=n=>{const{data:e,path:t,errorMaps:i,issueData:a}=n,s=[...t,...a.path||[]],o={...a,path:s};if(a.message!==void 0)return{...a,path:s,message:a.message};let l="";const p=i.filter(y=>!!y).slice().reverse();for(const y of p)l=y(o,{data:e,defaultError:l}).message;return{...a,path:s,message:l}},YI=[];function N(n,e){const t=Ya(),i=za({issueData:e,data:n.data,path:n.path,errorMaps:[n.common.contextualErrorMap,n.schemaErrorMap,t,t===xr?void 0:xr].filter(a=>!!a)});n.common.issues.push(i)}class tt{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(e,t){const i=[];for(const a of t){if(a.status==="aborted")return q;a.status==="dirty"&&e.dirty(),i.push(a.value)}return{status:e.value,value:i}}static async mergeObjectAsync(e,t){const i=[];for(const a of t){const s=await a.key,o=await a.value;i.push({key:s,value:o})}return tt.mergeObjectSync(e,i)}static mergeObjectSync(e,t){const i={};for(const a of t){const{key:s,value:o}=a;if(s.status==="aborted"||o.status==="aborted")return q;s.status==="dirty"&&e.dirty(),o.status==="dirty"&&e.dirty(),s.value!=="__proto__"&&(typeof o.value<"u"||a.alwaysSet)&&(i[s.value]=o.value)}return{status:e.value,value:i}}}const q=Object.freeze({status:"aborted"}),kr=n=>({status:"dirty",value:n}),ut=n=>({status:"valid",value:n}),cl=n=>n.status==="aborted",dl=n=>n.status==="dirty",Ai=n=>n.status==="valid",Si=n=>typeof Promise<"u"&&n instanceof Promise;function Za(n,e,t,i){if(t==="a"&&!i)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?n!==e||!i:!e.has(n))throw new TypeError("Cannot read private member from an object whose class did not declare it");return t==="m"?i:t==="a"?i.call(n):i?i.value:e.get(n)}function Cm(n,e,t,i,a){if(i==="m")throw new TypeError("Private method is not writable");if(i==="a"&&!a)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?n!==e||!a:!e.has(n))throw new TypeError("Cannot write private member to an object whose class did not declare it");return i==="a"?a.call(n,t):a?a.value=t:e.set(n,t),t}typeof SuppressedError=="function"&&SuppressedError;var F;(function(n){n.errToObj=e=>typeof e=="string"?{message:e}:e||{},n.toString=e=>typeof e=="string"?e:e==null?void 0:e.message})(F||(F={}));var Oi,Ci;class zt{constructor(e,t,i,a){this._cachedPath=[],this.parent=e,this.data=t,this._path=i,this._key=a}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const Bm=(n,e)=>{if(Ai(e))return{success:!0,data:e.value};if(!n.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const t=new bt(n.common.issues);return this._error=t,this._error}}};function z(n){if(!n)return{};const{errorMap:e,invalid_type_error:t,required_error:i,description:a}=n;if(e&&(t||i))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return e?{errorMap:e,description:a}:{errorMap:(o,l)=>{var p,y;const{message:f}=n;return o.code==="invalid_enum_value"?{message:f??l.defaultError}:typeof l.data>"u"?{message:(p=f??i)!==null&&p!==void 0?p:l.defaultError}:o.code!=="invalid_type"?{message:l.defaultError}:{message:(y=f??t)!==null&&y!==void 0?y:l.defaultError}},description:a}}class X{constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this)}get description(){return this._def.description}_getType(e){return Cn(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:Cn(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new tt,ctx:{common:e.parent.common,data:e.data,parsedType:Cn(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){const t=this._parse(e);if(Si(t))throw new Error("Synchronous parse encountered promise.");return t}_parseAsync(e){const t=this._parse(e);return Promise.resolve(t)}parse(e,t){const i=this.safeParse(e,t);if(i.success)return i.data;throw i.error}safeParse(e,t){var i;const a={common:{issues:[],async:(i=t==null?void 0:t.async)!==null&&i!==void 0?i:!1,contextualErrorMap:t==null?void 0:t.errorMap},path:(t==null?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:Cn(e)},s=this._parseSync({data:e,path:a.path,parent:a});return Bm(a,s)}async parseAsync(e,t){const i=await this.safeParseAsync(e,t);if(i.success)return i.data;throw i.error}async safeParseAsync(e,t){const i={common:{issues:[],contextualErrorMap:t==null?void 0:t.errorMap,async:!0},path:(t==null?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:Cn(e)},a=this._parse({data:e,path:i.path,parent:i}),s=await(Si(a)?a:Promise.resolve(a));return Bm(i,s)}refine(e,t){const i=a=>typeof t=="string"||typeof t>"u"?{message:t}:typeof t=="function"?t(a):t;return this._refinement((a,s)=>{const o=e(a),l=()=>s.addIssue({code:O.custom,...i(a)});return typeof Promise<"u"&&o instanceof Promise?o.then(p=>p?!0:(l(),!1)):o?!0:(l(),!1)})}refinement(e,t){return this._refinement((i,a)=>e(i)?!0:(a.addIssue(typeof t=="function"?t(i,a):t),!1))}_refinement(e){return new qt({schema:this,typeName:j.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}optional(){return Xt.create(this,this._def)}nullable(){return Mn.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return jt.create(this,this._def)}promise(){return Wr.create(this,this._def)}or(e){return Mi.create([this,e],this._def)}and(e){return Ni.create(this,e,this._def)}transform(e){return new qt({...z(this._def),schema:this,typeName:j.ZodEffects,effect:{type:"transform",transform:e}})}default(e){const t=typeof e=="function"?e:()=>e;return new Fi({...z(this._def),innerType:this,defaultValue:t,typeName:j.ZodDefault})}brand(){return new yl({typeName:j.ZodBranded,type:this,...z(this._def)})}catch(e){const t=typeof e=="function"?e:()=>e;return new Ui({...z(this._def),innerType:this,catchValue:t,typeName:j.ZodCatch})}describe(e){const t=this.constructor;return new t({...this._def,description:e})}pipe(e){return xi.create(this,e)}readonly(){return ki.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const zI=/^c[^\s-]{8,}$/i,ZI=/^[0-9a-z]+$/,XI=/^[0-9A-HJKMNP-TV-Z]{26}$/,QI=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,KI=/^[a-z0-9_-]{21}$/i,eD=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,tD=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,nD="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let ul;const rD=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,iD=/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/,aD=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,wm="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",sD=new RegExp(`^${wm}$`);function _m(n){let e="([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d";return n.precision?e=`${e}\\.\\d{${n.precision}}`:n.precision==null&&(e=`${e}(\\.\\d+)?`),e}function oD(n){return new RegExp(`^${_m(n)}$`)}function Mm(n){let e=`${wm}T${_m(n)}`;const t=[];return t.push(n.local?"Z?":"Z"),n.offset&&t.push("([+-]\\d{2}:?\\d{2})"),e=`${e}(${t.join("|")})`,new RegExp(`^${e}$`)}function lD(n,e){return!!((e==="v4"||!e)&&rD.test(n)||(e==="v6"||!e)&&iD.test(n))}class kt extends X{_parse(e){if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==$.string){const s=this._getOrReturnCtx(e);return N(s,{code:O.invalid_type,expected:$.string,received:s.parsedType}),q}const i=new tt;let a;for(const s of this._def.checks)if(s.kind==="min")e.data.length<s.value&&(a=this._getOrReturnCtx(e,a),N(a,{code:O.too_small,minimum:s.value,type:"string",inclusive:!0,exact:!1,message:s.message}),i.dirty());else if(s.kind==="max")e.data.length>s.value&&(a=this._getOrReturnCtx(e,a),N(a,{code:O.too_big,maximum:s.value,type:"string",inclusive:!0,exact:!1,message:s.message}),i.dirty());else if(s.kind==="length"){const o=e.data.length>s.value,l=e.data.length<s.value;(o||l)&&(a=this._getOrReturnCtx(e,a),o?N(a,{code:O.too_big,maximum:s.value,type:"string",inclusive:!0,exact:!0,message:s.message}):l&&N(a,{code:O.too_small,minimum:s.value,type:"string",inclusive:!0,exact:!0,message:s.message}),i.dirty())}else if(s.kind==="email")tD.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"email",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="emoji")ul||(ul=new RegExp(nD,"u")),ul.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"emoji",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="uuid")QI.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"uuid",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="nanoid")KI.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"nanoid",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="cuid")zI.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"cuid",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="cuid2")ZI.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"cuid2",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="ulid")XI.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"ulid",code:O.invalid_string,message:s.message}),i.dirty());else if(s.kind==="url")try{new URL(e.data)}catch{a=this._getOrReturnCtx(e,a),N(a,{validation:"url",code:O.invalid_string,message:s.message}),i.dirty()}else s.kind==="regex"?(s.regex.lastIndex=0,s.regex.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"regex",code:O.invalid_string,message:s.message}),i.dirty())):s.kind==="trim"?e.data=e.data.trim():s.kind==="includes"?e.data.includes(s.value,s.position)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:{includes:s.value,position:s.position},message:s.message}),i.dirty()):s.kind==="toLowerCase"?e.data=e.data.toLowerCase():s.kind==="toUpperCase"?e.data=e.data.toUpperCase():s.kind==="startsWith"?e.data.startsWith(s.value)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:{startsWith:s.value},message:s.message}),i.dirty()):s.kind==="endsWith"?e.data.endsWith(s.value)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:{endsWith:s.value},message:s.message}),i.dirty()):s.kind==="datetime"?Mm(s).test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:"datetime",message:s.message}),i.dirty()):s.kind==="date"?sD.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:"date",message:s.message}),i.dirty()):s.kind==="time"?oD(s).test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{code:O.invalid_string,validation:"time",message:s.message}),i.dirty()):s.kind==="duration"?eD.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"duration",code:O.invalid_string,message:s.message}),i.dirty()):s.kind==="ip"?lD(e.data,s.version)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"ip",code:O.invalid_string,message:s.message}),i.dirty()):s.kind==="base64"?aD.test(e.data)||(a=this._getOrReturnCtx(e,a),N(a,{validation:"base64",code:O.invalid_string,message:s.message}),i.dirty()):ee.assertNever(s);return{status:i.value,value:e.data}}_regex(e,t,i){return this.refinement(a=>e.test(a),{validation:t,code:O.invalid_string,...F.errToObj(i)})}_addCheck(e){return new kt({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...F.errToObj(e)})}url(e){return this._addCheck({kind:"url",...F.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...F.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...F.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...F.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...F.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...F.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...F.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...F.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...F.errToObj(e)})}datetime(e){var t,i;return typeof e=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:typeof(e==null?void 0:e.precision)>"u"?null:e==null?void 0:e.precision,offset:(t=e==null?void 0:e.offset)!==null&&t!==void 0?t:!1,local:(i=e==null?void 0:e.local)!==null&&i!==void 0?i:!1,...F.errToObj(e==null?void 0:e.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return typeof e=="string"?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:typeof(e==null?void 0:e.precision)>"u"?null:e==null?void 0:e.precision,...F.errToObj(e==null?void 0:e.message)})}duration(e){return this._addCheck({kind:"duration",...F.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...F.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:t==null?void 0:t.position,...F.errToObj(t==null?void 0:t.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...F.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...F.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...F.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...F.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...F.errToObj(t)})}nonempty(e){return this.min(1,F.errToObj(e))}trim(){return new kt({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new kt({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new kt({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>e.kind==="datetime")}get isDate(){return!!this._def.checks.find(e=>e.kind==="date")}get isTime(){return!!this._def.checks.find(e=>e.kind==="time")}get isDuration(){return!!this._def.checks.find(e=>e.kind==="duration")}get isEmail(){return!!this._def.checks.find(e=>e.kind==="email")}get isURL(){return!!this._def.checks.find(e=>e.kind==="url")}get isEmoji(){return!!this._def.checks.find(e=>e.kind==="emoji")}get isUUID(){return!!this._def.checks.find(e=>e.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(e=>e.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(e=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(e=>e.kind==="cuid2")}get isULID(){return!!this._def.checks.find(e=>e.kind==="ulid")}get isIP(){return!!this._def.checks.find(e=>e.kind==="ip")}get isBase64(){return!!this._def.checks.find(e=>e.kind==="base64")}get minLength(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}}kt.create=n=>{var e;return new kt({checks:[],typeName:j.ZodString,coerce:(e=n==null?void 0:n.coerce)!==null&&e!==void 0?e:!1,...z(n)})};function cD(n,e){const t=(n.toString().split(".")[1]||"").length,i=(e.toString().split(".")[1]||"").length,a=t>i?t:i,s=parseInt(n.toFixed(a).replace(".","")),o=parseInt(e.toFixed(a).replace(".",""));return s%o/Math.pow(10,a)}class Bn extends X{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==$.number){const s=this._getOrReturnCtx(e);return N(s,{code:O.invalid_type,expected:$.number,received:s.parsedType}),q}let i;const a=new tt;for(const s of this._def.checks)s.kind==="int"?ee.isInteger(e.data)||(i=this._getOrReturnCtx(e,i),N(i,{code:O.invalid_type,expected:"integer",received:"float",message:s.message}),a.dirty()):s.kind==="min"?(s.inclusive?e.data<s.value:e.data<=s.value)&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.too_small,minimum:s.value,type:"number",inclusive:s.inclusive,exact:!1,message:s.message}),a.dirty()):s.kind==="max"?(s.inclusive?e.data>s.value:e.data>=s.value)&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.too_big,maximum:s.value,type:"number",inclusive:s.inclusive,exact:!1,message:s.message}),a.dirty()):s.kind==="multipleOf"?cD(e.data,s.value)!==0&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.not_multiple_of,multipleOf:s.value,message:s.message}),a.dirty()):s.kind==="finite"?Number.isFinite(e.data)||(i=this._getOrReturnCtx(e,i),N(i,{code:O.not_finite,message:s.message}),a.dirty()):ee.assertNever(s);return{status:a.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,F.toString(t))}gt(e,t){return this.setLimit("min",e,!1,F.toString(t))}lte(e,t){return this.setLimit("max",e,!0,F.toString(t))}lt(e,t){return this.setLimit("max",e,!1,F.toString(t))}setLimit(e,t,i,a){return new Bn({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:i,message:F.toString(a)}]})}_addCheck(e){return new Bn({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:F.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:F.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:F.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:F.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:F.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:F.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:F.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:F.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:F.toString(e)})}get minValue(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find(e=>e.kind==="int"||e.kind==="multipleOf"&&ee.isInteger(e.value))}get isFinite(){let e=null,t=null;for(const i of this._def.checks){if(i.kind==="finite"||i.kind==="int"||i.kind==="multipleOf")return!0;i.kind==="min"?(t===null||i.value>t)&&(t=i.value):i.kind==="max"&&(e===null||i.value<e)&&(e=i.value)}return Number.isFinite(t)&&Number.isFinite(e)}}Bn.create=n=>new Bn({checks:[],typeName:j.ZodNumber,coerce:(n==null?void 0:n.coerce)||!1,...z(n)});class wn extends X{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce&&(e.data=BigInt(e.data)),this._getType(e)!==$.bigint){const s=this._getOrReturnCtx(e);return N(s,{code:O.invalid_type,expected:$.bigint,received:s.parsedType}),q}let i;const a=new tt;for(const s of this._def.checks)s.kind==="min"?(s.inclusive?e.data<s.value:e.data<=s.value)&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.too_small,type:"bigint",minimum:s.value,inclusive:s.inclusive,message:s.message}),a.dirty()):s.kind==="max"?(s.inclusive?e.data>s.value:e.data>=s.value)&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.too_big,type:"bigint",maximum:s.value,inclusive:s.inclusive,message:s.message}),a.dirty()):s.kind==="multipleOf"?e.data%s.value!==BigInt(0)&&(i=this._getOrReturnCtx(e,i),N(i,{code:O.not_multiple_of,multipleOf:s.value,message:s.message}),a.dirty()):ee.assertNever(s);return{status:a.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,F.toString(t))}gt(e,t){return this.setLimit("min",e,!1,F.toString(t))}lte(e,t){return this.setLimit("max",e,!0,F.toString(t))}lt(e,t){return this.setLimit("max",e,!1,F.toString(t))}setLimit(e,t,i,a){return new wn({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:i,message:F.toString(a)}]})}_addCheck(e){return new wn({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:F.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:F.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:F.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:F.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:F.toString(t)})}get minValue(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e}}wn.create=n=>{var e;return new wn({checks:[],typeName:j.ZodBigInt,coerce:(e=n==null?void 0:n.coerce)!==null&&e!==void 0?e:!1,...z(n)})};class Bi extends X{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==$.boolean){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.boolean,received:i.parsedType}),q}return ut(e.data)}}Bi.create=n=>new Bi({typeName:j.ZodBoolean,coerce:(n==null?void 0:n.coerce)||!1,...z(n)});class tr extends X{_parse(e){if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==$.date){const s=this._getOrReturnCtx(e);return N(s,{code:O.invalid_type,expected:$.date,received:s.parsedType}),q}if(isNaN(e.data.getTime())){const s=this._getOrReturnCtx(e);return N(s,{code:O.invalid_date}),q}const i=new tt;let a;for(const s of this._def.checks)s.kind==="min"?e.data.getTime()<s.value&&(a=this._getOrReturnCtx(e,a),N(a,{code:O.too_small,message:s.message,inclusive:!0,exact:!1,minimum:s.value,type:"date"}),i.dirty()):s.kind==="max"?e.data.getTime()>s.value&&(a=this._getOrReturnCtx(e,a),N(a,{code:O.too_big,message:s.message,inclusive:!0,exact:!1,maximum:s.value,type:"date"}),i.dirty()):ee.assertNever(s);return{status:i.value,value:new Date(e.data.getTime())}}_addCheck(e){return new tr({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:F.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:F.toString(t)})}get minDate(){let e=null;for(const t of this._def.checks)t.kind==="min"&&(e===null||t.value>e)&&(e=t.value);return e!=null?new Date(e):null}get maxDate(){let e=null;for(const t of this._def.checks)t.kind==="max"&&(e===null||t.value<e)&&(e=t.value);return e!=null?new Date(e):null}}tr.create=n=>new tr({checks:[],coerce:(n==null?void 0:n.coerce)||!1,typeName:j.ZodDate,...z(n)});class Xa extends X{_parse(e){if(this._getType(e)!==$.symbol){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.symbol,received:i.parsedType}),q}return ut(e.data)}}Xa.create=n=>new Xa({typeName:j.ZodSymbol,...z(n)});class wi extends X{_parse(e){if(this._getType(e)!==$.undefined){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.undefined,received:i.parsedType}),q}return ut(e.data)}}wi.create=n=>new wi({typeName:j.ZodUndefined,...z(n)});class _i extends X{_parse(e){if(this._getType(e)!==$.null){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.null,received:i.parsedType}),q}return ut(e.data)}}_i.create=n=>new _i({typeName:j.ZodNull,...z(n)});class jr extends X{constructor(){super(...arguments),this._any=!0}_parse(e){return ut(e.data)}}jr.create=n=>new jr({typeName:j.ZodAny,...z(n)});class nr extends X{constructor(){super(...arguments),this._unknown=!0}_parse(e){return ut(e.data)}}nr.create=n=>new nr({typeName:j.ZodUnknown,...z(n)});class un extends X{_parse(e){const t=this._getOrReturnCtx(e);return N(t,{code:O.invalid_type,expected:$.never,received:t.parsedType}),q}}un.create=n=>new un({typeName:j.ZodNever,...z(n)});class Qa extends X{_parse(e){if(this._getType(e)!==$.undefined){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.void,received:i.parsedType}),q}return ut(e.data)}}Qa.create=n=>new Qa({typeName:j.ZodVoid,...z(n)});class jt extends X{_parse(e){const{ctx:t,status:i}=this._processInputParams(e),a=this._def;if(t.parsedType!==$.array)return N(t,{code:O.invalid_type,expected:$.array,received:t.parsedType}),q;if(a.exactLength!==null){const o=t.data.length>a.exactLength.value,l=t.data.length<a.exactLength.value;(o||l)&&(N(t,{code:o?O.too_big:O.too_small,minimum:l?a.exactLength.value:void 0,maximum:o?a.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:a.exactLength.message}),i.dirty())}if(a.minLength!==null&&t.data.length<a.minLength.value&&(N(t,{code:O.too_small,minimum:a.minLength.value,type:"array",inclusive:!0,exact:!1,message:a.minLength.message}),i.dirty()),a.maxLength!==null&&t.data.length>a.maxLength.value&&(N(t,{code:O.too_big,maximum:a.maxLength.value,type:"array",inclusive:!0,exact:!1,message:a.maxLength.message}),i.dirty()),t.common.async)return Promise.all([...t.data].map((o,l)=>a.type._parseAsync(new zt(t,o,t.path,l)))).then(o=>tt.mergeArray(i,o));const s=[...t.data].map((o,l)=>a.type._parseSync(new zt(t,o,t.path,l)));return tt.mergeArray(i,s)}get element(){return this._def.type}min(e,t){return new jt({...this._def,minLength:{value:e,message:F.toString(t)}})}max(e,t){return new jt({...this._def,maxLength:{value:e,message:F.toString(t)}})}length(e,t){return new jt({...this._def,exactLength:{value:e,message:F.toString(t)}})}nonempty(e){return this.min(1,e)}}jt.create=(n,e)=>new jt({type:n,minLength:null,maxLength:null,exactLength:null,typeName:j.ZodArray,...z(e)});function qr(n){if(n instanceof Ge){const e={};for(const t in n.shape){const i=n.shape[t];e[t]=Xt.create(qr(i))}return new Ge({...n._def,shape:()=>e})}else return n instanceof jt?new jt({...n._def,type:qr(n.element)}):n instanceof Xt?Xt.create(qr(n.unwrap())):n instanceof Mn?Mn.create(qr(n.unwrap())):n instanceof Zt?Zt.create(n.items.map(e=>qr(e))):n}class Ge extends X{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const e=this._def.shape(),t=ee.objectKeys(e);return this._cached={shape:e,keys:t}}_parse(e){if(this._getType(e)!==$.object){const y=this._getOrReturnCtx(e);return N(y,{code:O.invalid_type,expected:$.object,received:y.parsedType}),q}const{status:i,ctx:a}=this._processInputParams(e),{shape:s,keys:o}=this._getCached(),l=[];if(!(this._def.catchall instanceof un&&this._def.unknownKeys==="strip"))for(const y in a.data)o.includes(y)||l.push(y);const p=[];for(const y of o){const f=s[y],m=a.data[y];p.push({key:{status:"valid",value:y},value:f._parse(new zt(a,m,a.path,y)),alwaysSet:y in a.data})}if(this._def.catchall instanceof un){const y=this._def.unknownKeys;if(y==="passthrough")for(const f of l)p.push({key:{status:"valid",value:f},value:{status:"valid",value:a.data[f]}});else if(y==="strict")l.length>0&&(N(a,{code:O.unrecognized_keys,keys:l}),i.dirty());else if(y!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const y=this._def.catchall;for(const f of l){const m=a.data[f];p.push({key:{status:"valid",value:f},value:y._parse(new zt(a,m,a.path,f)),alwaysSet:f in a.data})}}return a.common.async?Promise.resolve().then(async()=>{const y=[];for(const f of p){const m=await f.key,b=await f.value;y.push({key:m,value:b,alwaysSet:f.alwaysSet})}return y}).then(y=>tt.mergeObjectSync(i,y)):tt.mergeObjectSync(i,p)}get shape(){return this._def.shape()}strict(e){return F.errToObj,new Ge({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(t,i)=>{var a,s,o,l;const p=(o=(s=(a=this._def).errorMap)===null||s===void 0?void 0:s.call(a,t,i).message)!==null&&o!==void 0?o:i.defaultError;return t.code==="unrecognized_keys"?{message:(l=F.errToObj(e).message)!==null&&l!==void 0?l:p}:{message:p}}}:{}})}strip(){return new Ge({...this._def,unknownKeys:"strip"})}passthrough(){return new Ge({...this._def,unknownKeys:"passthrough"})}extend(e){return new Ge({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new Ge({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:j.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new Ge({...this._def,catchall:e})}pick(e){const t={};return ee.objectKeys(e).forEach(i=>{e[i]&&this.shape[i]&&(t[i]=this.shape[i])}),new Ge({...this._def,shape:()=>t})}omit(e){const t={};return ee.objectKeys(this.shape).forEach(i=>{e[i]||(t[i]=this.shape[i])}),new Ge({...this._def,shape:()=>t})}deepPartial(){return qr(this)}partial(e){const t={};return ee.objectKeys(this.shape).forEach(i=>{const a=this.shape[i];e&&!e[i]?t[i]=a:t[i]=a.optional()}),new Ge({...this._def,shape:()=>t})}required(e){const t={};return ee.objectKeys(this.shape).forEach(i=>{if(e&&!e[i])t[i]=this.shape[i];else{let s=this.shape[i];for(;s instanceof Xt;)s=s._def.innerType;t[i]=s}}),new Ge({...this._def,shape:()=>t})}keyof(){return Nm(ee.objectKeys(this.shape))}}Ge.create=(n,e)=>new Ge({shape:()=>n,unknownKeys:"strip",catchall:un.create(),typeName:j.ZodObject,...z(e)}),Ge.strictCreate=(n,e)=>new Ge({shape:()=>n,unknownKeys:"strict",catchall:un.create(),typeName:j.ZodObject,...z(e)}),Ge.lazycreate=(n,e)=>new Ge({shape:n,unknownKeys:"strip",catchall:un.create(),typeName:j.ZodObject,...z(e)});class Mi extends X{_parse(e){const{ctx:t}=this._processInputParams(e),i=this._def.options;function a(s){for(const l of s)if(l.result.status==="valid")return l.result;for(const l of s)if(l.result.status==="dirty")return t.common.issues.push(...l.ctx.common.issues),l.result;const o=s.map(l=>new bt(l.ctx.common.issues));return N(t,{code:O.invalid_union,unionErrors:o}),q}if(t.common.async)return Promise.all(i.map(async s=>{const o={...t,common:{...t.common,issues:[]},parent:null};return{result:await s._parseAsync({data:t.data,path:t.path,parent:o}),ctx:o}})).then(a);{let s;const o=[];for(const p of i){const y={...t,common:{...t.common,issues:[]},parent:null},f=p._parseSync({data:t.data,path:t.path,parent:y});if(f.status==="valid")return f;f.status==="dirty"&&!s&&(s={result:f,ctx:y}),y.common.issues.length&&o.push(y.common.issues)}if(s)return t.common.issues.push(...s.ctx.common.issues),s.result;const l=o.map(p=>new bt(p));return N(t,{code:O.invalid_union,unionErrors:l}),q}}get options(){return this._def.options}}Mi.create=(n,e)=>new Mi({options:n,typeName:j.ZodUnion,...z(e)});const pn=n=>n instanceof $i?pn(n.schema):n instanceof qt?pn(n.innerType()):n instanceof Li?[n.value]:n instanceof _n?n.options:n instanceof Gi?ee.objectValues(n.enum):n instanceof Fi?pn(n._def.innerType):n instanceof wi?[void 0]:n instanceof _i?[null]:n instanceof Xt?[void 0,...pn(n.unwrap())]:n instanceof Mn?[null,...pn(n.unwrap())]:n instanceof yl||n instanceof ki?pn(n.unwrap()):n instanceof Ui?pn(n._def.innerType):[];class Ka extends X{_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==$.object)return N(t,{code:O.invalid_type,expected:$.object,received:t.parsedType}),q;const i=this.discriminator,a=t.data[i],s=this.optionsMap.get(a);return s?t.common.async?s._parseAsync({data:t.data,path:t.path,parent:t}):s._parseSync({data:t.data,path:t.path,parent:t}):(N(t,{code:O.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[i]}),q)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,i){const a=new Map;for(const s of t){const o=pn(s.shape[e]);if(!o.length)throw new Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(const l of o){if(a.has(l))throw new Error(`Discriminator property ${String(e)} has duplicate value ${String(l)}`);a.set(l,s)}}return new Ka({typeName:j.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:a,...z(i)})}}function pl(n,e){const t=Cn(n),i=Cn(e);if(n===e)return{valid:!0,data:n};if(t===$.object&&i===$.object){const a=ee.objectKeys(e),s=ee.objectKeys(n).filter(l=>a.indexOf(l)!==-1),o={...n,...e};for(const l of s){const p=pl(n[l],e[l]);if(!p.valid)return{valid:!1};o[l]=p.data}return{valid:!0,data:o}}else if(t===$.array&&i===$.array){if(n.length!==e.length)return{valid:!1};const a=[];for(let s=0;s<n.length;s++){const o=n[s],l=e[s],p=pl(o,l);if(!p.valid)return{valid:!1};a.push(p.data)}return{valid:!0,data:a}}else return t===$.date&&i===$.date&&+n==+e?{valid:!0,data:n}:{valid:!1}}class Ni extends X{_parse(e){const{status:t,ctx:i}=this._processInputParams(e),a=(s,o)=>{if(cl(s)||cl(o))return q;const l=pl(s.value,o.value);return l.valid?((dl(s)||dl(o))&&t.dirty(),{status:t.value,value:l.data}):(N(i,{code:O.invalid_intersection_types}),q)};return i.common.async?Promise.all([this._def.left._parseAsync({data:i.data,path:i.path,parent:i}),this._def.right._parseAsync({data:i.data,path:i.path,parent:i})]).then(([s,o])=>a(s,o)):a(this._def.left._parseSync({data:i.data,path:i.path,parent:i}),this._def.right._parseSync({data:i.data,path:i.path,parent:i}))}}Ni.create=(n,e,t)=>new Ni({left:n,right:e,typeName:j.ZodIntersection,...z(t)});class Zt extends X{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==$.array)return N(i,{code:O.invalid_type,expected:$.array,received:i.parsedType}),q;if(i.data.length<this._def.items.length)return N(i,{code:O.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),q;!this._def.rest&&i.data.length>this._def.items.length&&(N(i,{code:O.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());const s=[...i.data].map((o,l)=>{const p=this._def.items[l]||this._def.rest;return p?p._parse(new zt(i,o,i.path,l)):null}).filter(o=>!!o);return i.common.async?Promise.all(s).then(o=>tt.mergeArray(t,o)):tt.mergeArray(t,s)}get items(){return this._def.items}rest(e){return new Zt({...this._def,rest:e})}}Zt.create=(n,e)=>{if(!Array.isArray(n))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new Zt({items:n,typeName:j.ZodTuple,rest:null,...z(e)})};class Vi extends X{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==$.object)return N(i,{code:O.invalid_type,expected:$.object,received:i.parsedType}),q;const a=[],s=this._def.keyType,o=this._def.valueType;for(const l in i.data)a.push({key:s._parse(new zt(i,l,i.path,l)),value:o._parse(new zt(i,i.data[l],i.path,l)),alwaysSet:l in i.data});return i.common.async?tt.mergeObjectAsync(t,a):tt.mergeObjectSync(t,a)}get element(){return this._def.valueType}static create(e,t,i){return t instanceof X?new Vi({keyType:e,valueType:t,typeName:j.ZodRecord,...z(i)}):new Vi({keyType:kt.create(),valueType:e,typeName:j.ZodRecord,...z(t)})}}class es extends X{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==$.map)return N(i,{code:O.invalid_type,expected:$.map,received:i.parsedType}),q;const a=this._def.keyType,s=this._def.valueType,o=[...i.data.entries()].map(([l,p],y)=>({key:a._parse(new zt(i,l,i.path,[y,"key"])),value:s._parse(new zt(i,p,i.path,[y,"value"]))}));if(i.common.async){const l=new Map;return Promise.resolve().then(async()=>{for(const p of o){const y=await p.key,f=await p.value;if(y.status==="aborted"||f.status==="aborted")return q;(y.status==="dirty"||f.status==="dirty")&&t.dirty(),l.set(y.value,f.value)}return{status:t.value,value:l}})}else{const l=new Map;for(const p of o){const y=p.key,f=p.value;if(y.status==="aborted"||f.status==="aborted")return q;(y.status==="dirty"||f.status==="dirty")&&t.dirty(),l.set(y.value,f.value)}return{status:t.value,value:l}}}}es.create=(n,e,t)=>new es({valueType:e,keyType:n,typeName:j.ZodMap,...z(t)});class rr extends X{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.parsedType!==$.set)return N(i,{code:O.invalid_type,expected:$.set,received:i.parsedType}),q;const a=this._def;a.minSize!==null&&i.data.size<a.minSize.value&&(N(i,{code:O.too_small,minimum:a.minSize.value,type:"set",inclusive:!0,exact:!1,message:a.minSize.message}),t.dirty()),a.maxSize!==null&&i.data.size>a.maxSize.value&&(N(i,{code:O.too_big,maximum:a.maxSize.value,type:"set",inclusive:!0,exact:!1,message:a.maxSize.message}),t.dirty());const s=this._def.valueType;function o(p){const y=new Set;for(const f of p){if(f.status==="aborted")return q;f.status==="dirty"&&t.dirty(),y.add(f.value)}return{status:t.value,value:y}}const l=[...i.data.values()].map((p,y)=>s._parse(new zt(i,p,i.path,y)));return i.common.async?Promise.all(l).then(p=>o(p)):o(l)}min(e,t){return new rr({...this._def,minSize:{value:e,message:F.toString(t)}})}max(e,t){return new rr({...this._def,maxSize:{value:e,message:F.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}rr.create=(n,e)=>new rr({valueType:n,minSize:null,maxSize:null,typeName:j.ZodSet,...z(e)});class Jr extends X{constructor(){super(...arguments),this.validate=this.implement}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==$.function)return N(t,{code:O.invalid_type,expected:$.function,received:t.parsedType}),q;function i(l,p){return za({data:l,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,Ya(),xr].filter(y=>!!y),issueData:{code:O.invalid_arguments,argumentsError:p}})}function a(l,p){return za({data:l,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,Ya(),xr].filter(y=>!!y),issueData:{code:O.invalid_return_type,returnTypeError:p}})}const s={errorMap:t.common.contextualErrorMap},o=t.data;if(this._def.returns instanceof Wr){const l=this;return ut(async function(...p){const y=new bt([]),f=await l._def.args.parseAsync(p,s).catch(g=>{throw y.addIssue(i(p,g)),y}),m=await Reflect.apply(o,this,f);return await l._def.returns._def.type.parseAsync(m,s).catch(g=>{throw y.addIssue(a(m,g)),y})})}else{const l=this;return ut(function(...p){const y=l._def.args.safeParse(p,s);if(!y.success)throw new bt([i(p,y.error)]);const f=Reflect.apply(o,this,y.data),m=l._def.returns.safeParse(f,s);if(!m.success)throw new bt([a(f,m.error)]);return m.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new Jr({...this._def,args:Zt.create(e).rest(nr.create())})}returns(e){return new Jr({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,i){return new Jr({args:e||Zt.create([]).rest(nr.create()),returns:t||nr.create(),typeName:j.ZodFunction,...z(i)})}}class $i extends X{get schema(){return this._def.getter()}_parse(e){const{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}$i.create=(n,e)=>new $i({getter:n,typeName:j.ZodLazy,...z(e)});class Li extends X{_parse(e){if(e.data!==this._def.value){const t=this._getOrReturnCtx(e);return N(t,{received:t.data,code:O.invalid_literal,expected:this._def.value}),q}return{status:"valid",value:e.data}}get value(){return this._def.value}}Li.create=(n,e)=>new Li({value:n,typeName:j.ZodLiteral,...z(e)});function Nm(n,e){return new _n({values:n,typeName:j.ZodEnum,...z(e)})}class _n extends X{constructor(){super(...arguments),Oi.set(this,void 0)}_parse(e){if(typeof e.data!="string"){const t=this._getOrReturnCtx(e),i=this._def.values;return N(t,{expected:ee.joinValues(i),received:t.parsedType,code:O.invalid_type}),q}if(Za(this,Oi,"f")||Cm(this,Oi,new Set(this._def.values),"f"),!Za(this,Oi,"f").has(e.data)){const t=this._getOrReturnCtx(e),i=this._def.values;return N(t,{received:t.data,code:O.invalid_enum_value,options:i}),q}return ut(e.data)}get options(){return this._def.values}get enum(){const e={};for(const t of this._def.values)e[t]=t;return e}get Values(){const e={};for(const t of this._def.values)e[t]=t;return e}get Enum(){const e={};for(const t of this._def.values)e[t]=t;return e}extract(e,t=this._def){return _n.create(e,{...this._def,...t})}exclude(e,t=this._def){return _n.create(this.options.filter(i=>!e.includes(i)),{...this._def,...t})}}Oi=new WeakMap,_n.create=Nm;class Gi extends X{constructor(){super(...arguments),Ci.set(this,void 0)}_parse(e){const t=ee.getValidEnumValues(this._def.values),i=this._getOrReturnCtx(e);if(i.parsedType!==$.string&&i.parsedType!==$.number){const a=ee.objectValues(t);return N(i,{expected:ee.joinValues(a),received:i.parsedType,code:O.invalid_type}),q}if(Za(this,Ci,"f")||Cm(this,Ci,new Set(ee.getValidEnumValues(this._def.values)),"f"),!Za(this,Ci,"f").has(e.data)){const a=ee.objectValues(t);return N(i,{received:i.data,code:O.invalid_enum_value,options:a}),q}return ut(e.data)}get enum(){return this._def.values}}Ci=new WeakMap,Gi.create=(n,e)=>new Gi({values:n,typeName:j.ZodNativeEnum,...z(e)});class Wr extends X{unwrap(){return this._def.type}_parse(e){const{ctx:t}=this._processInputParams(e);if(t.parsedType!==$.promise&&t.common.async===!1)return N(t,{code:O.invalid_type,expected:$.promise,received:t.parsedType}),q;const i=t.parsedType===$.promise?t.data:Promise.resolve(t.data);return ut(i.then(a=>this._def.type.parseAsync(a,{path:t.path,errorMap:t.common.contextualErrorMap})))}}Wr.create=(n,e)=>new Wr({type:n,typeName:j.ZodPromise,...z(e)});class qt extends X{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===j.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){const{status:t,ctx:i}=this._processInputParams(e),a=this._def.effect||null,s={addIssue:o=>{N(i,o),o.fatal?t.abort():t.dirty()},get path(){return i.path}};if(s.addIssue=s.addIssue.bind(s),a.type==="preprocess"){const o=a.transform(i.data,s);if(i.common.async)return Promise.resolve(o).then(async l=>{if(t.value==="aborted")return q;const p=await this._def.schema._parseAsync({data:l,path:i.path,parent:i});return p.status==="aborted"?q:p.status==="dirty"||t.value==="dirty"?kr(p.value):p});{if(t.value==="aborted")return q;const l=this._def.schema._parseSync({data:o,path:i.path,parent:i});return l.status==="aborted"?q:l.status==="dirty"||t.value==="dirty"?kr(l.value):l}}if(a.type==="refinement"){const o=l=>{const p=a.refinement(l,s);if(i.common.async)return Promise.resolve(p);if(p instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return l};if(i.common.async===!1){const l=this._def.schema._parseSync({data:i.data,path:i.path,parent:i});return l.status==="aborted"?q:(l.status==="dirty"&&t.dirty(),o(l.value),{status:t.value,value:l.value})}else return this._def.schema._parseAsync({data:i.data,path:i.path,parent:i}).then(l=>l.status==="aborted"?q:(l.status==="dirty"&&t.dirty(),o(l.value).then(()=>({status:t.value,value:l.value}))))}if(a.type==="transform")if(i.common.async===!1){const o=this._def.schema._parseSync({data:i.data,path:i.path,parent:i});if(!Ai(o))return o;const l=a.transform(o.value,s);if(l instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:l}}else return this._def.schema._parseAsync({data:i.data,path:i.path,parent:i}).then(o=>Ai(o)?Promise.resolve(a.transform(o.value,s)).then(l=>({status:t.value,value:l})):o);ee.assertNever(a)}}qt.create=(n,e,t)=>new qt({schema:n,typeName:j.ZodEffects,effect:e,...z(t)}),qt.createWithPreprocess=(n,e,t)=>new qt({schema:e,effect:{type:"preprocess",transform:n},typeName:j.ZodEffects,...z(t)});class Xt extends X{_parse(e){return this._getType(e)===$.undefined?ut(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}Xt.create=(n,e)=>new Xt({innerType:n,typeName:j.ZodOptional,...z(e)});class Mn extends X{_parse(e){return this._getType(e)===$.null?ut(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}Mn.create=(n,e)=>new Mn({innerType:n,typeName:j.ZodNullable,...z(e)});class Fi extends X{_parse(e){const{ctx:t}=this._processInputParams(e);let i=t.data;return t.parsedType===$.undefined&&(i=this._def.defaultValue()),this._def.innerType._parse({data:i,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}Fi.create=(n,e)=>new Fi({innerType:n,typeName:j.ZodDefault,defaultValue:typeof e.default=="function"?e.default:()=>e.default,...z(e)});class Ui extends X{_parse(e){const{ctx:t}=this._processInputParams(e),i={...t,common:{...t.common,issues:[]}},a=this._def.innerType._parse({data:i.data,path:i.path,parent:{...i}});return Si(a)?a.then(s=>({status:"valid",value:s.status==="valid"?s.value:this._def.catchValue({get error(){return new bt(i.common.issues)},input:i.data})})):{status:"valid",value:a.status==="valid"?a.value:this._def.catchValue({get error(){return new bt(i.common.issues)},input:i.data})}}removeCatch(){return this._def.innerType}}Ui.create=(n,e)=>new Ui({innerType:n,typeName:j.ZodCatch,catchValue:typeof e.catch=="function"?e.catch:()=>e.catch,...z(e)});class ts extends X{_parse(e){if(this._getType(e)!==$.nan){const i=this._getOrReturnCtx(e);return N(i,{code:O.invalid_type,expected:$.nan,received:i.parsedType}),q}return{status:"valid",value:e.data}}}ts.create=n=>new ts({typeName:j.ZodNaN,...z(n)});const dD=Symbol("zod_brand");class yl extends X{_parse(e){const{ctx:t}=this._processInputParams(e),i=t.data;return this._def.type._parse({data:i,path:t.path,parent:t})}unwrap(){return this._def.type}}class xi extends X{_parse(e){const{status:t,ctx:i}=this._processInputParams(e);if(i.common.async)return(async()=>{const s=await this._def.in._parseAsync({data:i.data,path:i.path,parent:i});return s.status==="aborted"?q:s.status==="dirty"?(t.dirty(),kr(s.value)):this._def.out._parseAsync({data:s.value,path:i.path,parent:i})})();{const a=this._def.in._parseSync({data:i.data,path:i.path,parent:i});return a.status==="aborted"?q:a.status==="dirty"?(t.dirty(),{status:"dirty",value:a.value}):this._def.out._parseSync({data:a.value,path:i.path,parent:i})}}static create(e,t){return new xi({in:e,out:t,typeName:j.ZodPipeline})}}class ki extends X{_parse(e){const t=this._def.innerType._parse(e),i=a=>(Ai(a)&&(a.value=Object.freeze(a.value)),a);return Si(t)?t.then(a=>i(a)):i(t)}unwrap(){return this._def.innerType}}ki.create=(n,e)=>new ki({innerType:n,typeName:j.ZodReadonly,...z(e)});function Vm(n,e={},t){return n?jr.create().superRefine((i,a)=>{var s,o;if(!n(i)){const l=typeof e=="function"?e(i):typeof e=="string"?{message:e}:e,p=(o=(s=l.fatal)!==null&&s!==void 0?s:t)!==null&&o!==void 0?o:!0,y=typeof l=="string"?{message:l}:l;a.addIssue({code:"custom",...y,fatal:p})}}):jr.create()}const uD={object:Ge.lazycreate};var j;(function(n){n.ZodString="ZodString",n.ZodNumber="ZodNumber",n.ZodNaN="ZodNaN",n.ZodBigInt="ZodBigInt",n.ZodBoolean="ZodBoolean",n.ZodDate="ZodDate",n.ZodSymbol="ZodSymbol",n.ZodUndefined="ZodUndefined",n.ZodNull="ZodNull",n.ZodAny="ZodAny",n.ZodUnknown="ZodUnknown",n.ZodNever="ZodNever",n.ZodVoid="ZodVoid",n.ZodArray="ZodArray",n.ZodObject="ZodObject",n.ZodUnion="ZodUnion",n.ZodDiscriminatedUnion="ZodDiscriminatedUnion",n.ZodIntersection="ZodIntersection",n.ZodTuple="ZodTuple",n.ZodRecord="ZodRecord",n.ZodMap="ZodMap",n.ZodSet="ZodSet",n.ZodFunction="ZodFunction",n.ZodLazy="ZodLazy",n.ZodLiteral="ZodLiteral",n.ZodEnum="ZodEnum",n.ZodEffects="ZodEffects",n.ZodNativeEnum="ZodNativeEnum",n.ZodOptional="ZodOptional",n.ZodNullable="ZodNullable",n.ZodDefault="ZodDefault",n.ZodCatch="ZodCatch",n.ZodPromise="ZodPromise",n.ZodBranded="ZodBranded",n.ZodPipeline="ZodPipeline",n.ZodReadonly="ZodReadonly"})(j||(j={}));const pD=(n,e={message:`Input not instance of ${n.name}`})=>Vm(t=>t instanceof n,e),ns=kt.create,hl=Bn.create,yD=ts.create,hD=wn.create,fl=Bi.create,$m=tr.create,fD=Xa.create,mD=wi.create,Lm=_i.create,TD=jr.create,rs=nr.create,ED=un.create,RD=Qa.create,bD=jt.create,Gm=Ge.create,gD=Ge.strictCreate,vD=Mi.create,ID=Ka.create,DD=Ni.create,PD=Zt.create,Fm=Vi.create,AD=es.create,SD=rr.create,OD=Jr.create,CD=$i.create,BD=Li.create,Um=_n.create,wD=Gi.create,_D=Wr.create,xm=qt.create,MD=Xt.create,ND=Mn.create,VD=qt.createWithPreprocess,$D=xi.create;var d=Object.freeze({__proto__:null,defaultErrorMap:xr,setErrorMap:HI,getErrorMap:Ya,makeIssue:za,EMPTY_PATH:YI,addIssueToContext:N,ParseStatus:tt,INVALID:q,DIRTY:kr,OK:ut,isAborted:cl,isDirty:dl,isValid:Ai,isAsync:Si,get util(){return ee},get objectUtil(){return ll},ZodParsedType:$,getParsedType:Cn,ZodType:X,datetimeRegex:Mm,ZodString:kt,ZodNumber:Bn,ZodBigInt:wn,ZodBoolean:Bi,ZodDate:tr,ZodSymbol:Xa,ZodUndefined:wi,ZodNull:_i,ZodAny:jr,ZodUnknown:nr,ZodNever:un,ZodVoid:Qa,ZodArray:jt,ZodObject:Ge,ZodUnion:Mi,ZodDiscriminatedUnion:Ka,ZodIntersection:Ni,ZodTuple:Zt,ZodRecord:Vi,ZodMap:es,ZodSet:rr,ZodFunction:Jr,ZodLazy:$i,ZodLiteral:Li,ZodEnum:_n,ZodNativeEnum:Gi,ZodPromise:Wr,ZodEffects:qt,ZodTransformer:qt,ZodOptional:Xt,ZodNullable:Mn,ZodDefault:Fi,ZodCatch:Ui,ZodNaN:ts,BRAND:dD,ZodBranded:yl,ZodPipeline:xi,ZodReadonly:ki,custom:Vm,Schema:X,ZodSchema:X,late:uD,get ZodFirstPartyTypeKind(){return j},coerce:{string:n=>kt.create({...n,coerce:!0}),number:n=>Bn.create({...n,coerce:!0}),boolean:n=>Bi.create({...n,coerce:!0}),bigint:n=>wn.create({...n,coerce:!0}),date:n=>tr.create({...n,coerce:!0})},any:TD,array:bD,bigint:hD,boolean:fl,date:$m,discriminatedUnion:ID,effect:xm,enum:Um,function:OD,instanceof:pD,intersection:DD,lazy:CD,literal:BD,map:AD,nan:yD,nativeEnum:wD,never:ED,null:Lm,nullable:ND,number:hl,object:Gm,oboolean:()=>fl().optional(),onumber:()=>hl().optional(),optional:MD,ostring:()=>ns().optional(),pipeline:$D,preprocess:VD,promise:_D,record:Fm,set:SD,strictObject:gD,string:ns,symbol:fD,transformer:xm,tuple:PD,undefined:mD,union:vD,unknown:rs,void:RD,NEVER:q,ZodIssueCode:O,quotelessJson:WI,ZodError:bt});function km(n){var a,s,o;if(!(n!=null&&n.dataType))return rs();const e=n.dataType.isNullable||!1,t=n.dataType.isList||!1;let i=rs();if(((a=n.dataType.entity)==null?void 0:a.type)===r.PrimitiveEntity)switch(n.dataType.entity.name){case A.String:i=ns();break;case A.JSON:i=Fm(rs());break;case A.Number:i=hl();break;case A.Boolean:i=fl();break;case A.Date:i=$m();break;case A.Enum:{const l=n.dataType.options||[];if(l.length===0)throw new Error(`Enum property ${n.name} has no options`);i=Um(l);break}case A.Null:i=Lm();break;case A.UUID:i=ns().uuid();break}else if(((s=n.dataType.entity)==null?void 0:s.type)===r.CustomEntity)i=jm(n.dataType.entity);else throw new Error(`Unsupported data type validation: ${(o=n.dataType.entity)==null?void 0:o.type}`);return e&&(i=i.nullable()),t&&(i=i.array()),i}function jm(n){const e=Gm({});for(const t of n.properties){const i=km(t);e.shape[t.name]=i}return e}function qm(n){const e=n.rangeStart;return new Date(e.getTime()+Math.random()*(Date.now()-e.getTime()))}function Jm(n){const e=n.rangeEnd;return new Date(Math.random()*e.getTime())}function Wm(n){const e=n.rangeStart,t=n.rangeEnd;return new Date(e.getTime()+Math.random()*(t.getTime()-e.getTime()))}function Hm(n){return n.rangeStart&&n.rangeEnd?Wm(n):n.rangeStart?qm(n):n.rangeEnd?Jm(n):new Date}function LD(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var Ym={},is={},as={};Object.defineProperty(as,"__esModule",{value:!0}),as.default=FD;let ss;const GD=new Uint8Array(16);function FD(){if(!ss&&(ss=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!ss))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return ss(GD)}var Nn={},ir={},os={};Object.defineProperty(os,"__esModule",{value:!0}),os.default=void 0;var UD=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;os.default=UD,Object.defineProperty(ir,"__esModule",{value:!0}),ir.default=void 0;var xD=kD(os);function kD(n){return n&&n.__esModule?n:{default:n}}function jD(n){return typeof n=="string"&&xD.default.test(n)}var qD=jD;ir.default=qD,Object.defineProperty(Nn,"__esModule",{value:!0}),Nn.default=void 0,Nn.unsafeStringify=zm;var JD=WD(ir);function WD(n){return n&&n.__esModule?n:{default:n}}const Qe=[];for(let n=0;n<256;++n)Qe.push((n+256).toString(16).slice(1));function zm(n,e=0){return Qe[n[e+0]]+Qe[n[e+1]]+Qe[n[e+2]]+Qe[n[e+3]]+"-"+Qe[n[e+4]]+Qe[n[e+5]]+"-"+Qe[n[e+6]]+Qe[n[e+7]]+"-"+Qe[n[e+8]]+Qe[n[e+9]]+"-"+Qe[n[e+10]]+Qe[n[e+11]]+Qe[n[e+12]]+Qe[n[e+13]]+Qe[n[e+14]]+Qe[n[e+15]]}function HD(n,e=0){const t=zm(n,e);if(!(0,JD.default)(t))throw TypeError("Stringified UUID is invalid");return t}var YD=HD;Nn.default=YD,Object.defineProperty(is,"__esModule",{value:!0}),is.default=void 0;var zD=XD(as),ZD=Nn;function XD(n){return n&&n.__esModule?n:{default:n}}let Zm,ml,Tl=0,El=0;function QD(n,e,t){let i=e&&t||0;const a=e||new Array(16);n=n||{};let s=n.node||Zm,o=n.clockseq!==void 0?n.clockseq:ml;if(s==null||o==null){const b=n.random||(n.rng||zD.default)();s==null&&(s=Zm=[b[0]|1,b[1],b[2],b[3],b[4],b[5]]),o==null&&(o=ml=(b[6]<<8|b[7])&16383)}let l=n.msecs!==void 0?n.msecs:Date.now(),p=n.nsecs!==void 0?n.nsecs:El+1;const y=l-Tl+(p-El)/1e4;if(y<0&&n.clockseq===void 0&&(o=o+1&16383),(y<0||l>Tl)&&n.nsecs===void 0&&(p=0),p>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");Tl=l,El=p,ml=o,l+=122192928e5;const f=((l&268435455)*1e4+p)%4294967296;a[i++]=f>>>24&255,a[i++]=f>>>16&255,a[i++]=f>>>8&255,a[i++]=f&255;const m=l/4294967296*1e4&268435455;a[i++]=m>>>8&255,a[i++]=m&255,a[i++]=m>>>24&15|16,a[i++]=m>>>16&255,a[i++]=o>>>8|128,a[i++]=o&255;for(let b=0;b<6;++b)a[i+b]=s[b];return e||(0,ZD.unsafeStringify)(a)}var KD=QD;is.default=KD;var ls={},Vn={},ji={};Object.defineProperty(ji,"__esModule",{value:!0}),ji.default=void 0;var eP=tP(ir);function tP(n){return n&&n.__esModule?n:{default:n}}function nP(n){if(!(0,eP.default)(n))throw TypeError("Invalid UUID");let e;const t=new Uint8Array(16);return t[0]=(e=parseInt(n.slice(0,8),16))>>>24,t[1]=e>>>16&255,t[2]=e>>>8&255,t[3]=e&255,t[4]=(e=parseInt(n.slice(9,13),16))>>>8,t[5]=e&255,t[6]=(e=parseInt(n.slice(14,18),16))>>>8,t[7]=e&255,t[8]=(e=parseInt(n.slice(19,23),16))>>>8,t[9]=e&255,t[10]=(e=parseInt(n.slice(24,36),16))/1099511627776&255,t[11]=e/4294967296&255,t[12]=e>>>24&255,t[13]=e>>>16&255,t[14]=e>>>8&255,t[15]=e&255,t}var rP=nP;ji.default=rP,Object.defineProperty(Vn,"__esModule",{value:!0}),Vn.URL=Vn.DNS=void 0,Vn.default=lP;var iP=Nn,aP=sP(ji);function sP(n){return n&&n.__esModule?n:{default:n}}function oP(n){n=unescape(encodeURIComponent(n));const e=[];for(let t=0;t<n.length;++t)e.push(n.charCodeAt(t));return e}const Xm="6ba7b810-9dad-11d1-80b4-00c04fd430c8";Vn.DNS=Xm;const Qm="6ba7b811-9dad-11d1-80b4-00c04fd430c8";Vn.URL=Qm;function lP(n,e,t){function i(a,s,o,l){var p;if(typeof a=="string"&&(a=oP(a)),typeof s=="string"&&(s=(0,aP.default)(s)),((p=s)===null||p===void 0?void 0:p.length)!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let y=new Uint8Array(16+a.length);if(y.set(s),y.set(a,s.length),y=t(y),y[6]=y[6]&15|e,y[8]=y[8]&63|128,o){l=l||0;for(let f=0;f<16;++f)o[l+f]=y[f];return o}return(0,iP.unsafeStringify)(y)}try{i.name=n}catch{}return i.DNS=Xm,i.URL=Qm,i}var cs={};Object.defineProperty(cs,"__esModule",{value:!0}),cs.default=void 0;function cP(n){if(typeof n=="string"){const e=unescape(encodeURIComponent(n));n=new Uint8Array(e.length);for(let t=0;t<e.length;++t)n[t]=e.charCodeAt(t)}return dP(uP(pP(n),n.length*8))}function dP(n){const e=[],t=n.length*32,i="0123456789abcdef";for(let a=0;a<t;a+=8){const s=n[a>>5]>>>a%32&255,o=parseInt(i.charAt(s>>>4&15)+i.charAt(s&15),16);e.push(o)}return e}function Km(n){return(n+64>>>9<<4)+14+1}function uP(n,e){n[e>>5]|=128<<e%32,n[Km(e)-1]=e;let t=1732584193,i=-271733879,a=-1732584194,s=271733878;for(let o=0;o<n.length;o+=16){const l=t,p=i,y=a,f=s;t=nt(t,i,a,s,n[o],7,-680876936),s=nt(s,t,i,a,n[o+1],12,-389564586),a=nt(a,s,t,i,n[o+2],17,606105819),i=nt(i,a,s,t,n[o+3],22,-1044525330),t=nt(t,i,a,s,n[o+4],7,-176418897),s=nt(s,t,i,a,n[o+5],12,1200080426),a=nt(a,s,t,i,n[o+6],17,-1473231341),i=nt(i,a,s,t,n[o+7],22,-45705983),t=nt(t,i,a,s,n[o+8],7,1770035416),s=nt(s,t,i,a,n[o+9],12,-1958414417),a=nt(a,s,t,i,n[o+10],17,-42063),i=nt(i,a,s,t,n[o+11],22,-1990404162),t=nt(t,i,a,s,n[o+12],7,1804603682),s=nt(s,t,i,a,n[o+13],12,-40341101),a=nt(a,s,t,i,n[o+14],17,-1502002290),i=nt(i,a,s,t,n[o+15],22,1236535329),t=rt(t,i,a,s,n[o+1],5,-165796510),s=rt(s,t,i,a,n[o+6],9,-1069501632),a=rt(a,s,t,i,n[o+11],14,643717713),i=rt(i,a,s,t,n[o],20,-373897302),t=rt(t,i,a,s,n[o+5],5,-701558691),s=rt(s,t,i,a,n[o+10],9,38016083),a=rt(a,s,t,i,n[o+15],14,-660478335),i=rt(i,a,s,t,n[o+4],20,-405537848),t=rt(t,i,a,s,n[o+9],5,568446438),s=rt(s,t,i,a,n[o+14],9,-1019803690),a=rt(a,s,t,i,n[o+3],14,-187363961),i=rt(i,a,s,t,n[o+8],20,1163531501),t=rt(t,i,a,s,n[o+13],5,-1444681467),s=rt(s,t,i,a,n[o+2],9,-51403784),a=rt(a,s,t,i,n[o+7],14,1735328473),i=rt(i,a,s,t,n[o+12],20,-1926607734),t=it(t,i,a,s,n[o+5],4,-378558),s=it(s,t,i,a,n[o+8],11,-2022574463),a=it(a,s,t,i,n[o+11],16,1839030562),i=it(i,a,s,t,n[o+14],23,-35309556),t=it(t,i,a,s,n[o+1],4,-1530992060),s=it(s,t,i,a,n[o+4],11,1272893353),a=it(a,s,t,i,n[o+7],16,-155497632),i=it(i,a,s,t,n[o+10],23,-1094730640),t=it(t,i,a,s,n[o+13],4,681279174),s=it(s,t,i,a,n[o],11,-358537222),a=it(a,s,t,i,n[o+3],16,-722521979),i=it(i,a,s,t,n[o+6],23,76029189),t=it(t,i,a,s,n[o+9],4,-640364487),s=it(s,t,i,a,n[o+12],11,-421815835),a=it(a,s,t,i,n[o+15],16,530742520),i=it(i,a,s,t,n[o+2],23,-995338651),t=at(t,i,a,s,n[o],6,-198630844),s=at(s,t,i,a,n[o+7],10,1126891415),a=at(a,s,t,i,n[o+14],15,-1416354905),i=at(i,a,s,t,n[o+5],21,-57434055),t=at(t,i,a,s,n[o+12],6,1700485571),s=at(s,t,i,a,n[o+3],10,-1894986606),a=at(a,s,t,i,n[o+10],15,-1051523),i=at(i,a,s,t,n[o+1],21,-2054922799),t=at(t,i,a,s,n[o+8],6,1873313359),s=at(s,t,i,a,n[o+15],10,-30611744),a=at(a,s,t,i,n[o+6],15,-1560198380),i=at(i,a,s,t,n[o+13],21,1309151649),t=at(t,i,a,s,n[o+4],6,-145523070),s=at(s,t,i,a,n[o+11],10,-1120210379),a=at(a,s,t,i,n[o+2],15,718787259),i=at(i,a,s,t,n[o+9],21,-343485551),t=$n(t,l),i=$n(i,p),a=$n(a,y),s=$n(s,f)}return[t,i,a,s]}function pP(n){if(n.length===0)return[];const e=n.length*8,t=new Uint32Array(Km(e));for(let i=0;i<e;i+=8)t[i>>5]|=(n[i/8]&255)<<i%32;return t}function $n(n,e){const t=(n&65535)+(e&65535);return(n>>16)+(e>>16)+(t>>16)<<16|t&65535}function yP(n,e){return n<<e|n>>>32-e}function ds(n,e,t,i,a,s){return $n(yP($n($n(e,n),$n(i,s)),a),t)}function nt(n,e,t,i,a,s,o){return ds(e&t|~e&i,n,e,a,s,o)}function rt(n,e,t,i,a,s,o){return ds(e&i|t&~i,n,e,a,s,o)}function it(n,e,t,i,a,s,o){return ds(e^t^i,n,e,a,s,o)}function at(n,e,t,i,a,s,o){return ds(t^(e|~i),n,e,a,s,o)}var hP=cP;cs.default=hP,Object.defineProperty(ls,"__esModule",{value:!0}),ls.default=void 0;var fP=eT(Vn),mP=eT(cs);function eT(n){return n&&n.__esModule?n:{default:n}}var TP=(0,fP.default)("v3",48,mP.default);ls.default=TP;var us={},ps={};Object.defineProperty(ps,"__esModule",{value:!0}),ps.default=void 0;var EP={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};ps.default=EP,Object.defineProperty(us,"__esModule",{value:!0}),us.default=void 0;var tT=nT(ps),RP=nT(as),bP=Nn;function nT(n){return n&&n.__esModule?n:{default:n}}function gP(n,e,t){if(tT.default.randomUUID&&!e&&!n)return tT.default.randomUUID();n=n||{};const i=n.random||(n.rng||RP.default)();if(i[6]=i[6]&15|64,i[8]=i[8]&63|128,e){t=t||0;for(let a=0;a<16;++a)e[t+a]=i[a];return e}return(0,bP.unsafeStringify)(i)}var vP=gP;us.default=vP;var ys={},hs={};Object.defineProperty(hs,"__esModule",{value:!0}),hs.default=void 0;function IP(n,e,t,i){switch(n){case 0:return e&t^~e&i;case 1:return e^t^i;case 2:return e&t^e&i^t&i;case 3:return e^t^i}}function Rl(n,e){return n<<e|n>>>32-e}function DP(n){const e=[1518500249,1859775393,2400959708,3395469782],t=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof n=="string"){const o=unescape(encodeURIComponent(n));n=[];for(let l=0;l<o.length;++l)n.push(o.charCodeAt(l))}else Array.isArray(n)||(n=Array.prototype.slice.call(n));n.push(128);const i=n.length/4+2,a=Math.ceil(i/16),s=new Array(a);for(let o=0;o<a;++o){const l=new Uint32Array(16);for(let p=0;p<16;++p)l[p]=n[o*64+p*4]<<24|n[o*64+p*4+1]<<16|n[o*64+p*4+2]<<8|n[o*64+p*4+3];s[o]=l}s[a-1][14]=(n.length-1)*8/Math.pow(2,32),s[a-1][14]=Math.floor(s[a-1][14]),s[a-1][15]=(n.length-1)*8&4294967295;for(let o=0;o<a;++o){const l=new Uint32Array(80);for(let g=0;g<16;++g)l[g]=s[o][g];for(let g=16;g<80;++g)l[g]=Rl(l[g-3]^l[g-8]^l[g-14]^l[g-16],1);let p=t[0],y=t[1],f=t[2],m=t[3],b=t[4];for(let g=0;g<80;++g){const I=Math.floor(g/20),P=Rl(p,5)+IP(I,y,f,m)+b+e[I]+l[g]>>>0;b=m,m=f,f=Rl(y,30)>>>0,y=p,p=P}t[0]=t[0]+p>>>0,t[1]=t[1]+y>>>0,t[2]=t[2]+f>>>0,t[3]=t[3]+m>>>0,t[4]=t[4]+b>>>0}return[t[0]>>24&255,t[0]>>16&255,t[0]>>8&255,t[0]&255,t[1]>>24&255,t[1]>>16&255,t[1]>>8&255,t[1]&255,t[2]>>24&255,t[2]>>16&255,t[2]>>8&255,t[2]&255,t[3]>>24&255,t[3]>>16&255,t[3]>>8&255,t[3]&255,t[4]>>24&255,t[4]>>16&255,t[4]>>8&255,t[4]&255]}var PP=DP;hs.default=PP,Object.defineProperty(ys,"__esModule",{value:!0}),ys.default=void 0;var AP=rT(Vn),SP=rT(hs);function rT(n){return n&&n.__esModule?n:{default:n}}var OP=(0,AP.default)("v5",80,SP.default);ys.default=OP;var fs={};Object.defineProperty(fs,"__esModule",{value:!0}),fs.default=void 0;var CP="00000000-0000-0000-0000-000000000000";fs.default=CP;var ms={};Object.defineProperty(ms,"__esModule",{value:!0}),ms.default=void 0;var BP=wP(ir);function wP(n){return n&&n.__esModule?n:{default:n}}function _P(n){if(!(0,BP.default)(n))throw TypeError("Invalid UUID");return parseInt(n.slice(14,15),16)}var MP=_P;ms.default=MP,function(n){Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"NIL",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(n,"parse",{enumerable:!0,get:function(){return y.default}}),Object.defineProperty(n,"stringify",{enumerable:!0,get:function(){return p.default}}),Object.defineProperty(n,"v1",{enumerable:!0,get:function(){return e.default}}),Object.defineProperty(n,"v3",{enumerable:!0,get:function(){return t.default}}),Object.defineProperty(n,"v4",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(n,"v5",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(n,"validate",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(n,"version",{enumerable:!0,get:function(){return o.default}});var e=f(is),t=f(ls),i=f(us),a=f(ys),s=f(fs),o=f(ms),l=f(ir),p=f(Nn),y=f(ji);function f(m){return m&&m.__esModule?m:{default:m}}}(Ym);function bl(n,e){if(!n||!e||!n.length||!e.length)throw new Error("Bad alphabet");this.srcAlphabet=n,this.dstAlphabet=e}bl.prototype.convert=function(n){var e,t,i,a={},s=this.srcAlphabet.length,o=this.dstAlphabet.length,l=n.length,p=typeof n=="string"?"":[];if(!this.isValid(n))throw new Error('Number "'+n+'" contains of non-alphabetic digits ('+this.srcAlphabet+")");if(this.srcAlphabet===this.dstAlphabet)return n;for(e=0;e<l;e++)a[e]=this.srcAlphabet.indexOf(n[e]);do{for(t=0,i=0,e=0;e<l;e++)t=t*s+a[e],t>=o?(a[i++]=parseInt(t/o,10),t=t%o):i>0&&(a[i++]=0);l=i,p=this.dstAlphabet.slice(t,t+1).concat(p)}while(i!==0);return p},bl.prototype.isValid=function(n){for(var e=0;e<n.length;++e)if(this.srcAlphabet.indexOf(n[e])===-1)return!1;return!0};var NP=bl,VP=NP;function qi(n,e){var t=new VP(n,e);return function(i){return t.convert(i)}}qi.BIN="01",qi.OCT="01234567",qi.DEC="0123456789",qi.HEX="0123456789abcdef";var $P=qi;const{v4:gl,validate:LP}=Ym,Ts=$P,vl={cookieBase90:"0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ!#$%&'()*+-./:<=>?@[]^_`{|}~",flickrBase58:"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ",uuid25Base36:"0123456789abcdefghijklmnopqrstuvwxyz"},GP={consistentLength:!0};let Il;const iT=(n,e,t)=>{const i=e(n.toLowerCase().replace(/-/g,""));return!t||!t.consistentLength?i:i.padStart(t.shortIdLength,t.paddingChar)},aT=(n,e)=>{const i=e(n).padStart(32,"0").match(/(\w{8})(\w{4})(\w{4})(\w{4})(\w{12})/);return[i[1],i[2],i[3],i[4],i[5]].join("-")},FP=n=>Math.ceil(Math.log(2**128)/Math.log(n));var UP=(()=>{const n=(e,t)=>{const i=e||vl.flickrBase58,a={...GP,...t};if([...new Set(Array.from(i))].length!==i.length)throw new Error("The provided Alphabet has duplicate characters resulting in unreliable results");const s=FP(i.length),o={shortIdLength:s,consistentLength:a.consistentLength,paddingChar:i[0]},l=Ts(Ts.HEX,i),p=Ts(i,Ts.HEX),y=()=>iT(gl(),l,o),m={alphabet:i,fromUUID:b=>iT(b,l,o),maxLength:s,generate:y,new:y,toUUID:b=>aT(b,p),uuid:gl,validate:(b,g=!1)=>{if(!b||typeof b!="string")return!1;const I=a.consistentLength?b.length===s:b.length<=s,P=b.split("").every(B=>i.includes(B));return g===!1?I&&P:I&&P&&LP(aT(b,p))}};return Object.freeze(m),m};return n.constants=vl,n.uuid=gl,n.generate=()=>(Il||(Il=n(vl.flickrBase58).generate),Il()),n})();const Es=LD(UP);function sT(){return Es().uuid()}function oT(n){return n.rangeStart+Math.random()}function lT(n){const e=n.rangeEnd;return Math.random()*e}function cT(n){const e=n.rangeStart,t=n.rangeEnd;return Math.random()*(t-e)+e}function dT(n){return n.rangeStart&&n.rangeEnd?cT(n):n.rangeStart?oT(n):n.rangeEnd?lT(n):Math.random()}function uT(n){const e=n.rangeStart;return Math.random().toString(36).substring(e)}function pT(n){const e=n.rangeEnd;return Math.random().toString(36).substring(0,e)}function yT(n){const e=n.rangeStart,t=n.rangeEnd;return Math.random().toString(36).substring(e,t)}function hT(n){return n.rangeStart&&n.rangeEnd?yT(n):n.rangeStart?uT(n):n.rangeEnd?pT(n):Math.random().toString(36)}function fT(n){return Math.random()>=.5}function xP(n){if(!n||!n.autogeneration)return null;switch(n.autogeneration.type){case qe.CurrentDateAndTime:if(n.name===A.Date)return new Date;case qe.Random:{if(n.name===A.Date)return Hm(n.autogeneration);if(n.name===A.Number)return dT(n.autogeneration);if(n.name===A.String)return hT(n.autogeneration);if(n.name===A.Boolean)return fT(n.autogeneration)}case qe.Unique:if(n.name===A.UUID)return sT();default:throw new Error(`Generating a ${n.autogeneration.type} value for a ${n.name} is not supported`)}}const Z="e7eb5382-3d99-44fd-972a-b8b1e819f6be",Dl="global-user-variable-id",mT="last-executed-timestamp-variable-id",kP={id:"alternative-relational-database-entity-identifier-property-data-type-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-identifier-property-data-type-id",entityType:r.DataType},jP={id:"alternative-relational-database-entity-identifier-property-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-identifier-property-id",entityType:r.Property},qP={like:!1,id:"alternative-relational-database-entity-identifier-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"alternative-relational-database-entity-identifier-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:null,parent:kP,autogeneration:{type:qe.Unique,rangeStart:null,rangeEnd:null},valueAsType:null},parent:jP},Rs={id:"alternative-relational-database-entity-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},JP={hidden:!1,required:!0,id:"alternative-relational-database-entity-identifier-property-id",name:"Identifier name",version:1,type:r.Property,private:!1,abstract:!1,implements:ja,static:!0,index:0,dataType:qP,description:"The name of the main database inside of the server instance where the data will be stored.",parent:Rs};r.GenericReference,r.DataType;const WP={id:"alternative-relational-database-entity-username-property-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-username-property-id",entityType:r.Property},HP={like:!1,id:"alternative-relational-database-entity-username-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:null,parent:WP},YP={hidden:!1,required:!0,id:"alternative-relational-database-entity-username-property-id",name:"Username",version:1,type:r.Property,private:!1,abstract:!1,implements:qa,static:!0,index:1,dataType:HP,description:"The username that will be used to connect to the database.",parent:Rs};r.GenericReference,r.DataType;const zP={id:"alternative-relational-database-entity-password-property-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-password-property-id",entityType:r.Property},ZP={like:!1,id:"alternative-relational-database-entity-password-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:null,parent:zP},XP={hidden:!1,required:!0,id:"alternative-relational-database-entity-password-property-id",name:"Password",version:1,type:r.Property,private:!1,abstract:!1,implements:Ja,static:!0,index:2,dataType:ZP,description:"The password that will be used to connect to the database.",parent:Rs},QP={id:"alternative-relational-database-entity-min-size-property-data-type-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-min-size-property-data-type-id",entityType:r.DataType},KP={id:"alternative-relational-database-entity-min-size-property-ref-id",type:r.GenericReference,entityId:"alternative-relational-database-entity-min-size-property-id",entityType:r.Property},eA={like:!1,id:"alternative-relational-database-entity-min-size-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ce,asType:!1,defaultValue:{id:"alternative-relational-database-entity-min-size-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.Number,value:6,parent:QP,autogeneration:null,valueAsType:null},parent:KP},tA={hidden:!1,required:!0,id:"alternative-relational-database-entity-min-size-property-id",name:"Minimum GB size",version:1,type:r.Property,private:!1,abstract:!1,implements:Wa,static:!0,index:3,dataType:eA,description:"The minimum size of the database in GB.",parent:Rs},nA={id:"alternative-relational-database-entity-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},TT={id:"alternative-relational-database-entity-id",type:r.CustomEntity,version:1,name:"Alternative relational Database",description:"A database that permanently stores the persisted entities attached to it.",abstract:!1,static:!0,properties:[JP,YP,XP,tA],methods:[],abstractMethods:[],extends:[],implements:[On],x:0,y:0,parent:nA},rA={id:"animal-prototype-database-property-ref-id",type:r.GenericReference,entityId:"animal-prototype-database-property-id",entityType:r.Property},iA={id:"animal-prototype-database-property-data-type-default-value-parent-ref-id",type:r.GenericReference,entityId:"animal-prototype-database-property-data-type-default-value-id",entityType:r.DataType},aA={like:!1,id:"animal-prototype-database-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:On,asType:!1,defaultValue:{id:"animal-prototype-database-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,value:null,name:A.EntityTemplate,valueAsType:TT,autogeneration:null,parent:iA},parent:rA},sA={id:"animal-prototype-database-property-parent-ref-id",type:r.GenericReference,entityId:"de67fc84-3719-46fd-9ab4-3fca3a3cc50d",entityType:r.CustomEntity},oA={hidden:!1,required:!0,id:"animal-prototype-database-property-id",name:"Database",version:1,type:r.Property,private:!1,abstract:!1,implements:Pi,static:!0,index:0,dataType:aA,description:"The database that the entity belongs to.",parent:sA},lA={type:r.GenericReference,id:"291e4d4f-01d8-40a0-90dc-5f1ac6636e9b",entityType:r.Property,entityId:"5cb617b0-92be-4dbe-a007-49093368d94f"},cA={like:!1,id:"c1930577-9e79-48a6-8905-be24611015c1",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:lA},dA={type:r.GenericReference,id:"e2b9e456-f2b3-4dc7-85a2-fbb68ed0c9c7",entityType:r.CustomEntity,entityId:"c9bc312a-10d3-48a7-9ab4-ea483a9e2416"},uA={hidden:!1,required:!0,type:r.Property,id:"5cb617b0-92be-4dbe-a007-49093368d94f",version:1,name:"Name",description:"The name of the animal",implements:null,static:!1,private:!1,index:0,dataType:cA,abstract:!1,parent:dA},pA={type:r.GenericReference,id:"abc565de-4c83-4936-bc48-4013bef213b8",entityType:r.Project,entityId:Z},yA={type:r.CustomEntity,id:"83eaa847-e62b-4192-84fb-3d8d6f5ea970",version:1,name:"Animal",description:"A living creature that is not human",abstract:!1,static:!1,abstractMethods:[],properties:[oA,uA],methods:[],extends:[],implements:[Le],x:0,y:0,parent:pA},hA={id:"default-relational-database-entity-identifier-property-data-type-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-identifier-property-data-type-id",entityType:r.DataType},fA={id:"default-relational-database-entity-identifier-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-identifier-property-id",entityType:r.Property},mA={like:!1,id:"default-relational-database-entity-identifier-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"default-relational-database-entity-identifier-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"main",parent:hA,autogeneration:{type:qe.Unique,rangeStart:null,rangeEnd:null},valueAsType:null},parent:fA},Hr={id:"default-relational-database-entity-ref-id",type:r.GenericReference,entityId:V.PERSISTED_ENTITY,entityType:r.BuiltInBaseEntity},TA={hidden:!1,required:!0,id:"default-relational-database-entity-identifier-property-id",name:"Identifier name",version:1,type:r.Property,private:!1,abstract:!1,implements:ja,static:!0,index:0,dataType:mA,description:"The name of the main database inside of the server instance where the data will be stored.",parent:Hr};r.GenericReference,r.DataType;const EA={id:"default-relational-database-entity-username-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-username-property-id",entityType:r.Property},RA={id:"default-relational-database-entity-username-property-default-value-parent-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-username-property-data-type-id",entityType:r.DataType},bA={like:!1,id:"default-relational-database-entity-username-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"default-relational-database-entity-username-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"root",parent:RA,autogeneration:null,valueAsType:null},parent:EA},gA={hidden:!1,required:!0,id:"default-relational-database-entity-username-property-id",name:"Username",version:1,type:r.Property,private:!1,abstract:!1,implements:qa,static:!0,index:1,dataType:bA,description:"The username that will be used to connect to the database.",parent:Hr};r.GenericReference,r.DataType;const vA={id:"default-relational-database-entity-password-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-password-property-id",entityType:r.Property},IA={id:"default-relational-database-entity-password-property-default-value-parent-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-password-property-data-type-id",entityType:r.DataType},DA={like:!1,id:"default-relational-database-entity-password-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"default-relational-database-entity-password-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"password",parent:IA,autogeneration:null,valueAsType:null},parent:vA},PA={hidden:!1,required:!0,id:"default-relational-database-entity-password-property-id",name:"Password",version:1,type:r.Property,private:!1,abstract:!1,implements:Ja,static:!0,index:2,dataType:DA,description:"The password that will be used to connect to the database.",parent:Hr},AA={id:"default-relational-database-entity-min-size-property-data-type-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-min-size-property-data-type-id",entityType:r.DataType},SA={id:"default-relational-database-entity-min-size-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-min-size-property-id",entityType:r.Property},OA={like:!1,id:"default-relational-database-entity-min-size-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ce,asType:!1,defaultValue:{id:"default-relational-database-entity-min-size-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.Number,value:6,parent:AA,autogeneration:null,valueAsType:null},parent:SA},CA={hidden:!1,required:!0,id:"default-relational-database-entity-min-size-property-id",name:"Minimum GB size",version:1,type:r.Property,private:!1,abstract:!1,implements:Wa,static:!0,index:3,dataType:OA,description:"The minimum size of the database in GB.",parent:Hr},BA={id:"default-relational-database-entity-default-property-data-type-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-default-property-data-type-id",entityType:r.DataType},wA={id:"default-relational-database-entity-default-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-default-property-id",entityType:r.Property},_A={like:!1,id:"default-relational-database-entity-default-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ce,asType:!1,defaultValue:{id:"default-relational-database-entity-default-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.Boolean,value:!0,parent:BA,autogeneration:null,valueAsType:null},parent:wA},MA={hidden:!0,required:!0,id:"default-relational-database-entity-default-property-id",name:"Default",version:1,type:r.Property,private:!1,abstract:!1,implements:Ko,static:!0,index:4,dataType:_A,description:"Whether this database is automatically picked by other entities as the default database.",parent:Hr},NA={id:"default-relational-database-entity-autoscaling-property-data-type-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-autoscaling-property-data-type-id",entityType:r.DataType},VA={id:"default-relational-database-entity-autoscaling-property-ref-id",type:r.GenericReference,entityId:"default-relational-database-entity-autoscaling-property-id",entityType:r.Property},$A={like:!1,id:"default-relational-database-entity-autoscaling-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:Ce,asType:!1,defaultValue:{id:"default-relational-database-entity-autoscaling-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.Boolean,value:!0,parent:NA,autogeneration:null,valueAsType:null},parent:VA},LA={hidden:!1,required:!0,id:"default-relational-database-entity-autoscaling-property-id",name:"Auto-scaling",version:1,type:r.Property,private:!1,abstract:!1,implements:el,static:!0,index:5,dataType:$A,description:"If true, this database will automatically scale up or down in memory size, based on the usage.s",parent:Hr},GA={id:"default-relational-database-entity-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},Pl={id:"default-relational-database-entity-id",type:r.CustomEntity,version:1,name:"Relational Database",description:"A database that permanently stores the persisted entities attached to it.",abstract:!1,static:!0,properties:[MA,LA,TA,gA,PA,CA],methods:[],abstractMethods:[],extends:[],implements:[On],x:0,y:0,parent:GA},FA={id:"user-prototype-database-property-data-type-ref-id",type:r.GenericReference,entityId:"user-prototype-database-property-data-type-id",entityType:r.DataType},UA={id:"user-prototype-database-property-ref-id",type:r.GenericReference,entityId:"user-prototype-database-property-id",entityType:r.Property},xA={like:!1,id:"user-prototype-database-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:On,asType:!1,defaultValue:{id:"user-prototype-database-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,value:null,name:A.EntityTemplate,valueAsType:Pl,autogeneration:null,parent:FA},parent:UA},kA={id:"user-prototype-database-property-parent-ref-id",type:r.GenericReference,entityId:"de67fc84-3719-46fd-9ab4-3fca3a3cc50d",entityType:r.CustomEntity},jA={hidden:!1,required:!0,id:"user-prototype-database-property-id",name:"Database",version:1,type:r.Property,private:!1,abstract:!1,implements:Pi,static:!0,index:0,dataType:xA,description:"The database that the entity belongs to.",parent:kA},qA={type:r.GenericReference,id:"user-prototype-parent-ref-id",entityType:r.Project,entityId:Z},Al={type:r.CustomEntity,id:"de67fc84-3719-46fd-9ab4-3fca3a3cc50d",version:1,name:"User",description:"A user of the application",implements:[Le],abstract:!1,static:!1,abstractMethods:[],extends:[],properties:[jA],methods:[],x:0,y:0,parent:qA},JA={type:r.GenericReference,id:"person-date-of-birth-property-data-type-parent-ref-id",entityType:r.Property,entityId:"person-date-of-birth-property-id"},WA={like:!1,id:"person-date-of-birth-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:cn,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:JA},HA={type:r.GenericReference,id:"person-date-of-birth-property-parent-ref-id",entityType:r.CustomEntity,entityId:"c9bc312a-10d3-48a7-9ab4-ea483a9e2416"},YA={hidden:!1,required:!0,type:r.Property,id:"person-date-of-birth-property-id",version:1,name:"Date of birth",description:"The date of birth of the person",implements:null,private:!1,static:!1,index:0,dataType:WA,abstract:!1,parent:HA},zA={type:r.GenericReference,id:"a2867827-2f8e-4c25-b18b-d91857d7f24e",entityType:r.Property,entityId:"cacfec92-46c3-4fca-a1d9-fd1ba94d78c7"},ZA={like:!1,id:"1d49f41b-17b9-4f48-87aa-3ce43498e5a9",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:zA},XA={type:r.GenericReference,id:"01cbe760-40a9-4f49-8e3d-194d2f57cb1e",entityType:r.CustomEntity,entityId:"c9bc312a-10d3-48a7-9ab4-ea483a9e2416"},QA={hidden:!1,required:!0,type:r.Property,id:"cacfec92-46c3-4fca-a1d9-fd1ba94d78c7",version:1,name:"Name",description:"The name of the person",implements:null,private:!1,static:!1,index:0,dataType:ZA,abstract:!1,parent:XA},KA={type:r.GenericReference,id:"3542b22a-3a2f-41c6-876e-24c885572498",entityType:r.Project,entityId:Z},pt={type:r.CustomEntity,id:"c9bc312a-10d3-48a7-9ab4-ea483a9e2416",version:1,name:"Person",description:"A entity to store more information about a person than the user entity does, to split the responsibilities and keep it the logic clean.",properties:[QA,YA],abstract:!1,static:!1,abstractMethods:[],methods:[],implements:[],extends:[Al],x:0,y:0,parent:KA},eS={type:r.GenericReference,id:"b59c80b7-b2e9-41e9-abcd-7c5652835efc",entityType:r.FunctionDeclaration,entityId:"36f29f96-c001-4b9a-b49c-83eff406a060"},tS={type:r.GenericReference,id:"1190b5a2-f25e-46db-884d-8a3dd1a44d94",entityType:r.ReturnStatement,entityId:"3ebc4342-c9e8-42e7-a61c-7937081e1d2e"},nS={type:r.GenericReference,id:"36c63126-7814-496f-a6cc-48662c2aabae",entityType:r.ArgumentDeclaration,entityId:"500dee3a-3435-4453-9699-0d053f646523"},rS={type:r.GenericReference,id:"c567e55d-ec12-4e4e-958e-f07522892b4b",entityType:r.ReturnDeclaration,entityId:"9e070523-7e07-4100-8637-960a187f5f14"},iS={like:!1,id:"3973c5a1-f0d8-49a0-a9a9-a0009bf3f0d8",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:rS},Sl={isError:!1,id:"9e070523-7e07-4100-8637-960a187f5f14",type:r.ReturnDeclaration,version:1,name:"Output Account Owner",description:null,dataType:iS,readsValue:nS,required:!0,index:0,parent:tS},aS={type:r.GenericReference,id:"567d923c-20da-4c1e-956d-962ea30c6d0b",entityType:r.FunctionDeclaration,entityId:"36f29f96-c001-4b9a-b49c-83eff406a060"},sS={type:r.GenericReference,id:"da85e620-59f3-42ab-88c8-b38d33c2c833",entityType:r.FunctionDeclaration,entityId:"36f29f96-c001-4b9a-b49c-83eff406a060"},ET={type:r.ReturnStatement,id:"3ebc4342-c9e8-42e7-a61c-7937081e1d2e",version:1,outputs:[Sl],calledByError:[],calledByEntry:[aS],calledBySuccess:[],throws:null,x:0,y:0,parent:sS},oS={type:r.GenericReference,id:"1c806bb7-4c25-4bad-963b-93dfbb7c8304",entityType:r.ArgumentDeclaration,entityId:"500dee3a-3435-4453-9699-0d053f646523"},lS={like:!1,id:"d90fcc18-642b-433c-8fcb-4094b9031cd5",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:oS},RT={id:"500dee3a-3435-4453-9699-0d053f646523",type:r.ArgumentDeclaration,version:1,name:"New Account Owner",description:null,dataType:lS,required:!0,writesValues:[Sl],index:0,parent:eS},cS={type:r.GenericReference,id:"83dceb60-f3c4-4085-824c-85f2003bfd27",entityType:r.CustomEntity,entityId:"506946aa-30da-48e6-918f-ffd9eac58813"},bT={type:r.FunctionDeclaration,id:"36f29f96-c001-4b9a-b49c-83eff406a060",version:1,name:"Change owner of bank account",description:null,implements:null,inputs:[RT],calls:[ET],returnStatements:[ET],index:0,collapsed:!1,private:!1,x:0,y:0,parent:cS},dS={type:r.GenericReference,id:"adbaf302-ffa9-49b6-a3c6-83f9a75068e3",entityType:r.VariableDeclaration,entityId:"8e36a476-766e-4cc2-a8a7-27a07dfb5a4b"},uS={like:!1,id:"79ee04aa-1ba4-4ae9-a406-ed45e5b03f7f",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:dS},pS={type:r.GenericReference,id:"55e212d1-f0ec-4bb6-acbe-60f741367daf",entityType:r.OutputMap,entityId:"dc9ddb8f-02a0-4a43-aea6-270ec7b7f8a4"},yS={type:r.GenericReference,id:"944e1171-3d9b-4559-9386-1d4974b15962",entityType:r.FunctionDeclaration,entityId:"15ee556d-681f-47de-a31f-16d4ba73cc4e"},hS={id:"8e36a476-766e-4cc2-a8a7-27a07dfb5a4b",type:r.VariableDeclaration,version:1,name:"Output Account Owner",description:null,dataType:uS,readsValue:pS,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:yS},fS={type:r.GenericReference,id:"b89ebc83-52cf-4447-a5ae-62241f713079",entityType:r.FunctionCall,entityId:"78f6dba8-bed8-44cd-8b0f-6dcc787d1e1e"},mS={id:"dc9ddb8f-02a0-4a43-aea6-270ec7b7f8a4",type:r.OutputMap,version:1,declaration:Sl,writesValues:[hS],index:0,parent:fS},TS={type:r.GenericReference,id:"c1b9e125-1aad-48b7-9687-95c57a6bc10d",entityType:r.FunctionDeclaration,entityId:"15ee556d-681f-47de-a31f-16d4ba73cc4e"},ES={type:r.GenericReference,id:"d2deaa02-e164-4425-905c-6dee47eb4eac",entityType:r.FunctionDeclaration,entityId:"15ee556d-681f-47de-a31f-16d4ba73cc4e"},RS={type:r.GenericReference,id:"1109a655-ac62-4110-a933-42a72106f4f0",entityType:r.VariableDeclaration,entityId:"8bea6986-8da2-487b-905d-2fb962db6728"},bS={like:!1,id:"7d9a1307-512e-42ec-9797-2f7229796b97",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:RS},gS={type:r.GenericReference,id:"bb61ebf7-57b3-4d14-905d-82ec907205b5",entityType:r.ArgumentDeclaration,entityId:"38f6b236-98ac-47b0-ab9c-d2f9610137b9"},vS={type:r.GenericReference,id:"6b8c7bf2-9fc8-4ea4-9ec0-f41679d513b1",entityType:r.FunctionDeclaration,entityId:"15ee556d-681f-47de-a31f-16d4ba73cc4e"},IS={type:r.GenericReference,id:"6163d1a1-7a94-49b1-95bb-aecd8d6d335c",entityType:r.FunctionCall,entityId:"78f6dba8-bed8-44cd-8b0f-6dcc787d1e1e"},DS={type:r.GenericReference,id:"1f900f62-4bd2-4246-94aa-b8f5aad384fd",entityType:r.VariableDeclaration,entityId:"8bea6986-8da2-487b-905d-2fb962db6728"},gT={id:"be8538be-e6f9-4b94-9314-a546003ebaa0",type:r.InputMap,version:1,declaration:RT,name:null,description:null,readsValue:DS,defaultValue:null,index:0,parent:IS},PS={type:r.VariableDeclaration,id:"8bea6986-8da2-487b-905d-2fb962db6728",version:1,name:"Changed Account Owner",description:null,dataType:bS,readsValue:gS,writesValues:[gT],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:vS},AS={type:r.FunctionCall,id:"78f6dba8-bed8-44cd-8b0f-6dcc787d1e1e",version:1,declaration:bT,inputs:[gT],outputs:[mS],process:null,successCalls:[],errorCalls:[],calledByError:[],calledByEntry:[TS],calledBySuccess:[],parent:ES,error:null,x:0,y:0},SS={type:r.GenericReference,id:"2d47aba1-a918-46a7-8db7-78809928654a",entityType:r.ArgumentDeclaration,entityId:"38f6b236-98ac-47b0-ab9c-d2f9610137b9"},OS={like:!1,id:"5583766c-e9a5-484c-8f43-f4b0a6a1876c",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:SS},CS={type:r.GenericReference,id:"3e2a81e4-55b2-49f5-94eb-39135e95c3d7",entityType:r.FunctionDeclaration,entityId:"15ee556d-681f-47de-a31f-16d4ba73cc4e"},BS={id:"38f6b236-98ac-47b0-ab9c-d2f9610137b9",type:r.ArgumentDeclaration,version:1,description:null,name:"New Company Owner",dataType:OS,required:!0,index:0,writesValues:[PS],parent:CS},wS={type:r.GenericReference,id:"30291b01-1b94-4d03-b434-dec122c2bc7d",entityType:r.CustomEntity,entityId:"506946aa-30da-48e6-918f-ffd9eac58813"},_S={type:r.FunctionDeclaration,id:"15ee556d-681f-47de-a31f-16d4ba73cc4e",version:1,description:null,name:"Change Account Owner",inputs:[BS],collapsed:!0,returnStatements:[],calls:[AS],private:!1,index:0,implements:null,x:0,y:0,parent:wS},MS={type:r.GenericReference,id:"72c7ac0a-886e-4e10-b7ed-2f5a819a0233",entityType:r.Property,entityId:"b8f4656a-2b77-43ab-af51-7c32ddede044"},NS={like:!1,id:"c09dd282-73f6-4077-a467-b66db20b9fc6",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:MS},VS={type:r.GenericReference,id:"8a950024-512c-4580-81db-a705410aeb99",entityType:r.CustomEntity,entityId:"506946aa-30da-48e6-918f-ffd9eac58813"},$S={hidden:!1,required:!0,type:r.Property,id:"b8f4656a-2b77-43ab-af51-7c32ddede044",version:1,name:"Account number",description:null,private:!0,implements:null,static:!1,index:0,dataType:NS,abstract:!1,parent:VS},LS={type:r.GenericReference,id:"b6704b6c-c3bd-49d0-8ebc-82d03e726cbb",entityType:r.Property,entityId:"733d06a6-b8c5-44f3-a1f7-a8c9bd9e44ea"},GS={like:!1,id:"c03e0b0a-88ab-401a-8833-4806738bdc37",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:LS},FS={type:r.GenericReference,id:"1ef999a7-e9ed-406a-866e-e58277fc985b",entityType:r.CustomEntity,entityId:"506946aa-30da-48e6-918f-ffd9eac58813"},US={hidden:!1,required:!0,type:r.Property,id:"733d06a6-b8c5-44f3-a1f7-a8c9bd9e44ea",version:1,description:null,name:"Account Owner",index:1,dataType:GS,implements:null,static:!1,private:!0,abstract:!1,parent:FS},xS={type:r.GenericReference,id:"d41d7f41-98b8-4f67-be92-c349fdda5156",entityType:r.Project,entityId:Z},Yr={type:r.CustomEntity,id:"506946aa-30da-48e6-918f-ffd9eac58813",version:1,name:"Bank Account",description:null,abstract:!1,static:!1,abstractMethods:[],properties:[$S,US],methods:[bT,_S],extends:[],implements:[Le],x:0,y:0,parent:xS},Ji="bitcoin-api-response-id",vT="time-property-id",IT="disclamer-property-id",DT="chart-name-property-id",PT="bpi-property-id",bs="bpi-entity-id",AT="usd-property-id",ST="gbp-property-id",OT="eur-property-id",zr="currency-entity-id",CT="currency-code-property-id",BT="currency-symbol-property-id",wT="currency-rate-property-id",_T="currency-description-property-id",MT="currency-rate-number-property-id",kS={type:r.GenericReference,id:"code-property-data-type-parent-ref-id",entityType:r.Property,entityId:CT},jS={like:!1,id:"code-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Sn,isList:!1,asType:!1,isNullable:!1,defaultValue:null,options:["USD","GBP","EUR"],constant:!1,parent:kS},qS={type:r.GenericReference,id:"code-property-parent-ref-id",entityType:r.CustomEntity,entityId:zr},JS={hidden:!1,required:!0,type:r.Property,id:CT,version:1,name:"code",description:null,dataType:jS,index:0,implements:null,static:!1,private:!1,abstract:!1,parent:qS},WS={type:r.GenericReference,id:"symbol-property-data-type-parent-ref-id",entityType:r.Property,entityId:BT},HS={like:!1,id:"symbol-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Sn,isList:!1,asType:!1,isNullable:!1,defaultValue:null,options:["$","£","€"],constant:!1,parent:WS},YS={type:r.GenericReference,id:"symbol-property-parent-ref-id",entityType:r.CustomEntity,entityId:zr},zS={hidden:!1,required:!0,type:r.Property,id:BT,version:1,name:"symbol",description:null,index:0,dataType:HS,implements:null,static:!1,private:!1,abstract:!1,parent:YS},ZS={type:r.GenericReference,id:"rate-property-data-type-parent-ref-id",entityType:r.Property,entityId:wT},XS={like:!1,id:"rate-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:ZS},QS={type:r.GenericReference,id:"rate-property-parent-ref-id",entityType:r.CustomEntity,entityId:zr},KS={hidden:!1,required:!0,type:r.Property,id:wT,version:1,name:"rate",description:null,index:0,dataType:XS,implements:null,static:!1,private:!1,abstract:!1,parent:QS},eO={type:r.GenericReference,id:"description-property-data-type-parent-ref-id",entityType:r.Property,entityId:_T},tO={like:!1,id:"description-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:eO},nO={type:r.GenericReference,id:"description-property-parent-ref-id",entityType:r.CustomEntity,entityId:zr},rO={hidden:!1,required:!0,type:r.Property,id:_T,version:1,name:"description",description:null,dataType:tO,implements:null,static:!1,index:0,private:!1,abstract:!1,parent:nO},iO={type:r.GenericReference,id:"rate-number-property-data-type-parent-ref-id",entityType:r.Property,entityId:MT},aO={like:!1,id:"rate-number-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:iO},sO={type:r.GenericReference,id:"rate-number-property-parent-ref-id",entityType:r.CustomEntity,entityId:zr},oO={hidden:!1,required:!0,type:r.Property,id:MT,version:1,name:"rate_float",description:null,dataType:aO,implements:null,static:!1,index:0,private:!1,abstract:!1,parent:sO},lO={type:r.GenericReference,id:"currency-prototype-parent-ref-id",entityType:r.Project,entityId:Z},gs={type:r.CustomEntity,id:zr,version:1,name:"Currency",description:"This entity describes a currency in the Bitcoin Price Index.",properties:[JS,zS,KS,rO,oO],static:!1,abstract:!1,abstractMethods:[],methods:[],extends:[],implements:[],x:0,y:0,parent:lO},cO={type:r.GenericReference,id:"usd-property-data-type-parent-ref-id",entityType:r.Property,entityId:AT},dO={like:!1,id:"usd-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gs,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:cO},uO={type:r.GenericReference,id:"usd-property-parent-ref-id",entityType:r.CustomEntity,entityId:bs},pO={hidden:!1,required:!0,id:AT,type:r.Property,version:1,name:"USD",description:null,index:0,dataType:dO,implements:null,static:!1,private:!1,abstract:!1,parent:uO},yO={type:r.GenericReference,id:"gbp-property-data-type-parent-ref-id",entityType:r.Property,entityId:ST},hO={like:!1,id:"gbp-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gs,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:yO},fO={type:r.GenericReference,id:"gbp-property-parent-ref-id",entityType:r.CustomEntity,entityId:bs},mO={hidden:!1,required:!0,id:ST,type:r.Property,version:1,name:"GBP",description:null,index:0,dataType:hO,implements:null,static:!1,private:!1,abstract:!1,parent:fO},TO={type:r.GenericReference,id:"eur-property-data-type-parent-ref-id",entityType:r.Property,entityId:OT},EO={like:!1,id:"eur-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gs,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:TO},RO={type:r.GenericReference,id:"eur-property-parent-ref-id",entityType:r.CustomEntity,entityId:bs},bO={hidden:!1,required:!0,id:OT,type:r.Property,version:1,name:"EUR",description:null,implements:null,static:!1,index:0,dataType:EO,private:!1,abstract:!1,parent:RO},gO={type:r.GenericReference,id:"bpi-prototype-parent-ref-id",entityType:r.Project,entityId:Z},NT={type:r.CustomEntity,id:bs,version:1,name:"BPI",description:"The Bitcoin Price Index",properties:[pO,mO,bO],abstract:!1,static:!1,abstractMethods:[],methods:[],extends:[],implements:[],x:0,y:0,parent:gO},vO={type:r.GenericReference,id:"time-property-data-type-parent-ref-id",entityType:r.Property,entityId:vT},IO={like:!1,id:"time-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:_o,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:vO},DO={type:r.GenericReference,id:"time-property-parent-ref-id",entityType:r.CustomEntity,entityId:Ji},PO={hidden:!1,required:!0,type:r.Property,id:vT,version:1,name:"time",description:null,index:0,dataType:IO,implements:null,static:!1,private:!1,abstract:!1,parent:DO},AO={type:r.GenericReference,id:"disclamer-property-data-type-parent-ref-id",entityType:r.Property,entityId:IT},SO={like:!1,id:"disclamer-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:AO},OO={type:r.GenericReference,id:"disclamer-property-parent-ref-id",entityType:r.CustomEntity,entityId:Ji},CO={hidden:!1,required:!0,type:r.Property,id:IT,version:1,name:"disclamer",description:null,index:0,dataType:SO,implements:null,static:!1,private:!1,abstract:!1,parent:OO},BO={type:r.GenericReference,id:"chart-name-property-data-type-parent-ref-id",entityType:r.Property,entityId:DT},wO={like:!1,id:"chart-name-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:BO},_O={type:r.GenericReference,id:"chart-name-property-parent-ref-id",entityType:r.CustomEntity,entityId:Ji},MO={hidden:!1,required:!0,type:r.Property,id:DT,version:1,name:"chartName",description:null,index:0,dataType:wO,implements:null,static:!1,private:!1,abstract:!1,parent:_O},NO={type:r.GenericReference,id:"bpi-property-data-type-parent-ref-id",entityType:r.Property,entityId:PT},VO={like:!1,id:"bpi-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:NT,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:NO},$O={type:r.GenericReference,id:"bpi-property-parent-ref-id",entityType:r.CustomEntity,entityId:Ji},LO={hidden:!1,required:!0,type:r.Property,id:PT,version:1,name:"bpi",description:null,implements:null,index:0,dataType:VO,static:!1,private:!1,abstract:!1,parent:$O},GO={type:r.GenericReference,id:"bitcoin-api-response-parent-ref-id",entityType:r.Project,entityId:Z},VT={type:r.CustomEntity,id:Ji,version:1,name:"Bitcoin API Response type",description:"The type of the data structure response from the Bitcoin API call",properties:[PO,CO,MO,LO],abstract:!1,static:!1,abstractMethods:[],methods:[],extends:[],implements:[],x:0,y:0,parent:GO},FO={type:r.GenericReference,id:"eefa0147-f873-484b-b4f3-9e6493aab183",entityType:r.ArgumentDeclaration,entityId:"f2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a"},UO={like:!1,id:"b9f35112-dcb2-4b7c-8fb9-f196b3fa37f9",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:FO},xO={type:r.GenericReference,id:"128770d6-5e3a-4aff-bca0-ad1f32ebefa8",entityType:r.ReturnStatement,entityId:"e4e05975-c277-471a-b869-f0aed316045c"},kO={type:r.GenericReference,id:"0be84bf9-6421-42b9-980f-6a03f30cb809",entityType:r.ReturnDeclaration,entityId:"a1ec31f0-25ca-42ac-a4c4-c9ec2255f55b"},jO={like:!1,id:"43daa02a-237b-4b7c-a6e9-2b8c167f6e22",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:kO},qO={type:r.GenericReference,id:"ad380383-4a47-43da-968e-75a2d603b230",entityType:r.ArgumentDeclaration,entityId:"f2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a"},$T={isError:!1,id:"a1ec31f0-25ca-42ac-a4c4-c9ec2255f55b",type:r.ReturnDeclaration,version:1,name:"New Company Owner",description:"The new owner of the company",dataType:jO,readsValue:qO,required:!0,index:0,parent:xO},JO={type:r.GenericReference,id:"4f24dc27-59a1-49bf-abcc-7d72b00926e4",entityType:r.FunctionDeclaration,entityId:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4"},WO={id:"f2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a",type:r.ArgumentDeclaration,version:1,name:"New Company Owner",description:null,dataType:UO,writesValues:[$T],required:!0,index:0,parent:JO},HO={type:r.GenericReference,id:"5c9a02f0-d2cf-4efc-828e-467f33a74dd3",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},YO={type:r.GenericReference,id:"2ff8f3da-e0c5-4f0f-b688-2c051c588786",entityType:r.FunctionDeclaration,entityId:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4"},zO={type:r.GenericReference,id:"195ae28c-159b-42de-80b1-2ebb8be3619f",entityType:r.FunctionDeclaration,entityId:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4"},LT={type:r.ReturnStatement,id:"e4e05975-c277-471a-b869-f0aed316045c",version:1,outputs:[$T],calledByError:[],calledByEntry:[YO],calledBySuccess:[],throws:null,x:0,y:0,parent:zO},ZO={type:r.FunctionDeclaration,id:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4",version:1,name:"Change owner of company",description:"Change the owner of the company to a new person",inputs:[WO],calls:[LT],index:0,collapsed:!1,implements:null,returnStatements:[LT],private:!1,x:0,y:0,parent:HO},XO={type:r.GenericReference,id:"e691026f-6db0-43ec-93cd-805ae7d713e3",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},QO={type:r.GenericReference,id:"29c4e3e0-1b66-4075-b559-45b27c5cf356",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},KO={type:r.GenericReference,id:"b1289358-b185-455d-8f58-7791b15cd52a",entityType:r.ReturnStatement,entityId:"9690cd1d-ea35-4e83-823d-0c7310265fee"},eC={type:r.GenericReference,id:"d847bb49-8789-4550-bb2d-e2d551993b28",entityType:r.VariableDeclaration,entityId:"e5a8b6d0-0e6f-4e9a-9b1e-8a2b5c7f0d5a"},tC={type:r.GenericReference,id:"06535500-c37c-4915-8398-1d4e184fa5e7",entityType:r.ReturnDeclaration,entityId:"e7a35277-a0c4-46d5-aca2-bddd0c26e931"},nC={like:!1,id:"d358dd91-35f7-4095-b728-3fb3c71dbc05",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:An,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:tC},Ol={isError:!1,id:"e7a35277-a0c4-46d5-aca2-bddd0c26e931",type:r.ReturnDeclaration,version:1,name:"Is name registered",description:"Whether the company name is already registered",dataType:nC,readsValue:eC,required:!0,index:0,parent:KO},rC={type:r.GenericReference,id:"gov-company-registry-return-statement-called-by-success-ref-id",entityType:r.VariableDeclaration,entityId:"e5a8b6d0-0e6f-4e9a-9b1e-8a2b5c7f0d5a"},Cl={type:r.ReturnStatement,id:"9690cd1d-ea35-4e83-823d-0c7310265fee",version:1,outputs:[Ol],calledByError:[],calledByEntry:[],calledBySuccess:[XO,rC],throws:null,x:0,y:0,parent:QO},iC={type:r.GenericReference,id:"b3126414-4c9b-495f-901e-59f5073c8d67",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},aC={type:r.GenericReference,id:"35115c48-618b-411b-a290-d746d22fdd10",entityType:r.VariableDeclaration,entityId:"83e12ebb-c958-4dee-b750-8ab9930f0f4e"},GT={id:"a0e7b4e5-2f5f-4d4c-8f5c-1e1f1e1a1b1a",type:r.InputMap,version:1,declaration:Wo,name:null,description:null,readsValue:aC,defaultValue:null,parent:iC,index:2},sC={type:r.GenericReference,id:"14f46eae-04a5-47d1-9c7f-28fb09b84d1d",entityType:r.VariableDeclaration,entityId:"e5a8b6d0-0e6f-4e9a-9b1e-8a2b5c7f0d5a"},oC={like:!1,id:"990bd5d1-07ea-4253-acc1-d03bedd22a38",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:An,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:sC},lC={type:r.GenericReference,id:"e4c3542a-8fb0-4b72-8d6e-3fdff812dd67",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},cC={type:r.GenericReference,id:"825f9f60-22a8-4cc6-9055-d7333f8e92f4",entityType:r.OutputMap,entityId:"8f30d787-9459-4d8d-98a2-b46fbc2006d5"},dC={type:r.GenericReference,id:"is-company-name-registered-var-called-by-ref",entityType:r.Operation,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},FT={type:r.VariableDeclaration,id:"e5a8b6d0-0e6f-4e9a-9b1e-8a2b5c7f0d5a",version:1,name:"Is name registered",description:"Whether the company name is registered with the government company registry",dataType:oC,readsValue:cC,writesValues:[Ol],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[dC],successCalls:[Cl],errorCalls:[],internalCalls:[],x:0,y:0,parent:lC},uC={type:r.GenericReference,id:"1aba021e-48ef-44ac-93d0-eaecac5895da",entityType:r.InputMap,entityId:"c3c8d6c1-3e0d-4e6c-9f9c-6b8c7d7f8e9a"},pC={type:r.GenericReference,id:"dffae7e0-0a5c-4c14-8ed2-8d680b4c4c86",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},yC={type:r.InputMap,id:"c3c8d6c1-3e0d-4e6c-9f9c-6b8c7d7f8e9a",version:1,declaration:$a,name:null,description:null,readsValue:null,defaultValue:{id:"gov-http-request-url-argument-default-value-id",type:r.PrimitiveValue,version:1,value:"https://api.publicapis.org/entries",name:A.String,valueAsType:null,parent:uC,autogeneration:null},index:1,parent:pC},hC={type:r.GenericReference,id:"64ae61f5-ace7-401b-926d-25f852daa60e",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},fC={id:"8f30d787-9459-4d8d-98a2-b46fbc2006d5",type:r.OutputMap,version:1,declaration:vi,index:2,writesValues:[FT],parent:hC},mC={type:r.GenericReference,id:"62a1a086-caea-4270-9c9f-a1695503e745",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},TC={id:"48cf7654-8f3e-4fcd-abc6-740876c310a0",type:r.InputMap,version:1,declaration:Va,name:null,description:null,readsValue:null,index:0,defaultValue:null,parent:mC},EC={type:r.GenericReference,id:"b0c9c79f-f525-428d-99e7-087d3237ad62",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},RC={id:"2c1dc406-4b71-4023-87b2-abede3a111d2",type:r.InputMap,version:1,name:null,description:null,declaration:La,index:3,readsValue:null,defaultValue:null,parent:EC},bC={type:r.GenericReference,id:"9887d6c9-d75b-4c97-b722-e2e60945ea20",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},gC={id:"3fef94b2-0278-43ae-b0c5-bc7083f0a111",type:r.InputMap,version:1,declaration:Ga,name:null,description:null,readsValue:null,index:4,defaultValue:null,parent:bC},vC={type:r.GenericReference,id:"561275b6-5056-45d8-bf7d-8abaa4645593",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},IC={id:"3efe20a7-4d63-411e-89ef-63e277f48d66",type:r.OutputMap,version:1,declaration:Fa,index:1,writesValues:[],parent:vC},DC={type:r.GenericReference,id:"3170ccc2-13de-4bfc-802a-a643be41cd42",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},PC={id:"40d34323-d7e6-440a-8016-67c05a3b66dd",type:r.OutputMap,version:1,declaration:vi,index:0,writesValues:[],parent:DC},AC={type:r.GenericReference,id:"7432fa82-f574-4c54-a8fa-4cc4376da3d5",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},SC={type:r.GenericReference,id:"8f518502-9eea-462c-8753-8bc3bf3e29a9",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},OC={type:r.GenericReference,id:"123b8f18-79d9-4166-a5f6-78ec4b461680",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},CC={type:r.GenericReference,id:"e691026f-6db0-43ec-93cd-805ae7d713e3",entityType:r.FunctionCall,entityId:"abb5d456-ee85-4800-bdd9-d409415f60d7"},BC={type:r.GenericReference,id:"a375eedf-4811-41aa-a998-4897c69c46b9",entityType:r.ReturnDeclaration,entityId:"024a9b77-c1cd-4b67-b3ba-1935046b590d"},wC={like:!1,id:"767cc5ed-20ec-4fd1-89b1-c8d19daa87d1",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:et,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:BC},_C={type:r.GenericReference,id:"e64b0c23-129d-4d74-8ab4-eec60e1e5b9b",entityType:r.ReturnStatement,entityId:"ea444a9e-6a5b-4138-b81f-0d5618c3c6f3"},UT={isError:!0,id:"024a9b77-c1cd-4b67-b3ba-1935046b590d",type:r.ReturnDeclaration,version:1,name:"Error",description:"The error that occurred during the HTTP request to the government company registry",dataType:wC,required:!0,readsValue:null,index:0,parent:_C},MC={type:r.ReturnStatement,id:"ea444a9e-6a5b-4138-b81f-0d5618c3c6f3",version:1,outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[CC],throws:UT,x:0,y:0,parent:OC},NC={type:r.GenericReference,id:"323814fb-9723-49ef-bbba-f882384f18e4",entityType:r.FunctionCall,entityId:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7"},VC={id:"2f63f7ba-0ff0-458a-92bc-65d1dd4df8c3",type:r.OutputMap,declaration:Yo,version:1,writesValues:[UT],index:0,parent:NC},$C={type:r.Operation,id:"4eb96d0b-025b-4ed1-ae34-0cebbb07f1e7",version:1,declaration:Ii,inputs:[TC,yC,GT,RC,gC],outputs:[PC,IC,fC],process:null,calledByError:[],calledByEntry:[AC],calledBySuccess:[],successCalls:[Cl,FT],errorCalls:[MC],error:VC,x:0,y:0,parent:SC},LC={type:r.GenericReference,id:"597b8aa2-f6f2-4f7d-bbb9-b703d02de96a",entityType:r.InputMap,entityId:"b0e7b4e5-2f5f-4d4c-8f5c-1e1f1e1a1b1a"},GC={type:r.GenericReference,id:"546d99b3-28c4-4186-93a0-ac53c1565e07",entityType:r.Operation,entityId:"8f2094c0-e27e-465e-9280-112da0de9019"},FC={id:"b0e7b4e5-2f5f-4d4c-8f5c-1e1f1e1a1b1a",type:r.InputMap,version:1,declaration:_a,name:null,description:null,readsValue:null,defaultValue:{id:"base-query-string-map-default-value-id",type:r.PrimitiveValue,version:1,value:"?name=",name:A.String,parent:LC,valueAsType:null,autogeneration:null},index:0,parent:GC},UC={type:r.GenericReference,id:"6a56fb22-82e1-47c9-bf85-41c4e5986c74",entityType:r.Operation,entityId:"8f2094c0-e27e-465e-9280-112da0de9019"},xC={type:r.GenericReference,id:"191c6a6d-9bcb-441e-bf98-de0da96f5f3a",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},kC={type:r.GenericReference,id:"d8fcbb76-dae2-40cf-847a-02364721b387",entityType:r.VariableDeclaration,entityId:"83e12ebb-c958-4dee-b750-8ab9930f0f4e"},jC={like:!1,id:"6a70c42b-024a-47c6-8a9d-af52be9c9b9a",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:kC},qC={type:r.GenericReference,id:"2282e2c0-ed9e-4c7b-86fc-1a364fa0fdb8",entityType:r.OutputMap,entityId:"f6c22cf8-63e4-4b2d-b649-b5ab884cf9a5"},JC={type:r.GenericReference,id:"assembled-query-string-called-by-ref",entityType:r.Operation,entityId:"8f2094c0-e27e-465e-9280-112da0de9019"},xT={type:r.VariableDeclaration,id:"83e12ebb-c958-4dee-b750-8ab9930f0f4e",version:1,name:"Query string",description:"The final, assembled query string that will be used in the HTTP request to the government company registry",dataType:jC,readsValue:qC,writesValues:[GT],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[JC],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:xC},WC={id:"f6c22cf8-63e4-4b2d-b649-b5ab884cf9a5",type:r.OutputMap,version:1,writesValues:[xT],declaration:bi,index:0,parent:UC},HC={type:r.GenericReference,id:"a1b48e7c-0301-4747-b4dd-b5af79956f7f",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},YC={type:r.GenericReference,id:"487c9235-be95-4c96-b9b5-2714b374a277",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},zC={type:r.GenericReference,id:"f6471f4f-b269-46fa-80ec-885e87a449c2",entityId:"a4106e8e-ec4f-4633-a636-09ae73135f69",entityType:r.ArgumentDeclaration},ZC={type:r.GenericReference,id:"62b4afb0-6c21-4b0f-abd3-cebef7b17c28",entityType:r.Operation,entityId:"8f2094c0-e27e-465e-9280-112da0de9019"},kT={id:"08f36e2b-bad2-425c-8129-93560bec8488",version:1,type:r.InputMap,declaration:Ma,name:null,description:null,readsValue:zC,defaultValue:null,index:1,parent:ZC},XC={type:r.Operation,id:"8f2094c0-e27e-465e-9280-112da0de9019",declaration:gi,version:1,inputs:[FC,kT],outputs:[WC],process:null,calledByError:[],calledByEntry:[HC],calledBySuccess:[],successCalls:[xT],errorCalls:[],error:null,x:0,y:0,parent:YC},QC={type:r.GenericReference,id:"c2e0e9b4-aa46-4974-bf8a-886b737b12fb",entityType:r.ArgumentDeclaration,entityId:"a4106e8e-ec4f-4633-a636-09ae73135f69"},KC={like:!1,id:"a4279518-3bf3-44b7-a2ac-65142ca37f1c",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:QC},eB={type:r.GenericReference,id:"dc273f24-164b-4943-82f9-589b237141e2",entityType:r.FunctionDeclaration,entityId:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d"},jT={id:"a4106e8e-ec4f-4633-a636-09ae73135f69",type:r.ArgumentDeclaration,version:1,name:"Company Name to check",description:"The name of the company to check in the government registry",dataType:KC,required:!1,writesValues:[kT],index:0,parent:eB},tB={type:r.GenericReference,id:"2178a10c-1cc0-4dad-97c3-0941be6c9738",entityType:r.Project,entityId:Z},qT={type:r.FunctionDeclaration,id:"e0f6e8a7-6e4b-4d0e-8a1a-6b4c1b0b7e9d",version:1,name:"Check Gov Company Registry availability",description:"Check whether the company name is already registered in the government company registry, or it is available for a new company to use.",inputs:[jT],calls:[XC,$C],returnStatements:[Cl],implements:null,index:null,collapsed:!1,private:!1,x:0,y:0,parent:tB},nB={type:r.GenericReference,id:"4d66c53c-f0f7-496a-9955-1e6c8533c5e0",entityType:r.Condition,entityId:"a8f4b0f2-5e5e-4e8f-9d7b-1b5b9b6e9a4b"},rB={type:r.GenericReference,id:"6fa0c8e0-d104-4b4d-a035-d4f6e0c49f09",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},iB={type:r.GenericReference,id:"146408d5-5336-4877-941a-777dd5871926",entityType:r.ArgumentDeclaration,entityId:"c6cf620c-1eee-4919-8578-1a0b6c088551"},aB={type:r.GenericReference,id:"34ae8f8c-548d-4654-984a-6f36affdaf49",entityType:r.FunctionCall,entityId:"d2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a"},JT={id:"69b1215d-9ebf-4274-b9cb-d4a5888f5122",version:1,type:r.InputMap,declaration:jT,name:null,description:null,readsValue:iB,defaultValue:null,index:0,parent:aB},sB={type:r.GenericReference,id:"07540a94-dda1-40b3-8452-f209bdc87b88",entityType:r.FunctionCall,entityId:"d2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a"},oB={type:r.GenericReference,id:"eaddf12a-a995-429e-90a0-13bf06efeb28",entityType:r.VariableDeclaration,entityId:"faaf3bf6-917d-40d7-aee6-5164f6646c4b"},lB={like:!1,id:"7fdaf943-3ffb-48e0-b766-b86cc24090cf",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:An,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:oB},cB={type:r.GenericReference,id:"030fb5c5-af4d-4c85-8cf0-e99edd50d2bd",entityType:r.OutputMap,entityId:"c1ec31f0-25ca-42ac-a4c4-c9ec2255f55b"},dB={type:r.GenericReference,id:"a8b618e9-c68c-48c1-8bd6-ef47c87d699e",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},uB={type:r.GenericReference,id:"is-company-name-valid-var-called-by-ref",entityType:r.FunctionCall,entityId:"d2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a"},WT={type:r.VariableDeclaration,id:"faaf3bf6-917d-40d7-aee6-5164f6646c4b",version:1,name:"Is name valid",description:"Whether the company name is valid",dataType:lB,readsValue:cB,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[uB],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:dB},pB={id:"c1ec31f0-25ca-42ac-a4c4-c9ec2255f55b",type:r.OutputMap,version:1,declaration:Ol,writesValues:[WT],index:0,parent:sB},yB={type:r.FunctionCall,id:"d2c2c3b0-5f3c-4d0d-9e4c-2d5a2c1f1e2a",version:1,declaration:qT,inputs:[JT],outputs:[pB],calledByError:[],calledByEntry:[],process:null,calledBySuccess:[nB],successCalls:[WT],errorCalls:[],error:null,x:0,y:0,parent:rB},hB={type:r.GenericReference,id:"9d0b87b4-bfed-4e02-9e84-6831c21feae2",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},fB={type:r.GenericReference,id:"74345f4f-e80d-48be-adff-d12fcea25bec",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},mB={type:r.GenericReference,id:"b39279ea-969a-4efb-a9ec-353bfd13db65",entityType:r.ArgumentDeclaration,entityId:"c6cf620c-1eee-4919-8578-1a0b6c088551"},TB={type:r.GenericReference,id:"549db613-f225-4c5b-9634-7d096717f0ff",entityType:r.Condition,entityId:"a8f4b0f2-5e5e-4e8f-9d7b-1b5b9b6e9a4b"},HT={id:"358e242c-7448-442e-ab8b-fd7fa119ea71",version:1,type:r.InputMap,declaration:er.fixedArguments[0],name:null,description:null,readsValue:mB,defaultValue:null,index:0,parent:TB},EB={type:r.Condition,id:"a8f4b0f2-5e5e-4e8f-9d7b-1b5b9b6e9a4b",version:1,declaration:er,inputs:[HT],calledByError:[],calledByEntry:[hB],calledBySuccess:[],successCalls:[yB],errorCalls:[],x:0,y:0,parent:fB},RB={type:r.GenericReference,id:"43ba1e25-f805-488f-8ae8-c58bb6215b2f",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},bB={type:r.GenericReference,id:"eb091bed-507f-4a1e-93b5-7cd2fccfe002",entityType:r.VariableDeclaration,entityId:"9c928995-0dd5-4f97-9962-56b343bc8a45"},gB={like:!1,id:"d64152ea-831f-4426-9506-a39bfa170513",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Yr,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:bB},vB={type:r.GenericReference,id:"7e79c29f-f7bd-441a-a77e-c627604dae94",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},IB={type:r.GenericReference,id:"8995ce5f-d5cf-4341-a8b1-5c046cc78b89",entityType:r.ArgumentDeclaration,entityId:"7ed0f7bb-2df0-44e2-b0b3-0709dcca8071"},DB={type:r.GenericReference,id:"new-company-bank-account-var-decl-1-called-by-ref",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},YT={type:r.VariableDeclaration,id:"9c928995-0dd5-4f97-9962-56b343bc8a45",version:1,name:"New bank account",description:"The new entity value representing the new bank account of the company",dataType:gB,readsValue:IB,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[DB],calledBySuccess:[],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:vB},PB={type:r.GenericReference,id:"9a4887bf-d50d-43e4-bdd5-a5262f65f04b",entityType:r.ArgumentDeclaration,entityId:"7ed0f7bb-2df0-44e2-b0b3-0709dcca8071"},AB={like:!1,id:"ae148c06-3143-49e9-9614-c3aca3f6fa7b",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Yr,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:PB},SB={id:"7ed0f7bb-2df0-44e2-b0b3-0709dcca8071",type:r.ArgumentDeclaration,version:1,name:"New bank account",description:"The new bank account of the company",dataType:AB,required:!0,index:1,writesValues:[YT],parent:RB},OB={type:r.GenericReference,id:"caec9cf8-3133-48d4-a390-114fa71b2933",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},CB={type:r.GenericReference,id:"cebcbad8-ca87-4c4b-be8a-312293d49892",entityType:r.FunctionDeclaration,entityId:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84"},BB={type:r.GenericReference,id:"7b8ccfe5-f9cd-4776-a19b-80c689bbe3df",entityType:r.ArgumentDeclaration,entityId:"c6cf620c-1eee-4919-8578-1a0b6c088551"},wB={like:!1,id:"2a6b4703-ac8d-4d25-8abd-48a115577fec",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:BB},_B={id:"c6cf620c-1eee-4919-8578-1a0b6c088551",type:r.ArgumentDeclaration,version:1,name:"New company name",description:null,dataType:wB,required:!0,index:0,writesValues:[HT,JT],parent:CB},MB={type:r.FunctionDeclaration,id:"183fd975-a5d3-4dff-8d6a-c62f5a4d5a84",version:1,name:"Company changed event",description:"The event that is triggered when a company is changed",returnStatements:[],collapsed:!1,inputs:[_B,SB],calls:[EB,YT],index:1,private:!1,implements:null,x:0,y:0,parent:OB},NB={type:r.GenericReference,id:"employee-manager-property-data-type-entity-ref-id",entityType:r.CustomEntity,entityId:"employee-entity-id"},VB={type:r.GenericReference,id:"employee-manager-property-data-type-parent-ref-id",entityType:r.Property,entityId:"employee-manager-property-id"},$B={like:!1,id:"employee-manager-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:NB,isList:!1,isNullable:!0,asType:!1,defaultValue:null,constant:!1,parent:VB},LB={type:r.GenericReference,id:"employee-manager-property-parent-ref-id",entityType:r.CustomEntity,entityId:"employee-entity-id"},GB={hidden:!1,required:!0,type:r.Property,id:"employee-manager-property-id",version:1,name:"Manager",description:"The manager of the employee",index:0,implements:null,private:!1,static:!1,dataType:$B,abstract:!1,parent:LB},FB={type:r.GenericReference,id:"employee-start-date-property-data-type-parent-ref-id",entityType:r.Property,entityId:"employee-start-date-property-id"},UB={like:!1,id:"employee-start-date-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:cn,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:FB},xB={type:r.GenericReference,id:"employee-start-date-property-parent-ref-id",entityType:r.CustomEntity,entityId:"employee-entity-id"},kB={hidden:!1,required:!0,type:r.Property,id:"employee-start-date-property-id",version:1,name:"Start date",description:"The date the employee started working in the company",index:0,private:!1,static:!1,implements:null,dataType:UB,abstract:!1,parent:xB},jB={type:r.GenericReference,id:"employee-department-property-ref-id",entityType:r.Property,entityId:"employee-department-property-id"},qB={like:!1,id:"employee-department-property-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Sn,isList:!1,isNullable:!1,asType:!1,options:["Human Resources","Finance","IT","Sales","Marketing","Customer Service","Logistics","Product"],defaultValue:null,constant:!1,parent:jB},JB={type:r.GenericReference,id:"employee-department-property-parent-ref-id",entityType:r.CustomEntity,entityId:"employee-entity-id"},WB={hidden:!1,required:!0,type:r.Property,id:"employee-department-property-id",version:1,name:"Department",description:"The department the employee works in, from a list of departments in the company",index:0,implements:null,static:!1,private:!1,dataType:qB,abstract:!1,parent:JB},HB={type:r.GenericReference,id:"employee-prototype-parent-ref-id",entityType:r.Project,entityId:Z},Ct={type:r.CustomEntity,id:"employee-entity-id",version:1,name:"Employee",description:"A entity that represents an employee in the company",properties:[WB,kB,GB],abstract:!1,static:!1,abstractMethods:[],methods:[],implements:[],extends:[pt],x:0,y:0,parent:HB},YB={type:r.GenericReference,id:"dec8fbfe-9124-41fd-9f1c-5b2f07cfd6ba",entityType:r.Property,entityId:"4f52d044-f3dd-4bdf-927e-637c3b92e8bd"},zB={like:!1,id:"bc0b8979-6c43-4d47-a712-6742b89e3c00",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:YB},ZB={type:r.GenericReference,id:"4f8c0a05-466e-4672-b4c4-6bd408c0be9a",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},XB={hidden:!1,required:!0,type:r.Property,id:"4f52d044-f3dd-4bdf-927e-637c3b92e8bd",version:1,name:"Company Name",private:!1,static:!1,description:"The name of the company",index:0,implements:null,dataType:zB,abstract:!1,parent:ZB},QB={type:r.GenericReference,id:"95173fe0-a6e6-443c-94f3-f7c5cf171fcf",entityType:r.Property,entityId:"80c86e1b-caca-4ba5-9b1f-38f72d10e4a3"},KB={like:!1,id:"ddbb6f5c-0cf4-41fb-83b3-b6c47c0e338d",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Yr,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:QB},ew={type:r.GenericReference,id:"6a9a0b72-a05d-4169-b3f3-5afb01e8d0df",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},Bl={hidden:!1,required:!0,type:r.Property,id:"80c86e1b-caca-4ba5-9b1f-38f72d10e4a3",version:1,name:"Bank account",description:"The bank account of the company",index:1,implements:null,static:!1,private:!1,dataType:KB,abstract:!1,parent:ew},tw={type:r.GenericReference,id:"62892cc6-d227-4088-90d3-ae7c15ed4af4",entityType:r.Property,entityId:"19a31727-1fba-40a5-be25-18e0f149d5cb"},nw={like:!1,id:"1f7629df-dc29-4c89-8369-c6d043e97a9e",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:pt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:tw},rw={type:r.GenericReference,id:"89384206-fd5a-4f0a-849c-f777473e5773",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},iw={hidden:!1,required:!0,type:r.Property,id:"19a31727-1fba-40a5-be25-18e0f149d5cb",version:1,name:"Company Owner",description:"The person that owns the company",index:2,static:!1,implements:null,dataType:nw,private:!0,abstract:!1,parent:rw},aw={type:r.GenericReference,id:"4d2ffb6c-5f38-436e-8339-fb9878ac2b5e",entityType:r.Property,entityId:"f8310850-a87e-405c-b182-4f1d5fa49240"},sw={like:!1,id:"ad44250b-40c2-48f7-a480-381fa938f562",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ct,isList:!0,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:aw},ow={type:r.GenericReference,id:"aa5d4eee-6fac-4e72-bf21-9c8750024541",entityType:r.CustomEntity,entityId:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},lw={hidden:!1,required:!0,type:r.Property,id:"f8310850-a87e-405c-b182-4f1d5fa49240",version:1,name:"Employees",description:null,index:3,dataType:sw,implements:null,private:!0,static:!1,abstract:!1,parent:ow},cw={type:r.GenericReference,id:"e3c03b6b-2ea0-4d99-865d-5e6a348672d0",entityType:r.Project,entityId:Z},gt={type:r.CustomEntity,id:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d",version:1,name:"Company",description:null,properties:[XB,Bl,iw,lw],static:!1,abstract:!1,abstractMethods:[],methods:[ZO,MB],extends:[],implements:[Le],x:0,y:0,parent:cw},dw={type:r.GenericReference,id:"ffcad334-138d-4b67-8fb3-5f0e6f5fefbd",entityType:r.Project,entityId:Z},wl={type:r.FunctionDeclaration,id:"0f89260c-8c58-4639-8629-d9ea5ab40ba7",version:1,name:"Show popup",description:null,inputs:[],calls:[],returnStatements:[],implements:null,collapsed:!1,private:!1,index:null,x:0,y:0,parent:dw};r.GenericReference,r.DataType;const uw={id:"cron-job-entity-expression-property-ref-id",type:r.GenericReference,entityId:"cron-job-entity-expression-property-id",entityType:r.Property},pw={like:!1,id:"cron-job-entity-expression-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:null,parent:uw},yw={id:"cron-job-entity-ref-id",type:r.GenericReference,entityId:"cron-job-entity-id",entityType:r.CustomEntity},hw={hidden:!1,required:!0,id:"cron-job-entity-expression-property-id",type:r.Property,version:1,name:"Cron expression",description:"The cron expression that defines when the cron job should be triggered",dataType:pw,implements:null,static:!0,private:!1,abstract:!1,index:0,parent:yw},fw={id:"cron-job-entity-trigger-show-popup-func-call-called-by-ref-one-id",type:r.GenericReference,entityId:"show-popup-func-decl-id",entityType:r.FunctionDeclaration},mw={id:"cron-job-entity-trigger-show-popup-func-call-parent-ref-id",type:r.GenericReference,entityId:"cron-job-entity-trigger-func-decl-id",entityType:r.FunctionDeclaration},Tw={id:"cron-job-entity-trigger-show-popup-func-call-id",version:1,type:r.FunctionCall,declaration:wl,inputs:[],outputs:[],process:null,successCalls:[],calledByError:[],calledByEntry:[fw],calledBySuccess:[],errorCalls:[],error:null,x:0,y:0,parent:mw},Ew={id:"cron-job-entity-trigger-func-decl-parent-ref-id",type:r.GenericReference,entityId:"cron-job-entity-id",entityType:r.CustomEntity},Rw={id:"cron-job-entity-trigger-func-decl-id",version:1,type:r.FunctionDeclaration,name:"Scheduled trigger",description:"The function that is called when the cron job is triggered",inputs:[],private:!1,implements:nl,calls:[Tw],collapsed:!1,returnStatements:[],index:0,x:0,y:0,parent:Ew},bw={id:"cron-job-entity-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},gw={id:"cron-job-entity-id",version:1,type:r.CustomEntity,name:"Run at 12pm on Christmas day",description:"A cron job that runs at 12pm on Christmas day",properties:[hw],static:!0,abstract:!1,abstractMethods:[],extends:[rl],implements:[],methods:[Rw],x:0,y:0,parent:bw},vw={type:r.GenericReference,id:"52dbd85c-48b1-462a-8205-2437d6fb1cb4",entityType:r.Project,entityId:Z},Iw={type:r.CustomEntity,id:"6f0908c2-09c6-4a8b-8f43-d2467fe6fb39",version:1,name:"Get bank all bank accounts",description:null,properties:[],static:!0,abstract:!1,abstractMethods:[],methods:[],extends:[],implements:[ka],x:0,y:0,parent:vw},zT="f558fbf8-67de-4545-9804-6ae621e0b2d4",Dw={id:"getCompanyByIdEndpointPathParamsVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointPathParamsVariableDataType"},Pw={id:"getCompanyByIdEndpointPathParamsArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"getCompanyByIdEndpointPathParamsArgumentDeclaration"},Aw={like:!1,id:"getCompanyByIdEndpointPathParamsVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:k,asType:!1,defaultValue:{id:"getCompanyByIdEndpointPathParamsVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:Dw,autogeneration:null,valueAsType:null},parent:Pw},Sw={id:"getCompanyByIdEndpointReachedEntityEventRef",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"getCompanyByIdEndpointReachedEntityEvent"},Ow={id:"getCompanyByIdEndpointRequestHeadersVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointRequestHeadersVariableDataType"},Cw={id:"getCompanyByIdEndpointRequestHeadersArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"getCompanyByIdEndpointRequestHeadersArgumentDeclaration"},Bw={like:!1,id:"getCompanyByIdEndpointRequestHeadersVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:et,asType:!1,defaultValue:{id:"getCompanyByIdEndpointRequestHeadersVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:Ow,autogeneration:null,valueAsType:null},parent:Cw},ww={id:"getCompanyByIdEndpointRequestHeadersArgumentDeclaration",version:1,description:"A set of any properties, with names and value that transmit metadata about the request.",type:r.ArgumentDeclaration,writesValues:[],name:"Request headers",dataType:Bw,required:!0,index:0,parent:Sw},_w={id:"getCompanyByIdEndpointReachedEntityEventRefTwo",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"getCompanyByIdEndpointReachedEntityEvent"},Mw={id:"getCompanyByIdEndpointPathParamsArgumentDeclaration",type:r.ArgumentDeclaration,description:"A standarized text, without spaces that is added at the end of the domain and routes the request to a specific resource within the target server. For example: /api/users/123, /api/users/123/:name, /api/users/123/:name/:age.",version:1,name:"Path parameters",writesValues:[],dataType:Aw,required:!0,index:1,parent:_w},Nw={id:"getCompanyByIdEndpointReachedEntityEventRefThree",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"getCompanyByIdEndpointReachedEntityEvent"},Vw={id:"getCompanyByIdEndpointRequestQueryParamsVariableDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointRequestQueryParamsVariableDataType"},$w={id:"getCompanyByIdEndpointRequestQueryParamsArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"getCompanyByIdEndpointRequestQueryParamsArgumentDeclaration"},Lw={like:!1,id:"getCompanyByIdEndpointRequestQueryParamsVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,asType:!1,entity:k,defaultValue:{id:"getCompanyByIdEndpointRequestQueryParamsVariableDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:Vw,autogeneration:null,valueAsType:null},parent:$w},Gw={id:"getCompanyByIdEndpointRequestQueryParamsArgumentDeclaration",version:1,description:"A text with standarized format, without spaces that is added at the end of the URL path, after the ? character. It contains data that might be used to process the request. For example: /api/users?name=John&age=30",type:r.ArgumentDeclaration,writesValues:[],name:"Request query params",dataType:Lw,required:!0,index:2,parent:Nw},Fw={id:"getCompanyByIdEndpointReachedEntityEventRefFour",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"getCompanyByIdEndpointReachedEntityEvent"},Uw={id:"getCompanyByIdEndpointRequestBodyArgumentDeclarationRef",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:"getCompanyByIdEndpointRequestBodyArgumentDeclaration"},xw={like:!1,id:"getCompanyByIdEndpointRequestBodyVariableDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,asType:!1,constant:!1,entity:et,defaultValue:null,parent:Uw},kw={id:"getCompanyByIdEndpointRequestBodyArgumentDeclaration",version:1,description:"The main data payload of the request.",type:r.ArgumentDeclaration,writesValues:[],name:"Request body",dataType:xw,index:3,required:!0,parent:Fw},jw={id:"getCompanyByIdEndpointResponseCodeReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"getCompanyByIdEndpointResponseCodeReturnDeclaration"},qw={like:!1,id:"9ba575b0-6f8e-436d-a3de-3b843622aa17",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:jw},Jw={id:"getCompanyByIdEndpointReturnStatementRef",type:r.GenericReference,entityType:r.ReturnStatement,entityId:"getCompanyByIdEndpointReturnStatement"},Ww={isError:!1,id:"getCompanyByIdEndpointResponseCodeReturnDeclaration",version:1,description:"A standarized number that represents the status of the response. 200 for OK, 404 for not found, 500 for server error, etc.",type:r.ReturnDeclaration,name:"Response code",dataType:qw,readsValue:null,required:!0,index:0,parent:Jw},Hw={id:"getCompanyByIdEndpointResponseHeadersDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointResponseHeadersDataType"},Yw={id:"getCompanyByIdEndpointResponseHeadersReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"getCompanyByIdEndpointResponseHeadersReturnDeclaration"},zw={like:!1,id:"getCompanyByIdEndpointResponseHeadersDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!0,isNullable:!1,constant:!1,entity:et,asType:!1,defaultValue:{id:"getCompanyByIdEndpointResponseHeadersDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.JSON,value:{},parent:Hw,autogeneration:null,valueAsType:null},parent:Yw},Zw={id:"getCompanyByIdEndpointReturnStatementRefTwo",type:r.GenericReference,entityType:r.ReturnStatement,entityId:"getCompanyByIdEndpointReturnStatement"},Xw={isError:!1,id:"getCompanyByIdEndpointResponseHeadersReturnDeclaration",version:1,description:"A set of any properties, with names and value that transmit metadata about the response.",type:r.ReturnDeclaration,name:"Response headers",dataType:zw,readsValue:null,required:!0,index:1,parent:Zw},Qw={id:"getCompanyByIdEndpointResponseBodyReturnDeclarationRef",type:r.GenericReference,entityType:r.ReturnDeclaration,entityId:"getCompanyByIdEndpointResponseBodyReturnDeclaration"},Kw={like:!1,id:"getCompanyByIdEndpointResponseBodyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,asType:!1,constant:!1,entity:et,defaultValue:null,parent:Qw},e_={id:"getCompanyByIdEndpointReturnStatementRefThree",type:r.GenericReference,entityType:r.ReturnStatement,entityId:"getCompanyByIdEndpointReturnStatement"},t_={isError:!1,id:"getCompanyByIdEndpointResponseBodyReturnDeclaration",version:1,description:"The main data payload of the response.",type:r.ReturnDeclaration,name:"Response body",dataType:Kw,readsValue:null,required:!0,index:2,parent:e_},n_={id:"getCompanyByIdEndpointReturnStatementCallerRef",type:r.GenericReference,entityId:"getCompanyByIdEndpointReachedEntityEvent",entityType:r.FunctionDeclaration},r_={id:"getCompanyByIdEndpointReachedEntityEventRefFive",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"getCompanyByIdEndpointReachedEntityEvent"},i_={id:"getCompanyByIdEndpointReturnStatement",type:r.ReturnStatement,version:1,outputs:[Ww,Xw,t_],calledByError:[],calledByEntry:[n_],calledBySuccess:[],throws:null,x:0,y:0,parent:r_},a_={id:"endpointBuiltInBaseEntityRefFour",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:zT},s_={id:"getCompanyByIdEndpointReachedEntityEvent",name:"Endpoint reached",version:1,type:r.FunctionDeclaration,inputs:[ww,Mw,Gw,kw],returnStatements:[i_],description:"Fired when the endpoint is reached.",calls:[],collapsed:!1,implements:Qo,index:0,private:!1,x:0,y:0,parent:a_},o_={id:"getCompanyByIdEndpointPathPropertyDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointPathPropertyDataType"},l_={id:"getCompanyByIdEndpointPathPropertyRef",type:r.GenericReference,entityType:r.Property,entityId:"getCompanyByIdEndpointPathProperty"},c_={like:!1,id:"getCompanyByIdEndpointPathPropertyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!0,entity:k,asType:!1,defaultValue:{id:"getCompanyByIdEndpointPathPropertyDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,name:A.String,value:"/company/{id}",parent:o_,valueAsType:null,autogeneration:null},parent:l_},d_={id:"getCompanyByIdEndpointBaseEntityRefTwo",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},u_={hidden:!1,required:!0,id:"getCompanyByIdEndpointPathProperty",name:"Path",version:1,type:r.Property,private:!1,abstract:!1,static:!0,implements:Zo,dataType:c_,index:1,description:"Path to the endpoint, for example /api/users, or /api/users/{id}, or /api/users/{id}/:name. The path can contain parameters, which are defined by curly braces, and will be passed to the endpoint event as variables with the same name.",parent:d_},p_={id:"getCompanyByIdEndpointMethodPropertyDataTypeRef",type:r.GenericReference,entityType:r.DataType,entityId:"getCompanyByIdEndpointMethodPropertyDataType"},y_={id:"getCompanyByIdEndpointMethodPropertyRef",type:r.GenericReference,entityType:r.Property,entityId:"getCompanyByIdEndpointMethodProperty"},h_={like:!1,id:"getCompanyByIdEndpointMethodPropertyDataType",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:Sn,isList:!0,isNullable:!1,constant:!0,asType:!1,defaultValue:{id:"getCompanyByIdEndpointMethodPropertyDataTypeDefaultValueId",type:r.PrimitiveValue,version:1,value:"GET",name:A.Enum,parent:p_,valueAsType:null,autogeneration:null},options:["GET","POST","PUT","DELETE","PATCH","OPTIONS","HEAD","TRACE","CONNECT","CUSTOM"],parent:y_},f_={id:"getCompanyByIdEndpointBaseEntityRefThree",type:r.GenericReference,entityType:r.BuiltInBaseEntity,entityId:V.HTTP_ENDPOINT},m_={hidden:!1,required:!0,id:"getCompanyByIdEndpointMethodProperty",name:"Method",version:1,type:r.Property,private:!1,abstract:!1,static:!0,implements:Xo,index:0,dataType:h_,description:null,parent:f_},T_={type:r.GenericReference,id:"6a905153-8aa8-4424-bd7b-6415731a2725",entityType:r.Project,entityId:Z},E_={type:r.CustomEntity,id:zT,version:1,name:"Get given company data by id",description:null,properties:[u_,m_],methods:[s_],static:!0,abstract:!1,abstractMethods:[],extends:[],implements:[ka],x:0,y:0,parent:T_},R_={id:"product-prototype-database-property-ref-id",type:r.GenericReference,entityId:"product-prototype-database-property-id",entityType:r.Property},b_={id:"product-prototype-database-property-data-type-default-value-parent-ref-id",type:r.GenericReference,entityId:"product-prototype-database-property-data-type-default-value-id",entityType:r.DataType},g_={like:!1,id:"product-prototype-database-property-data-type-id",version:1,type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,isList:!1,isNullable:!1,constant:!1,entity:On,asType:!1,defaultValue:{id:"product-prototype-database-property-data-type-default-value-id",type:r.PrimitiveValue,version:1,value:null,name:A.EntityTemplate,valueAsType:Pl,autogeneration:null,parent:b_},parent:R_},v_={id:"product-prototype-database-property-parent-ref-id",type:r.GenericReference,entityId:"de67fc84-3719-46fd-9ab4-3fca3a3cc50d",entityType:r.CustomEntity},I_={hidden:!1,required:!0,id:"product-prototype-database-property-id",name:"Database",version:1,type:r.Property,private:!1,abstract:!1,implements:Pi,static:!0,index:0,dataType:g_,description:"The database that the entity belongs to.",parent:v_},D_={type:r.GenericReference,id:"13a4045e-dcb0-4159-8d33-10a646078b5a",entityType:r.Property,entityId:"d519c26a-15b8-40d8-ad09-13fa9342e9ba"},P_={like:!1,id:"7449779e-1d4e-409c-81c6-4b611336ed18",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:D_},A_={type:r.GenericReference,id:"0969562f-d836-406f-8b48-dd9d417fbe72",entityType:r.CustomEntity,entityId:"a2d0ec83-72ce-4f54-b059-a39e018fa86c"},S_={hidden:!1,required:!0,type:r.Property,id:"d519c26a-15b8-40d8-ad09-13fa9342e9ba",version:1,name:"Name",description:"The name of the product",index:0,implements:null,static:!1,private:!1,dataType:P_,abstract:!1,parent:A_},O_={type:r.GenericReference,id:"833a5425-7bd0-41dd-9e97-e018acce9592",entityType:r.Project,entityId:Z},C_={type:r.CustomEntity,id:"a2d0ec83-72ce-4f54-b059-a39e018fa86c",version:1,name:"Product",description:"A product that can be sold",implements:[Le],extends:[],abstract:!1,static:!1,abstractMethods:[],properties:[I_,S_],methods:[],x:0,y:0,parent:O_},Wi="project-loaded-event-id",Qt="get-bitcoin-price-http-call-operation-id",ZT="get-bitcoin-price-http-call-response-body-id",vs="validate-bitcoin-price-response-operation-ids",B_={type:r.GenericReference,id:"validate-bitcoin-data-to-validate-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:ZT},w_={type:r.GenericReference,id:"validate-bitcoin-data-to-validate-input-map-parent-ref-id",entityType:r.Operation,entityId:vs},XT={id:"validate-bitcoin-data-to-validate-input-map-id",type:r.InputMap,version:1,declaration:Qn.fixedArguments[1],name:null,description:null,readsValue:B_,defaultValue:null,index:0,parent:w_},__={type:r.GenericReference,id:"validate-bitcoin-type-to-match-input-map-default-value-parent-ref-id",entityType:r.InputMap,entityId:"validate-bitcoin-type-to-match-input-map-id"},M_={type:r.GenericReference,id:"validate-bitcoin-type-to-match-input-map-parent-ref-id",entityType:r.Operation,entityId:vs},N_={id:"validate-bitcoin-type-to-match-input-map-id",type:r.InputMap,version:1,declaration:Qn.fixedArguments[0],name:null,description:null,readsValue:null,defaultValue:{id:"validate-bitcoin-type-to-match-input-map-default-value-id",type:r.PrimitiveValue,version:1,name:A.EntityTemplate,valueAsType:VT,value:null,parent:__,autogeneration:null},index:0,parent:M_},V_={type:r.GenericReference,id:"validate-bitcoin-validated-entity-output-map-parent-ref-id",entityType:r.Operation,entityId:vs},$_={id:"validate-bitcoin-validated-entity-output-map-id",type:r.OutputMap,version:1,declaration:Qn.fixedReturns[0],writesValues:[],index:0,parent:V_},L_={type:r.GenericReference,id:"validate-bitcoin-price-response-operation-parent-ref-id",entityType:r.GlobalEvent,entityId:Wi},G_={type:r.GenericReference,id:"validate-bitcoin-price-response-operation-called-by-ref-id",entityType:r.Operation,entityId:Qt},F_={type:r.Operation,id:vs,version:1,declaration:Qn,inputs:[N_,XT],outputs:[$_],process:null,successCalls:[],errorCalls:[],error:null,x:0,y:0,calledByError:[],calledByEntry:[],calledBySuccess:[G_],parent:L_},U_={type:r.GenericReference,id:"96edb661-3f36-406c-8921-f1679dd796a3",entityType:r.FunctionCall,entityId:Qt},x_={id:"c93e1393-9b5e-4de2-b8da-7eae647d715a",version:1,type:r.InputMap,declaration:Va,name:null,description:null,readsValue:null,defaultValue:null,index:0,parent:U_},k_={type:r.GenericReference,id:"40312b28-71b8-4b01-a654-58b87191939d",entityType:r.FunctionCall,entityId:Qt},j_={type:r.GenericReference,id:"6ea96c7d-02a7-4971-82ad-2f32a0fec8b4",entityType:r.InputMap,entityId:"9f21cbac-5a83-4983-8923-9224ffd3ba9f"},q_={id:"9f21cbac-5a83-4983-8923-9224ffd3ba9f",version:1,type:r.InputMap,declaration:$a,name:null,description:null,readsValue:null,defaultValue:{id:"get-bitcoin-price-http-request-url-argument-default-value-id",type:r.PrimitiveValue,version:1,value:"https://api.coindesk.com/v1/bpi/currentprice.json",name:A.String,parent:j_,valueAsType:null,autogeneration:null},index:1,parent:k_},J_={type:r.GenericReference,id:"2610bf4a-c8a2-4746-b6cc-eb15f7fa8e9c",entityType:r.FunctionCall,entityId:Qt},W_={id:"ffb3cd9d-c955-4104-bc7b-299120fe4ede",version:1,type:r.InputMap,declaration:La,name:null,description:null,readsValue:null,defaultValue:null,index:2,parent:J_},H_={type:r.GenericReference,id:"bfd29a6a-671a-448c-9f2f-f8c7e4ad8349",entityType:r.FunctionCall,entityId:Qt},Y_={id:"412bf1f3-1a8e-4665-a95f-82117540e34e",version:1,type:r.InputMap,declaration:Ga,name:null,description:null,readsValue:null,defaultValue:null,index:3,parent:H_},z_={type:r.GenericReference,id:"616a15f3-c224-4b11-b95c-63314edef409",entityType:r.FunctionCall,entityId:Qt},Z_={id:"4dd4651c-02e4-45f1-b50f-824f3bcb1648",version:1,type:r.OutputMap,declaration:Fa,writesValues:[],index:1,parent:z_},X_={type:r.GenericReference,id:"28793b68-4d7e-4826-aee1-f201a3499faf",entityType:r.FunctionCall,entityId:Qt},Q_={id:"94fe9d35-4dd4-4729-a50c-5283ccd7e661",version:1,type:r.OutputMap,declaration:Ho,writesValues:[],index:0,parent:X_},K_={type:r.GenericReference,id:"f13e04b2-49b4-4c69-85b8-cbbafafa3524",entityType:r.FunctionCall,entityId:Qt},eM={id:ZT,type:r.OutputMap,version:1,declaration:vi,writesValues:[XT],index:2,parent:K_},tM={type:r.GenericReference,id:"6148d6d0-caaa-45fc-b601-ff2493dfc60f",entityType:r.FunctionDeclaration,entityId:Qt},nM={type:r.GenericReference,id:"b115f084-807b-44b3-ae01-b69cc342f761",entityType:r.GlobalEvent,entityId:Wi},rM={type:r.Operation,id:Qt,version:1,declaration:Ii,inputs:[x_,q_,W_,Y_],outputs:[Q_,Z_,eM],process:null,parent:nM,calledByError:[],calledByEntry:[tM],calledBySuccess:[],successCalls:[F_],errorCalls:[],error:null,x:0,y:0},iM={type:r.GenericReference,id:"24e76019-3f94-475b-91ce-297f76bbc224",entityType:r.GlobalEvent,entityId:Wi},aM={type:r.GenericReference,id:"0eac8e29-cdf2-42f8-8ea7-ad76d4d79abe",entityType:r.GlobalEvent,entityId:Wi},sM={process:null,type:r.FunctionCall,id:"2d2e7593-bfbf-457c-a607-5fce18eef457",version:1,declaration:wl,inputs:[],outputs:[],calledByError:[],calledByEntry:[iM],calledBySuccess:[],parent:aM,successCalls:[],errorCalls:[],error:null,x:0,y:0},oM={id:"793b5999-a9da-47fb-9665-0c17ebc6d5c9",type:r.GenericReference,entityType:r.Project,entityId:"2e7eb5382-3d99-44fd-972a-b8b1e819f6be"},lM={type:r.GlobalEvent,id:Wi,version:1,name:on.PROJECT_PUBLICATION_COMPLETED,returnStatements:[],collapsed:!1,implements:Ha,parent:oM,inputs:[],calls:[sM,rM],x:0,y:0},$t="abort-execution-func-declaration-id",Hi="abort-execution-func-exec-var-declaration-id",Is="abort-execution-func-small-wait-op-id",_l="abort-execution-func-long-wait-op-id",QT="abort-execution-func-long-wait-process-output-id",KT="abort-execution-func-exec-var-instance-write-id",eE="abort-execution-func-long-wait-return-stmt-id",tE="abort-execution-func-small-wait-return-stmt-id",cM="abort-execution-func-exec-var-instance-abort-call-id",Ml="abort-execution-func-exec-var-instance-abort-internal-call-id",nE="abort-execution-func-exec-second-wait-op-id",dM={type:r.GenericReference,id:"short-wait-return-statement-returned-hello-string-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:"short-wait-return-statement-returned-hello-string-id"},uM={type:r.GenericReference,id:"short-wait-return-statement-returned-hello-string-data-type-default-value-parent-ref-id",entityType:r.DataType,entityId:"short-wait-return-statement-returned-hello-string-data-type-id"},pM={like:!1,id:"short-wait-return-statement-returned-hello-string-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:{id:"short-wait-return-statement-returned-hello-string-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"Hello 2",autogeneration:null,valueAsType:null,parent:uM},constant:!1,parent:dM},yM={type:r.GenericReference,id:"short-wait-return-statement-returned-hello-string-parent-ref-id",entityType:r.ReturnStatement,entityId:tE},hM={isError:!1,id:"short-wait-return-statement-returned-hello-string-id",type:r.ReturnDeclaration,version:1,name:"Return 1",description:"A random string that is returned by the function",dataType:pM,readsValue:null,required:!0,index:0,parent:yM},fM={type:r.GenericReference,id:"short-wait-return-statement-called-by-ref-id",entityType:r.Operation,entityId:Is},mM={type:r.GenericReference,id:"short-wait-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:$t},rE={type:r.ReturnStatement,id:tE,version:1,outputs:[hM],calledByError:[],calledByEntry:[],calledBySuccess:[fM],throws:null,x:0,y:0,parent:mM},TM={type:r.GenericReference,id:"second-wait-argument-default-value-parent-ref-id",entityType:r.InputMap,entityId:"second-wait-argument-map-id"},EM={type:r.GenericReference,id:"second-wait-argument-map-parent-ref-id",entityType:r.Operation,entityId:nE},RM={id:"second-wait-argument-map-id",type:r.InputMap,version:1,declaration:Zn,name:null,description:null,readsValue:null,defaultValue:{id:"second-wait-argument-default-value-id",type:r.PrimitiveValue,version:1,value:2e3,valueAsType:null,autogeneration:null,name:A.Number,parent:TM},index:0,parent:EM},bM={type:r.GenericReference,id:"small-wait-parent-ref-id",entityType:r.FunctionDeclaration,entityId:$t},gM={type:r.GenericReference,id:"small-wait-called-by-ref-one-id",entityType:r.InternalCall,entityId:Ml},vM={id:nE,type:r.Operation,version:1,declaration:dt,inputs:[RM],outputs:[],process:null,successCalls:[rE],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[],calledBySuccess:[gM],error:null,parent:bM},IM={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-abort-internal-call-called-by-ref-one-id",entityType:r.VariableInstance,entityId:KT},DM={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-abort-internal-call-called-by-ref-two-id",entityType:r.Operation,entityId:Is},PM={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-main-project-ref-id",entityType:r.FunctionDeclaration,entityId:$t},AM={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-declaration-ref-id",entityType:r.VariableDeclaration,entityId:Hi},SM={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-internal-call-ref-one-id",entityType:r.InternalCall,entityId:Ml},OM={id:cM,type:r.VariableInstance,version:1,declaration:AM,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],x:0,y:0,readsValue:null,writesValues:[],internalCalls:[SM],parent:PM},iE={id:Ml,type:r.InternalCall,version:1,inputs:[],outputs:[],declaration:il,process:null,calledByError:[],calledByEntry:[],calledBySuccess:[IM,DM],successCalls:[vM],errorCalls:[],error:null,index:0,parent:OM},CM={type:r.GenericReference,id:"abort-exec-func-var-write-instance-main-project-ref-id",entityType:r.FunctionDeclaration,entityId:$t},BM={type:r.GenericReference,id:"abort-exec-func-var-write-instance-called-by-ref-one-id",entityType:r.VariableDeclaration,entityId:Hi},wM={type:r.GenericReference,id:"abort-exec-func-var-write-instance-called-by-ref-two-id",entityType:r.FunctionDeclaration,entityId:$t},_M={type:r.GenericReference,id:"abort-exec-func-abort-call-var-instance-declaration-ref-id",entityType:r.VariableDeclaration,entityId:Hi},MM={type:r.GenericReference,id:"abort-exec-func-var-write-instance-reads-value-ref-id",entityType:r.OutputMap,entityId:QT},Nl={id:KT,type:r.VariableInstance,version:1,declaration:_M,inputs:[],outputs:[],calledByError:[],calledByEntry:[wM],calledBySuccess:[BM],successCalls:[iE],errorCalls:[],x:0,y:0,readsValue:MM,writesValues:[],internalCalls:[],parent:CM},NM={type:r.GenericReference,id:"abort-exec-func-var-decl-datatype-parent-ref-id",entityType:r.VariableDeclaration,entityId:Hi};r.GenericReference,r.DataType;const VM={like:!1,id:"abort-exec-func-var-decl-datatype-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:al,version:1,asType:!1,isList:!1,isNullable:!1,constant:!1,parent:NM,defaultValue:null},$M={type:r.GenericReference,id:"abort-exec-func-var-decl-main-project-ref-id",entityType:r.FunctionDeclaration,entityId:$t},LM={type:r.GenericReference,id:"abort-exec-func-var-decl-called-by-ref-one-id",entityType:r.FunctionDeclaration,entityId:$t},GM={id:Hi,type:r.VariableDeclaration,version:1,name:"Execution in progress",description:"A variable that holds an ongoing execution to abort it if needed",dataType:VM,inputs:[],outputs:[],calledByError:[],calledByEntry:[LM],calledBySuccess:[],successCalls:[Nl],errorCalls:[],x:0,y:0,readsValue:null,writesValues:[],internalCalls:[],parent:$M},FM={type:r.GenericReference,id:"long-wait-return-statement-returned-hello-string-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:"long-wait-return-statement-returned-hello-string-id"},UM={type:r.GenericReference,id:"long-wait-return-statement-returned-hello-string-data-type-default-value-parent-ref-id",entityType:r.DataType,entityId:"long-wait-return-statement-returned-hello-string-data-type-id"},xM={like:!1,id:"long-wait-return-statement-returned-hello-string-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,asType:!1,isList:!1,isNullable:!1,defaultValue:{id:"long-wait-return-statement-returned-hello-string-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.String,value:"Hello 1",autogeneration:null,valueAsType:null,parent:UM},constant:!1,parent:FM},kM={type:r.GenericReference,id:"long-wait-return-statement-returned-hello-string-parent-ref-id",entityType:r.ReturnStatement,entityId:eE},jM={isError:!1,id:"long-wait-return-statement-returned-hello-string-id",type:r.ReturnDeclaration,version:1,name:"Return 2",description:"A random string that is returned by the function",dataType:xM,readsValue:null,required:!0,index:0,parent:kM},qM={type:r.GenericReference,id:"long-wait-return-statement-called-by-ref-id",entityType:r.Operation,entityId:_l},JM={type:r.GenericReference,id:"long-wait-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:$t},aE={type:r.ReturnStatement,id:eE,version:1,outputs:[jM],calledByError:[],calledByEntry:[],calledBySuccess:[qM],throws:null,x:0,y:0,parent:JM},WM={type:r.GenericReference,id:"long-argument-default-value-parent-ref-id",entityType:r.InputMap,entityId:"long-argument-map-id"},sE={type:r.GenericReference,id:"long-argument-map-parent-ref-id",entityType:r.Operation,entityId:_l},HM={id:"long-argument-map-id",type:r.InputMap,version:1,declaration:Zn,name:null,description:null,readsValue:null,defaultValue:{id:"long-argument-default-value-id",type:r.PrimitiveValue,version:1,value:1500,valueAsType:null,autogeneration:null,name:A.Number,parent:WM},index:0,parent:sE},YM={type:r.GenericReference,id:"long-parent-ref-id",entityType:r.FunctionDeclaration,entityId:$t},zM={type:r.GenericReference,id:"long-called-by-ref-one-id",entityType:r.FunctionDeclaration,entityId:$t},ZM={id:QT,type:r.OutputMap,version:1,declaration:ol,writesValues:[Nl],index:0,parent:sE},XM={id:_l,type:r.Operation,version:1,declaration:dt,inputs:[HM],outputs:[],process:ZM,successCalls:[aE],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[zM],calledBySuccess:[],error:null,parent:YM},QM={type:r.GenericReference,id:"small-wait-argument-default-value-parent-ref-id",entityType:r.InputMap,entityId:"small-wait-argument-map-id"},KM={type:r.GenericReference,id:"small-wait-argument-map-parent-ref-id",entityType:r.Operation,entityId:Is},eN={id:"small-wait-argument-map-id",type:r.InputMap,version:1,declaration:Zn,name:null,description:null,readsValue:null,defaultValue:{id:"small-wait-argument-default-value-id",type:r.PrimitiveValue,version:1,value:500,valueAsType:null,autogeneration:null,name:A.Number,parent:QM},index:0,parent:KM},tN={type:r.GenericReference,id:"small-wait-parent-ref-id",entityType:r.FunctionDeclaration,entityId:$t},nN={type:r.GenericReference,id:"small-wait-called-by-ref-one-id",entityType:r.FunctionDeclaration,entityId:$t},rN={id:Is,type:r.Operation,version:1,declaration:dt,inputs:[eN],outputs:[],process:null,successCalls:[iE],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[nN],calledBySuccess:[],error:null,parent:tN},iN={type:r.GenericReference,id:"abort-execution-func-decl-parent-ref-id",entityType:r.Project,entityId:Z},oE={id:"abort-execution-func-decl-id",type:r.FunctionDeclaration,version:1,name:"Test aborting execution",description:"Executes a wait and then aborts the execution of that wait",inputs:[],returnStatements:[aE,rE],calls:[rN,GM,Nl,XM],implements:null,private:!1,collapsed:!1,index:null,x:0,y:0,parent:iN},aN={type:r.GenericReference,id:"call-execution-abort-func-parent-ref-id",entityType:r.Project,entityId:Z},sN={id:"call-execution-abort-func-id",type:r.FunctionCall,version:1,declaration:oE,inputs:[],process:null,outputs:[],successCalls:[],errorCalls:[],error:null,calledByError:[],calledByEntry:[],calledBySuccess:[],x:0,y:0,parent:aN},Vl="manual-hello-world-loop-func-decl-id",lE="manual-hello-world-loop-func-return-statement-id",Kt="manual-hello-world-loop-id",Yi="manual-hello-world-loop-body-id",$l="manual-hello-world-loop-break-statement-id",zi="manual-hello-world-loop-current-iteration-number-output-map-id",Ll="manual-hello-world-loop-previous-iterations-results-output-map-id",Gl="assembled-hello-world-text-output-id",cE="assembled-hello-world-list-output-id",Zi="iteration-number-is-equal-or-greater-than-10-condition-id",Ds="join-hello-world-and-number-operation-id",Ps="append-string-to-list-operation-id",dE="hello-world-loop-output-map-id",oN={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-output-declaration-parent-ref",entityType:r.ReturnStatement,entityId:lE},lN={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-output-declaration-data-type-parent-ref",entityType:r.ReturnDeclaration,entityId:"manual-hello-world-loop-function-declaration-output-declaration"},cN={like:!1,id:"manual-hello-world-loop-function-declaration-output-declaration-data-type",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!0,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:lN},dN={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-output-declaration-reads-value-ref",entityType:r.OutputMap,entityId:dE},uE={isError:!1,id:"manual-hello-world-loop-function-declaration-output-declaration",version:1,type:r.ReturnDeclaration,name:"Results",description:null,dataType:cN,readsValue:dN,required:!0,index:0,parent:oN},uN={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-return-statement-called-by-ref",entityType:r.Loop,entityId:Kt},pN={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-parent-ref",entityType:r.FunctionDeclaration,entityId:Vl},pE={type:r.ReturnStatement,id:lE,version:1,outputs:[uE],calledByError:[],calledByEntry:[],calledBySuccess:[uN],parent:pN,throws:null,x:0,y:0},yN={type:r.GenericReference,id:"hello-world-loop-break-statement-ref-id",entityType:r.BreakStatement,entityId:$l},hN={type:r.GenericReference,id:"hello-world-loop-break-statement-reads-value-ref-id",entityType:r.OutputMap,entityId:Gl},yE={isError:!1,id:"hello-world-loop-break-statement-output-id",version:1,type:r.ReturnDeclaration,name:"Iteration result",description:null,dataType:null,readsValue:hN,required:!0,index:0,parent:yN},fN={type:r.GenericReference,id:"hello-world-loop-break-statement-counter-reads-value-ref-id",entityType:r.ArgumentDeclaration,entityId:zi},mN={type:r.GenericReference,id:"hello-world-loop-break-statement-counter-ref-id",entityType:r.BreakStatement,entityId:$l},hE={isError:!1,id:"hello-world-loop-break-statement-counter-output-id",version:1,type:r.ReturnDeclaration,name:"Iteration counter",description:null,dataType:null,readsValue:fN,required:!0,index:1,parent:mN},TN={type:r.GenericReference,id:"hello-world-loop-break-statement-called-by-ref-id",entityType:r.Condition,entityId:Zi},EN={type:r.GenericReference,id:"hello-world-loop-break-statement-parent-ref-id",entityType:r.Loop,entityId:Kt},fE={type:r.BreakStatement,id:$l,version:1,outputs:[yE,hE],calledByError:[],calledByEntry:[],calledBySuccess:[TN],parent:EN,throws:null,x:0,y:0},RN={type:r.GenericReference,id:"hello-world-loop-continue-statement-ref-id",entityType:r.ContinueStatement,entityId:"hello-world-loop-continue-statement"},bN={type:r.GenericReference,id:"hello-world-loop-continue-statement-output-data-type-ref-id",entityType:r.ReturnDeclaration,entityId:"hello-world-loop-continue-statement-output-id"},gN={like:!1,id:"hello-world-loop-continue-statement-output-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:null,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:bN},vN={type:r.GenericReference,id:"hello-world-loop-continue-statement-reads-value-ref-id",entityType:r.OutputMap,entityId:Gl},mE={isError:!1,id:"hello-world-loop-continue-statement-output-id",version:1,type:r.ReturnDeclaration,name:"Iteration result",description:null,dataType:gN,readsValue:vN,required:!0,index:0,parent:RN},IN={type:r.GenericReference,id:"hello-world-loop-continue-statement-called-by-ref-id",entityType:r.Condition,entityId:Zi},DN={type:r.GenericReference,id:"hello-world-loop-continue-statement-parent-ref-id",entityType:r.Loop,entityId:Kt},TE={type:r.ContinueStatement,id:"hello-world-loop-continue-statement",version:1,outputs:[mE],calledBySuccess:[],calledByError:[IN],calledByEntry:[],parent:DN,throws:null,x:0,y:0};r.GenericReference,r.InputMap;const PN={type:r.GenericReference,id:"append-string-to-list-base-string-map-parent-ref-id",entityType:r.Operation,entityId:Ps},AN={type:r.GenericReference,id:"base-string-map-reads-value-ref-id",entityType:r.OutputMap,entityId:Ll},EE={id:"append-string-to-list-base-string-map-id",type:r.InputMap,version:1,declaration:Uo,name:null,description:null,readsValue:AN,defaultValue:null,index:0,parent:PN},SN={type:r.GenericReference,id:"assembly-string-map-parent-ref-id",entityType:r.Operation,entityId:Ps},ON={id:cE,type:r.OutputMap,version:1,writesValues:[yE],declaration:bi,index:0,parent:SN},CN={type:r.GenericReference,id:"append-string-to-list-called-by-ref-id",entityType:r.Condition,entityId:Zi},BN={type:r.GenericReference,id:"latest-string-to-add-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:cE},wN={type:r.GenericReference,id:"62b4afb0-6c21-4b0f-abd3-cebef7b17c28",entityType:r.Operation,entityId:Ps},RE={id:"latest-string-to-add-input-map-id",version:1,type:r.InputMap,declaration:xo,name:null,description:null,readsValue:BN,defaultValue:null,index:1,parent:wN},_N={type:r.GenericReference,id:"append-string-to-list-parent-ref-id",entityType:r.FunctionDeclaration,entityId:Kt},MN={type:r.Operation,id:Ps,declaration:Na,version:1,inputs:[EE,RE],outputs:[ON],calledByError:[],process:null,calledByEntry:[],calledBySuccess:[CN],successCalls:[],errorCalls:[],error:null,x:0,y:0,parent:_N},NN={type:r.GenericReference,id:"iteration-number-is-equal-or-greater-than-10-condition-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:Yi},VN={type:r.GenericReference,id:"iteration-number-is-equal-or-greater-than-10-condition-parent-ref-id",entityType:r.Loop,entityId:Kt},$N={type:r.GenericReference,id:"current-iteration-number-to-check-map-reads-value-ref-id",entityType:r.OutputMap,entityId:zi},bE={type:r.GenericReference,id:"iteration-number-is-equal-or-greater-than-10-condition-ref-two-id",entityType:r.Condition,entityId:Zi},LN={id:"current-iteration-number-to-check-map-id",version:1,type:r.InputMap,declaration:Ur.fixedArguments[0],name:null,description:null,readsValue:$N,index:1,defaultValue:null,parent:bE},GN={type:r.GenericReference,id:"max-num-iterations-value-map-default-value-parent-ref-id",entityType:r.InputMap,entityId:"max-num-iterations-value-map-id"},FN={id:"max-num-iterations-value-map-id",version:1,type:r.InputMap,declaration:Ur.fixedArguments[1],name:null,description:null,readsValue:null,index:0,defaultValue:{id:"max-num-iterations-value-map-default-value-id",type:r.PrimitiveValue,version:1,name:A.Number,value:10,autogeneration:null,valueAsType:null,parent:GN},parent:bE},UN={type:r.Condition,id:Zi,version:1,declaration:Ur,inputs:[FN,LN],calledByError:[],calledByEntry:[NN],calledBySuccess:[],successCalls:[fE,MN],errorCalls:[TE],x:0,y:0,parent:VN},xN={type:r.GenericReference,id:"base-string-map-ref-id",entityType:r.InputMap,entityId:"join-hello-world-and-number-base-string-map-id"},kN={type:r.GenericReference,id:"join-hello-world-and-number-base-string-map-parent-ref-id",entityType:r.Operation,entityId:Ds},jN={id:"join-hello-world-and-number-base-string-map-id",type:r.InputMap,version:1,declaration:_a,name:null,description:null,readsValue:null,defaultValue:{id:"join-hello-world-and-number-base-string-map-default-value-id",type:r.PrimitiveValue,version:1,value:"Hello world ",name:A.String,parent:xN,valueAsType:null,autogeneration:null},index:0,parent:kN},qN={type:r.GenericReference,id:"assembly-string-map-parent-ref-id",entityType:r.Operation,entityId:Ds},JN={id:Gl,type:r.OutputMap,version:1,writesValues:[RE,mE],declaration:bi,index:0,parent:qN},WN={type:r.GenericReference,id:"join-hello-world-and-number-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:Yi},HN={type:r.GenericReference,id:"current-iteration-number-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:zi},YN={type:r.GenericReference,id:"62b4afb0-6c21-4b0f-abd3-cebef7b17c28",entityType:r.Operation,entityId:Ds},gE={id:"current-iteration-number-input-map-id",version:1,type:r.InputMap,declaration:Ma,name:null,description:null,readsValue:HN,defaultValue:null,index:1,parent:YN},zN={type:r.GenericReference,id:"join-hello-world-and-number-parent-ref-id",entityType:r.FunctionDeclaration,entityId:Kt},ZN={type:r.Operation,id:Ds,declaration:gi,version:1,inputs:[jN,gE],outputs:[JN],process:null,calledByError:[],calledByEntry:[WN],calledBySuccess:[],successCalls:[],errorCalls:[],error:null,x:0,y:0,parent:zN},XN={id:"manual-hello-world-loop-iterations-results-declaration-data-type-parent-ref-id",type:r.GenericReference,entityId:Ll,entityType:r.ArgumentDeclaration},QN={like:!1,id:"manual-hello-world-loop-iterations-results-declaration-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,isList:!0,isNullable:!1,constant:!1,entity:null,asType:!1,defaultValue:null,parent:XN},KN={id:"manual-hello-world-loop-previous-iterations-results-output-map-parent-ref-id",type:r.GenericReference,entityId:Yi,entityType:r.FunctionDeclaration},e0={id:Ll,type:r.ArgumentDeclaration,version:1,name:"Previous iterations results",description:"The results of the previous iterations of the loop.",required:!0,dataType:QN,writesValues:[EE],index:1,parent:KN},t0={id:"manual-hello-world-loop-current-iteration-number-output-map-parent-ref-id",type:r.GenericReference,entityId:Yi,entityType:r.FunctionDeclaration},n0={id:"manual-flow-loop-current-iteration-number-declaration-data-type-parent-ref-id",type:r.GenericReference,entityId:zi,entityType:r.ArgumentDeclaration};r.DataType;const r0={id:zi,type:r.ArgumentDeclaration,version:1,name:"Current iteration number",description:"The number of the current iteration of the loop. Starts at 1.",required:!0,dataType:null,writesValues:[gE,hE],index:0,parent:t0},i0={id:"manual-flow-loop-body-parent-ref-id",type:r.GenericReference,entityId:Kt,entityType:r.Loop},a0={id:Yi,type:r.FunctionDeclaration,version:1,name:"Iteration logic trigger",description:"This function is called multiple times, once for each iteration of the loop.",inputs:[r0,e0],calls:[UN,ZN],implements:null,collapsed:!1,returnStatements:[],private:!1,index:0,x:0,y:0,parent:i0},s0={type:r.GenericReference,id:"hello-world-loop-iteration-result-inline-output-declaration-parent-ref-id",entityType:r.Loop,entityId:Kt},vE={id:"hello-world-loop-iteration-result-inline-output-declaration-id",version:1,type:r.ValueDescriptor,name:"Iteration result",description:null,dataType:null,required:!0,index:0,parent:s0},o0={type:r.GenericReference,id:"hello-world-loop-break-statement-output-map-parent-ref-id",entityType:r.Loop,entityId:Kt},l0={type:r.OutputMap,id:dE,version:1,declaration:vE,writesValues:[uE],index:0,parent:o0},c0={id:"manual-hello-world-loop-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},d0={id:"manual-hello-world-loop-called-by-ref-id",type:r.GenericReference,entityId:Vl,entityType:r.FunctionDeclaration},u0={id:Kt,type:r.Loop,version:1,declaration:zo,inputs:[],outputsDeclarations:[vE],outputs:[l0],body:a0,successCalls:[pE],errorCalls:[],process:null,error:null,calledByError:[],calledByEntry:[d0],calledBySuccess:[],breakStatements:[fE],continueStatements:[TE],x:0,y:0,parent:c0},p0={type:r.GenericReference,id:"manual-hello-world-loop-function-declaration-parent-ref-id",entityType:r.Project,entityId:Z},IE={type:r.FunctionDeclaration,id:Vl,version:1,name:"Manual hello world loop",description:null,inputs:[],calls:[u0],returnStatements:[pE],implements:null,collapsed:!1,private:!1,index:null,x:0,y:0,parent:p0},y0={type:r.GenericReference,id:"call-hello-world-loop-parent-ref-id",entityType:r.Project,entityId:Z},h0={id:"call-hello-world-loop-id",type:r.FunctionCall,version:1,declaration:IE,inputs:[],outputs:[],process:null,successCalls:[],errorCalls:[],error:null,calledByError:[],calledByEntry:[],calledBySuccess:[],x:0,y:0,parent:y0},yn="company-dto-function-declaration-id",Fl="company-dto-func-declaration-argument-dcl-id",en="company-dto-function-company-variable-id",Ln="company-dto-function-company-dto-variable-id",Zr="iterate-over-employee-list-loop-id",DE="iterate-over-employee-list-loop-employee-dto-output-map-id",Ul="iterate-over-employee-list-loop-body-current-employee-argument-declaration-id",Xi="iterate-over-employee-list-loop-body-map-employee-dto-function-call-id",PE="iterate-over-employee-list-continue-statement-employee-dto-output-decl-id",f0="iterate-over-employee-list-loop-body-map-employee-dto-function-call-employee-dto-output-map-id",AE="iterate-over-employee-list-continue-statement-id",As="iterate-over-employee-list-loop-body-id",SE="company-dto-func-declaration-return-statement-id",OE="company-dto-func-declaration-return-decl-id",CE="company-dto-func-declaration-company-variable-id-output-map-id",BE="company-dto-func-declaration-company-variable-employess-output-map-id",wE="company-dto-func-declaration-company-variable-name-output-map-id",m0="company-dto-func-declaration-company-dto-variable-input-map-id",T0="company-dto-func-declaration-company-dto-variable-employess-input-map-id",E0="company-dto-func-declaration-company-dto-variable-name-input-map-id",Ss="company-dto-func-declaration-owner-variable-id",R0="company-dto-func-declaration-company-dto-variable-owner-input-map-id",_E="company-dto-func-declaration-company-variable-owner-output-map-id",ME="company-dto-func-declaration-owner-variable-id-output-map-id",Os="company-dto-func-declaration-bank-account-variable-id",b0="company-dto-func-declaration-company-dto-variable-bank-account-input-map-id",NE="company-dto-func-declaration-company-variable-bank-account-output-map-id",VE="company-dto-func-declaration-bank-account-variable-id-output-map-id",g0={type:r.GenericReference,id:"company-dto-func-returned-company-dto-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:OE},v0={like:!1,id:"company-dto-func-returned-company-dto-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:g0},I0={type:r.GenericReference,id:"company-dto-func-returned-company-dto-parent-ref-id",entityType:r.ReturnStatement,entityId:SE},D0={type:r.GenericReference,id:"company-dto-func-returned-company-dto-reads-value-ref-id",entityType:r.VariableDeclaration,entityId:Ln},$E={isError:!1,id:OE,type:r.ReturnDeclaration,version:1,name:"Company DTO",description:"Output the company data in the format that it will be sent through an HTTP request.",dataType:v0,readsValue:D0,required:!0,index:0,parent:I0},P0={type:r.GenericReference,id:"company-dto-func-return-statement-called-by-ref-id",entityType:r.Operation,entityId:Ln},A0={type:r.GenericReference,id:"company-dto-func-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yn},xl={type:r.ReturnStatement,id:SE,version:1,outputs:[$E],calledByError:[],calledByEntry:[],calledBySuccess:[P0],throws:null,x:0,y:0,parent:A0},S0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-owner-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:ME},O0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-owner-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ln},LE={id:R0,type:r.InputMap,version:1,declaration:null,name:"owner_id",description:null,defaultValue:null,index:5,readsValue:S0,parent:O0},C0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-bank-account-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:VE},B0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-bank-account-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ln},GE={id:b0,type:r.InputMap,version:1,declaration:null,name:"bank_account_id",description:null,defaultValue:null,index:4,readsValue:C0,parent:B0},w0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-name-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:wE},_0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-name-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ln},FE={id:E0,type:r.InputMap,version:1,declaration:null,name:"name",description:null,defaultValue:null,index:3,readsValue:w0,parent:_0},M0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-employess-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:DE},N0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-employess-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ln},UE={id:T0,type:r.InputMap,version:1,declaration:null,name:"employees",description:null,defaultValue:null,index:2,readsValue:M0,parent:N0},V0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-id-output-map-reads-value-ref-id",entityType:r.OutputMap,entityId:CE},$0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ln},xE={id:m0,type:r.InputMap,version:1,declaration:null,name:"id",description:"The ID of the company",defaultValue:null,index:1,readsValue:V0,parent:$0},L0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yn},G0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-called-by-ref-one-id",entityType:r.VariableDeclaration,entityId:Os},F0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-called-by-ref-two-id",entityType:r.VariableDeclaration,entityId:Ss},U0={type:r.GenericReference,id:"company-dto-func-company-dto-variable-called-by-ref-three-id",entityType:r.VariableDeclaration,entityId:Zr},kl={id:Ln,type:r.VariableDeclaration,version:1,name:"Company DTO",dataType:null,description:"A variable holding the data of a mapped company DTO",calledByError:[],calledByEntry:[],calledBySuccess:[G0,F0,U0],successCalls:[xl],errorCalls:[],readsValue:null,writesValues:[$E],inputs:[xE,FE,GE,LE,UE],outputs:[],internalCalls:[],parent:L0,x:0,y:0},ar="employee-dto-func-declaration-id",jl="employee-dto-func-declaration-argument-dcl-id",kE="employee-dto-func-declaration-return-statement-id",jE="employee-dto-func-declaration-return-decl-id",sr="employee-dto-func-declaration-employee-variable-id",or="employee-dto-func-declaration-employee-dto-variable-id",Cs="employee-dto-func-declaration-manager-variable-id",qE="employee-dto-func-declaration-employee-variable-id-output-map-id",JE="employee-dto-func-declaration-employee-variable-birth-date-output-map-id",WE="employee-dto-func-declaration-employee-variable-department-output-map-id",HE="employee-dto-func-declaration-employee-variable-manager-output-map-id",YE="employee-dto-func-declaration-manager-variable-id-output-map-id",x0="employee-dto-func-declaration-employee-dto-variable-input-map-id",k0="employee-dto-func-declaration-employee-dto-variable-birth-date-input-map-id",j0="employee-dto-func-declaration-employee-dto-variable-department-input-map-id",q0="employee-dto-func-declaration-employee-dto-variable-manager-input-map-id",J0={type:r.GenericReference,id:"employee-dto-func-returned-employee-dto-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:jE},W0={like:!1,id:"employee-dto-func-returned-employee-dto-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:J0},H0={type:r.GenericReference,id:"employee-dto-func-returned-employee-dto-parent-ref-id",entityType:r.ReturnStatement,entityId:kE},Y0={type:r.GenericReference,id:"employee-dto-func-returned-employee-dto-reads-value-ref-id",entityType:r.VariableDeclaration,entityId:or},zE={isError:!1,id:jE,type:r.ReturnDeclaration,version:1,name:"Employee DTO",description:"Output the employee data in the format that it will be sent through an HTTP request.",dataType:W0,readsValue:Y0,required:!0,index:0,parent:H0},z0={type:r.GenericReference,id:"employee-dto-func-return-statement-called-by-ref-id",entityType:r.Operation,entityId:or},Z0={type:r.GenericReference,id:"employee-dto-func-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ar},ql={type:r.ReturnStatement,id:kE,version:1,outputs:[zE],calledByError:[],calledByEntry:[],calledBySuccess:[z0],throws:null,x:0,y:0,parent:Z0},X0={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-manager-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:YE},Q0={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-manager-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:or},ZE={id:q0,type:r.InputMap,version:1,declaration:null,name:"manager_id",description:null,defaultValue:null,index:4,readsValue:X0,parent:Q0},K0={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-department-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:WE},e1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-department-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:or},XE={id:j0,type:r.InputMap,version:1,declaration:null,name:"department_name",description:null,defaultValue:null,index:3,readsValue:K0,parent:e1},t1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-birth-date-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:JE},n1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-birth-date-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:or},QE={id:k0,type:r.InputMap,version:1,declaration:null,name:"birth_date",description:null,defaultValue:null,index:2,readsValue:t1,parent:n1},r1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-id-output-map-reads-value-ref-id",entityType:r.OutputMap,entityId:qE},i1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:or},KE={id:x0,type:r.InputMap,version:1,declaration:null,name:"id",description:"The ID of the employee",defaultValue:null,index:1,readsValue:r1,parent:i1},a1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ar},s1={type:r.GenericReference,id:"employee-dto-func-employee-dto-variable-called-by-ref-id",entityType:r.VariableDeclaration,entityId:Cs},o1={id:or,type:r.VariableDeclaration,version:1,name:"Employee DTO",dataType:null,description:"A variable holding the data of a mapped employee DTO",calledByError:[],calledByEntry:[],calledBySuccess:[s1],successCalls:[ql],errorCalls:[],readsValue:null,writesValues:[zE],inputs:[KE,QE,XE,ZE],outputs:[],internalCalls:[],parent:a1,x:0,y:0},l1={type:r.GenericReference,id:"employee-dto-func-manager-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Cs},c1={id:YE,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[ZE],parent:l1},d1={type:r.GenericReference,id:"employee-dto-func-manager-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:Cs},u1={like:!1,id:"employee-dto-func-manager-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ct,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:d1,defaultValue:null},p1={type:r.GenericReference,id:"employee-dto-func-manager-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:HE},y1={type:r.GenericReference,id:"employee-dto-func-manager-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ar};r.GenericReference,r.VariableDeclaration;const eR={id:Cs,type:r.VariableDeclaration,version:1,name:"Manager",dataType:u1,description:"A variable holding an inherited manager",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[o1],errorCalls:[],readsValue:p1,writesValues:[],inputs:[],outputs:[c1],internalCalls:[],parent:y1,x:0,y:0},h1={type:r.GenericReference,id:"employee-dto-func-employee-variable-manager-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:sr},f1={id:HE,type:r.OutputMap,version:1,declaration:Ct.properties[2],index:3,writesValues:[eR],parent:h1},m1={type:r.GenericReference,id:"employee-dto-func-employee-variable-department-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:sr},T1={id:WE,type:r.OutputMap,version:1,declaration:Ct.properties[0],index:2,writesValues:[XE],parent:m1},E1={type:r.GenericReference,id:"employee-dto-func-employee-variable-birth-date-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:sr},R1={id:JE,type:r.OutputMap,version:1,declaration:pt.properties[1],index:1,writesValues:[QE],parent:E1},b1={type:r.GenericReference,id:"employee-dto-func-employee-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:sr},g1={id:qE,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[KE],parent:b1},v1={type:r.GenericReference,id:"employee-dto-func-employee-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:sr},I1={like:!1,id:"employee-dto-func-employee-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ct,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:v1,defaultValue:null},D1={type:r.GenericReference,id:"employee-dto-func-employee-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ar},P1={type:r.GenericReference,id:"employee-dto-func-employee-variable-reads-value-ref-id",entityType:r.ArgumentDeclaration,entityId:jl},A1={type:r.GenericReference,id:"employee-dto-func-employee-variable-called-by-id",entityType:r.FunctionDeclaration,entityId:ar},tR={id:sr,type:r.VariableDeclaration,version:1,name:"Company employee",dataType:I1,description:"A variable holding a company employee",calledByError:[],calledByEntry:[A1],calledBySuccess:[],successCalls:[eR],errorCalls:[],readsValue:P1,writesValues:[],inputs:[],outputs:[g1,R1,T1,f1],internalCalls:[],parent:D1,x:0,y:0},S1={type:r.GenericReference,id:"employee-dto-func-declaration-employee-input-declaration-data-type-parent-ref-id",entityId:jl,entityType:r.ArgumentDeclaration},O1={type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,id:"employee-dto-func-declaration-employee-input-declaration-data-type-id",version:1,entity:Ct,asType:!1,isList:!1,isNullable:!1,constant:!1,like:!1,parent:S1,defaultValue:null},C1={type:r.GenericReference,id:"employee-dto-func-declaration-employee-input-declaration-parent-ref-id",entityId:ar,entityType:r.FunctionDeclaration},B1={type:r.ArgumentDeclaration,id:jl,version:1,name:"Employee",description:"The employee to create a DTO for",required:!0,dataType:O1,index:0,writesValues:[tR],parent:C1},w1={type:r.GenericReference,id:"employee-dto-function-declaration-parent-ref-id",entityType:r.Project,entityId:Z},Jl={type:r.FunctionDeclaration,id:ar,version:1,name:"Employee DTO",description:"Takes a employee and returns a DTO of that employee",index:null,inputs:[B1],calls:[tR],implements:null,returnStatements:[ql],collapsed:!1,private:!1,x:0,y:0,parent:w1},_1={id:"iterate-over-employee-list-continue-statement-employee-dto-output-decl-data-type-parent-ref-id",type:r.GenericReference,entityId:PE,entityType:r.ReturnDeclaration},M1={like:!1,id:"iterate-over-employee-list-continue-statement-employee-dto-output-decl-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,defaultValue:null,entity:Ct,isList:!1,isNullable:!1,asType:!1,constant:!1,parent:_1},N1={id:"iterate-over-employee-list-continue-statement-employee-dto-output-decl-reads-value-ref-id",type:r.GenericReference,entityId:Xi,entityType:r.OutputMap},V1={id:"iterate-over-employee-list-continue-statement-employee-dto-output-decl-parent-ref-id",type:r.GenericReference,entityId:AE,entityType:r.ContinueStatement},nR={isError:!1,id:PE,type:r.ReturnDeclaration,version:1,name:"Employee DTO",description:"The DTO of the employee entity.",readsValue:N1,dataType:M1,required:!0,index:0,parent:V1},$1={id:"iterate-over-employee-list-continue-statement-called-by-ref-id",type:r.GenericReference,entityId:Xi,entityType:r.FunctionCall},L1={id:"iterate-over-employee-list-continue-statement-parent-ref-id",type:r.GenericReference,entityId:Zr,entityType:r.Loop},rR={id:AE,type:r.ContinueStatement,version:1,calledByError:[],calledByEntry:[],calledBySuccess:[$1],outputs:[nR],throws:null,x:0,y:0,parent:L1},G1={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-employee-dto-output-map-parent-ref-id",type:r.GenericReference,entityId:Xi,entityType:r.FunctionCall},F1={id:f0,type:r.OutputMap,version:1,declaration:ql.outputs[0],writesValues:[nR],index:0,parent:G1},U1={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-employee-input-map-reads-value-ref-id",type:r.GenericReference,entityId:Ul,entityType:r.ArgumentDeclaration},x1={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-employee-input-map-parent-ref-id",type:r.GenericReference,entityId:Xi,entityType:r.FunctionCall},iR={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-employee-input-map-id",type:r.InputMap,version:1,name:null,description:null,declaration:Jl.inputs[0],readsValue:U1,index:0,defaultValue:null,parent:x1},k1={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-called-by-ref-id",type:r.GenericReference,entityId:As,entityType:r.FunctionDeclaration},j1={id:"iterate-over-employee-list-loop-body-map-employee-dto-function-call-parent-ref-id",type:r.GenericReference,entityId:As,entityType:r.FunctionDeclaration},q1={id:Xi,type:r.FunctionCall,version:1,declaration:Jl,inputs:[iR],process:null,outputs:[F1],calledByError:[],calledByEntry:[k1],calledBySuccess:[],successCalls:[rR],errorCalls:[],error:null,x:0,y:0,parent:j1},J1={type:r.GenericReference,id:"iterate-over-employee-list-loop-body-current-employee-argument-declaration-data-type-parent-ref-id",entityId:Ul,entityType:r.ArgumentDeclaration},W1={like:!1,id:"iterate-over-employee-list-loop-body-current-employee-argument-declaration-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,defaultValue:null,entity:Ct,isList:!1,isNullable:!1,asType:!1,constant:!1,parent:J1},H1={id:"iterate-over-employee-list-loop-body-current-employee-argument-declaration-parent-ref-id",type:r.GenericReference,entityId:As,entityType:r.FunctionDeclaration},Y1={id:Ul,type:r.ArgumentDeclaration,version:1,name:"Current employee",description:"The current employee entity being processed.",dataType:W1,required:!0,index:0,writesValues:[iR],parent:H1},z1={id:"iterate-over-employee-list-loop-body-parent-ref-id",type:r.GenericReference,entityId:Zr,entityType:r.Loop},Z1={id:As,type:r.FunctionDeclaration,version:1,name:"Iteration logic trigger",description:"This function is called once for each entity in the list.",inputs:[Y1],calls:[q1],implements:null,collapsed:!1,returnStatements:[],private:!1,index:0,x:0,y:0,parent:z1},X1={id:"iterate-over-employee-list-loop-iteration-list-input-map-parent-ref-id",type:r.GenericReference,entityId:Zr,entityType:r.Loop},Q1={id:"iterate-over-employee-list-loop-iteration-list-input-map-reads-value-ref-id",type:r.GenericReference,entityId:BE,entityType:r.OutputMap},aR={id:"iterate-over-employee-list-loop-iteration-list-input-map-id",type:r.InputMap,version:1,name:null,description:null,declaration:Kn.fixedArguments[0],defaultValue:null,readsValue:Q1,index:0,parent:X1},K1={id:"iterate-over-employee-list-loop-parent-ref-id",type:r.GenericReference,entityId:yn,entityType:r.FunctionDeclaration},eV={id:"iterate-over-employee-list-loop-employee-dto-output-map-parent-ref-id",type:r.GenericReference,entityId:Zr,entityType:r.Loop},tV={id:DE,type:r.OutputMap,version:1,declaration:Kn.fixedReturns[0],writesValues:[UE],index:0,parent:eV},nV={type:r.GenericReference,id:"iterate-over-employee-list-loop-called-by-ref-id",entityType:r.VariableDeclaration,entityId:en},rV={id:Zr,type:r.Loop,version:1,declaration:Kn,inputs:[aR],successCalls:[kl],errorCalls:[],outputsDeclarations:[],outputs:[tV],body:Z1,process:null,calledByError:[],calledByEntry:[],calledBySuccess:[nV],breakStatements:[],continueStatements:[rR],error:null,x:0,y:0,parent:K1},iV={type:r.GenericReference,id:"company-dto-func-bank-account-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Os},aV={id:VE,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[GE],parent:iV},sV={type:r.GenericReference,id:"company-dto-func-bank-account-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:Os},oV={like:!1,id:"company-dto-func-bank-account-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:sV,defaultValue:null},lV={type:r.GenericReference,id:"company-dto-func-bank-account-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:NE},cV={type:r.GenericReference,id:"company-dto-func-bank-account-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yn};r.GenericReference,r.VariableDeclaration;const sR={id:Os,type:r.VariableDeclaration,version:1,name:"Bank account",dataType:oV,description:"A variable holding an inherited bank account",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[kl],errorCalls:[],readsValue:lV,writesValues:[],inputs:[],outputs:[aV],internalCalls:[],parent:cV,x:0,y:0},dV={type:r.GenericReference,id:"company-dto-func-owner-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ss},uV={id:ME,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[LE],parent:dV},pV={type:r.GenericReference,id:"company-dto-func-owner-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:Ss},yV={like:!1,id:"company-dto-func-owner-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:pV,defaultValue:null},hV={type:r.GenericReference,id:"company-dto-func-owner-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:_E},fV={type:r.GenericReference,id:"company-dto-func-owner-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yn};r.GenericReference,r.VariableDeclaration;const oR={id:Ss,type:r.VariableDeclaration,version:1,name:"Owner",dataType:yV,description:"A variable holding an inherited owner",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[kl],errorCalls:[],readsValue:hV,writesValues:[],inputs:[],outputs:[uV],internalCalls:[],parent:fV,x:0,y:0},mV={type:r.GenericReference,id:"company-dto-func-company-variable-owner-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},TV={id:_E,type:r.OutputMap,version:1,declaration:gt.properties[2],index:4,writesValues:[oR],parent:mV},EV={type:r.GenericReference,id:"company-dto-func-company-variable-bank-account-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},RV={id:NE,type:r.OutputMap,version:1,declaration:gt.properties[2],index:3,writesValues:[sR],parent:EV},bV={type:r.GenericReference,id:"company-dto-func-company-variable-name-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},gV={id:wE,type:r.OutputMap,version:1,declaration:gt.properties[0],index:2,writesValues:[FE],parent:bV},vV={type:r.GenericReference,id:"company-dto-func-company-variable-employess-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},IV={id:BE,type:r.OutputMap,version:1,declaration:gt.properties[3],index:1,writesValues:[aR],parent:vV},DV={type:r.GenericReference,id:"company-dto-func-company-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},PV={id:CE,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[xE],parent:DV},AV={type:r.GenericReference,id:"company-dto-func-company-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:en},SV={like:!1,id:"company-dto-func-company-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:AV,defaultValue:null},OV={type:r.GenericReference,id:"company-dto-func-company-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yn},CV={type:r.GenericReference,id:"company-dto-func-company-variable-reads-value-ref-id",entityType:r.ArgumentDeclaration,entityId:Fl},BV={type:r.GenericReference,id:"company-dto-func-company-variable-called-by-id",entityType:r.FunctionDeclaration,entityId:yn},lR={id:en,type:r.VariableDeclaration,version:1,name:"Company",dataType:SV,description:"A variable holding a company",calledByError:[],calledByEntry:[BV],calledBySuccess:[],successCalls:[sR,oR,rV],errorCalls:[],readsValue:CV,writesValues:[],inputs:[],outputs:[PV,IV,gV,RV,TV],internalCalls:[],parent:OV,x:0,y:0},wV={type:r.GenericReference,id:"company-dto-func-declaration-company-input-declaration-data-type-parent-ref-id",entityId:Fl,entityType:r.ArgumentDeclaration},_V={type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,id:"company-dto-func-declaration-company-input-declaration-data-type-id",version:1,entity:gt,asType:!1,isList:!1,isNullable:!1,constant:!1,like:!1,parent:wV,defaultValue:null},MV={type:r.GenericReference,id:"company-dto-func-declaration-company-input-declaration-parent-ref-id",entityId:yn,entityType:r.FunctionDeclaration},NV={type:r.ArgumentDeclaration,id:Fl,version:1,name:"Company",description:"The company to create a DTO for",required:!0,dataType:_V,index:0,writesValues:[lR],parent:MV},VV={type:r.GenericReference,id:"company-dto-function-declaration-parent-ref-id",entityType:r.Project,entityId:Z},Wl={type:r.FunctionDeclaration,id:yn,version:1,name:"Company DTO",description:"Takes a company and returns a DTO of that company",inputs:[NV],calls:[lR],implements:null,index:null,returnStatements:[xl],collapsed:!1,private:!1,x:0,y:0,parent:VV},Qi="exec-in-parallel-operation-call-id",Ki="exec-sequentially-operation-call-id",yt="concurrency-and-wait-function-declaration-id",cR="concurrency-and-wait-return-statement-id",dR="concurrency-and-wait-return-declaration-id",Hl="exec-in-parallel-argument-map-id",uR="exec-sequentially-argument-map-id",Yl="wait-for-2-seconds-operation-id",pR="wait-for-2-seconds-argument-map-id",zl="map-company-dto-function-call-id",yR="map-company-dto-function-call-company-dto-output-map-id",ea="company-dto-variable-one-id",Zl="company-dto-variable-one-instance-id",$V="company-dto-variable-two-id",LV={type:r.GenericReference,id:"returned-company-dto-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:dR},GV={like:!1,id:"returned-company-dto-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:LV},FV={type:r.GenericReference,id:"returned-company-dto-parent-ref-id",entityType:r.ReturnStatement,entityId:cR},UV={type:r.GenericReference,id:"returned-company-dto-reads-value-ref-id",entityType:r.VariableDeclaration,entityId:ea},hR={isError:!1,id:dR,type:r.ReturnDeclaration,version:1,name:"Company DTO",description:"Output the company data in the format that it will be sent through an HTTP request.",dataType:GV,readsValue:UV,required:!0,index:0,parent:FV},xV={type:r.GenericReference,id:"concurrency-and-wait-return-statement-called-by-ref-id",entityType:r.Operation,entityId:Yl},kV={type:r.GenericReference,id:"concurrency-and-wait-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},fR={type:r.ReturnStatement,id:cR,version:1,outputs:[hR],calledByError:[],calledByEntry:[],calledBySuccess:[xV],throws:null,x:0,y:0,parent:kV},jV={type:r.GenericReference,id:"company-dto-variable-two-called-by-ref-id",entityType:r.VariableInstance,entityId:Zl},qV={type:r.GenericReference,id:"company-dto-variable-two-reads-value-ref-id",entityType:r.VariableInstance,entityId:Zl},JV={type:r.GenericReference,id:"company-dto-variable-two-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},mR={id:$V,type:r.VariableDeclaration,version:1,name:"Company DTO",description:null,dataType:null,inputs:[],outputs:[],successCalls:[],errorCalls:[],calledByError:[],calledByEntry:[],calledBySuccess:[jV],internalCalls:[],writesValues:[hR],readsValue:qV,x:0,y:0,parent:JV},WV={type:r.GenericReference,id:"company-dto-variable-one-instance-called-by-ref-id",entityType:r.VariableDeclaration,entityId:ea},HV={type:r.GenericReference,id:"company-dto-variable-one-instance-reads-value-ref-id",entityType:r.VariableDeclaration,entityId:ea},YV={type:r.GenericReference,id:"company-dto-variable-one-instance-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},zV={type:r.GenericReference,id:"company-dto-variable-one-instance-declaration-ref-id",entityType:r.VariableDeclaration,entityId:ea},TR={id:Zl,type:r.VariableInstance,version:1,declaration:zV,inputs:[],outputs:[],successCalls:[mR],errorCalls:[],calledByError:[],calledByEntry:[],calledBySuccess:[WV],internalCalls:[],writesValues:[mR],readsValue:HV,x:0,y:0,parent:YV},ZV={type:r.GenericReference,id:"company-dto-variable-one-called-by-ref-id",entityType:r.FunctionCall,entityId:zl},XV={type:r.GenericReference,id:"company-dto-variable-one-reads-value-ref-id",entityType:r.OutputMap,entityId:yR},QV={type:r.GenericReference,id:"company-dto-variable-one-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},ER={id:ea,type:r.VariableDeclaration,version:1,name:"Company DTO",description:null,dataType:null,inputs:[],outputs:[],successCalls:[TR],errorCalls:[],calledByError:[],calledByEntry:[],calledBySuccess:[ZV],internalCalls:[],writesValues:[TR],readsValue:XV,x:0,y:0,parent:QV},RR={type:r.GenericReference,id:"map-company-dto-function-call-company-input-map-parent-ref-id",entityType:r.FunctionCall,entityId:zl},KV={id:"map-company-dto-function-call-company-input-map-id",type:r.InputMap,version:1,declaration:Wl.inputs[0],name:null,description:null,defaultValue:null,index:0,readsValue:null,parent:RR},e$={id:yR,type:r.OutputMap,version:1,declaration:xl.outputs[0],writesValues:[ER],index:0,parent:RR},t$={id:"map-company-dto-function-call-called-by-ref-id",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:yt},n$={id:"map-company-dto-function-call-parent-ref-id",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:yt},r$={id:zl,type:r.FunctionCall,version:1,declaration:Wl,successCalls:[ER],process:null,errorCalls:[],inputs:[KV],outputs:[e$],calledByError:[],calledByEntry:[t$],calledBySuccess:[],parent:n$,x:0,y:0,error:null},i$={type:r.GenericReference,id:"last-timestamp-variable-datatype-parent-ref-id",entityType:r.VariableDeclaration,entityId:mT},a$={type:r.GenericReference,id:"last-timestamp-variable-default-value-parent-ref-id",entityType:r.DataType,entityId:"last-timestamp-variable-datatype-id"},s$={like:!1,id:"last-timestamp-variable-datatype-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:cn,version:1,asType:!1,isList:!1,isNullable:!1,constant:!1,parent:i$,defaultValue:{id:"last-timestamp-variable-default-value-id",type:r.PrimitiveValue,version:1,name:A.Date,value:null,autogeneration:{type:qe.CurrentDateAndTime,rangeStart:null,rangeEnd:null},parent:a$,valueAsType:null}},o$={type:r.GenericReference,id:"last-timestamp-variable-main-project-ref-id",entityType:r.Project,entityId:Z},Xl={id:mT,type:r.VariableDeclaration,version:1,name:"Last registered current time",description:"A test variable that holds the last current date and time that was registered.",dataType:s$,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],x:0,y:0,readsValue:null,writesValues:[],internalCalls:[],parent:o$},l$={type:r.GenericReference,id:"wait-for-2-seconds-argument-default-value-parent-ref-id",entityType:r.InputMap,entityId:pR},c$={type:r.GenericReference,id:"wait-for-2-seconds-argument-map-parent-ref-id",entityType:r.Operation,entityId:Yl},d$={id:pR,type:r.InputMap,version:1,declaration:Zn,name:null,description:null,readsValue:null,defaultValue:{id:"wait-for-2-seconds-argument-default-value-id",type:r.PrimitiveValue,version:1,value:2e3,valueAsType:null,autogeneration:null,name:A.Number,parent:l$},index:0,parent:c$},u$={type:r.GenericReference,id:"wait-for-2-seconds-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},p$={type:r.GenericReference,id:"wait-for-2-seconds-called-by-ref-one-id",entityType:r.FunctionDeclaration,entityId:Ki},y$={type:r.GenericReference,id:"wait-for-2-seconds-called-by-ref-two-id",entityType:r.FunctionDeclaration,entityId:Qi},bR={id:Yl,type:r.Operation,version:1,declaration:xt,inputs:[d$],outputs:[],process:null,successCalls:[fR],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[p$,y$],calledBySuccess:[],error:null,parent:u$},h$={type:r.GenericReference,id:"wait-for-random-amount-argument-default-value-parent-ref-id",entityType:r.InputMap,entityId:"wait-for-random-amount-input-map-id"},f$={type:r.GenericReference,id:"wait-for-random-amount-argument-map-parent-ref-id",entityType:r.Operation,entityId:"wait-for-random-amount-id"},m$={id:"wait-for-random-amount-input-map-id",type:r.InputMap,version:1,declaration:Zn,name:null,description:null,readsValue:null,defaultValue:{id:"wait-for-random-amount-argument-default-value-id",type:r.PrimitiveValue,version:1,value:null,valueAsType:null,autogeneration:{type:qe.Random,rangeStart:1e3,rangeEnd:4e3},name:A.Number,parent:h$},index:0,parent:f$},T$={type:r.GenericReference,id:"wait-for-random-amount-parent-ref-id",entityType:r.Project,entityId:Z},Xr={id:"wait-for-random-amount-id",type:r.Operation,version:1,declaration:xt,inputs:[m$],process:null,outputs:[],successCalls:[],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[],calledBySuccess:[],error:null,parent:T$},gR="list-of-functions-variable-id",E$={type:r.GenericReference,id:"list-of-functions-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:gR},R$={id:"list-of-functions-variable-action-descriptor-id",type:r.ActionDescriptor,version:1,name:"Action to execute",description:"An action of any type, to be executed. It can contain any number of inputs and outputs.",argumentsType:U.Dynamic,dynamicArgumentTypes:null,fixedArguments:[],returnsType:U.Dynamic,error:null,dynamicReturnTypes:null,fixedReturns:[],parent:null},b$={type:r.GenericReference,id:"list-of-functions-variable-data-type-default-parent-ref-id",entityType:r.DataType,entityId:"list-of-functions-variable-data-type-id"},g$={like:!1,id:"list-of-functions-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:R$,asType:!1,isList:!0,isNullable:!1,defaultValue:{id:"list-of-functions-variable-data-type-default-value-id",type:r.PrimitiveValue,version:1,name:A.ActionDescriptor,value:null,valueAsType:[Xr,Xr,Xr,Xr,Xr],autogeneration:null,parent:b$},constant:!1,parent:E$},v$={type:r.GenericReference,id:"list-of-functions-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt};r.GenericReference,r.InputMap;const I$={type:r.GenericReference,id:"list-of-functions-variable-writes-value-one-ref-id",entityType:r.InputMap,entityId:uR},D$={type:r.GenericReference,id:"list-of-functions-variable-writes-value-two-ref-id",entityType:r.InputMap,entityId:Hl},vR={id:gR,type:r.VariableDeclaration,version:1,name:"List of functions to execute",description:"A list of functions to be executed in parallel",dataType:g$,parent:v$,readsValue:null,writesValues:[I$,D$],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],inputs:[],outputs:[],internalCalls:[],x:0,y:0},P$={type:r.GenericReference,id:"exec-in-parallel-return-map-parent-ref-id",entityType:r.Operation,entityId:Qi},A$={type:r.GenericReference,id:"exec-in-parallel-result-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},S$={type:r.GenericReference,id:"exec-in-parallel-result-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:"exec-in-parallel-return-map-id"},O$={type:r.GenericReference,id:"exec-in-parallel-result-variable-called-by-ref-id",entityType:r.Operation,entityId:Qi},IR={id:"exec-in-parallel-result-variable-id",type:r.VariableInstance,version:1,declaration:Xl,readsValue:S$,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[O$],successCalls:[],errorCalls:[],internalCalls:[],parent:A$,x:0,y:0},C$={id:"exec-in-parallel-return-map-id",type:r.OutputMap,version:1,declaration:jo,writesValues:[IR],index:0,parent:P$},B$={type:r.GenericReference,id:"exec-in-parallel-argument-map-parent-ref-id",entityType:r.Operation,entityId:Qi},w$={id:Hl,type:r.InputMap,version:1,declaration:ko,name:null,description:null,readsValue:vR,defaultValue:null,index:0,parent:B$},_$={type:r.GenericReference,id:"exec-in-parallel-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},M$={type:r.GenericReference,id:"exec-in-parallel-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:yt},N$={process:null,id:Qi,type:r.Operation,version:1,declaration:xt,inputs:[w$],outputs:[C$],successCalls:[bR,IR],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[M$],calledBySuccess:[],error:null,parent:_$},V$={type:r.GenericReference,id:"exec-sequentially-return-map-parent-ref-id",entityType:r.Operation,entityId:Ki},$$={type:r.GenericReference,id:"exec-sequentially-result-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},L$={type:r.GenericReference,id:"exec-sequentially-result-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:"exec-sequentially-return-map-id"},G$={type:r.GenericReference,id:"exec-sequentially-result-variable-called-by-ref-id",entityType:r.Operation,entityId:Ki},DR={id:"exec-sequentially-result-variable-id",type:r.VariableInstance,version:1,declaration:Xl,readsValue:L$,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[G$],successCalls:[],errorCalls:[],internalCalls:[],parent:$$,x:0,y:0},F$={id:"exec-sequentially-return-map-id",type:r.OutputMap,version:1,declaration:Jo,writesValues:[DR],index:0,parent:V$},U$={type:r.GenericReference,id:"exec-sequentially-argument-map-parent-ref-id",entityType:r.Operation,entityId:Ki},x$={id:uR,type:r.InputMap,version:1,declaration:qo,name:null,description:null,readsValue:vR,defaultValue:null,index:0,parent:U$},k$={type:r.GenericReference,id:"exec-sequentially-parent-ref-id",entityType:r.FunctionDeclaration,entityId:yt},j$={type:r.GenericReference,id:"exec-sequentially-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:yt},q$={id:Ki,type:r.Operation,version:1,declaration:dn,inputs:[x$],process:null,outputs:[F$],successCalls:[bR,DR],errorCalls:[],x:0,y:0,calledByError:[],calledByEntry:[j$],calledBySuccess:[],error:null,parent:k$},J$={type:r.GenericReference,id:"concurrency-and-wait-parent-ref-id",entityType:r.Project,entityId:Z},W$={type:r.FunctionDeclaration,id:yt,version:1,name:"Execute with concurrency and wait",description:"Executes a hardcoded list of actions in parallel and waits for some time before ending the logic with some unrelated data payload as the result.",inputs:[],calls:[q$,N$,r$],returnStatements:[fR],implements:null,index:null,collapsed:!1,private:!1,x:0,y:0,parent:J$},H$={type:r.GenericReference,id:"3521f2c8-a5c0-419c-8808-4fc6a73d0b78",entityType:r.ReturnDeclaration,entityId:"e1ec31f0-25ca-42ac-a4c4-c9ec2255f55b"},Y$={like:!1,id:"ce8b9a30-afe9-4d4f-879f-1677efca2c47",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:gt,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:H$},z$={type:r.GenericReference,id:"8ee66e38-b060-474e-a503-594063a8ec24",entityType:r.ReturnStatement,entityId:"40a23a98-d3b2-42b1-9652-b33779ad15aa"},Z$={isError:!1,id:"e1ec31f0-25ca-42ac-a4c4-c9ec2255f55b",type:r.ReturnDeclaration,version:1,name:"Created company",description:"The new company that was created",dataType:Y$,readsValue:null,required:!0,index:0,parent:z$},X$={type:r.GenericReference,id:"9cb3c1e4-7250-4be6-be2a-69c2dd366d6f",entityType:r.FunctionDeclaration,entityId:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4"},Q$={type:r.GenericReference,id:"c065fcdd-e054-4f95-941c-7eaa65c35d04",entityType:r.FunctionDeclaration,entityId:"d683bfc1-a464-4810-8ec0-1dd8eaa0c3c4"},PR={type:r.ReturnStatement,id:"40a23a98-d3b2-42b1-9652-b33779ad15aa",version:1,outputs:[Z$],calledByError:[],calledByEntry:[Q$],calledBySuccess:[],throws:null,x:0,y:0,parent:X$},K$={type:r.GenericReference,id:"312ef836-9e40-4d57-b177-03b7145ed074",entityType:r.Project,entityId:Z},eL={type:r.FunctionDeclaration,id:"5059c093-eda2-4efc-b7b4-aaaadd4d44de",version:1,name:"Create new company",description:null,inputs:[],calls:[PR],index:null,implements:null,returnStatements:[PR],collapsed:!1,private:!1,x:0,y:0,parent:K$},Ql="get-current-date-and-time-func-decl-id",AR="get-current-date-and-time-return-statement-id",SR="get-current-date-and-time-return-declaration-id",OR="get-current-date-and-time-return-declaration-data-type-id",tL={type:r.GenericReference,id:"get-current-date-and-time-return-declaration-data-type-value-parent-ref-id",entityType:r.DataType,entityId:OR},nL={type:r.GenericReference,id:"get-current-date-and-time-return-declaration-data-type-parent-ref-id",entityType:r.ReturnDeclaration,entityId:SR},rL={type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,id:OR,version:1,entity:cn,asType:!1,isList:!1,isNullable:!1,like:!1,defaultValue:{id:"last-timestamp-variable-default-value-id",type:r.PrimitiveValue,version:1,value:null,name:A.Date,valueAsType:null,autogeneration:{type:qe.CurrentDateAndTime,rangeStart:null,rangeEnd:null},parent:tL},constant:!1,parent:nL},iL={type:r.GenericReference,id:"get-current-date-and-time-return-declaration-parent-ref-id",entityType:r.ReturnStatement,entityId:AR};r.ReturnDeclaration;const aL={type:r.GenericReference,id:"get-current-date-and-time-return-statement-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:Ql},sL={type:r.GenericReference,id:"get-current-date-and-time-return-statement-parent-ref-id",entityType:r.FunctionDeclaration,entityId:Ql};r.ReturnStatement;const oL={type:r.GenericReference,id:"concurrency-and-wait-parent-ref-id",entityType:r.Project,entityId:Z},lL={type:r.FunctionDeclaration,id:Ql,version:1,name:"Get current date and time",description:"Generates and returns the current date and time at the time of the execution",inputs:[],calls:[],returnStatements:[],implements:null,index:null,collapsed:!1,private:!1,x:0,y:0,parent:oL},CR="do-math-return-statement-id",BR="do-math-return-declaration-id",cL={type:r.GenericReference,id:"do-math-func-var-to-return-one-ref-id",entityType:r.VariableDeclaration,entityId:"do-math-func-var-to-return-one-id"},dL={like:!1,id:"do-math-func-var-to-return-one-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:cL},uL={type:r.GenericReference,id:"do-math-func-decl-ref-two-id",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},pL={type:r.GenericReference,id:"do-math-func-var-to-return-one-map-ref-id",entityType:r.ReturnDeclaration,entityId:BR},yL={type:r.VariableDeclaration,id:"do-math-func-var-to-return-one-id",version:1,description:null,name:"Fixed result",dataType:dL,readsValue:null,writesValues:[pL],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:uL},hL={type:r.GenericReference,id:"96ec244e-594b-45f7-802b-6dc3056920f6",entityType:r.ReturnStatement,entityId:CR},fL={type:r.GenericReference,id:"d120c0cc-9d13-4e45-90e2-4e1ee825ca46",entityType:r.ReturnDeclaration,entityId:"873a3556-4911-4141-b2a0-49c677b56fb4"},mL={like:!1,id:"da91aa23-9985-49ac-a8bf-9d623ba1ba8f",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:fL},TL={isError:!1,id:BR,version:1,type:r.ReturnDeclaration,name:"Result",description:null,dataType:mL,readsValue:yL,required:!0,index:0,parent:hL},EL={type:r.GenericReference,id:"57fd93e4-93a1-484e-82eb-4dd15d2d0e24",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},RL={type:r.GenericReference,id:"0a86e8d5-ab21-476e-a482-b928cbf351e3",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},wR={type:r.ReturnStatement,id:CR,version:1,outputs:[TL],calledByError:[],calledByEntry:[],calledBySuccess:[EL],parent:RL,throws:null,x:0,y:0},bL={type:r.GenericReference,id:"a2db26be-57f2-48e5-9769-cdbf0d95dc7c",entityType:r.VariableDeclaration,entityId:"d0e9f1f3-7e9f-4e1f-8d8e-7b4b3e6c6a6a"},gL={like:!1,id:"c3e9d5f0-204f-45f9-85f7-e1b56b468388",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,asType:!1,isList:!1,isNullable:!1,defaultValue:null,constant:!1,parent:bL},vL={type:r.GenericReference,id:"692122c5-610a-4504-90dd-f5a5202d116c",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},IL={type:r.GenericReference,id:"do-math-func-return-one-called-by",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},DL={type:r.GenericReference,id:"6dceb501-be5b-4252-afb4-3c0d08abba33",entityType:r.OutputMap,entityId:"64752080-ee0f-4cfe-9897-a0668f2b2aca"},_R={type:r.VariableDeclaration,id:"d0e9f1f3-7e9f-4e1f-8d8e-7b4b3e6c6a6a",version:1,name:"Result",dataType:gL,description:null,readsValue:DL,writesValues:[],inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[IL],successCalls:[],errorCalls:[],internalCalls:[],x:0,y:0,parent:vL},PL={type:r.GenericReference,id:"5440f523-af38-4981-8035-89d162fe8041",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},AL={type:r.GenericReference,id:"8c482c35-e674-4713-a1dd-63c3d13b611c",entityType:r.OutputMap,entityId:"64752080-ee0f-4cfe-9897-a0668f2b2aca"},SL={type:r.GenericReference,id:"c0a299cd-5869-4930-8cf0-90e3ceb8a903",entityType:r.VariableDeclaration,entityId:"46b2fe23-b417-4887-a35d-09b186679172"},OL={like:!1,id:"51c0c1df-2ee3-41df-ae52-ac512d8cf795",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,asType:!1,isNullable:!1,defaultValue:null,constant:!1,parent:SL},CL={type:r.GenericReference,id:"do-math-func-return-two-called-by",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},MR={type:r.VariableDeclaration,id:"46b2fe23-b417-4887-a35d-09b186679172",version:1,name:"Total",description:null,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[CL],successCalls:[],errorCalls:[],dataType:OL,readsValue:AL,writesValues:[],internalCalls:[],parent:PL,x:0,y:0},NR={type:r.GenericReference,id:"6e4d776e-6af2-4321-b630-c78110fd677c",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},BL={type:r.GenericReference,id:"5b60955b-2486-40b6-bb24-ffd97ccd8902",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},wL={type:r.GenericReference,id:"1a49923f-bc6f-453f-a438-e74e5475c2a9",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},_L={type:r.GenericReference,id:"02bfde0a-b757-4072-9613-6e9c7c9a424a",entityType:r.ArgumentDeclaration,entityId:"d8895765-f705-457e-85fa-25d130926769"},VR={id:"928953b0-0e3f-4d8c-ae5a-84620b4b8c68",version:1,type:r.InputMap,declaration:Mo,name:null,description:null,readsValue:_L,defaultValue:null,index:0,parent:wL},ML={id:"64752080-ee0f-4cfe-9897-a0668f2b2aca",type:r.OutputMap,version:1,declaration:Vo,writesValues:[_R,MR],index:0,parent:BL},NL={type:r.GenericReference,id:"d235a7f6-07ff-4f35-98d2-8f42dd59cf9f",entityType:r.Operation,entityId:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e"},VL={id:"8827e8e9-9381-4ad7-8f61-5419c23c9136",type:r.GenericReference,entityType:r.VariableDeclaration,entityId:"72a338d8-0183-4ca2-8760-227517854595"},$R={id:"a5525249-0eb5-472b-97bc-5e4cc0d75aee",version:1,type:r.InputMap,declaration:No,name:null,description:null,readsValue:VL,defaultValue:null,index:1,parent:NL},$L={type:r.Operation,id:"e8c8c0a3-2e3e-4f6a-8e3d-8e0a0f9d7d8e",declaration:wa,version:1,inputs:[VR,$R],outputs:[ML],calledByError:[],calledByEntry:[NR],calledBySuccess:[],process:null,successCalls:[wR,_R,MR],errorCalls:[],parent:NR,error:null,x:0,y:0},LL={type:r.GenericReference,id:"a2c40226-2270-4963-a865-c777ba79c551",entityType:r.DataType,entityId:"a350a9e9-25ee-477f-a83d-9e98ed2451662"},GL={id:"f47731b3-f278-4ab5-aeb2-24519c1119fb",type:r.GenericReference,entityId:"72a338d8-0183-4ca2-8760-227517854595",entityType:r.ArgumentDeclaration},LR={like:!1,id:"a350a9e9-25ee-477f-a83d-9e98ed2451662",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,isNullable:!1,asType:!1,defaultValue:{id:"do-math-func-argument-two-default-value-id",type:r.PrimitiveValue,version:1,value:1,name:A.Number,parent:LL,valueAsType:null,autogeneration:null},constant:!1,parent:GL},FL={type:r.GenericReference,id:"5f5d8dd0-7f3b-40cd-9f84-83d976887eaf",entityType:r.ArgumentDeclaration,entityId:"649bf0a4-6532-44aa-9818-a03d1c6564e9"},UL={type:r.GenericReference,id:"ca018d0f-a8b3-4c7e-a408-c8b372d04aff",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},xL={type:r.GenericReference,id:"do-math-func-var-called-by-ref",entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},GR={type:r.VariableDeclaration,id:"72a338d8-0183-4ca2-8760-227517854595",version:1,name:"Z",description:null,dataType:LR,inputs:[],outputs:[],calledByError:[],calledByEntry:[xL],calledBySuccess:[],successCalls:[],errorCalls:[],readsValue:FL,writesValues:[$R],internalCalls:[],x:0,y:0,parent:UL},kL={entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b",type:r.GenericReference,id:"af0cf105-4075-425f-aecc-b25d3600fcc4"},jL={id:"649bf0a4-6532-44aa-9818-a03d1c6564e9",type:r.ArgumentDeclaration,version:1,name:"Z",description:"The number to add",dataType:LR,writesValues:[GR],required:!0,index:1,parent:kL},qL={type:r.GenericReference,id:"56953b5d-3e43-4dea-a62c-f3e868ba81bb",entityType:r.Project,entityId:Z},JL={id:"868defc8-5c95-48ed-942d-257e8b9b9b00",type:r.GenericReference,entityType:r.FunctionDeclaration,entityId:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b"},WL={type:r.GenericReference,id:"35167664-a793-49f1-9eaf-fb57eac30897",entityType:r.DataType,entityId:"55b12914-91b1-48b7-9a3e-9c5d0d2a2ec2"},HL={id:"d47ceef6-be6f-40f1-a7b3-c73c8d8a6c6a",type:r.GenericReference,entityId:"d8895765-f705-457e-85fa-25d130926769",entityType:r.ArgumentDeclaration},YL={like:!1,id:"55b12914-91b1-48b7-9a3e-9c5d0d2a2ec2",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,isNullable:!1,asType:!1,defaultValue:{id:"do-math-func-argument-one-default-value-id",type:r.PrimitiveValue,version:1,value:5,name:A.Number,parent:WL,valueAsType:null,autogeneration:null},constant:!1,parent:HL},zL={id:"d8895765-f705-457e-85fa-25d130926769",type:r.ArgumentDeclaration,version:1,name:"N",dataType:YL,description:"The number to add",writesValues:[VR],required:!0,index:0,parent:JL},ZL={type:r.FunctionDeclaration,id:"b4c1d8d2-9c5e-4e0c-bd5e-3a6a0e4d2f0b",version:1,name:"Do math",description:"This function does math",inputs:[zL,jL],calls:[$L,GR],implements:null,index:null,collapsed:!1,returnStatements:[wR],private:!1,x:0,y:0,parent:qL},ht="replace-bank-account-in-company-func-declaration-id",Kl="company-entity-to-modify-arg-declaration-id",ec="account-number-to-create-arg-decl-id",Qr="company-main-variable-id",Kr="search-person-by-id-id",FR="new-bank-account-owner-arg-decl-id",UR="search-person-by-id-output-declaration-id",tc="search-person-by-id-output-entity-map-id",ta="person-not-empty-condition-id",Bs="create-new-bank-account-instance-operation-id",xR="create-new-bank-account-instance-operation-output-entity-map-id",kR="company-bank-account-output-map-id",nc="old-bank-account-var-declaration-id",jR="old-bank-account-var-instance-id",qR="company-variable-instance-id",rc="delete-bank-account-internal-call-id",na="new-bank-account-data-variable-declaration-id",XL={type:r.GenericReference,id:"company-variable-instance-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},QL={type:r.GenericReference,id:"company-variable-instance-called-by-ref-id",entityType:r.InternalCall,entityId:rc},KL={type:r.GenericReference,id:"company-variable-instance-declaration-ref-id",entityType:r.VariableDeclaration,entityId:Qr},eG={type:r.GenericReference,id:"bank-account-input-map-parent-ref-id",entityType:r.VariableInstance,entityId:qR},tG={type:r.GenericReference,id:"bank-account-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:xR},JR={type:r.InputMap,id:"bank-account-input-map-id",version:1,readsValue:tG,declaration:Bl,name:null,description:null,index:0,defaultValue:null,parent:eG},nG={type:r.VariableInstance,id:qR,version:1,declaration:KL,inputs:[JR],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[QL],successCalls:[],errorCalls:[],internalCalls:[],parent:XL,readsValue:null,writesValues:[],x:0,y:0},rG={type:r.GenericReference,id:"bank-account-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:Qr},iG={type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,id:"bank-account-variable-data-type-id",version:1,entity:Yr,asType:!1,isList:!1,isNullable:!1,constant:!1,like:!1,defaultValue:null,parent:rG},aG={type:r.GenericReference,id:"bank-account-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:kR},sG={type:r.GenericReference,id:"bank-account-variable-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},oG={type:r.GenericReference,id:"bank-account-variable-called-by-ref-id",entityType:r.VariableDeclaration,entityId:Qr},lG={type:r.GenericReference,id:"delete-bank-account-internal-call-called-by-ref-id",entityType:r.Operation,entityId:Bs};r.GenericReference,r.VariableInstance;const cG={type:r.GenericReference,id:"delete-bank-account-internal-call-called-by-ref-two-id",entityType:r.VariableDeclaration,entityId:nc},dG={type:r.GenericReference,id:"old-bank-account-variable-trigger-delete-decl-ref-id",entityType:r.VariableDeclaration,entityId:nc},uG={type:r.GenericReference,id:"bank-account-variable-parent-ref-two-id",entityType:r.FunctionDeclaration,entityId:ht},pG={type:r.GenericReference,id:"old-bank-account-variable-trigger-delete-internal-call-ref-id",entityType:r.InternalCall,entityId:rc},yG={type:r.VariableInstance,id:jR,version:1,declaration:dG,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],internalCalls:[pG],errorCalls:[],parent:uG,readsValue:null,writesValues:[],x:0,y:0},WR={process:null,type:r.InternalCall,id:rc,version:1,declaration:tl,index:0,successCalls:[nG],errorCalls:[],inputs:[],outputs:[],error:null,calledByError:[],calledByEntry:[],calledBySuccess:[lG,cG],parent:yG},HR={type:r.VariableDeclaration,id:nc,version:1,name:"Old bank account",description:"The existing bank account that needs to be replaced in the company entity",dataType:iG,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[oG],successCalls:[WR],internalCalls:[],errorCalls:[],parent:sG,readsValue:aG,writesValues:[],x:0,y:0},hG={type:r.GenericReference,id:"company-variable-declaration-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:Qr},fG={type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,id:"company-variable-declaration-data-type-id",version:1,entity:gt,asType:!1,isList:!1,isNullable:!1,like:!1,constant:!1,defaultValue:null,parent:hG},mG={type:r.GenericReference,id:"company-variable-declaration-reads-value-ref-id",entityType:r.ArgumentDeclaration,entityId:Kl},TG={type:r.GenericReference,id:"company-variable-declaration-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},EG={type:r.GenericReference,id:"company-variable-declaration-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:ht},RG={type:r.GenericReference,id:"company-bank-account-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:Qr},bG={id:kR,version:1,type:r.OutputMap,declaration:Bl,index:0,parent:RG,writesValues:[HR]},YR={type:r.VariableDeclaration,id:Qr,version:1,name:"Company",description:"The company entity that was passed as an argument to the parent function",dataType:fG,inputs:[],outputs:[bG],calledByError:[],calledByEntry:[EG],calledBySuccess:[],successCalls:[HR],errorCalls:[],parent:TG,internalCalls:[],readsValue:mG,writesValues:[],x:0,y:0},gG={type:r.GenericReference,id:"create-new-bank-account-account-owner-dynamic-input-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:na},vG={id:"create-new-bank-account-account-owner-dynamic-input-map-reads-value-ref-id",type:r.GenericReference,entityType:r.OutputMap,entityId:tc},zR={id:"create-new-bank-account-account-owner-dynamic-input-map-id",version:1,type:r.InputMap,declaration:null,name:"Account owner",description:null,readsValue:vG,index:1,defaultValue:null,parent:gG},IG={id:"create-new-bank-account-account-number-dynamic-input-map-reads-value-ref-id",type:r.GenericReference,entityType:r.ArgumentDeclaration,entityId:ec},DG={type:r.GenericReference,id:"create-new-bank-account-account-number-dynamic-input-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:na},ZR={id:"create-new-bank-account-account-number-dynamic-input-map-id",version:1,type:r.InputMap,declaration:null,name:"Account number",description:null,readsValue:IG,defaultValue:null,index:0,parent:DG},XR={type:r.GenericReference,id:"create-new-bank-account-instance-operation-entity-to-create-input-map-parent-ref-id",entityType:r.Operation,entityId:Bs},PG={id:"create-new-bank-account-instance-operation-entity-to-create-input-map-id",version:1,type:r.InputMap,declaration:Xn.fixedArguments[0],name:null,description:null,index:0,readsValue:null,defaultValue:{type:r.PrimitiveValue,name:A.EntityTemplate,value:null,valueAsType:Yr,autogeneration:null},parent:XR},AG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-entity-data-input-map-reads-value-ref-id",entityType:r.VariableDeclaration,entityId:na},QR={id:"create-new-bank-account-instance-operation-entity-data-input-map-id",version:1,type:r.InputMap,declaration:Xn.fixedArguments[1],name:null,description:null,index:1,readsValue:AG,defaultValue:null,parent:XR},SG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-output-entity-map-parent-ref-id",entityType:r.Operation,entityId:Bs},OG={id:xR,version:1,type:r.OutputMap,declaration:Xn.fixedReturns[0],index:0,writesValues:[JR],parent:SG},CG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-called-by-ref-id",entityType:r.Condition,entityId:ta},BG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-called-by-ref-id",entityType:r.VariableDeclaration,entityId:na},wG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},KR={process:null,id:Bs,type:r.Operation,version:1,declaration:Xn,inputs:[PG,QR],error:null,outputs:[OG],successCalls:[WR],errorCalls:[],calledByError:[],calledByEntry:[],calledBySuccess:[BG,CG],parent:wG,x:0,y:0},_G={type:r.GenericReference,id:"new-bank-account-data-variable-declaration-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},MG={type:r.GenericReference,id:"create-new-bank-account-instance-operation-called-by-ref-id",entityType:r.Condition,entityId:ta},NG={id:na,type:r.VariableDeclaration,version:1,inputs:[ZR,zR],dataType:null,name:"New bank Account's data",description:null,readsValue:null,outputs:[],writesValues:[QR],successCalls:[KR],errorCalls:[],internalCalls:[],calledByError:[],calledBySuccess:[MG],calledByEntry:[],x:0,y:0,parent:_G},VG={id:"person-not-found-thrown-error-datatype-default-value-parent-ref-id",type:r.GenericReference,entityId:"person-not-found-thrown-error-datatype-id",entityType:r.DataType},$G={id:"person-not-found-thrown-error-datatype-parent-ref-id",type:r.GenericReference,entityId:"person-not-found-thrown-error-id",entityType:r.ReturnDeclaration};r.DataType,r.PrimitiveValue,A.String;const LG={id:"person-not-found-thrown-error-parent-ref-id",type:r.GenericReference,entityId:"person-not-found-error-return-statement-id",entityType:r.ReturnStatement},GG={isError:!0,id:"person-not-found-thrown-error-id",type:r.ReturnDeclaration,version:1,dataType:null,name:"Person not found error",description:"If the person entity was not found this error is outputted",parent:LG,required:!0,index:0,readsValue:null},FG={id:"person-not-found-error-return-statement-called-by-ref-id",type:r.GenericReference,entityId:ta,entityType:r.Condition},UG={id:"person-not-found-error-return-statement-parent-ref-id",type:r.GenericReference,entityId:ht,entityType:r.FunctionDeclaration},xG={id:"person-not-found-error-return-statement-id",type:r.ReturnStatement,version:1,throws:GG,outputs:[],calledBySuccess:[],calledByError:[FG],calledByEntry:[],x:0,y:0,parent:UG},kG={type:r.GenericReference,id:"person-not-empty-condition-called-by-ref-id",entityType:r.Search,entityId:Kr},jG={type:r.GenericReference,id:"person-not-empty-condition-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},qG={type:r.GenericReference,id:"person-entity-to-check-map-reads-value-ref-id",entityType:r.OutputMap,entityId:tc},JG={type:r.GenericReference,id:"person-not-empty-condition-ref-two-id",entityType:r.Condition,entityId:ta},eb={id:"person-entity-to-check-map-id",version:1,type:r.InputMap,declaration:er.fixedArguments[0],name:null,description:null,readsValue:qG,index:0,defaultValue:null,parent:JG},WG={type:r.Condition,id:ta,version:1,declaration:er,inputs:[eb],calledByError:[],calledByEntry:[],calledBySuccess:[kG],successCalls:[NG,KR],errorCalls:[xG],x:0,y:0,parent:jG},HG={type:r.GenericReference,id:"search-person-by-id-output-entity-declaration-datatype-parent-ref-id",entityType:r.ValueDescriptor,entityId:UR},YG={like:!1,id:"search-person-by-id-output-entity-declaration-datatype-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,isList:!1,constant:!1,asType:!1,isNullable:!1,entity:pt,defaultValue:null,parent:HG},zG={type:r.GenericReference,id:"search-person-by-id-output-entity-declaration-parent-ref-id",entityType:r.Search,entityId:Kr},tb={id:UR,type:r.ValueDescriptor,version:1,dataType:YG,name:"Found person",description:"The person entity that was found",parent:zG,required:!0,index:0},ZG={type:r.GenericReference,id:"search-person-by-id-output-entity-map-parent-ref-id",entityType:r.Search,entityId:Kr},XG={type:r.OutputMap,id:tc,version:1,declaration:tb,parent:ZG,writesValues:[eb,zR],index:0},QG={id:"search-person-by-id-input-declaration-datatype-parent-ref-id",type:r.GenericReference,entityId:"search-person-by-id-input-declaration-id",entityType:r.ArgumentDeclaration};r.DataType;const KG={type:r.GenericReference,id:"search-person-by-id-input-declaration-parent-ref-id",entityType:r.Search,entityId:Kr},nb={id:"search-person-by-id-input-declaration-id",type:r.ArgumentDeclaration,version:1,dataType:null,name:"Person ID",description:"The unique identifier (ID) property of the person entity",index:0,required:!0,parent:KG,writesValues:[]},eF={type:r.GenericReference,id:"search-person-by-id-input-map-parent-ref-id",entityType:r.Search,entityId:Kr},tF={id:"search-person-by-id-input-map-reads-value-ref-id",type:r.GenericReference,entityId:FR,entityType:r.ArgumentDeclaration},rb={type:r.InputMap,id:"search-person-by-id-input-map",version:1,declaration:nb,name:null,description:null,readsValue:tF,defaultValue:null,parent:eF,index:0},nF={from:{name:"c9bc312a-10d3-48a7-9ab4-ea483a9e2416"},items:[{name:"*"}],where:[{name:"id",value:"{{dynamic_value_1}}"}]},rF={type:r.GenericReference,id:"search-person-by-id-parent-ref-id",entityType:r.FunctionDeclaration,entityId:ht},iF={type:r.GenericReference,id:"search-person-by-id-called-by-ref-id",entityType:r.FunctionDeclaration,entityId:ht},aF={type:r.Search,id:Kr,version:1,name:"Search person by ID",description:"Searches for a person entity given the UUID",query:nF,inputsDeclarations:[nb],inputs:[rb],outputsDeclarations:[tb],outputs:[XG],calledByError:[],calledByEntry:[iF],calledBySuccess:[],error:null,successCalls:[WG],errorCalls:[],parent:rF,x:0,y:0};r.GenericReference,r.DataType;const sF={id:"account-number-to-create-arg-decl-data-type-parent-ref-id",type:r.GenericReference,entityId:ec,entityType:r.ArgumentDeclaration},oF={like:!1,id:"account-number-to-create-arg-decl-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:k,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:sF},lF={entityType:r.FunctionDeclaration,entityId:ht,type:r.GenericReference,id:"account-number-to-create-arg-decl-parent-ref-id"},cF={id:ec,type:r.ArgumentDeclaration,version:1,name:"Account number",description:"The account number of the new bank account entity",dataType:oF,writesValues:[ZR],required:!0,index:1,parent:lF};r.GenericReference,r.DataType;const dF={id:"new-bank-account-owner-arg-decl-data-type-parent-ref-id",type:r.GenericReference,entityId:"new-bank-account-owner-arg-decl-id",entityType:r.ArgumentDeclaration},uF={like:!1,id:"new-bank-account-owner-arg-decl-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ba,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:dF},pF={entityType:r.FunctionDeclaration,entityId:ht,type:r.GenericReference,id:"new-bank-account-owner-arg-decl-parent-ref-id"},yF={id:FR,type:r.ArgumentDeclaration,version:1,name:"New account owner ID",description:"If it has changed, this is the new person entity, that owns of the bank account",dataType:uF,writesValues:[rb],required:!1,index:1,parent:pF},hF={type:r.GenericReference,id:"replace-bank-account-in-company-parent-ref",entityType:r.Project,entityId:Z},fF={type:r.GenericReference,id:"company-entity-to-modify-parent-ref",entityType:r.FunctionDeclaration,entityId:ht};r.GenericReference,r.DataType;const mF={id:"d47ceef6-be6f-40f1-a7b3-c73c8d8a6c6a",type:r.GenericReference,entityId:Kl,entityType:r.ArgumentDeclaration},TF={like:!1,id:"company-entity-to-modify-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ce,isList:!1,isNullable:!1,asType:!1,defaultValue:null,constant:!1,parent:mF},EF={id:Kl,type:r.ArgumentDeclaration,version:1,name:"Company",dataType:TF,description:"The company to replace the bank account for",writesValues:[YR],required:!0,index:0,parent:fF},RF={type:r.FunctionDeclaration,id:ht,version:1,name:"Replace bank account",description:"This action takes an existing company and data to create a new bank account entity. It then creates a bank account, deletes the old one, and updates the company with the new bank account",inputs:[EF,cF,yF],index:null,implements:null,calls:[aF,YR],collapsed:!1,returnStatements:[],private:!1,x:0,y:0,parent:hF},bF={type:r.GenericReference,id:"e0a937bd-3a85-4037-a973-916985b9f94b",entityType:r.Project,entityId:"7268bc97-c0e6-4d88-b37e-d3241b5f77a6"},gF={type:r.FunctionDeclaration,version:1,id:"6bedb217-f844-4332-af72-9626b2a32511",name:"Some library main function",description:null,inputs:[],calls:[],implements:null,collapsed:!0,index:null,returnStatements:[],private:!1,parent:bF,x:0,y:0},vF={type:r.GenericReference,id:"948e6869-ae5b-4914-bea0-b9f02ad6a014",entityType:r.Project,entityId:"23b23d8b-1929-4505-a350-745c8550e731"},IF={type:r.GenericReference,id:"f3d6f2c6-1b3e-4e9d-8c9d-5b5b9f0b8d9c",entityType:r.Project,entityId:"7268bc97-c0e6-4d88-b37e-d3241b5f77a6"},DF={type:r.InstalledProject,version:1,id:"7268bc97-c0e6-4d88-b37e-d3241b5f77a6",name:"Third Party Installed Project",description:null,functions:[gF],events:[],implements:IF,parent:vF,x:0,y:0},ic="iterate-over-list-loop-id",ib="iterate-over-list-loop-body-id",ab="iterate-over-list-loop-body-current-iteration-argument-declaration-id",PF={type:r.GenericReference,id:"iterate-over-list-loop-body-current-iteration-argument-declaration-data-type-parent-ref-id",entityId:ab,entityType:r.ArgumentDeclaration},AF={like:!1,id:"iterate-over-list-loop-body-current-iteration-argument-declaration-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,defaultValue:null,entity:null,isList:!1,isNullable:!1,asType:!1,constant:!1,parent:PF},SF={id:"iterate-over-list-loop-body-current-iteration-argument-declaration-parent-ref-id",type:r.GenericReference,entityId:ib,entityType:r.FunctionDeclaration},OF={id:ab,type:r.ArgumentDeclaration,version:1,name:"Current value",description:"The current value being processed.",dataType:AF,required:!0,index:0,writesValues:[],parent:SF},CF={id:"iterate-over-list-loop-body-parent-ref-id",type:r.GenericReference,entityId:ic,entityType:r.Loop},BF={id:ib,type:r.FunctionDeclaration,version:1,name:"Iteration logic trigger",description:"This function is called once for each entity in the list.",inputs:[OF],calls:[],implements:null,collapsed:!1,returnStatements:[],private:!1,index:0,x:0,y:0,parent:CF},wF={id:"iterate-over-list-loop-iteration-list-input-map-parent-ref-id",type:r.GenericReference,entityId:ic,entityType:r.Loop},_F={id:"iterate-over-list-loop-iteration-list-input-map-id",type:r.InputMap,version:1,name:null,description:null,declaration:Kn.fixedArguments[0],defaultValue:null,readsValue:null,index:0,parent:wF},MF={id:"iterate-over-list-loop-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},NF={id:ic,type:r.Loop,version:1,declaration:Kn,inputs:[_F],successCalls:[],errorCalls:[],outputsDeclarations:[],outputs:[],process:null,body:BF,calledByError:[],calledByEntry:[],calledBySuccess:[],breakStatements:[],continueStatements:[],error:null,x:0,y:0,parent:MF};var ac=(n=>(n.EQ="eq",n.NEQ="neq",n.GT="gt",n.GTE="gte",n.LT="lt",n.LTE="lte",n.LIKE="like",n.ILIKE="ilike",n))(ac||{}),sb=(n=>(n.COUNT="count",n.SUM="sum",n.AVG="avg",n.MIN="min",n.MAX="max",n))(sb||{});const VF={from:{name:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},items:{from:{name:"ed3a6098-12ee-4632-a6dd-c2e6c542f66d"},items:[{function:{name:sb.COUNT,items:["f8310850-a87e-405c-b182-4f1d5fa49240"]},alias:"employee_count"}],where:[{name:"80c86e1b-caca-4ba5-9b1f-38f72d10e4a3",operation:ac.NEQ,value:null}]},where:[{name:"employee_count",operation:ac.GT,value:1}]},$F={id:"find-companies-with-multiple-employees-and-bank-account-search-parent-ref-id",type:r.GenericReference,entityId:Z,entityType:r.Project},LF={id:"find-companies-with-multiple-employees-and-bank-account-search-companies-list-output-declaration-parent-ref-id",type:r.GenericReference,entityId:"find-companies-with-multiple-employees-and-bank-account",entityType:r.Search},ob={id:"find-companies-with-multiple-employees-and-bank-account-search-companies-list-output-declaration-id",type:r.ValueDescriptor,version:1,name:"companies",description:"List of companies with multiple employees and an existing bank account",dataType:null,required:!0,index:0,parent:LF},GF={id:"find-companies-with-multiple-employees-and-bank-account-search-companies-list-output-parent-ref-id",type:r.GenericReference,entityId:"find-companies-with-multiple-employees-and-bank-account",entityType:r.Search},FF={id:"find-companies-with-multiple-employees-and-bank-account-search-companies-list-output-id",type:r.OutputMap,version:1,declaration:ob,writesValues:[],index:0,parent:GF},UF={id:"find-companies-with-multiple-employees-and-bank-account",type:r.Search,version:1,name:"Find companies with multiple employees and a bank account",description:"This search statement finds companies with multiple employees and an existing bank account",inputsDeclarations:[],outputsDeclarations:[ob],inputs:[],outputs:[FF],query:VF,successCalls:[],errorCalls:[],error:null,calledByError:[],calledByEntry:[],calledBySuccess:[],x:0,y:0,parent:$F},ei="random-company-employee-test-variable-id",sc="manager-global-variable-id",lb="global-user-instance-id",lr="employee-mapped-dto-variable-id",oc="employee-mapped-dto-variable-instance-id",cb="random-employee-id-output-map-id",db="random-employee-birth-date-output-map-id",ub="random-employee-department-output-map-id",pb="random-employee-manager-output-map-id",yb="manager-global-id-output-map-id",hb="global-user-instance-id-output-map-id",xF="employee-mapped-dto-requester-id-input-map-id",fb="employee-mapped-dto-now-timestamp-input-map-id",kF="employee-mapped-dto-id-input-map-id",jF="employee-mapped-dto-birth-date-input-map-id",qF="employee-mapped-dto-department-input-map-id",JF="employee-mapped-dto-manager-input-map-id",WF={type:r.GenericReference,id:"employee-mapped-dto-manager-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:yb},HF={type:r.GenericReference,id:"employee-mapped-dto-manager-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:lr},mb={id:JF,type:r.InputMap,version:1,declaration:null,name:"manager_id",description:null,defaultValue:null,index:4,readsValue:WF,parent:HF},YF={type:r.GenericReference,id:"employee-mapped-dto-department-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:ub},zF={type:r.GenericReference,id:"employee-mapped-dto-department-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:lr},Tb={id:qF,type:r.InputMap,version:1,declaration:null,name:"department_name",description:null,defaultValue:null,index:3,readsValue:YF,parent:zF},ZF={type:r.GenericReference,id:"employee-mapped-dto-birth-date-input-map-reads-value-ref-id",entityType:r.OutputMap,entityId:db},XF={type:r.GenericReference,id:"employee-mapped-dto-birth-date-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:lr},Eb={id:jF,type:r.InputMap,version:1,declaration:null,name:"birth_date",description:null,defaultValue:null,index:2,readsValue:ZF,parent:XF},QF={type:r.GenericReference,id:"employee-mapped-dto-id-output-map-reads-value-ref-id",entityType:r.OutputMap,entityId:cb},KF={type:r.GenericReference,id:"employee-mapped-dto-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:lr},Rb={id:kF,type:r.InputMap,version:1,declaration:null,name:"id",description:"The ID of the employee",defaultValue:null,index:1,readsValue:QF,parent:KF},e4={type:r.GenericReference,id:"employee-mapped-dto-requester-id-output-map-reads-value-ref-id",entityType:r.OutputMap,entityId:hb},t4={type:r.GenericReference,id:"employee-mapped-dto-requester-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:lr},bb={id:xF,type:r.InputMap,version:1,declaration:null,name:"requester_id",description:"The ID of the current user making the request",defaultValue:null,index:0,readsValue:e4,parent:t4},n4={type:r.GenericReference,id:"manager-variable-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:sc},r4={id:yb,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[mb],parent:n4},i4={type:r.GenericReference,id:"manager-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:sc},a4={like:!1,id:"manager-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ct,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:i4,defaultValue:null},s4={type:r.GenericReference,id:"manager-variable-reads-value-ref-id",entityType:r.OutputMap,entityId:pb},o4={type:r.GenericReference,id:"manager-variable-parent-ref-id",entityType:r.Project,entityId:Z},gb={id:sc,type:r.VariableDeclaration,version:1,name:"Manager",dataType:a4,description:"A variable holding an inherited manager for testing purposes",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],readsValue:s4,writesValues:[],inputs:[],outputs:[r4],internalCalls:[],parent:o4,x:0,y:0},l4={type:r.GenericReference,id:"random-company-employee-manager-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:ei},c4={id:pb,type:r.OutputMap,version:1,declaration:Ct.properties[2],index:3,writesValues:[gb],parent:l4},d4={type:r.GenericReference,id:"random-company-employee-department-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:ei},u4={id:ub,type:r.OutputMap,version:1,declaration:Ct.properties[0],index:2,writesValues:[Tb],parent:d4},p4={type:r.GenericReference,id:"random-company-employee-birth-date-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:ei},y4={id:db,type:r.OutputMap,version:1,declaration:pt.properties[1],index:1,writesValues:[Eb],parent:p4},h4={type:r.GenericReference,id:"random-company-employee-id-output-map-parent-ref-id",entityType:r.VariableDeclaration,entityId:ei},f4={id:cb,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[Rb],parent:h4},m4={type:r.GenericReference,id:"random-company-employee-test-variable-data-type-parent-ref-id",entityType:r.VariableDeclaration,entityId:ei},T4={like:!1,id:"random-company-employee-test-variable-data-type-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,version:1,entity:Ct,asType:!1,isList:!1,isNullable:!0,constant:!1,parent:m4,defaultValue:null},E4={type:r.GenericReference,id:"random-company-employee-test-variable-parent-ref-id",entityType:r.Project,entityId:Z},R4={id:ei,type:r.VariableDeclaration,version:1,name:"Company employee",dataType:T4,description:"A variable holding a random company employee for testing purposes",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],readsValue:null,writesValues:[],inputs:[],outputs:[f4,y4,u4,c4],internalCalls:[],parent:E4,x:0,y:0},b4={type:r.GenericReference,id:"employee-mapped-dto-variable-instance-now-timestamp-input-map-default-value-parent-ref-id",entityType:r.InputMap,entityId:fb},g4={type:r.PrimitiveValue,id:"employee-mapped-dto-variable-instance-now-timestamp-input-map-default-value-id",name:A.Date,version:1,valueAsType:null,value:null,autogeneration:{type:qe.CurrentDateAndTime,rangeStart:null,rangeEnd:null},parent:b4},v4={type:r.GenericReference,id:"employee-mapped-dto-variable-instance-now-timestamp-input-map-parent-ref-id",entityType:r.VariableInstance,entityId:oc},I4={id:fb,type:r.InputMap,version:1,declaration:null,name:"now",description:"The current timestamp when the operation is executed",defaultValue:g4,index:5,readsValue:null,parent:v4},D4={type:r.GenericReference,id:"employee-mapped-dto-variable-instance-decl-ref-id",entityType:r.VariableDeclaration,entityId:lr},P4={type:r.GenericReference,id:"employee-mapped-dto-variable-instance-called-by-success-ref-id",entityType:r.VariableDeclaration,entityId:oc},A4={type:r.GenericReference,id:"employee-mapped-dto-variable-instance-parent-ref-id",entityType:r.Project,entityId:Z},S4={id:oc,type:r.VariableInstance,version:1,declaration:D4,calledByError:[],calledByEntry:[],calledBySuccess:[P4],successCalls:[],errorCalls:[],readsValue:null,writesValues:[],inputs:[I4],outputs:[],internalCalls:[],parent:A4,x:0,y:0},O4={type:r.GenericReference,id:"employee-mapped-dto-variable-parent-ref-id",entityType:r.Project,entityId:Z},C4={id:lr,type:r.VariableDeclaration,version:1,name:"Employee DTO",dataType:null,description:"A variable holding the data of a mapped employee DTO",calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[S4],errorCalls:[],readsValue:null,writesValues:[],inputs:[bb,Rb,Eb,Tb,mb],outputs:[],internalCalls:[],parent:O4,x:0,y:0},B4={type:r.GenericReference,id:"0e63e617-f9d3-42e8-bde0-1bb0b1df7034",entityType:r.VariableDeclaration,entityId:Dl},w4={like:!1,id:"e75645ce-d3df-4f07-a897-ae9ef4d917fd",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:Al,version:1,asType:!1,isList:!1,isNullable:!1,constant:!1,parent:B4,defaultValue:null},_4={type:r.GenericReference,id:"e92a8ff5-3fef-4e0c-8d8f-92c930b2890b",entityType:r.Project,entityId:Z},vb={id:Dl,type:r.VariableDeclaration,version:1,name:"Current user",description:"The user that is currently logged in",dataType:w4,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],x:0,y:0,readsValue:null,writesValues:[],internalCalls:[],parent:_4},M4={type:r.GenericReference,id:"manager-variable-id-output-map-parent-ref-id",entityType:r.VariableInstance,entityId:lb},N4={id:hb,type:r.OutputMap,version:1,declaration:Le.properties[1],index:0,writesValues:[bb],parent:M4},V4={type:r.GenericReference,id:"global-user-instance-parent-ref-id",entityType:r.Project,entityId:Z},$4={id:lb,type:r.VariableInstance,version:1,declaration:vb,calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],readsValue:null,writesValues:[],inputs:[],outputs:[N4],internalCalls:[],parent:V4,x:0,y:0},L4={type:r.GenericReference,id:"is-test-environment-variable-dcl-datatype-parent-ref-id",entityType:r.VariableDeclaration,entityId:Dl},G4={type:r.GenericReference,id:"is-test-environment-variable-dcl-datatype-default-value-parent-ref-id",entityType:r.DataType,entityId:"is-test-environment-variable-dcl-datatype-id"},F4={like:!1,id:"is-test-environment-variable-dcl-datatype-id",type:r.DataType,andChildrenGroup:null,orChildrenGroup:null,entity:An,version:1,asType:!1,isList:!1,isNullable:!1,constant:!0,parent:L4,defaultValue:{id:"is-test-environment-variable-dcl-datatype-default-value-id",name:A.Boolean,version:1,value:null,type:r.PrimitiveValue,autogeneration:{type:qe.Random,rangeStart:null,rangeEnd:null},valueAsType:null,parent:G4}},U4={type:r.GenericReference,id:"is-test-environment-variable-dcl-main-project-ref-id",entityType:r.Project,entityId:Z},Ib={id:"is-test-environment-variable-dcl-id",type:r.VariableDeclaration,version:1,name:"Is test envrioment",description:"Indicates whether the current environment is a test environment or not.",dataType:F4,inputs:[],outputs:[],calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],x:0,y:0,readsValue:null,writesValues:[],internalCalls:[],parent:U4},x4={type:r.GenericReference,id:"is-test-environment-variable-instance-parent-ref-id",entityType:r.Project,entityId:Z},k4={id:"is-test-environment-variable-instance-id",type:r.VariableInstance,version:1,declaration:Ib,calledByError:[],calledByEntry:[],calledBySuccess:[],successCalls:[],errorCalls:[],readsValue:null,writesValues:[],inputs:[],outputs:[],internalCalls:[],parent:x4,x:0,y:0},Db={type:r.Project,id:Z,version:1,name:"Mocked project to compile",description:"This project is used to test all sorts of features and edge cases. It is not meant to be used in production. Or to have any functionality that makes sense",projects:[DF],entities:[Pl,Al,pt,C_,Ct,gs,NT,VT,Yr,Iw,gt,E_,TT,yA,gw],functions:[W$,oE,Jl,eL,lL,IE,Wl,wl,RF,qT,ZL],events:[lM],variableDeclarations:[Ib,vb,Xl,R4,gb,C4],variableInstances:[k4,$4],conditions:[],operations:[Xr],functionCalls:[sN,h0],loops:[NF],searches:[UF]};var T=(n=>(n.Error="error",n.Warning="warning",n))(T||{}),D=(n=>(n.InvalidObjectStructure="invalid-object-structure",n.NameNotUniqueInScope="name-not-unique-in-scope",n.EmptyName="empty-name",n.MissingCaller="missing-caller",n.PropertyOverwrite="property-overwrite",n.MethodOverwrite="method-overwrite",n.NoOverlapWithImplementedSignature="no-overlap-with-implemented-signature",n.ReaderWriterIncompatibleDataType="reader-writer-incompatible-data-type",n.UnreachableEntity="unreachable-entity",n.InternalCallParentMissingDataType="internal-call-parent-missing-data-type",n.InternalCallParentDeclarationEntityInvalidType="internal-call-parent-declaration-entity-invalid-type",n.InternalCallDeclarationNotFoundInParentDatatypeEntity="internal-call-declaration-not-found-in-parent-datatype-entity",n.InternalCallDeclarationIsNotFunctionDeclaration="internal-call-declaration-is-not-function-declaration",n.InternalCallDeclarationNotInParentDatatypeEntity="internal-call-declaration-not-in-parent-datatype-entity",n))(D||{}),h=(n=>(n.RootReference="root-reference",n.ReferencedEntityNotFound="referenced-entity-not-found",n.EntityIdNotUnique="entity-id-not-unique",n.BuiltInEntityGenerated="built-in-entity-generated",n.BuiltInEntityUpdated="built-in-entity-updated",n.BuiltInEntityDeleted="built-in-entity-deleted",n.UnknownEntityType="unknown-entity-type",n.MissingTypeProperty="missing-type-property",n.MissingIdProperty="missing-id-property",n.BuiltInEntityParent="built-in-entity-parent",n.InvalidBuiltInEntityReference="invalid-built-in-entity-reference",n.RecommendedImplementAbstractEntityAction="recommended-implement-abstract-entity-action",n.RecommendedImplementOperationAction="recommended-implement-operation-action",n.RecommendedImplementFunctionCallAction="recommended-implement-function-call-action",n.RecommendedImplementVariableDeclarationAction="recommended-implement-variable-declaration-action",n.RecommendedImplementVariableInstanceAction="recommended-implement-variable-instance-action",n.RecommendedImplementConditionAction="recommended-implement-condition-action",n.InvalidReferenceObjectStructure="invalid-reference-object-structure",n.ContainsSingleButShouldBeReferenceList="contains-single-but-should-be-reference-list",n.ContainsListButShouldReferenceSingle="contains-list-but-should-reference-single",n.InvalidParentReference="invalid-parent-reference",n.InvalidImplementsReference="invalid-implements-reference",n.InvalidExtendsReference="invalid-extends-reference",n.InvalidGenerationActionPayload="invalid-generation-action-payload",n.InvalidReference="invalid-reference",n.InvalidInternalCallParentRelation="invalid-internal-call-parent-relation",n.InvalidUpdateEntityOperation="invalid-update-entity-operation",n.NewEntityWouldOverriteExisting="new-entity-would-overrite-existing",n.InvalidDownstreamPropertyOverride="invalid-downstream-property-override",n.UnrecognizedProperty="unrecognized-property",n.SelfReference="self-reference",n.DuplicateReference="duplicate-reference",n.CallerWithIncompatibleScope="caller-with-incompatible-scope",n.InvalidFunctionDeclarationForFunctionCall="invalid-function-declaration-for-function-call",n.InvalidInputMapDeclaration="invalid-input-map-declaration",n.InvalidActionDescriptorForOperation="invalid-action-descriptor-for-operation",n.InvalidActionDescriptorForCondition="invalid-action-descriptor-for-condition",n.InvalidActionDescriptorForLoop="invalid-action-descriptor-for-loop",n.InvalidInmutablePropertyOverride="invalid-inmutable-property-override",n.OutputOverwrite="output-overwrite",n.InputOverwrite="input-overwrite",n.IncompatibleScope="incompatible-scope",n.InvalidParentUpdate="invalid-parent-update",n.NonInteractiveEntityReferenced="non-interactive-entity-referenced",n.InvalidParentRelationType="invalid-parent-relation-type",n))(h||{}),_=(n=>(n.ScopeWithoutLogic="scope-without-logic",n.ExtendingAbstractEntity="extending-abstract-entity",n.ImplementingNonAbstractEntity="implementing-non-abstract-entity",n.AbstractEntityWithNonAbstractMethods="abstract-entity-with-non-abstract-methods",n.AbstractEntityWithNonAbstractProperties="abstract-entity-with-non-abstract-properties",n.StaticEntityWithNonStaticProperties="static-entity-with-non-static-properties",n.NonStaticPropertyInStaticEntity="non-static-property-in-static-entity",n.AbstractPropertyInNonAbstractEntity="abstract-property-in-non-abstract-entity",n.AbstractMethodInNonAbstractEntity="abstract-method-in-non-abstract-entity",n.IncorrectEntityImplementation="incorrect-entity-implementation",n.IncorrectMethodImplementation="incorrect-method-implementation",n.IncorrectPropertyImplementation="incorrect-property-implementation",n.PropertyImplementsNonAbstact="property-implements-non-abstract",n.NonStaticPropertyImplementsStatic="non-static-property-implements-static",n.StaticPropertyImplementsNonStatic="static-property-implements-non-static",n.PropertyImplementsIncompatibleType="property-implements-incompatible-type",n.MissingPropertyImplementation="missing-property-implementation",n.MissingMethodImplementation="missing-method-implementation",n.NoProperties="no-properties",n.ReadingFromIncompatibleType="reading-from-incompatible-type",n.WritingToIncompatibleType="writing-to-incompatible-type",n.InvalidPropertiesCombination="invalid-properties-combination",n.DisconnectedCallableEntity="disconnected-callable-entity",n.VariableReadsValueAndInternalCall="variable-reads-value-and-internal-call",n.VariableWritesValuesAndInternalCall="variable-writes-values-and-internal-call",n.VariableHasInputsAndInternalCall="variable-has-inputs-and-internal-calls",n.VariableHasOutputsAndInternalCall="variable-has-outputs-and-internal-call",n.VariableIsCalledAndHasInternalCall="variable-is-called-and-has-internal-call",n.VariableCallsOthersAndHasInternalCall="variable-calls-others-and-has-internal-call",n))(_||{});class E{constructor(e){c(this,"id");c(this,"message");c(this,"issue");c(this,"severity");c(this,"code");this.id=e.id,this.message=e.message,this.issue=e.issue,this.severity=e.severity,this.code=e.code}toEntityError(e){return this.code in D?new cr({id:this.id,message:this.message,issue:this.issue,severity:this.severity,code:this.code,entity:e}):null}}class cr{constructor(e){c(this,"id");c(this,"message");c(this,"issue");c(this,"severity");c(this,"code");c(this,"entity");this.id=e.id,this.message=e.message,this.issue=e.issue,this.severity=e.severity,this.code=e.code,this.entity=e.entity}clone(){return new cr({id:this.id,message:this.message,issue:this.issue,severity:this.severity,code:this.code,entity:this.entity})}}function j4(n){const e=new Set;return n.filter(t=>e.has(t.id)?!1:(e.add(t.id),!0))}function H(n){const e=n.entity.errors.find(i=>i.id===n.id);return e?{new:!1,error:e}:{new:!0,error:new cr(n)}}function q4(n,e){const t=new Map;return n.forEach(i=>{t.set(i.id,i)}),e.forEach(i=>{t.set(i.id,i)}),Array.from(t.values())}function ne(n,e){const t=[];return e.forEach(i=>{const a=n.find(s=>s.id===i.id);a?t.push(a):t.push(i)}),t}const ra=d.union([d.string(),d.number(),d.boolean(),d.date()]),Pb=d.enum([qe.CurrentDateAndTime,qe.Random,qe.Unique]),ws=d.object({type:Pb,rangeStart:ra.nullable(),rangeEnd:ra.nullable()}),ia=ws.extend({type:d.literal(qe.Random),rangeStart:ra,rangeEnd:ra}),lc=ws.extend({type:d.literal(qe.Unique),rangeStart:d.null(),rangeEnd:d.null()}),Ab=ws.extend({type:d.literal(qe.CurrentDateAndTime),rangeStart:d.null(),rangeEnd:d.null()}),_s=ia.extend({rangeStart:d.number().nullable(),rangeEnd:d.number().nullable()}),Sb=_s.extend({rangeStart:d.number(),rangeEnd:d.null()}),Ob=_s.extend({rangeStart:d.null(),rangeEnd:d.number()}),Cb=_s.extend({rangeStart:d.number(),rangeEnd:d.number()}),Ms=ia.extend({rangeStart:d.number().nullable(),rangeEnd:d.number().nullable()}),Bb=Ms.extend({rangeStart:d.number(),rangeEnd:d.null()}),wb=Ms.extend({rangeStart:d.null(),rangeEnd:d.number()}),_b=Ms.extend({rangeStart:d.number(),rangeEnd:d.number()}),Ns=ia.extend({rangeStart:d.date().nullable(),rangeEnd:d.date().nullable()}),Mb=Ns.extend({rangeStart:d.date(),rangeEnd:d.null()}),Nb=Ns.extend({rangeStart:d.null(),rangeEnd:d.date()}),Vb=Ns.extend({rangeStart:d.date(),rangeEnd:d.date()}),cc=ia.extend({rangeStart:d.null(),rangeEnd:d.null()}),dc=d.union([Bb,wb,_b]),uc=d.union([Sb,Ob,Cb]),pc=d.union([Mb,Nb,Vb,Ab]),yc=d.union([dc,uc,pc,lc,cc]);function aa(){return d.union([d.object({type:d.literal(r.ValueDescriptor)}),d.record(d.string(),d.any())])}function $b(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ValueDescriptor)})}function hc(){return d.object({id:d.string(),type:d.literal(r.ValueDescriptor),name:d.string(),required:d.boolean()})}function J4(){return hc().merge(d.object({version:d.number(),index:d.number()}))}function W4(){return hc().merge(d.object({}))}function H4(){return d.object({dataType:mn(),parent:Gn()})}function Y4(){return J4().merge(H4())}function Vs(){return d.union([d.object({type:d.literal(r.PrimitiveEntity)}),d.record(d.string(),d.any())])}function $s(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.PrimitiveEntity)})}function Ls(){return d.object({id:d.string(),type:d.literal(r.PrimitiveEntity),name:d.string(),description:d.string().nullable(),static:d.boolean(),abstract:d.boolean()})}function z4(){return Ls().merge(d.object({version:d.number()}))}function Z4(){return Ls().merge(d.object({}))}function X4(){return d.object({properties:d.array(dr()),methods:d.array(Bt()),abstractMethods:d.array(tn()),extends:d.array(d.union([Vs(),ti()]))})}function Q4(){return z4().merge(X4())}function dr(){return d.union([d.object({type:d.literal(r.Property)}),d.record(d.string(),d.any())])}function Lb(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.Property)})}function fc(){return d.object({id:d.string(),type:d.literal(r.Property),name:d.string(),description:d.string().nullable(),private:d.boolean(),static:d.boolean(),required:d.boolean(),abstract:d.boolean()})}function K4(){return fc().merge(d.object({version:d.number(),index:d.number()}))}function eU(){return fc().merge(d.object({}))}function tU(){return d.object({dataType:mn(),implements:dr().nullable(),parent:d.union([hr(),$s(),Gs()])})}function nU(){return K4().merge(tU())}function rU(){return d.enum([V.CRON_JOB,V.EXECUTION,V.HTTP_ENDPOINT,V.PERSISTED_ENTITY,V.RELATIONAL_DATABASE])}function ti(){return d.union([d.object({type:d.literal(r.BuiltInBaseEntity)}),d.record(d.string(),d.any())])}function Gs(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.BuiltInBaseEntity)})}function mc(){return d.object({id:d.string(),version:d.number(),type:d.literal(r.BuiltInBaseEntity),name:rU(),description:d.string().nullable(),abstract:d.boolean(),static:d.boolean()})}function iU(){return mc()}function aU(){return mc().merge(d.object({}))}function sU(){return d.object({properties:d.array(dr()),methods:d.array(Bt()),abstractMethods:d.array(tn()),extends:d.array(d.union([ti(),Vs()]))})}function oU(){return iU().merge(sU())}function Gb(){return d.enum([U.Dynamic,U.Fixed,U.None])}function tn(){return d.union([d.object({type:d.literal(r.ActionDescriptor)}),d.record(d.string(),d.any())])}function Gn(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ActionDescriptor)})}function Fs(){return d.object({id:d.string(),type:d.literal(r.ActionDescriptor),name:d.string(),description:d.string().nullable(),argumentsType:Gb(),returnsType:Gb()})}function lU(){return Fs().merge(d.object({version:d.number()}))}function cU(){return Fs().merge(d.object({}))}function dU(){return d.object({fixedArguments:d.array(aa()),fixedReturns:d.array(aa()),dynamicArgumentTypes:mn().nullable(),dynamicReturnTypes:mn().nullable(),parent:d.union([vt(),hr(),Gs(),$s()]).nullable()})}function Fb(){return lU().merge(dU())}function ni(){return d.union([d.object({type:d.literal(r.Loop)}),d.record(d.string(),d.any())])}function nn(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.Loop)})}function Ub(){return d.object({id:d.string(),type:d.literal(r.Loop)})}function uU(){return Ub().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function pU(){return Ub().merge(d.object({declaration:d.union([d.string(),Bt()])}))}function yU(){return d.object({calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),declaration:tn(),inputs:d.array(Jt()),outputs:d.array(ft()),outputsDeclarations:d.array(aa()),successCalls:d.array(We()),errorCalls:d.array(We()),error:ft(),body:Bt(),parent:d.union([En(),vt()]),breakStatements:d.array(si()),continueStatements:d.array(ri())})}function hU(){return uU().merge(yU())}function ri(){return d.union([d.object({type:d.literal(r.ContinueStatement)}),d.record(d.string(),d.any())])}function ii(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ContinueStatement)})}function Tc(){return d.object({id:d.string(),type:d.literal(r.ContinueStatement)})}function fU(){return Tc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function mU(){return Tc().merge(d.object({}))}function TU(){return d.object({calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),outputs:d.array(hn()),throws:d.optional(hn()),parent:nn()})}function EU(){return fU().merge(TU())}function ur(){return d.union([d.object({type:d.literal(r.ReturnStatement)}),d.record(d.string(),d.any())])}function ai(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ReturnStatement)})}function Ec(){return d.object({id:d.string(),type:d.literal(r.ReturnStatement)})}function RU(){return Ec().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function bU(){return Ec().merge(d.object({}))}function gU(){return d.object({calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),outputs:d.array(hn()),throws:d.optional(hn()),parent:En()})}function vU(){return RU().merge(gU())}function hn(){return d.union([d.object({type:d.literal(r.ReturnDeclaration)}),d.record(d.string(),d.any())])}function xb(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ReturnDeclaration)})}function Rc(){return d.object({id:d.string(),type:d.literal(r.ReturnDeclaration),name:d.string(),description:d.string().nullable(),isError:d.boolean()})}function IU(){return Rc().merge(d.object({version:d.number(),index:d.number()}))}function DU(){return Rc().merge(d.object({}))}function PU(){return d.object({dataType:mn().nullable(),readsValue:ua().nullable(),parent:d.union([ai(),Gn(),fn(),ii()])})}function AU(){return IU().merge(PU())}function si(){return d.union([d.object({type:d.literal(r.BreakStatement)}),d.record(d.string(),d.any())])}function fn(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.BreakStatement)})}function bc(){return d.object({id:d.string(),type:d.literal(r.BreakStatement)})}function SU(){return bc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function OU(){return bc().merge(d.object({}))}function CU(){return d.object({calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),outputs:d.array(hn()),throws:d.optional(hn()),parent:nn()})}function BU(){return SU().merge(CU())}function ft(){return d.union([d.object({type:d.literal(r.OutputMap)}),d.record(d.string(),d.any())])}function gc(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.OutputMap)})}function vc(){return d.object({id:d.string(),type:d.literal(r.OutputMap)})}function wU(){return vc().merge(d.object({version:d.number(),index:d.number()}))}function _U(){return vc().merge(d.object({}))}function MU(){return d.object({writesValues:d.array(Tn()),declaration:d.union([hn(),dr()]),parent:d.union([de(),nn(),fn()])})}function NU(){return wU().merge(MU())}function oi(){return d.union([d.object({type:d.literal(r.FunctionCall)}),d.record(d.string(),d.any())])}function sa(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.FunctionCall)})}function Ic(){return d.object({id:d.string(),type:d.literal(r.FunctionCall)})}function VU(){return Ic().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function $U(){return Ic().merge(d.object({}))}function LU(){return d.object({successCalls:d.array(We()),errorCalls:d.array(We()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),writesValues:d.array(Tn()),declaration:Bt(),inputs:d.array(Jt()),outputs:d.array(ft()),error:d.optional(ft()),parent:d.union([En(),vt()])})}function GU(){return VU().merge(LU())}function FU(){return d.enum([_e.Equal,_e.NotEqual,_e.MoreThan,_e.MoreThanOrEqual,_e.LessThan,_e.LessThanOrEqual,_e.And,_e.Or,Nt.Empty,Nt.NotEmpty])}function oa(){return d.union([d.object({type:d.literal(r.Condition)}),d.record(d.string(),d.any())])}function Us(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.Condition)})}function Dc(){return d.object({id:d.string(),type:d.literal(r.Condition)})}function UU(){return Dc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function xU(){return Dc().merge(d.object({}))}function kU(){return d.object({successCalls:d.array(We()),errorCalls:d.array(We()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),leftValue:Jt(),rightValue:Jt().nullable(),operator:FU(),parent:d.union([En(),vt()])})}function jU(){return UU().merge(kU())}function la(){return d.union([d.object({type:d.literal(r.Search)}),d.record(d.string(),d.any())])}function ca(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.Search)})}function Pc(){return d.object({id:d.string(),type:d.literal(r.Search),name:d.string(),query:d.any(),description:d.string().nullable()})}function qU(){return Pc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function JU(){return Pc().merge(d.object({}))}function WU(){return d.object({successCalls:d.array(We()),errorCalls:d.array(We()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),inputsDeclarations:d.array(yr()),inputs:d.array(Jt()),outputsDeclarations:d.array(aa()),outputs:d.array(ft()),parent:d.union([En(),vt()]),error:ft().nullable()})}function HU(){return qU().merge(WU())}function da(){return d.union([d.object({type:d.literal(r.InternalCall)}),d.record(d.string(),d.any())])}function Ac(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.InternalCall)})}function Sc(){return d.object({id:d.string(),type:d.literal(r.InternalCall),index:d.number()})}function YU(){return Sc().merge(d.object({version:d.number(),index:d.number()}))}function zU(){return Sc().merge(d.object({declaration:d.union([d.string(),Bt()])}))}function ZU(){return d.object({successCalls:d.array(We()),errorCalls:d.array(We()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),writesValues:d.array(Tn()),declaration:Bt(),inputs:d.array(Jt()),outputs:d.array(ft()),parent:Fn(),error:d.optional(ft())})}function XU(){return YU().merge(ZU())}function Jt(){return d.union([d.object({type:d.literal(r.InputMap)}),d.record(d.string(),d.any())])}function xs(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.InputMap)})}function Oc(){return d.object({id:d.string(),type:d.literal(r.InputMap),name:d.string().nullable().optional(),description:d.string().nullable().optional()})}function QU(){return Oc().merge(d.object({version:d.number(),index:d.number()}))}function KU(){return Oc().merge(d.object({}))}function ex(){return d.object({defaultValue:Cc().nullable(),declaration:d.union([yr(),dr()]).nullable(),readsValue:ua().nullable(),parent:d.union([de(),xs(),nn(),fn()])})}function tx(){return QU().merge(ex())}function li(){return d.union([d.object({type:d.literal(r.Operation)}),d.record(d.string(),d.any())])}function ci(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.Operation)})}function ks(){return d.object({id:d.string(),type:d.literal(r.Operation)})}function nx(){return ks().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function rx(){return ks().merge(d.object({}))}function ix(){return ks().merge(d.object({successCalls:d.array(We()),errorCalls:d.array(We()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),writesValues:d.array(Tn()),declaration:tn(),inputs:d.array(Jt()),outputs:d.array(ft()),error:d.array(ft()),parent:d.union([En(),vt()])}))}function ax(){return nx().merge(ix())}function js(){return d.union([d.string(),d.number(),d.boolean(),d.null(),d.date()])}function kb(){return d.record(d.string(),js())}function sx(){return d.array(d.union([js(),kb()]))}function jb(){return d.union([js(),kb(),sx()])}function qb(){return d.union([js(),jb()])}function Jb(){return d.enum([A.String,A.Number,A.Boolean,A.Null,A.Date,A.JSON,A.Enum,A.File,A.UUID,A.EntityTemplate,A.ActionDescriptor])}function ox(){return d.union([hr(),ci(),pa()])}function lx(){return d.object({id:d.string(),name:Jb(),type:d.literal(r.PrimitiveValue),value:qb(),autogeneration:yc.nullable()})}function cx(){return lx().merge(d.object({}))}function Wt(){return d.object({id:d.string(),version:d.number(),name:Jb(),type:d.literal(r.PrimitiveValue),value:qb(),valueAsType:ox().nullable(),autogeneration:yc.nullable(),parent:d.union([Bc(),xs()])})}function dx(){return Wt().extend({name:d.literal(A.String),value:d.string(),autogeneration:dc.nullable()})}function ux(){return Wt().extend({name:d.literal(A.Number),value:d.number(),autogeneration:uc.nullable()})}function px(){return Wt().extend({name:d.literal(A.Boolean),value:d.boolean(),autogeneration:cc.nullable()})}function yx(){return Wt().extend({name:d.literal(A.Null),value:d.null(),autogeneration:d.null()})}function hx(){return Wt().extend({name:d.literal(A.Date),value:d.date(),autogeneration:pc.nullable()})}function fx(){return Wt().extend({name:d.literal(A.JSON),value:jb(),autogeneration:d.null()})}function mx(){return Wt().extend({name:d.literal(A.Enum),value:d.string(),autogeneration:d.null()})}function Tx(){return Wt().extend({name:d.literal(A.File),value:d.string(),autogeneration:d.null()})}function Ex(){return Wt().extend({name:d.literal(A.UUID),value:d.string(),autogeneration:lc.nullable()})}function Rx(){return Wt().extend({name:d.literal(A.EntityTemplate),value:hr(),autogeneration:d.null()})}function bx(){return Wt().extend({name:d.literal(A.ActionDescriptor),value:pa(),autogeneration:d.null()})}function Cc(){return d.union([dx(),ux(),px(),yx(),hx(),fx(),mx(),Tx(),Ex(),Rx(),bx()])}function mn(){return d.union([d.object({type:d.literal(r.DataType)}),d.record(d.string(),d.any())])}function Bc(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.DataType)})}function wc(){return d.object({id:d.string(),type:d.literal(r.DataType),isNullable:d.boolean(),isList:d.boolean(),constant:d.boolean(),asType:d.boolean(),options:d.array(d.string()).optional()})}function gx(){return wc().merge(d.object({version:d.number()}))}function vx(){return wc().merge(d.object({}))}function Ix(){return d.object({defaultValue:Cc().nullable(),entity:d.union([di(),ti(),Vs(),tn()]).nullable(),parent:d.union([Lb(),Yb(),Gn(),$b()])})}function Dx(){return gx().merge(Ix())}function _c(){return d.union([d.object({type:d.literal(r.VariableDeclaration)}),d.record(d.string(),d.any())])}function Px(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.VariableDeclaration)})}function Mc(){return d.object({id:d.string(),type:d.literal(r.VariableDeclaration),name:d.string(),description:d.string().nullable()})}function Ax(){return Mc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function Sx(){return Mc().merge(d.object({}))}function Ox(){return d.object({dataType:mn().nullable(),readsValue:ua().nullable(),writesValues:d.array(Tn()),inputs:d.array(Jt()),outputs:d.array(ft()),successCalls:d.array(We()),errorCalls:d.array(We()),internalCalls:d.array(da()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),parent:d.union([En(),vt()])})}function Cx(){return Ax().merge(Ox())}function Wb(){return d.union([d.object({type:d.literal(r.VariableInstance)}),d.record(d.string(),d.any())])}function Bx(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.VariableInstance)})}function Nc(){return d.object({id:d.string(),type:d.literal(r.VariableInstance)})}function wx(){return Nc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function _x(){return Nc().merge(d.object({}))}function Mx(){return d.object({declaration:_c(),dataType:mn().nullable(),readsValue:ua().nullable(),writesValues:d.array(Tn()),inputs:d.array(Jt()),outputs:d.array(ft()),successCalls:d.array(We()),errorCalls:d.array(We()),internalCalls:d.array(da()),calledBySuccess:d.array(de()),calledByError:d.array(de()),calledByEntry:d.array(Je()),parent:d.union([En(),vt()])})}function Nx(){return wx().merge(Mx())}function Vc(){return d.union([d.object({type:d.literal(r.InstalledProject)}),d.record(d.string(),d.any())])}function qs(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.InstalledProject)})}function Vx(){return d.object({id:d.string(),type:d.literal(r.InstalledProject)})}function $x(){return d.object({version:d.number(),x:d.number(),y:d.number()})}function Lx(){return d.object({})}function Gx(){return d.object({implements:vt(),description:d.string().nullable(),functions:d.array(Bt()),events:d.array($c()),parent:vt()})}function Fx(){return $x().merge(Gx())}function $c(){return d.union([d.object({type:d.literal(r.GlobalEvent)}),d.record(d.string(),d.any())])}function Ux(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.GlobalEvent)})}function Js(){return d.object({id:d.string(),type:d.literal(r.GlobalEvent),name:d.string(),collapsed:d.boolean()})}function xx(){return Js().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function kx(){return Js().merge(d.object({}))}function jx(){return Js().merge(d.object({returnStatements:d.array(ur()),implements:d.array(Fb()),inputs:d.array(yr()),calls:d.array(We()),parent:d.union([vt(),qs()])}))}function qx(){return xx().merge(jx())}function pr(){return d.union([_c(),Wb()])}function Fn(){return d.union([Px(),Bx()])}function Tn(){return d.union([pr(),Jt(),hn()])}function Hb(){return d.union([Fn(),xs(),xb()])}function ua(){return d.union([pr(),yr(),ft(),li(),da(),oi()])}function Jx(){return d.union([Fn(),Lc(),gc(),ci(),Ac(),sa()])}function Wx(){return d.union([yr(),ft(),Tn()])}function Yb(){return d.union([Lc(),gc(),Hb()])}function Ws(){return $c()}function Hs(){return Ux()}function Ys(){return d.union([li(),oi(),oa(),la(),pr(),da(),ni()])}function de(){return d.union([ci(),sa(),Us(),ca(),Fn(),Ac(),nn()])}function zs(){return d.union([li(),oi(),oa(),la(),pr(),ni()])}function Zs(){return d.union([ci(),sa(),Us(),ca(),Fn(),nn()])}function zb(){return d.union([Ys(),ur(),si(),ri()])}function We(){return d.union([de(),ai(),fn(),ii()])}function Zb(){return d.union([zs(),ur(),si(),ri()])}function Xb(){return d.union([Zs(),ai(),fn(),ii()])}function Un(){return d.union([Bt(),Ws()])}function Je(){return d.union([pa(),Hs()])}function Hx(){return d.union([Ys(),Un()])}function Yx(){return d.union([de(),Je()])}function zx(){return d.union([zs(),Un()])}function Zx(){return d.union([Zs(),Je()])}function Xx(){return d.union([zb(),Un()])}function Qx(){return d.union([We(),Je()])}function Kx(){return d.union([Zb(),Un()])}function e8(){return d.union([Xb(),Je()])}function t8(){return d.union([Un(),ni()])}function En(){return d.union([Je(),nn()])}function n8(){return d.union([Ys(),Un()])}function r8(){return d.union([de(),Je()])}function i8(){return d.union([zs(),Un()])}function a8(){return d.union([Zs(),Je()])}function s8(){return d.union([ur(),si(),ri()])}function o8(){return d.union([ai(),fn(),ii()])}function l8(){return d.union([ti(),b8(),Vc(),di(),Bt(),Ws(),pr(),Jt(),ft(),oa(),li(),oi(),hn(),yr(),Vs(),mn(),dr(),tn(),ur(),ri(),si(),ni(),la(),tn(),tn(),aa(),da()])}function c8(){return d.union([Gs(),vt(),qs(),hr(),pa(),Hs(),Fn(),xs(),gc(),Us(),ci(),sa(),xb(),Lc(),$s(),Bc(),Lb(),Gn(),ai(),ii(),fn(),nn(),ca(),Gn(),Gn(),$b(),Ac()])}function d8(){return d.union([Vc(),di(),Bt(),Ws(),pr(),oa(),li(),oi(),ur(),ri(),si(),ni(),la()])}function u8(){return d.union([qs(),hr(),pa(),Hs(),Fn(),Us(),ci(),sa(),ai(),ii(),fn(),nn(),ca()])}function yr(){return d.union([d.object({type:d.literal(r.ArgumentDeclaration)}),d.record(d.string(),d.any())])}function Lc(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.ArgumentDeclaration)})}function Gc(){return d.object({id:d.string(),type:d.literal(r.ArgumentDeclaration)})}function p8(){return Gc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function y8(){return Gc().merge(d.object({}))}function h8(){return d.object({dataType:mn().nullable(),writesValues:d.array(Tn()),parent:d.union([Je(),Gn(),Gn(),ca(),fn()])})}function f8(){return p8().merge(h8())}function Bt(){return d.union([d.object({type:d.literal(r.FunctionDeclaration)}),d.record(d.string(),d.any())])}function pa(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.FunctionDeclaration)})}function Fc(){return d.object({id:d.string(),type:d.literal(r.FunctionDeclaration),name:d.string(),description:d.string().nullable()})}function m8(){return Fc().merge(d.object({version:d.number(),x:d.number(),y:d.number(),index:d.number().nullable()}))}function T8(){return Fc()}function E8(){return d.object({inputs:d.array(yr()),implements:tn().nullable(),returnStatements:d.array(ur()),parent:d.union([vt(),qs(),hr(),nn(),Gs(),$s()])})}function R8(){return m8().merge(E8())}function b8(){return d.union([d.object({type:d.literal(r.Project)}),d.record(d.string(),d.any())])}function vt(){return d.object({entityType:d.literal(r.Project),entityId:d.string(),id:d.string(),type:d.literal(r.GenericReference)})}function Uc(){return d.object({id:d.string(),type:d.literal(r.Project),name:d.string(),description:d.string().nullable()})}function g8(){return Uc().merge(d.object({version:d.number()}))}function v8(){return Uc()}function I8(){return d.object({entities:d.array(di()),functions:d.array(Bt()),events:d.array($c()),projects:d.array(Vc()),variableDeclarations:d.array(_c()),variableInstances:d.array(Wb()),conditions:d.array(oa()),operations:d.array(li()),functionCalls:d.array(oi()),loops:d.array(ni()),searches:d.array(la())})}function D8(){return g8().merge(I8())}function di(){return d.union([d.object({type:d.literal(r.CustomEntity)}),d.record(d.string(),d.any())])}function hr(){return d.object({id:d.string(),type:d.literal(r.GenericReference),entityId:d.string(),entityType:d.literal(r.CustomEntity)})}function xc(){return d.object({id:d.string(),type:d.literal(r.CustomEntity),name:d.string(),description:d.string().nullable(),static:d.boolean(),abstract:d.boolean()})}function P8(){return xc().merge(d.object({version:d.number(),x:d.number(),y:d.number()}))}function A8(){return xc().merge(d.object({}))}function S8(){return d.union([vt(),Bc()])}function O8(){return d.object({properties:d.array(dr()),methods:d.array(Bt()),abstractMethods:d.array(tn()),extends:d.array(d.union([di(),ti()])),implements:d.array(d.union([di(),ti()])),parent:S8()})}function C8(){return P8().merge(O8())}function B8(n){const e=C8(),t=n.toJSON();e.safeParse(t).success;const a=n.implements.flatMap(f=>M8(n,f)),s=n.extends.flatMap(f=>N8(n,f)),o=$8(n),l=V8(n);n.methods.flatMap(f=>f.validate());const p=[...a,...s,...o,...l];return ne(n.errors,p)}function w8(n,e){const t=e.properties.filter(s=>s.abstract),i=[];let a=[...n.properties];return t.forEach(s=>{const o=a.find(l=>{var p;return((p=l.implements)==null?void 0:p.id)===s.id});o?a=a.filter(l=>l.id!==o.id):i.push(s)}),i}function _8(n,e){const t=e.abstractMethods,i=[];let a=[...n.methods];return t.forEach(s=>{const o=a.find(l=>{var p;return((p=l.implements)==null?void 0:p.id)===s.id});o?a=a.filter(l=>l.id!==o.id):i.push(s)}),i}function M8(n,e){const t=[];if(!e.abstract){const f=H({id:n.id+"--"+_.ImplementingNonAbstractEntity,message:`Entity "${n.name}" with id "${n.id}" is implementing a non-abstract entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:_.ImplementingNonAbstractEntity,entity:n});return t.push(f.error),t}const i=e.properties.filter(f=>f.abstract),a=[];let s=[...n.properties];i.forEach(f=>{const m=s.find(b=>{var g;return((g=b.implements)==null?void 0:g.id)===f.id});m?s=s.filter(b=>b.id!==m.id):a.push(f)}),a.length&&a.forEach(f=>{const m=H({id:n.id+"--"+_.MissingPropertyImplementation+"--"+f.id,message:`Property "${f.name}" with id "${f.id}" of entity "${e.name}" with id "${e.id}" is not implemented when entity "${n.name}" with id "${n.id}" implements it`,issue:null,severity:T.Error,code:_.MissingPropertyImplementation,entity:n});t.push(m.error)});const o=[];let l=[...n.methods];e.abstractMethods.forEach(f=>{const m=l.find(b=>{var g;return((g=b.implements)==null?void 0:g.id)===f.id});m?l=l.filter(b=>b.id!==m.id):o.push(f)}),o.length&&o.forEach(f=>{const m=H({id:n.id+"--"+_.MissingMethodImplementation+"--"+f.id,message:`Method "${f.name}" with id "${f.id}" of entity "${e.name}" with id "${e.id}" is not implemented when entity "${n.name}" with id "${n.id}" implements it`,issue:null,severity:T.Error,code:_.MissingMethodImplementation,entity:n});t.push(m.error)});const p=[];e.properties.forEach(f=>{const m=s.find(b=>b.name===f.name);m&&p.push([m,f])}),p.length&&p.forEach(([f])=>{const m=H({id:n.id+"--"+D.PropertyOverwrite+"--"+f.id,message:`Property "${f.name}" with id "${f.id}" of entity "${n.name}" with id "${n.id}" overwrites the property with the same name from the base entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:D.PropertyOverwrite,entity:n});t.push(m.error)});const y=[];return e.methods.forEach(f=>{const m=l.find(b=>b.name===f.name);m&&y.push([m,f])}),y.length&&y.forEach(([f])=>{const m=H({id:n.id+"--"+D.MethodOverwrite+"--"+f.id,message:`Method "${f.name}" with id "${f.id}" of entity "${n.name}" with id "${n.id}" overwrites the method with the same name from the base entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:D.MethodOverwrite,entity:n});t.push(m.error)}),t}function N8(n,e){const t=[],i=[];if(e.abstract){const s=H({id:n.id+"--"+_.ExtendingAbstractEntity,message:`Entity "${n.name}" with id "${n.id}" is extending an abstract entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:_.ExtendingAbstractEntity,entity:n});return t.push(s.error),t}n.properties.forEach(s=>{var l;const o=e.properties.find(p=>p.name===s.name);((l=s.implements)==null?void 0:l.id)!==(o==null?void 0:o.id)&&o&&i.push(s)}),i.length&&i.forEach(s=>{const o=H({id:n.id+"--"+D.PropertyOverwrite,message:`Property "${s.name}" with id "${s.id}" of entity "${n.name}" with id "${n.id}" overwrites the property with the same name from the extended entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:D.PropertyOverwrite,entity:n});t.push(o.error)});const a=[];return n.methods.forEach(s=>{var l;const o=e.methods.find(p=>p.name===s.name);((l=s.implements)==null?void 0:l.id)!==(o==null?void 0:o.id)&&o&&a.push(s)}),a.length&&a.forEach(s=>{const o=H({id:n.id+"--"+D.MethodOverwrite,message:`Method "${s.name}" with id "${s.id}" of entity "${n.name}" with id "${n.id}" overwrites the method with the same name from the extended entity "${e.name}" with id "${e.id}"`,issue:null,severity:T.Error,code:D.MethodOverwrite,entity:n});t.push(o.error)}),t}function V8(n){const e=[];if(!n.properties.length){const t=H({id:n.id+"--"+_.NoProperties,message:"No properties implemented",issue:null,severity:T.Warning,code:_.NoProperties,entity:n});e.push(t.error)}return n.properties.forEach(t=>{t.validate()}),e}function $8(n){const e=[];if(n.abstract){if(n.methods.length){const t=H({id:n.id+"--"+_.AbstractEntityWithNonAbstractMethods,message:`Entity "${n.name}" with id "${n.id}" is marked as abstract but has non-abstract methods`,issue:null,severity:T.Error,code:_.AbstractEntityWithNonAbstractMethods,entity:n});e.push(t.error)}if(n.properties.some(t=>!t.abstract)){const t=H({id:n.id+"--"+_.AbstractEntityWithNonAbstractProperties,message:`Entity "${n.name}" with id "${n.id}" is marked as abstract but has non-abstract properties`,issue:null,severity:T.Error,code:_.AbstractEntityWithNonAbstractProperties,entity:n});e.push(t.error),n.properties.forEach(i=>{if(!i.abstract){const a=H({id:n.id+"--"+_.StaticEntityWithNonStaticProperties+"--"+i.id,message:`Property "${i.name}" with id "${i.id}" of entity "${n.name}" with id "${n.id}" is not marked as abstract but the entity is marked as abstract`,issue:null,severity:T.Error,code:_.StaticEntityWithNonStaticProperties,entity:n});e.push(a.error)}})}}else{if(n.abstractMethods.length){const t=H({id:n.id+"--"+_.AbstractPropertyInNonAbstractEntity,message:`Entity "${n.name}" with id "${n.id}" is not marked as abstract but has abstract methods`,issue:null,severity:T.Error,code:_.AbstractPropertyInNonAbstractEntity,entity:n});e.push(t.error)}if(n.properties.some(t=>t.abstract)){const t=H({id:n.id+"--"+_.AbstractMethodInNonAbstractEntity,message:`Entity "${n.name}" with id "${n.id}" is not marked as abstract but has abstract properties`,issue:null,severity:T.Error,code:_.AbstractMethodInNonAbstractEntity,entity:n});e.push(t.error),n.properties.forEach(i=>{if(i.abstract){const a=H({id:n.id+"--"+_.AbstractMethodInNonAbstractEntity+"--"+i.id,message:`Property "${i.name}" with id "${i.id}" of entity "${n.name}" with id "${n.id}" is marked as abstract but the entity is not marked as abstract`,issue:null,severity:T.Error,code:_.AbstractMethodInNonAbstractEntity,entity:n});e.push(a.error)}})}}if(n.static&&n.properties.some(t=>!t.static)){const t=H({id:n.id+"--"+_.StaticEntityWithNonStaticProperties,message:`Entity "${n.name}" with id "${n.id}" is marked as static but has non-static properties`,issue:null,severity:T.Error,code:_.StaticEntityWithNonStaticProperties,entity:n});e.push(t.error),n.properties.forEach(i=>{if(!i.static){const a=H({id:n.id+"--"+_.NonStaticPropertyInStaticEntity+"--"+i.id,message:`Property "${i.name}" with id "${i.id}" of entity "${n.name}" with id "${n.id}" is not marked as static but the entity is marked as static`,issue:null,severity:T.Error,code:_.NonStaticPropertyInStaticEntity,entity:n});e.push(a.error)}})}return e}function L8(n){return n instanceof Error&&n.name==="ZodError"&&"issues"in n&&Array.isArray(n.issues)}var G8=class extends Error{constructor(e,t){super(e,t);c(this,"name");c(this,"details");this.name="ZodValidationError",this.details=F8(t)}toString(){return this.message}};function F8(n){if(n){const e=n.cause;if(L8(e))return e.issues}return[]}var U8="; ",Qb="Validation error",x8=": ",k8=", or ";function j8(n,e,t){return e!==null?n.length>0?[e,n].join(t):e:n.length>0?n:Qb}var q8=/[$_\p{ID_Start}][$\u200c\u200d\p{ID_Continue}]*/u;function J8(n){return n.length===1?n[0].toString():n.reduce((e,t)=>{if(typeof t=="number")return e+"["+t.toString()+"]";if(t.includes('"'))return e+'["'+W8(t)+'"]';if(!q8.test(t))return e+'["'+t+'"]';const i=e.length===0?"":".";return e+i+t},"")}function W8(n){return n.replace(/"/g,'\\"')}function H8(n){return n.length!==0}function Xs(n){const{issue:e,issueSeparator:t,unionSeparator:i,includePath:a}=n;if(e.code==="invalid_union")return e.unionErrors.reduce((s,o)=>{const l=o.issues.map(p=>Xs({issue:p,issueSeparator:t,unionSeparator:i,includePath:a})).join(t);return s.includes(l)||s.push(l),s},[]).join(i);if(e.code==="invalid_arguments")return[e.message,...e.argumentsError.issues.map(s=>Xs({issue:s,issueSeparator:t,unionSeparator:i,includePath:a}))].join(t);if(e.code==="invalid_return_type")return[e.message,...e.returnTypeError.issues.map(s=>Xs({issue:s,issueSeparator:t,unionSeparator:i,includePath:a}))].join(t);if(a&&H8(e.path)){if(e.path.length===1){const s=e.path[0];if(typeof s=="number")return`${e.message} at index ${s}`}return`${e.message} at "${J8(e.path)}"`}return e.message}function Y8(n,e={}){const{issueSeparator:t=U8,unionSeparator:i=k8,prefixSeparator:a=x8,prefix:s=Qb,includePath:o=!0}=e,l=Xs({issue:n,issueSeparator:t,unionSeparator:i,includePath:o}),p=j8(l,s,a);return new G8(p,{cause:new bt([n])})}var Kb="1.13.7",eg=typeof self=="object"&&self.self===self&&self||typeof global=="object"&&global.global===global&&global||Function("return this")()||{},Qs=Array.prototype,kc=Object.prototype,tg=typeof Symbol<"u"?Symbol.prototype:null,z8=Qs.push,ya=Qs.slice,ha=kc.toString,Z8=kc.hasOwnProperty,ng=typeof ArrayBuffer<"u",X8=typeof DataView<"u",Q8=Array.isArray,rg=Object.keys,ig=Object.create,ag=ng&&ArrayBuffer.isView,K8=isNaN,e6=isFinite,sg=!{toString:null}.propertyIsEnumerable("toString"),og=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],t6=Math.pow(2,53)-1;function It(n,e){return e=e==null?n.length-1:+e,function(){for(var t=Math.max(arguments.length-e,0),i=Array(t),a=0;a<t;a++)i[a]=arguments[a+e];switch(e){case 0:return n.call(this,i);case 1:return n.call(this,arguments[0],i);case 2:return n.call(this,arguments[0],arguments[1],i)}var s=Array(e+1);for(a=0;a<e;a++)s[a]=arguments[a];return s[e]=i,n.apply(this,s)}}function xn(n){var e=typeof n;return e==="function"||e==="object"&&!!n}function n6(n){return n===null}function lg(n){return n===void 0}function cg(n){return n===!0||n===!1||ha.call(n)==="[object Boolean]"}function r6(n){return!!(n&&n.nodeType===1)}function st(n){var e="[object "+n+"]";return function(t){return ha.call(t)===e}}const jc=st("String"),dg=st("Number"),i6=st("Date"),a6=st("RegExp"),s6=st("Error"),ug=st("Symbol"),pg=st("ArrayBuffer");var yg=st("Function"),o6=eg.document&&eg.document.childNodes;typeof/./!="function"&&typeof Int8Array!="object"&&typeof o6!="function"&&(yg=function(n){return typeof n=="function"||!1});const mt=yg,hg=st("Object");var fg=X8&&(!/\[native code\]/.test(String(DataView))||hg(new DataView(new ArrayBuffer(8)))),qc=typeof Map<"u"&&hg(new Map),l6=st("DataView");function c6(n){return n!=null&&mt(n.getInt8)&&pg(n.buffer)}const Ks=fg?c6:l6,fr=Q8||st("Array");function kn(n,e){return n!=null&&Z8.call(n,e)}var Jc=st("Arguments");(function(){Jc(arguments)||(Jc=function(n){return kn(n,"callee")})})();const Wc=Jc;function d6(n){return!ug(n)&&e6(n)&&!isNaN(parseFloat(n))}function mg(n){return dg(n)&&K8(n)}function Tg(n){return function(){return n}}function Eg(n){return function(e){var t=n(e);return typeof t=="number"&&t>=0&&t<=t6}}function Rg(n){return function(e){return e==null?void 0:e[n]}}const eo=Rg("byteLength"),u6=Eg(eo);var p6=/\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/;function y6(n){return ag?ag(n)&&!Ks(n):u6(n)&&p6.test(ha.call(n))}const bg=ng?y6:Tg(!1),Dt=Rg("length");function h6(n){for(var e={},t=n.length,i=0;i<t;++i)e[n[i]]=!0;return{contains:function(a){return e[a]===!0},push:function(a){return e[a]=!0,n.push(a)}}}function gg(n,e){e=h6(e);var t=og.length,i=n.constructor,a=mt(i)&&i.prototype||kc,s="constructor";for(kn(n,s)&&!e.contains(s)&&e.push(s);t--;)s=og[t],s in n&&n[s]!==a[s]&&!e.contains(s)&&e.push(s)}function Ye(n){if(!xn(n))return[];if(rg)return rg(n);var e=[];for(var t in n)kn(n,t)&&e.push(t);return sg&&gg(n,e),e}function fa(n){if(n==null)return!0;var e=Dt(n);return typeof e=="number"&&(fr(n)||jc(n)||Wc(n))?e===0:Dt(Ye(n))===0}function vg(n,e){var t=Ye(e),i=t.length;if(n==null)return!i;for(var a=Object(n),s=0;s<i;s++){var o=t[s];if(e[o]!==a[o]||!(o in a))return!1}return!0}function re(n){if(n instanceof re)return n;if(!(this instanceof re))return new re(n);this._wrapped=n}re.VERSION=Kb,re.prototype.value=function(){return this._wrapped},re.prototype.valueOf=re.prototype.toJSON=re.prototype.value,re.prototype.toString=function(){return String(this._wrapped)};function Ig(n){return new Uint8Array(n.buffer||n,n.byteOffset||0,eo(n))}var Dg="[object DataView]";function Hc(n,e,t,i){if(n===e)return n!==0||1/n===1/e;if(n==null||e==null)return!1;if(n!==n)return e!==e;var a=typeof n;return a!=="function"&&a!=="object"&&typeof e!="object"?!1:Pg(n,e,t,i)}function Pg(n,e,t,i){n instanceof re&&(n=n._wrapped),e instanceof re&&(e=e._wrapped);var a=ha.call(n);if(a!==ha.call(e))return!1;if(fg&&a=="[object Object]"&&Ks(n)){if(!Ks(e))return!1;a=Dg}switch(a){case"[object RegExp]":case"[object String]":return""+n==""+e;case"[object Number]":return+n!=+n?+e!=+e:+n==0?1/+n===1/e:+n==+e;case"[object Date]":case"[object Boolean]":return+n==+e;case"[object Symbol]":return tg.valueOf.call(n)===tg.valueOf.call(e);case"[object ArrayBuffer]":case Dg:return Pg(Ig(n),Ig(e),t,i)}var s=a==="[object Array]";if(!s&&bg(n)){var o=eo(n);if(o!==eo(e))return!1;if(n.buffer===e.buffer&&n.byteOffset===e.byteOffset)return!0;s=!0}if(!s){if(typeof n!="object"||typeof e!="object")return!1;var l=n.constructor,p=e.constructor;if(l!==p&&!(mt(l)&&l instanceof l&&mt(p)&&p instanceof p)&&"constructor"in n&&"constructor"in e)return!1}t=t||[],i=i||[];for(var y=t.length;y--;)if(t[y]===n)return i[y]===e;if(t.push(n),i.push(e),s){if(y=n.length,y!==e.length)return!1;for(;y--;)if(!Hc(n[y],e[y],t,i))return!1}else{var f=Ye(n),m;if(y=f.length,Ye(e).length!==y)return!1;for(;y--;)if(m=f[y],!(kn(e,m)&&Hc(n[m],e[m],t,i)))return!1}return t.pop(),i.pop(),!0}function f6(n,e){return Hc(n,e)}function ma(n){if(!xn(n))return[];var e=[];for(var t in n)e.push(t);return sg&&gg(n,e),e}function Yc(n){var e=Dt(n);return function(t){if(t==null)return!1;var i=ma(t);if(Dt(i))return!1;for(var a=0;a<e;a++)if(!mt(t[n[a]]))return!1;return n!==Og||!mt(t[zc])}}var zc="forEach",Ag="has",Zc=["clear","delete"],Sg=["get",Ag,"set"],m6=Zc.concat(zc,Sg),Og=Zc.concat(Sg),T6=["add"].concat(Zc,zc,Ag);const E6=qc?Yc(m6):st("Map"),R6=qc?Yc(Og):st("WeakMap"),b6=qc?Yc(T6):st("Set"),g6=st("WeakSet");function ui(n){for(var e=Ye(n),t=e.length,i=Array(t),a=0;a<t;a++)i[a]=n[e[a]];return i}function v6(n){for(var e=Ye(n),t=e.length,i=Array(t),a=0;a<t;a++)i[a]=[e[a],n[e[a]]];return i}function Cg(n){for(var e={},t=Ye(n),i=0,a=t.length;i<a;i++)e[n[t[i]]]=t[i];return e}function Xc(n){var e=[];for(var t in n)mt(n[t])&&e.push(t);return e.sort()}function Qc(n,e){return function(t){var i=arguments.length;if(e&&(t=Object(t)),i<2||t==null)return t;for(var a=1;a<i;a++)for(var s=arguments[a],o=n(s),l=o.length,p=0;p<l;p++){var y=o[p];(!e||t[y]===void 0)&&(t[y]=s[y])}return t}}const Bg=Qc(ma),to=Qc(Ye),wg=Qc(ma,!0);function I6(){return function(){}}function _g(n){if(!xn(n))return{};if(ig)return ig(n);var e=I6();e.prototype=n;var t=new e;return e.prototype=null,t}function D6(n,e){var t=_g(n);return e&&to(t,e),t}function P6(n){return xn(n)?fr(n)?n.slice():Bg({},n):n}function A6(n,e){return e(n),n}function Mg(n){return fr(n)?n:[n]}re.toPath=Mg;function Ta(n){return re.toPath(n)}function Kc(n,e){for(var t=e.length,i=0;i<t;i++){if(n==null)return;n=n[e[i]]}return t?n:void 0}function Ng(n,e,t){var i=Kc(n,Ta(e));return lg(i)?t:i}function S6(n,e){e=Ta(e);for(var t=e.length,i=0;i<t;i++){var a=e[i];if(!kn(n,a))return!1;n=n[a]}return!!t}function ed(n){return n}function Ea(n){return n=to({},n),function(e){return vg(e,n)}}function td(n){return n=Ta(n),function(e){return Kc(e,n)}}function Ra(n,e,t){if(e===void 0)return n;switch(t??3){case 1:return function(i){return n.call(e,i)};case 3:return function(i,a,s){return n.call(e,i,a,s)};case 4:return function(i,a,s,o){return n.call(e,i,a,s,o)}}return function(){return n.apply(e,arguments)}}function Vg(n,e,t){return n==null?ed:mt(n)?Ra(n,e,t):xn(n)&&!fr(n)?Ea(n):td(n)}function nd(n,e){return Vg(n,e,1/0)}re.iteratee=nd;function Pt(n,e,t){return re.iteratee!==nd?re.iteratee(n,e):Vg(n,e,t)}function O6(n,e,t){e=Pt(e,t);for(var i=Ye(n),a=i.length,s={},o=0;o<a;o++){var l=i[o];s[l]=e(n[l],l,n)}return s}function $g(){}function C6(n){return n==null?$g:function(e){return Ng(n,e)}}function B6(n,e,t){var i=Array(Math.max(0,n));e=Ra(e,t,1);for(var a=0;a<n;a++)i[a]=e(a);return i}function rd(n,e){return e==null&&(e=n,n=0),n+Math.floor(Math.random()*(e-n+1))}const ba=Date.now||function(){return new Date().getTime()};function Lg(n){var e=function(s){return n[s]},t="(?:"+Ye(n).join("|")+")",i=RegExp(t),a=RegExp(t,"g");return function(s){return s=s==null?"":""+s,i.test(s)?s.replace(a,e):s}}const Gg={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},w6=Lg(Gg),_6=Cg(Gg),M6=Lg(_6),N6=re.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var id=/(.)^/,V6={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},$6=/\\|'|\r|\n|\u2028|\u2029/g;function L6(n){return"\\"+V6[n]}var G6=/^\s*(\w|\$)+\s*$/;function F6(n,e,t){!e&&t&&(e=t),e=wg({},e,re.templateSettings);var i=RegExp([(e.escape||id).source,(e.interpolate||id).source,(e.evaluate||id).source].join("|")+"|$","g"),a=0,s="__p+='";n.replace(i,function(y,f,m,b,g){return s+=n.slice(a,g).replace($6,L6),a=g+y.length,f?s+=`'+
|
|
2
2
|
((__t=(`+f+`))==null?'':_.escape(__t))+
|
|
3
3
|
'`:m?s+=`'+
|
|
4
4
|
((__t=(`+m+`))==null?'':__t)+
|
|
@@ -10,7 +10,7 @@ __p+='`),y}),s+=`';
|
|
|
10
10
|
`,o="obj";s=`var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};
|
|
11
11
|
`+s+`return __p;
|
|
12
12
|
`;var l;try{l=new Function(o,"_",s)}catch(y){throw y.source=s,y}var p=function(y){return l.call(this,y,re)};return p.source="function("+o+`){
|
|
13
|
-
`+s+"}",p}function U6(n,e,t){e=Ta(e);var i=e.length;if(!i)return mt(t)?t.call(n):t;for(var a=0;a<i;a++){var s=n==null?void 0:n[e[a]];s===void 0&&(s=t,a=i),n=mt(s)?s.call(n):s}return n}var x6=0;function k6(n){var e=++x6+"";return n?n+e:e}function j6(n){var e=re(n);return e._chain=!0,e}function Gg(n,e,t,i,a){if(!(i instanceof e))return n.apply(t,a);var s=wg(n.prototype),o=n.apply(s,a);return xn(o)?o:s}var pi=It(function(n,e){var t=pi.placeholder,i=function(){for(var a=0,s=e.length,o=Array(s),l=0;l<s;l++)o[l]=e[l]===t?arguments[a++]:e[l];for(;a<arguments.length;)o.push(arguments[a++]);return Gg(n,i,this,this,o)};return i});pi.placeholder=re;const Fg=It(function(n,e,t){if(!mt(n))throw new TypeError("Bind must be called on a function");var i=It(function(a){return Gg(n,i,e,this,t.concat(a))});return i}),wt=Tg(Dt);function mr(n,e,t,i){if(i=i||[],!e&&e!==0)e=1/0;else if(e<=0)return i.concat(n);for(var a=i.length,s=0,o=Dt(n);s<o;s++){var l=n[s];if(wt(l)&&(fr(l)||Wc(l)))if(e>1)mr(l,e-1,t,i),a=i.length;else for(var p=0,y=l.length;p<y;)i[a++]=l[p++];else t||(i[a++]=l)}return i}const q6=It(function(n,e){e=mr(e,!1,!1);var t=e.length;if(t<1)throw new Error("bindAll must be passed function names");for(;t--;){var i=e[t];n[i]=Fg(n[i],n)}return n});function J6(n,e){var t=function(i){var a=t.cache,s=""+(e?e.apply(this,arguments):i);return kn(a,s)||(a[s]=n.apply(this,arguments)),a[s]};return t.cache={},t}const Ug=It(function(n,e,t){return setTimeout(function(){return n.apply(null,t)},e)}),W6=pi(Ug,re,1);function H6(n,e,t){var i,a,s,o,l=0;t||(t={});var p=function(){l=t.leading===!1?0:ba(),i=null,o=n.apply(a,s),i||(a=s=null)},y=function(){var f=ba();!l&&t.leading===!1&&(l=f);var m=e-(f-l);return a=this,s=arguments,m<=0||m>e?(i&&(clearTimeout(i),i=null),l=f,o=n.apply(a,s),i||(a=s=null)):!i&&t.trailing!==!1&&(i=setTimeout(p,m)),o};return y.cancel=function(){clearTimeout(i),l=0,i=a=s=null},y}function Y6(n,e,t){var i,a,s,o,l,p=function(){var f=ba()-a;e>f?i=setTimeout(p,e-f):(i=null,t||(o=n.apply(l,s)),i||(s=l=null))},y=It(function(f){return l=this,s=f,a=ba(),i||(i=setTimeout(p,e),t&&(o=n.apply(l,s))),o});return y.cancel=function(){clearTimeout(i),i=s=l=null},y}function z6(n,e){return pi(e,n)}function ad(n){return function(){return!n.apply(this,arguments)}}function Z6(){var n=arguments,e=n.length-1;return function(){for(var t=e,i=n[e].apply(this,arguments);t--;)i=n[t].call(this,i);return i}}function X6(n,e){return function(){if(--n<1)return e.apply(this,arguments)}}function xg(n,e){var t;return function(){return--n>0&&(t=e.apply(this,arguments)),n<=1&&(e=null),t}}const Q6=pi(xg,2);function kg(n,e,t){e=Pt(e,t);for(var i=Ye(n),a,s=0,o=i.length;s<o;s++)if(a=i[s],e(n[a],a,n))return a}function jg(n){return function(e,t,i){t=Pt(t,i);for(var a=Dt(e),s=n>0?0:a-1;s>=0&&s<a;s+=n)if(t(e[s],s,e))return s;return-1}}const sd=jg(1),qg=jg(-1);function Jg(n,e,t,i){t=Pt(t,i,1);for(var a=t(e),s=0,o=Dt(n);s<o;){var l=Math.floor((s+o)/2);t(n[l])<a?s=l+1:o=l}return s}function Wg(n,e,t){return function(i,a,s){var o=0,l=Dt(i);if(typeof s=="number")n>0?o=s>=0?s:Math.max(s+l,o):l=s>=0?Math.min(s+1,l):s+l+1;else if(t&&s&&l)return s=t(i,a),i[s]===a?s:-1;if(a!==a)return s=e(ya.call(i,o,l),fg),s>=0?s+o:-1;for(s=n>0?o:l-1;s>=0&&s<l;s+=n)if(i[s]===a)return s;return-1}}const Hg=Wg(1,sd,Jg),K6=Wg(-1,qg);function od(n,e,t){var i=wt(n)?sd:kg,a=i(n,e,t);if(a!==void 0&&a!==-1)return n[a]}function e9(n,e){return od(n,Ea(e))}function Rn(n,e,t){e=Ra(e,t);var i,a;if(wt(n))for(i=0,a=n.length;i<a;i++)e(n[i],i,n);else{var s=Ye(n);for(i=0,a=s.length;i<a;i++)e(n[s[i]],s[i],n)}return n}function Tr(n,e,t){e=Pt(e,t);for(var i=!wt(n)&&Ye(n),a=(i||n).length,s=Array(a),o=0;o<a;o++){var l=i?i[o]:o;s[o]=e(n[l],l,n)}return s}function Yg(n){var e=function(t,i,a,s){var o=!wt(t)&&Ye(t),l=(o||t).length,p=n>0?0:l-1;for(s||(a=t[o?o[p]:p],p+=n);p>=0&&p<l;p+=n){var y=o?o[p]:p;a=i(a,t[y],y,t)}return a};return function(t,i,a,s){var o=arguments.length>=3;return e(t,Ra(i,s,4),a,o)}}const ld=Yg(1),zg=Yg(-1);function yi(n,e,t){var i=[];return e=Pt(e,t),Rn(n,function(a,s,o){e(a,s,o)&&i.push(a)}),i}function t9(n,e,t){return yi(n,ad(Pt(e)),t)}function Zg(n,e,t){e=Pt(e,t);for(var i=!wt(n)&&Ye(n),a=(i||n).length,s=0;s<a;s++){var o=i?i[s]:s;if(!e(n[o],o,n))return!1}return!0}function Xg(n,e,t){e=Pt(e,t);for(var i=!wt(n)&&Ye(n),a=(i||n).length,s=0;s<a;s++){var o=i?i[s]:s;if(e(n[o],o,n))return!0}return!1}function bn(n,e,t,i){return wt(n)||(n=ui(n)),(typeof t!="number"||i)&&(t=0),Hg(n,e,t)>=0}const n9=It(function(n,e,t){var i,a;return mt(e)?a=e:(e=Ta(e),i=e.slice(0,-1),e=e[e.length-1]),Tr(n,function(s){var o=a;if(!o){if(i&&i.length&&(s=Kc(s,i)),s==null)return;o=s[e]}return o==null?o:o.apply(s,t)})});function cd(n,e){return Tr(n,td(e))}function r9(n,e){return yi(n,Ea(e))}function Qg(n,e,t){var i=-1/0,a=-1/0,s,o;if(e==null||typeof e=="number"&&typeof n[0]!="object"&&n!=null){n=wt(n)?n:ui(n);for(var l=0,p=n.length;l<p;l++)s=n[l],s!=null&&s>i&&(i=s)}else e=Pt(e,t),Rn(n,function(y,f,m){o=e(y,f,m),(o>a||o===-1/0&&i===-1/0)&&(i=y,a=o)});return i}function i9(n,e,t){var i=1/0,a=1/0,s,o;if(e==null||typeof e=="number"&&typeof n[0]!="object"&&n!=null){n=wt(n)?n:ui(n);for(var l=0,p=n.length;l<p;l++)s=n[l],s!=null&&s<i&&(i=s)}else e=Pt(e,t),Rn(n,function(y,f,m){o=e(y,f,m),(o<a||o===1/0&&i===1/0)&&(i=y,a=o)});return i}var a9=/[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g;function Kg(n){return n?fr(n)?ya.call(n):jc(n)?n.match(a9):wt(n)?Tr(n,ed):ui(n):[]}function ev(n,e,t){if(e==null||t)return wt(n)||(n=ui(n)),n[rd(n.length-1)];var i=Kg(n),a=Dt(i);e=Math.max(Math.min(e,a),0);for(var s=a-1,o=0;o<e;o++){var l=rd(o,s),p=i[o];i[o]=i[l],i[l]=p}return i.slice(0,e)}function s9(n){return ev(n,1/0)}function o9(n,e,t){var i=0;return e=Pt(e,t),cd(Tr(n,function(a,s,o){return{value:a,index:i++,criteria:e(a,s,o)}}).sort(function(a,s){var o=a.criteria,l=s.criteria;if(o!==l){if(o>l||o===void 0)return 1;if(o<l||l===void 0)return-1}return a.index-s.index}),"value")}function no(n,e){return function(t,i,a){var s=e?[[],[]]:{};return i=Pt(i,a),Rn(t,function(o,l){var p=i(o,l,t);n(s,o,p)}),s}}const l9=no(function(n,e,t){kn(n,t)?n[t].push(e):n[t]=[e]}),c9=no(function(n,e,t){n[t]=e}),d9=no(function(n,e,t){kn(n,t)?n[t]++:n[t]=1}),u9=no(function(n,e,t){n[t?0:1].push(e)},!0);function p9(n){return n==null?0:wt(n)?n.length:Ye(n).length}function y9(n,e,t){return e in t}const tv=It(function(n,e){var t={},i=e[0];if(n==null)return t;mt(i)?(e.length>1&&(i=Ra(i,e[1])),e=ma(n)):(i=y9,e=mr(e,!1,!1),n=Object(n));for(var a=0,s=e.length;a<s;a++){var o=e[a],l=n[o];i(l,o,n)&&(t[o]=l)}return t}),h9=It(function(n,e){var t=e[0],i;return mt(t)?(t=ad(t),e.length>1&&(i=e[1])):(e=Tr(mr(e,!1,!1),String),t=function(a,s){return!bn(e,s)}),tv(n,t,i)});function nv(n,e,t){return ya.call(n,0,Math.max(0,n.length-(e==null||t?1:e)))}function dd(n,e,t){return n==null||n.length<1?e==null||t?void 0:[]:e==null||t?n[0]:nv(n,n.length-e)}function ro(n,e,t){return ya.call(n,e==null||t?1:e)}function f9(n,e,t){return n==null||n.length<1?e==null||t?void 0:[]:e==null||t?n[n.length-1]:ro(n,Math.max(0,n.length-e))}function m9(n){return yi(n,Boolean)}function T9(n,e){return mr(n,e,!1)}const rv=It(function(n,e){return e=mr(e,!0,!0),yi(n,function(t){return!bn(e,t)})}),E9=It(function(n,e){return rv(n,e)});function ud(n,e,t,i){lg(e)||(i=t,t=e,e=!1),t!=null&&(t=Pt(t,i));for(var a=[],s=[],o=0,l=Dt(n);o<l;o++){var p=n[o],y=t?t(p,o,n):p;e&&!t?((!o||s!==y)&&a.push(p),s=y):t?bn(s,y)||(s.push(y),a.push(p)):bn(a,p)||a.push(p)}return a}const R9=It(function(n){return ud(mr(n,!0,!0))});function b9(n){for(var e=[],t=arguments.length,i=0,a=Dt(n);i<a;i++){var s=n[i];if(!bn(e,s)){var o;for(o=1;o<t&&bn(arguments[o],s);o++);o===t&&e.push(s)}}return e}function pd(n){for(var e=n&&Qg(n,Dt).length||0,t=Array(e),i=0;i<e;i++)t[i]=cd(n,i);return t}const g9=It(pd);function v9(n,e){for(var t={},i=0,a=Dt(n);i<a;i++)e?t[n[i]]=e[i]:t[n[i][0]]=n[i][1];return t}function I9(n,e,t){e==null&&(e=n||0,n=0),t||(t=e<n?-1:1);for(var i=Math.max(Math.ceil((e-n)/t),0),a=Array(i),s=0;s<i;s++,n+=t)a[s]=n;return a}function D9(n,e){if(e==null||e<1)return[];for(var t=[],i=0,a=n.length;i<a;)t.push(ya.call(n,i,i+=e));return t}function yd(n,e){return n._chain?re(e).chain():e}function iv(n){return Rn(Xc(n),function(e){var t=re[e]=n[e];re.prototype[e]=function(){var i=[this._wrapped];return z8.apply(i,arguments),yd(this,t.apply(re,i))}}),re}Rn(["pop","push","reverse","shift","sort","splice","unshift"],function(n){var e=Qs[n];re.prototype[n]=function(){var t=this._wrapped;return t!=null&&(e.apply(t,arguments),(n==="shift"||n==="splice")&&t.length===0&&delete t[0]),yd(this,t)}}),Rn(["concat","join","slice"],function(n){var e=Qs[n];re.prototype[n]=function(){var t=this._wrapped;return t!=null&&(t=e.apply(t,arguments)),yd(this,t)}});var av=iv(Object.freeze(Object.defineProperty({__proto__:null,VERSION:Qb,after:X6,all:Zg,allKeys:ma,any:Xg,assign:to,before:xg,bind:Fg,bindAll:q6,chain:j6,chunk:D9,clone:P6,collect:Tr,compact:m9,compose:Z6,constant:mg,contains:bn,countBy:d9,create:D6,debounce:Y6,default:re,defaults:Bg,defer:W6,delay:Ug,detect:od,difference:rv,drop:ro,each:Rn,escape:w6,every:Zg,extend:Cg,extendOwn:to,filter:yi,find:od,findIndex:sd,findKey:kg,findLastIndex:qg,findWhere:e9,first:dd,flatten:T9,foldl:ld,foldr:zg,forEach:Rn,functions:Xc,get:Mg,groupBy:l9,has:S6,head:dd,identity:ed,include:bn,includes:bn,indexBy:c9,indexOf:Hg,initial:nv,inject:ld,intersection:b9,invert:Og,invoke:n9,isArguments:Wc,isArray:fr,isArrayBuffer:ug,isBoolean:lg,isDataView:Ks,isDate:i6,isElement:r6,isEmpty:fa,isEqual:f6,isError:s6,isFinite:d6,isFunction:mt,isMap:E6,isMatch:gg,isNaN:fg,isNull:n6,isNumber:cg,isObject:xn,isRegExp:a6,isSet:b6,isString:jc,isSymbol:dg,isTypedArray:Rg,isUndefined:og,isWeakMap:R6,isWeakSet:g6,iteratee:nd,keys:Ye,last:f9,lastIndexOf:K6,map:Tr,mapObject:O6,matcher:Ea,matches:Ea,max:Qg,memoize:J6,methods:Xc,min:i9,mixin:iv,negate:ad,noop:Vg,now:ba,object:v9,omit:h9,once:Q6,pairs:v6,partial:pi,partition:u9,pick:tv,pluck:cd,property:td,propertyOf:C6,random:rd,range:I9,reduce:ld,reduceRight:zg,reject:t9,rest:ro,restArguments:It,result:U6,sample:ev,select:yi,shuffle:s9,size:p9,some:Xg,sortBy:o9,sortedIndex:Jg,tail:ro,take:dd,tap:A6,template:F6,templateSettings:N6,throttle:H6,times:B6,toArray:Kg,toPath:_g,transpose:pd,unescape:M6,union:R9,uniq:ud,unique:ud,uniqueId:k6,unzip:pd,values:ui,where:r9,without:E9,wrap:z6,zip:g9},Symbol.toStringTag,{value:"Module"})));av._=av;function io(n){return n.charAt(0).toUpperCase()+n.slice(1)}function sv(n){return n.charAt(0).toLowerCase()+n.slice(1)}function ov(n,e){if(n.type!==r.Property||e.type!==r.Property)throw new Error(`Expected property entities for comparison. But got ${n.type} and ${e.type}.`);return n===e||n.id===e.id?!0:n.name!==e.name||n.static!==e.static||n.abstract!==e.abstract?!1:Ht(n.dataType,e.dataType).compatible}function lv(n,e){if(n.type!==r.CustomEntity||e.type!==r.CustomEntity)throw new Error(`Expected custom entities for comparison. But got ${n.type} and ${e.type}.`);if(n===e||n.id===e.id)return!0;if(n.properties.length!==e.properties.length)return!1;let t=[...e.properties];const i=[];for(let a=0;a<n.properties.length;a++){const s=n.properties[a];t.find(l=>{const p=ov(s,l);return p&&(t=t.filter(y=>y.id!==l.id)),p})||i.push(s)}return!(i.length>0)}var Lt=(n=>(n.BothUnconstrained="both-unconstrained",n.AConstraintBUnconstrained="a-constraint-b-unconstrained",n.BConstraintAUnconstrained="b-constraint-a-unconstrained",n.Same="same",n.AIsListBIsNot="a-is-list-b-is-not",n.BIsListAIsNot="b-is-list-a-is-not",n.AIsNullableBIsNot="a-is-nullable-b-is-not",n.BIsNullableAIsNot="b-is-nullable-a-is-not",n.AIsTemplateBIsNot="a-is-template-b-is-not",n.BIsTemplateAIsNot="b-is-template-a-is-not",n.BothUntyped="both-untyped",n.AIsUntypedBIsNot="a-is-untyped-b-is-not",n.BIsUntypedAIsNot="b-is-untyped-a-is-not",n.TypeEntityMismatch="type-entity-mismatch",n.SameCustomEntities="same-custom-entities",n.CompatibleCustomEntities="compatible-custom-entities",n.IncompatibleCustomEntities="incompatible-custom-entities",n.SamePrimitiveEntities="same-primitive-entities",n.IncompatiblePrimitiveEntities="incompatible-primitive-entities",n.SameBuiltInBaseEntities="same-built-in-base-entities",n.IncompatibleBuiltInBaseEntities="incompatible-built-in-base-entities",n.CheckUnknown="check-unknown",n))(Lt||{});function Ht(n,e){var t,i,a,s,o,l,p,y,f,m,b;if(n&&n.type!==r.DataType||e&&e.type!==r.DataType)throw new Error(`Expected data-type entities for comparison. But got ${n==null?void 0:n.type} and ${e==null?void 0:e.type}.`);if(n===null&&e===null)return{compatible:!0,type:"both-unconstrained"};if(n===null)return{compatible:!0,type:"a-constraint-b-unconstrained"};if(e===null)return{compatible:!0,type:"b-constraint-a-unconstrained"};if(n===e)return{compatible:!0,type:"same"};if(n.id===e.id)return{compatible:!0,type:"same"};if(n.isList!==e.isList)return{compatible:!1,type:n.isList?"a-is-list-b-is-not":"b-is-list-a-is-not"};if(n.isNullable!==e.isNullable)return{compatible:!1,type:n.isNullable?"a-is-nullable-b-is-not":"b-is-nullable-a-is-not"};if(n.asType!==e.asType)return{compatible:!1,type:n.asType?"a-is-template-b-is-not":"b-is-template-a-is-not"};if(!n.entity&&e.entity)return{compatible:!0,type:"a-is-untyped-b-is-not"};if(n.entity&&!e.entity)return{compatible:!0,type:"b-is-untyped-a-is-not"};if(!n.entity&&!e.entity)return{compatible:!0,type:"both-untyped"};if(((t=n.entity)==null?void 0:t.type)!==((i=e.entity)==null?void 0:i.type))return{compatible:!1,type:"type-entity-mismatch"};if(((a=n.entity)==null?void 0:a.type)===r.CustomEntity){if(((s=n.entity)==null?void 0:s.id)===((o=e.entity)==null?void 0:o.id))return{compatible:!0,type:"same-custom-entities"};const g=lv(n.entity,e.entity);return{compatible:g,type:g?"compatible-custom-entities":"incompatible-custom-entities"}}return((l=n.entity)==null?void 0:l.type)===r.PrimitiveEntity?((p=n.entity)==null?void 0:p.id)===((y=e.entity)==null?void 0:y.id)?{compatible:!0,type:"same-primitive-entities"}:{compatible:!1,type:"incompatible-primitive-entities"}:((f=n.entity)==null?void 0:f.type)===r.BuiltInBaseEntity?((m=n.entity)==null?void 0:m.id)===((b=e.entity)==null?void 0:b.id)?{compatible:!0,type:"same-built-in-base-entities"}:{compatible:!1,type:"incompatible-built-in-base-entities"}:{compatible:!1,type:"check-unknown"}}function P9(n){const e=n.project.builtInBaseEntities.find(a=>a.id===V.EXECUTION),t={id:n.id+"--infered-data-type",version:1,type:r.DataType,isList:!1,isNullable:!1,andChildrenGroup:null,orChildrenGroup:null,asType:!1,entity:null,constant:!1,defaultValue:null,parent:null},i=R(t,n.project);return i.inferred=!0,i.sync(t),i.setParent(n),i.entity=e,i}function cv(n){return n.dataType?n.dataType:null}function dv(n){var e;return(e=n.declaration)!=null&&e.dataType?n.declaration.dataType:n.readsValue?rn(n.readsValue):null}function hd(n){return n.dataType&&!n.dataType.inferred&&n.dataType.isResolved()?n.dataType:n.readsValue?rn(n.readsValue):null}function uv(n){return rn(n.declaration)}function pv(n){return n.dataType&&!n.dataType.inferred?n.dataType:(n.dataType&&n.dataType.inferred,n.inferDataTypeAndSyncInstancesInputsAndOutputs(),n.dataType)}function yv(n){var e;return((e=n.declaration)==null?void 0:e.dataType)||null}function rn(n){switch(n.type){case r.VariableDeclaration:return pv(n);case r.ArgumentDeclaration:return cv(n);case r.ReturnDeclaration:return hd(n);case r.VariableInstance:return uv(n);case r.InputMap:return dv(n);case r.OutputMap:return yv(n);default:throw new Error(`Cannot infer data type from entity of type ${n.type}.`)}}function ao(n){switch(n.type){case r.ArgumentDeclaration:return n.getDataType();case r.InputMap:return n.getDataType();case r.VariableDeclaration:return n.getDataType();case r.VariableInstance:return n.getDataType();case r.OutputMap:return n.getDataType();case r.ReturnDeclaration:return n.getDataType();case r.Property:return n.getDataType();case r.ValueDescriptor:return n.getDataType();default:return null}}function C(n){if(n){let e=null;return typeof n=="string"?e=n:n.entityId?e=n.entityId:n.type!==r.GenericReference&&(e=n.id),e}return null}function Er(n){return n.declaration||n}function A9(n){return n.type===r.VariableDeclaration?n.parent===n.project?"global-declaration":"local-declaration":n.declaration.parent===n.project?"global-instance":"local-instance"}function fd(n,e){const t=[];if(n.type===r.Project)t.push(...n.variableDeclarations);else{const a=Et(Se(n)).filter(s=>s.type===r.VariableDeclaration);t.push(...a),n.parent&&(ct.includes(n.parent.type)||n.parent.type===r.Project)&&t.push(...fd(n.parent))}return t}function S9(n){return n.replace(/(?:^\w|[A-Z]|\b\w)/g,function(e,t){return t===0?e.toLowerCase():e.toUpperCase()}).replace(/\s+/g,"")}function O9(n){return n.split(/\s+/).map(i=>i[0].toUpperCase()+i.slice(1).toLowerCase()).join("")}function hv(n){var e;return(e=n.match(/[A-Z]{2,}(?=[A-Z][a-z]+[0-9]*|\b)|[A-Z]?[a-z]+[0-9]*|[A-Z]|[0-9]+/g))==null?void 0:e.map(t=>t.toLowerCase()).join("-")}function so(n){return hv(n).toLowerCase()}function Rr(n,e=!0){if(!(n!=null&&n.dataType))return"Any data type";if(!n.dataType.entity)return n.dataType.isList?"List of an unknown data type":"Unknown data type";if(n.dataType.entity.type===r.PrimitiveEntity){let t=n.dataType.entity.name;switch(n.dataType.entity.name){case A.String:t="Text";break;case A.JSON:t=e?"Any data structure":"Unknown data structure";break;default:t=n.dataType.entity.name;break}return n.dataType.isList?`List of ${t}s`:`${t.slice(0,1).toUpperCase()}${t.slice(1)}`}else return n.dataType.isList?`List of ${n.dataType.entity.name} entities`:`${n.dataType.entity.name.slice(0,1).toUpperCase()+n.dataType.entity.name.slice(1)} entity`}function fv(n){return Rr(n.declaration)}function C9(n){return n.type===r.VariableInstance?fv(n):Rr(n)}function mv(n){if(!n)return"Any data type";if(!n.entity)return"Inherited";if(n.entity.type===r.PrimitiveEntity){const e=n.entity.name===A.String?"Text":n.entity.name;return n.isList?`List of ${e}s`:`${e.slice(0,1).toUpperCase()}${e.slice(1)}`}else if(n.entity.type===r.CustomEntity){const e=Td(n.entity);return n.isList?`List of ${e} entities`:e.slice(0,1).toUpperCase()+e.slice(1)}else if(n.entity.type===r.BuiltInBaseEntity){const e=md(n.entity);return n.isList?`List of ${e} entities`:e.slice(0,1).toUpperCase()+e.slice(1)}else return n.isList?`List of ${n.entity.name} entities`:`${n.entity.name.slice(0,1).toUpperCase()+n.entity.name.slice(1)} entity`}function Tv(n){if(!n.dataType)return"Any data type";if(!n.dataType.entity)return"Inherited";if(n.dataType.entity.type===r.PrimitiveEntity){const e=n.dataType.entity.name===A.String?"Text":n.dataType.entity.name;return n.dataType.isList?`List of ${e}s`:`${e.slice(0,1).toUpperCase()}${e.slice(1)}`}else if(n.dataType.entity.type===r.CustomEntity){const e=Td(n.dataType.entity);return n.dataType.isList?`List of ${e} entities`:e.slice(0,1).toUpperCase()+e.slice(1)}else if(n.dataType.entity.type===r.BuiltInBaseEntity){const e=md(n.dataType.entity);return n.dataType.isList?`List of ${e} entities`:e.slice(0,1).toUpperCase()+e.slice(1)}else return n.dataType.isList?`List of ${n.dataType.entity.name} entities`:`${n.dataType.entity.name.slice(0,1).toUpperCase()+n.dataType.entity.name.slice(1)} entity`}function Ev(n){switch(n.type){case r.Property:return Tv(n);case r.VariableDeclaration:return Rr(n);case r.ArgumentDeclaration:return Rr(n,!1);case r.InputMap:{const e=n.declaration;return e?Ev(e):"Unknown data type"}case r.ReturnDeclaration:return Rr(n,!1);case r.OutputMap:{const e=n.declaration;return Rr(e,!1)}}return"Unknown data type"}function oo(n){switch(n.declaration.id){case _e.Equal:return"is equal to";case _e.NotEqual:return"is not equal to";case _e.MoreThan:return"is greater than";case _e.MoreThanOrEqual:return"is greater than or equal to";case _e.LessThan:return"is less than";case _e.LessThanOrEqual:return"is less than or equal to";case _e.And:return"and";case _e.Or:return"or";case Nt.Empty:return"is empty";case Nt.NotEmpty:return"is not empty"}}function Rv(n){return n.includes(V.HTTP_ENDPOINT)?"HTTP endpoint":n.includes(V.PERSISTED_ENTITY)?"Persisted entity":n.includes(V.CRON_JOB)?"Scheduled execution":n.includes(V.RELATIONAL_DATABASE)?"Relational database":"Entity"}function md(n){switch(n.name){case V.HTTP_ENDPOINT:return"HTTP endpoint";case V.PERSISTED_ENTITY:return"Persisted entity";case V.CRON_JOB:return"Scheduled execution";case V.RELATIONAL_DATABASE:return"Relational database"}return"Entity"}function Td(n){const e=nI(n);if(!e){const t=eI(n);return t.includes(V.HTTP_ENDPOINT)?"HTTP endpoint":t.includes(V.PERSISTED_ENTITY)?"Persisted entity":t.includes(V.CRON_JOB)?"Scheduled execution":t.includes(V.RELATIONAL_DATABASE)?"Relational database":S(n,n.project)+" entity"}return S(e,n.project)+" entity"}function bv(n){let e="Find ";return n.outputsDeclarations.forEach((t,i)=>{const a=ao(t),s=sv(a&&a.entity?S(a.entity,n.project):"unstructured data");i===0?e+=`${s} `:i===n.outputsDeclarations.length-1?e+=`and ${s} `:e+=`, ${s} `}),e}function gv(n){switch(n.name){case A.String:return"Text";case A.Number:return"Number";case A.Boolean:return"Boolean";case A.JSON:return"Data structure";case A.UUID:return"Unique identifier";case A.Date:return"Date";case A.EntityTemplate:return"Entity as template";case A.Enum:return"Enumeration";case A.File:return"File";case A.Null:return"Empty";case A.ActionDescriptor:return"Action descriptor";default:return n.name}}function vv(n){switch(n.id){case Q.List:return"Loop over list items";case Q.ManualFlow:return"Manual flow control loop";case Q.ObjectKeys:return"Loop over object keys";case Q.ObjectValues:return"Loop over object values";case Q.Counted:return"Loop given number of times";case Q.String:return"Loop over text characters";case lt.Addition:return"Sum numbers";case lt.Substraction:return"Subtract numbers";case lt.Multiplication:return"Multiply numbers";case lt.Division:return"Divide numbers";case lt.Remainder:return"Get remainder of numbers";case lt.Exponentiation:return"Get exponent of numbers";case Ae.AddIndex:return"Add at index position";case Ae.DeleteFirst:return"Delete first character";case Ae.DeleteLast:return"Delete last character";case Ae.DeleteIndex:return"Delete at index position";case Ae.Join:return"Join texts";case Ae.ReplaceAllMatches:return"Replace all matches";case Ae.ReplaceFirst:return"Replace first match";case Ae.ReplaceLast:return"Replace last match";case Ae.Split:return"Split text";case Ae.ReplaceIndex:return"Replace at index position";case Ae.ReplaceSingleMatch:return"Replace single match";case Ae.GetFirst:return"Get first character";case Ae.GetLast:return"Get last character";case Ae.GetIndex:return"Get at index position";case Ae.Append:return"Add at the end";case Ae.Prepend:return"Add at the start";case Oe.Wait:return"Wait";case Oe.Parallel:return"Run in parallel";case Oe.Sequential:return"Run in sequence";case Xe.HttpRequest:return"HTTP request";case Ze.CreateNewInstance:return"Create new copy of entity";case W.AddIndex:return"Add item at index position";case W.DeleteFirst:return"Delete first item";case W.DeleteLast:return"Delete last item";case W.DeleteIndex:return"Delete item at index position";case W.Join:return"Join lists";case W.ReplaceAllMatches:return"Replace all matches";case W.ReplaceFirst:return"Replace first match";case W.ReplaceLast:return"Replace last match";case W.Split:return"Split list";case W.ReplaceIndex:return"Replace at index position";case W.ReplaceSingleMatch:return"Replace single match";case W.GetFirst:return"Get first item";case W.GetLast:return"Get last item";case W.GetIndex:return"Get item at index position";case W.Append:return"Add item at the end";case W.Prepend:return"Add item at the start";case on.PROJECT_PUBLICATION_COMPLETED:return"Project publication completed";default:return(n.name.slice(0,1).toUpperCase()+n.name.slice(1)).replaceAll("-"," ")}}function S(n,e){var t;if(r.FunctionDeclaration===n.type){const i=n.name;if(Object.values(Ot).includes(i))switch(i){case Ot.AbortExecution:return"Abort execution";case Ot.DeletePersistedEntity:return"Delete persisted entity";case Ot.SoftDeletePersistedEntity:return"Soft delete persisted entity";default:return io(n.type).replaceAll("-"," ")}return i}if(r.BuiltInBaseEntity===n.type)return Rv([n.name]);if(Zd.includes(n.type)&&n.type!==r.ActionDescriptor)return n.name;switch(n.type){case r.Search:return bv(n);case r.Operation:case r.InternalCall:case r.Loop:const i=Mt(n.declaration,e);return S(i,e);case r.ActionDescriptor:return vv(n);case r.BreakStatement:const a=Mt(n.parent,e);return`Stop loop ${S(a,e)}`;case r.ContinueStatement:const s=Mt(n.parent,e);return`Execute next iteration of ${S(s,e)}`;case r.FunctionCall:return Mt(n.declaration,e).name;case r.Condition:{const l=n;if((t=n.inputs)!=null&&t.length){const p=S(l.inputs[0],l.project);if(l.inputs[1]){const y=l.inputs[1].declaration.name;return`If ${p} ${oo(l)} ${y}`}return`If ${p} ${oo(l)}`}else return`If ${oo(l)}`}case r.ReturnStatement:{const l=Mt(n.parent,e);return`Output of ${S(l,e)}`}case r.InputMap:if(n.declaration){const l=Mt(n.declaration,e);return S(l,e)||""}else return n.name||"";case r.VariableInstance:{const l=Mt(n.declaration,e);return S(l,e)||""}case r.OutputMap:if(n.declaration){const l=Mt(n.declaration,e);return(l==null?void 0:l.name)||""}else return"";case r.PrimitiveEntity:case r.PrimitiveValue:return gv(n);default:return io(n.type).replaceAll("-"," ")}}function lo(n,e){const t=[];n.name||t.push(new E({id:`${n.id}--${D.EmptyName}`,message:`Entity with id "${n.id}" and type "${n.type}" has an empty name. Please provide a 'name' string.`,severity:T.Error,code:D.EmptyName,issue:null}));const i=e.entities.filter(a=>a.name===n.name);return i.length&&t.push(new E({id:`${n.id}--${D.NameNotUniqueInScope}`,message:`Entity with id "${n.id}" and type "${n.type}" has a name "${n.name}" that is not unique in the project. Entity with id "${i[0].id}" has the same name.
|
|
13
|
+
`+s+"}",p}function U6(n,e,t){e=Ta(e);var i=e.length;if(!i)return mt(t)?t.call(n):t;for(var a=0;a<i;a++){var s=n==null?void 0:n[e[a]];s===void 0&&(s=t,a=i),n=mt(s)?s.call(n):s}return n}var x6=0;function k6(n){var e=++x6+"";return n?n+e:e}function j6(n){var e=re(n);return e._chain=!0,e}function Fg(n,e,t,i,a){if(!(i instanceof e))return n.apply(t,a);var s=_g(n.prototype),o=n.apply(s,a);return xn(o)?o:s}var pi=It(function(n,e){var t=pi.placeholder,i=function(){for(var a=0,s=e.length,o=Array(s),l=0;l<s;l++)o[l]=e[l]===t?arguments[a++]:e[l];for(;a<arguments.length;)o.push(arguments[a++]);return Fg(n,i,this,this,o)};return i});pi.placeholder=re;const Ug=It(function(n,e,t){if(!mt(n))throw new TypeError("Bind must be called on a function");var i=It(function(a){return Fg(n,i,e,this,t.concat(a))});return i}),wt=Eg(Dt);function mr(n,e,t,i){if(i=i||[],!e&&e!==0)e=1/0;else if(e<=0)return i.concat(n);for(var a=i.length,s=0,o=Dt(n);s<o;s++){var l=n[s];if(wt(l)&&(fr(l)||Wc(l)))if(e>1)mr(l,e-1,t,i),a=i.length;else for(var p=0,y=l.length;p<y;)i[a++]=l[p++];else t||(i[a++]=l)}return i}const q6=It(function(n,e){e=mr(e,!1,!1);var t=e.length;if(t<1)throw new Error("bindAll must be passed function names");for(;t--;){var i=e[t];n[i]=Ug(n[i],n)}return n});function J6(n,e){var t=function(i){var a=t.cache,s=""+(e?e.apply(this,arguments):i);return kn(a,s)||(a[s]=n.apply(this,arguments)),a[s]};return t.cache={},t}const xg=It(function(n,e,t){return setTimeout(function(){return n.apply(null,t)},e)}),W6=pi(xg,re,1);function H6(n,e,t){var i,a,s,o,l=0;t||(t={});var p=function(){l=t.leading===!1?0:ba(),i=null,o=n.apply(a,s),i||(a=s=null)},y=function(){var f=ba();!l&&t.leading===!1&&(l=f);var m=e-(f-l);return a=this,s=arguments,m<=0||m>e?(i&&(clearTimeout(i),i=null),l=f,o=n.apply(a,s),i||(a=s=null)):!i&&t.trailing!==!1&&(i=setTimeout(p,m)),o};return y.cancel=function(){clearTimeout(i),l=0,i=a=s=null},y}function Y6(n,e,t){var i,a,s,o,l,p=function(){var f=ba()-a;e>f?i=setTimeout(p,e-f):(i=null,t||(o=n.apply(l,s)),i||(s=l=null))},y=It(function(f){return l=this,s=f,a=ba(),i||(i=setTimeout(p,e),t&&(o=n.apply(l,s))),o});return y.cancel=function(){clearTimeout(i),i=s=l=null},y}function z6(n,e){return pi(e,n)}function ad(n){return function(){return!n.apply(this,arguments)}}function Z6(){var n=arguments,e=n.length-1;return function(){for(var t=e,i=n[e].apply(this,arguments);t--;)i=n[t].call(this,i);return i}}function X6(n,e){return function(){if(--n<1)return e.apply(this,arguments)}}function kg(n,e){var t;return function(){return--n>0&&(t=e.apply(this,arguments)),n<=1&&(e=null),t}}const Q6=pi(kg,2);function jg(n,e,t){e=Pt(e,t);for(var i=Ye(n),a,s=0,o=i.length;s<o;s++)if(a=i[s],e(n[a],a,n))return a}function qg(n){return function(e,t,i){t=Pt(t,i);for(var a=Dt(e),s=n>0?0:a-1;s>=0&&s<a;s+=n)if(t(e[s],s,e))return s;return-1}}const sd=qg(1),Jg=qg(-1);function Wg(n,e,t,i){t=Pt(t,i,1);for(var a=t(e),s=0,o=Dt(n);s<o;){var l=Math.floor((s+o)/2);t(n[l])<a?s=l+1:o=l}return s}function Hg(n,e,t){return function(i,a,s){var o=0,l=Dt(i);if(typeof s=="number")n>0?o=s>=0?s:Math.max(s+l,o):l=s>=0?Math.min(s+1,l):s+l+1;else if(t&&s&&l)return s=t(i,a),i[s]===a?s:-1;if(a!==a)return s=e(ya.call(i,o,l),mg),s>=0?s+o:-1;for(s=n>0?o:l-1;s>=0&&s<l;s+=n)if(i[s]===a)return s;return-1}}const Yg=Hg(1,sd,Wg),K6=Hg(-1,Jg);function od(n,e,t){var i=wt(n)?sd:jg,a=i(n,e,t);if(a!==void 0&&a!==-1)return n[a]}function e9(n,e){return od(n,Ea(e))}function Rn(n,e,t){e=Ra(e,t);var i,a;if(wt(n))for(i=0,a=n.length;i<a;i++)e(n[i],i,n);else{var s=Ye(n);for(i=0,a=s.length;i<a;i++)e(n[s[i]],s[i],n)}return n}function Tr(n,e,t){e=Pt(e,t);for(var i=!wt(n)&&Ye(n),a=(i||n).length,s=Array(a),o=0;o<a;o++){var l=i?i[o]:o;s[o]=e(n[l],l,n)}return s}function zg(n){var e=function(t,i,a,s){var o=!wt(t)&&Ye(t),l=(o||t).length,p=n>0?0:l-1;for(s||(a=t[o?o[p]:p],p+=n);p>=0&&p<l;p+=n){var y=o?o[p]:p;a=i(a,t[y],y,t)}return a};return function(t,i,a,s){var o=arguments.length>=3;return e(t,Ra(i,s,4),a,o)}}const ld=zg(1),Zg=zg(-1);function yi(n,e,t){var i=[];return e=Pt(e,t),Rn(n,function(a,s,o){e(a,s,o)&&i.push(a)}),i}function t9(n,e,t){return yi(n,ad(Pt(e)),t)}function Xg(n,e,t){e=Pt(e,t);for(var i=!wt(n)&&Ye(n),a=(i||n).length,s=0;s<a;s++){var o=i?i[s]:s;if(!e(n[o],o,n))return!1}return!0}function Qg(n,e,t){e=Pt(e,t);for(var i=!wt(n)&&Ye(n),a=(i||n).length,s=0;s<a;s++){var o=i?i[s]:s;if(e(n[o],o,n))return!0}return!1}function bn(n,e,t,i){return wt(n)||(n=ui(n)),(typeof t!="number"||i)&&(t=0),Yg(n,e,t)>=0}const n9=It(function(n,e,t){var i,a;return mt(e)?a=e:(e=Ta(e),i=e.slice(0,-1),e=e[e.length-1]),Tr(n,function(s){var o=a;if(!o){if(i&&i.length&&(s=Kc(s,i)),s==null)return;o=s[e]}return o==null?o:o.apply(s,t)})});function cd(n,e){return Tr(n,td(e))}function r9(n,e){return yi(n,Ea(e))}function Kg(n,e,t){var i=-1/0,a=-1/0,s,o;if(e==null||typeof e=="number"&&typeof n[0]!="object"&&n!=null){n=wt(n)?n:ui(n);for(var l=0,p=n.length;l<p;l++)s=n[l],s!=null&&s>i&&(i=s)}else e=Pt(e,t),Rn(n,function(y,f,m){o=e(y,f,m),(o>a||o===-1/0&&i===-1/0)&&(i=y,a=o)});return i}function i9(n,e,t){var i=1/0,a=1/0,s,o;if(e==null||typeof e=="number"&&typeof n[0]!="object"&&n!=null){n=wt(n)?n:ui(n);for(var l=0,p=n.length;l<p;l++)s=n[l],s!=null&&s<i&&(i=s)}else e=Pt(e,t),Rn(n,function(y,f,m){o=e(y,f,m),(o<a||o===1/0&&i===1/0)&&(i=y,a=o)});return i}var a9=/[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g;function ev(n){return n?fr(n)?ya.call(n):jc(n)?n.match(a9):wt(n)?Tr(n,ed):ui(n):[]}function tv(n,e,t){if(e==null||t)return wt(n)||(n=ui(n)),n[rd(n.length-1)];var i=ev(n),a=Dt(i);e=Math.max(Math.min(e,a),0);for(var s=a-1,o=0;o<e;o++){var l=rd(o,s),p=i[o];i[o]=i[l],i[l]=p}return i.slice(0,e)}function s9(n){return tv(n,1/0)}function o9(n,e,t){var i=0;return e=Pt(e,t),cd(Tr(n,function(a,s,o){return{value:a,index:i++,criteria:e(a,s,o)}}).sort(function(a,s){var o=a.criteria,l=s.criteria;if(o!==l){if(o>l||o===void 0)return 1;if(o<l||l===void 0)return-1}return a.index-s.index}),"value")}function no(n,e){return function(t,i,a){var s=e?[[],[]]:{};return i=Pt(i,a),Rn(t,function(o,l){var p=i(o,l,t);n(s,o,p)}),s}}const l9=no(function(n,e,t){kn(n,t)?n[t].push(e):n[t]=[e]}),c9=no(function(n,e,t){n[t]=e}),d9=no(function(n,e,t){kn(n,t)?n[t]++:n[t]=1}),u9=no(function(n,e,t){n[t?0:1].push(e)},!0);function p9(n){return n==null?0:wt(n)?n.length:Ye(n).length}function y9(n,e,t){return e in t}const nv=It(function(n,e){var t={},i=e[0];if(n==null)return t;mt(i)?(e.length>1&&(i=Ra(i,e[1])),e=ma(n)):(i=y9,e=mr(e,!1,!1),n=Object(n));for(var a=0,s=e.length;a<s;a++){var o=e[a],l=n[o];i(l,o,n)&&(t[o]=l)}return t}),h9=It(function(n,e){var t=e[0],i;return mt(t)?(t=ad(t),e.length>1&&(i=e[1])):(e=Tr(mr(e,!1,!1),String),t=function(a,s){return!bn(e,s)}),nv(n,t,i)});function rv(n,e,t){return ya.call(n,0,Math.max(0,n.length-(e==null||t?1:e)))}function dd(n,e,t){return n==null||n.length<1?e==null||t?void 0:[]:e==null||t?n[0]:rv(n,n.length-e)}function ro(n,e,t){return ya.call(n,e==null||t?1:e)}function f9(n,e,t){return n==null||n.length<1?e==null||t?void 0:[]:e==null||t?n[n.length-1]:ro(n,Math.max(0,n.length-e))}function m9(n){return yi(n,Boolean)}function T9(n,e){return mr(n,e,!1)}const iv=It(function(n,e){return e=mr(e,!0,!0),yi(n,function(t){return!bn(e,t)})}),E9=It(function(n,e){return iv(n,e)});function ud(n,e,t,i){cg(e)||(i=t,t=e,e=!1),t!=null&&(t=Pt(t,i));for(var a=[],s=[],o=0,l=Dt(n);o<l;o++){var p=n[o],y=t?t(p,o,n):p;e&&!t?((!o||s!==y)&&a.push(p),s=y):t?bn(s,y)||(s.push(y),a.push(p)):bn(a,p)||a.push(p)}return a}const R9=It(function(n){return ud(mr(n,!0,!0))});function b9(n){for(var e=[],t=arguments.length,i=0,a=Dt(n);i<a;i++){var s=n[i];if(!bn(e,s)){var o;for(o=1;o<t&&bn(arguments[o],s);o++);o===t&&e.push(s)}}return e}function pd(n){for(var e=n&&Kg(n,Dt).length||0,t=Array(e),i=0;i<e;i++)t[i]=cd(n,i);return t}const g9=It(pd);function v9(n,e){for(var t={},i=0,a=Dt(n);i<a;i++)e?t[n[i]]=e[i]:t[n[i][0]]=n[i][1];return t}function I9(n,e,t){e==null&&(e=n||0,n=0),t||(t=e<n?-1:1);for(var i=Math.max(Math.ceil((e-n)/t),0),a=Array(i),s=0;s<i;s++,n+=t)a[s]=n;return a}function D9(n,e){if(e==null||e<1)return[];for(var t=[],i=0,a=n.length;i<a;)t.push(ya.call(n,i,i+=e));return t}function yd(n,e){return n._chain?re(e).chain():e}function av(n){return Rn(Xc(n),function(e){var t=re[e]=n[e];re.prototype[e]=function(){var i=[this._wrapped];return z8.apply(i,arguments),yd(this,t.apply(re,i))}}),re}Rn(["pop","push","reverse","shift","sort","splice","unshift"],function(n){var e=Qs[n];re.prototype[n]=function(){var t=this._wrapped;return t!=null&&(e.apply(t,arguments),(n==="shift"||n==="splice")&&t.length===0&&delete t[0]),yd(this,t)}}),Rn(["concat","join","slice"],function(n){var e=Qs[n];re.prototype[n]=function(){var t=this._wrapped;return t!=null&&(t=e.apply(t,arguments)),yd(this,t)}});var sv=av(Object.freeze(Object.defineProperty({__proto__:null,VERSION:Kb,after:X6,all:Xg,allKeys:ma,any:Qg,assign:to,before:kg,bind:Ug,bindAll:q6,chain:j6,chunk:D9,clone:P6,collect:Tr,compact:m9,compose:Z6,constant:Tg,contains:bn,countBy:d9,create:D6,debounce:Y6,default:re,defaults:wg,defer:W6,delay:xg,detect:od,difference:iv,drop:ro,each:Rn,escape:w6,every:Xg,extend:Bg,extendOwn:to,filter:yi,find:od,findIndex:sd,findKey:jg,findLastIndex:Jg,findWhere:e9,first:dd,flatten:T9,foldl:ld,foldr:Zg,forEach:Rn,functions:Xc,get:Ng,groupBy:l9,has:S6,head:dd,identity:ed,include:bn,includes:bn,indexBy:c9,indexOf:Yg,initial:rv,inject:ld,intersection:b9,invert:Cg,invoke:n9,isArguments:Wc,isArray:fr,isArrayBuffer:pg,isBoolean:cg,isDataView:Ks,isDate:i6,isElement:r6,isEmpty:fa,isEqual:f6,isError:s6,isFinite:d6,isFunction:mt,isMap:E6,isMatch:vg,isNaN:mg,isNull:n6,isNumber:dg,isObject:xn,isRegExp:a6,isSet:b6,isString:jc,isSymbol:ug,isTypedArray:bg,isUndefined:lg,isWeakMap:R6,isWeakSet:g6,iteratee:nd,keys:Ye,last:f9,lastIndexOf:K6,map:Tr,mapObject:O6,matcher:Ea,matches:Ea,max:Kg,memoize:J6,methods:Xc,min:i9,mixin:av,negate:ad,noop:$g,now:ba,object:v9,omit:h9,once:Q6,pairs:v6,partial:pi,partition:u9,pick:nv,pluck:cd,property:td,propertyOf:C6,random:rd,range:I9,reduce:ld,reduceRight:Zg,reject:t9,rest:ro,restArguments:It,result:U6,sample:tv,select:yi,shuffle:s9,size:p9,some:Qg,sortBy:o9,sortedIndex:Wg,tail:ro,take:dd,tap:A6,template:F6,templateSettings:N6,throttle:H6,times:B6,toArray:ev,toPath:Mg,transpose:pd,unescape:M6,union:R9,uniq:ud,unique:ud,uniqueId:k6,unzip:pd,values:ui,where:r9,without:E9,wrap:z6,zip:g9},Symbol.toStringTag,{value:"Module"})));sv._=sv;function io(n){return n.charAt(0).toUpperCase()+n.slice(1)}function ov(n){return n.charAt(0).toLowerCase()+n.slice(1)}function lv(n,e){if(n.type!==r.Property||e.type!==r.Property)throw new Error(`Expected property entities for comparison. But got ${n.type} and ${e.type}.`);return n===e||n.id===e.id?!0:n.name!==e.name||n.static!==e.static||n.abstract!==e.abstract?!1:Ht(n.dataType,e.dataType).compatible}function cv(n,e){if(n.type!==r.CustomEntity||e.type!==r.CustomEntity)throw new Error(`Expected custom entities for comparison. But got ${n.type} and ${e.type}.`);if(n===e||n.id===e.id)return!0;if(n.properties.length!==e.properties.length)return!1;let t=[...e.properties];const i=[];for(let a=0;a<n.properties.length;a++){const s=n.properties[a];t.find(l=>{const p=lv(s,l);return p&&(t=t.filter(y=>y.id!==l.id)),p})||i.push(s)}return!(i.length>0)}var Lt=(n=>(n.BothUnconstrained="both-unconstrained",n.AConstraintBUnconstrained="a-constraint-b-unconstrained",n.BConstraintAUnconstrained="b-constraint-a-unconstrained",n.Same="same",n.AIsListBIsNot="a-is-list-b-is-not",n.BIsListAIsNot="b-is-list-a-is-not",n.AIsNullableBIsNot="a-is-nullable-b-is-not",n.BIsNullableAIsNot="b-is-nullable-a-is-not",n.AIsTemplateBIsNot="a-is-template-b-is-not",n.BIsTemplateAIsNot="b-is-template-a-is-not",n.BothUntyped="both-untyped",n.AIsUntypedBIsNot="a-is-untyped-b-is-not",n.BIsUntypedAIsNot="b-is-untyped-a-is-not",n.TypeEntityMismatch="type-entity-mismatch",n.SameCustomEntities="same-custom-entities",n.CompatibleCustomEntities="compatible-custom-entities",n.IncompatibleCustomEntities="incompatible-custom-entities",n.SamePrimitiveEntities="same-primitive-entities",n.IncompatiblePrimitiveEntities="incompatible-primitive-entities",n.SameBuiltInBaseEntities="same-built-in-base-entities",n.IncompatibleBuiltInBaseEntities="incompatible-built-in-base-entities",n.CheckUnknown="check-unknown",n))(Lt||{});function Ht(n,e){var t,i,a,s,o,l,p,y,f,m,b;if(n&&n.type!==r.DataType||e&&e.type!==r.DataType)throw new Error(`Expected data-type entities for comparison. But got ${n==null?void 0:n.type} and ${e==null?void 0:e.type}.`);if(n===null&&e===null)return{compatible:!0,type:"both-unconstrained"};if(n===null)return{compatible:!0,type:"a-constraint-b-unconstrained"};if(e===null)return{compatible:!0,type:"b-constraint-a-unconstrained"};if(n===e)return{compatible:!0,type:"same"};if(n.id===e.id)return{compatible:!0,type:"same"};if(n.isList!==e.isList)return{compatible:!1,type:n.isList?"a-is-list-b-is-not":"b-is-list-a-is-not"};if(n.isNullable!==e.isNullable)return{compatible:!1,type:n.isNullable?"a-is-nullable-b-is-not":"b-is-nullable-a-is-not"};if(n.asType!==e.asType)return{compatible:!1,type:n.asType?"a-is-template-b-is-not":"b-is-template-a-is-not"};if(!n.entity&&e.entity)return{compatible:!0,type:"a-is-untyped-b-is-not"};if(n.entity&&!e.entity)return{compatible:!0,type:"b-is-untyped-a-is-not"};if(!n.entity&&!e.entity)return{compatible:!0,type:"both-untyped"};if(((t=n.entity)==null?void 0:t.type)!==((i=e.entity)==null?void 0:i.type))return{compatible:!1,type:"type-entity-mismatch"};if(((a=n.entity)==null?void 0:a.type)===r.CustomEntity){if(((s=n.entity)==null?void 0:s.id)===((o=e.entity)==null?void 0:o.id))return{compatible:!0,type:"same-custom-entities"};const g=cv(n.entity,e.entity);return{compatible:g,type:g?"compatible-custom-entities":"incompatible-custom-entities"}}return((l=n.entity)==null?void 0:l.type)===r.PrimitiveEntity?((p=n.entity)==null?void 0:p.id)===((y=e.entity)==null?void 0:y.id)?{compatible:!0,type:"same-primitive-entities"}:{compatible:!1,type:"incompatible-primitive-entities"}:((f=n.entity)==null?void 0:f.type)===r.BuiltInBaseEntity?((m=n.entity)==null?void 0:m.id)===((b=e.entity)==null?void 0:b.id)?{compatible:!0,type:"same-built-in-base-entities"}:{compatible:!1,type:"incompatible-built-in-base-entities"}:{compatible:!1,type:"check-unknown"}}function P9(n){const e=n.project.builtInBaseEntities.find(a=>a.id===V.EXECUTION),t={id:n.id+"--infered-data-type",version:1,type:r.DataType,isList:!1,isNullable:!1,andChildrenGroup:null,orChildrenGroup:null,asType:!1,entity:null,constant:!1,defaultValue:null,parent:null},i=R(t,n.project);return i.inferred=!0,i.sync(t),i.setParent(n),i.entity=e,i}function dv(n){return n.dataType?n.dataType:null}function uv(n){var e;return(e=n.declaration)!=null&&e.dataType?n.declaration.dataType:n.readsValue?rn(n.readsValue):null}function hd(n){return n.dataType&&!n.dataType.inferred&&n.dataType.isResolved()?n.dataType:n.readsValue?rn(n.readsValue):null}function pv(n){return rn(n.declaration)}function yv(n){return n.dataType&&!n.dataType.inferred?n.dataType:(n.dataType&&n.dataType.inferred,n.inferDataTypeAndSyncInstancesInputsAndOutputs(),n.dataType)}function hv(n){var e;return((e=n.declaration)==null?void 0:e.dataType)||null}function rn(n){switch(n.type){case r.VariableDeclaration:return yv(n);case r.ArgumentDeclaration:return dv(n);case r.ReturnDeclaration:return hd(n);case r.VariableInstance:return pv(n);case r.InputMap:return uv(n);case r.OutputMap:return hv(n);default:throw new Error(`Cannot infer data type from entity of type ${n.type}.`)}}function ao(n){switch(n.type){case r.ArgumentDeclaration:return n.getDataType();case r.InputMap:return n.getDataType();case r.VariableDeclaration:return n.getDataType();case r.VariableInstance:return n.getDataType();case r.OutputMap:return n.getDataType();case r.ReturnDeclaration:return n.getDataType();case r.Property:return n.getDataType();case r.ValueDescriptor:return n.getDataType();default:return null}}function C(n){if(n){let e=null;return typeof n=="string"?e=n:n.entityId?e=n.entityId:n.type!==r.GenericReference&&(e=n.id),e}return null}function Er(n){return n.declaration||n}function A9(n){return n.type===r.VariableDeclaration?n.parent===n.project?"global-declaration":"local-declaration":n.declaration.parent===n.project?"global-instance":"local-instance"}function fd(n,e){const t=[];if(n.type===r.Project)t.push(...n.variableDeclarations);else{const a=Et(Se(n)).filter(s=>s.type===r.VariableDeclaration);t.push(...a),n.parent&&(ct.includes(n.parent.type)||n.parent.type===r.Project)&&t.push(...fd(n.parent))}return t}function S9(n){return n.replace(/(?:^\w|[A-Z]|\b\w)/g,function(e,t){return t===0?e.toLowerCase():e.toUpperCase()}).replace(/\s+/g,"")}function O9(n){return n.split(/\s+/).map(i=>i[0].toUpperCase()+i.slice(1).toLowerCase()).join("")}function fv(n){var e;return(e=n.match(/[A-Z]{2,}(?=[A-Z][a-z]+[0-9]*|\b)|[A-Z]?[a-z]+[0-9]*|[A-Z]|[0-9]+/g))==null?void 0:e.map(t=>t.toLowerCase()).join("-")}function so(n){return fv(n).toLowerCase()}function Rr(n,e=!0){if(!(n!=null&&n.dataType))return"Any data type";if(!n.dataType.entity)return n.dataType.isList?"List of an unknown data type":"Unknown data type";if(n.dataType.entity.type===r.PrimitiveEntity){let t=n.dataType.entity.name;switch(n.dataType.entity.name){case A.String:t="Text";break;case A.JSON:t=e?"Any data structure":"Unknown data structure";break;default:t=n.dataType.entity.name;break}return n.dataType.isList?`List of ${t}s`:`${t.slice(0,1).toUpperCase()}${t.slice(1)}`}else return n.dataType.isList?`List of ${n.dataType.entity.name} entities`:`${n.dataType.entity.name.slice(0,1).toUpperCase()+n.dataType.entity.name.slice(1)} entity`}function mv(n){return Rr(n.declaration)}function C9(n){return n.type===r.VariableInstance?mv(n):Rr(n)}function Tv(n){if(!n)return"Any data type";if(!n.entity)return"Inherited";if(n.entity.type===r.PrimitiveEntity){const e=n.entity.name===A.String?"Text":n.entity.name;return n.isList?`List of ${e}s`:`${e.slice(0,1).toUpperCase()}${e.slice(1)}`}else if(n.entity.type===r.CustomEntity){const e=Td(n.entity);return n.isList?`List of ${e} entities`:e.slice(0,1).toUpperCase()+e.slice(1)}else if(n.entity.type===r.BuiltInBaseEntity){const e=md(n.entity);return n.isList?`List of ${e} entities`:e.slice(0,1).toUpperCase()+e.slice(1)}else return n.isList?`List of ${n.entity.name} entities`:`${n.entity.name.slice(0,1).toUpperCase()+n.entity.name.slice(1)} entity`}function Ev(n){if(!n.dataType)return"Any data type";if(!n.dataType.entity)return"Inherited";if(n.dataType.entity.type===r.PrimitiveEntity){const e=n.dataType.entity.name===A.String?"Text":n.dataType.entity.name;return n.dataType.isList?`List of ${e}s`:`${e.slice(0,1).toUpperCase()}${e.slice(1)}`}else if(n.dataType.entity.type===r.CustomEntity){const e=Td(n.dataType.entity);return n.dataType.isList?`List of ${e} entities`:e.slice(0,1).toUpperCase()+e.slice(1)}else if(n.dataType.entity.type===r.BuiltInBaseEntity){const e=md(n.dataType.entity);return n.dataType.isList?`List of ${e} entities`:e.slice(0,1).toUpperCase()+e.slice(1)}else return n.dataType.isList?`List of ${n.dataType.entity.name} entities`:`${n.dataType.entity.name.slice(0,1).toUpperCase()+n.dataType.entity.name.slice(1)} entity`}function Rv(n){switch(n.type){case r.Property:return Ev(n);case r.VariableDeclaration:return Rr(n);case r.ArgumentDeclaration:return Rr(n,!1);case r.InputMap:{const e=n.declaration;return e?Rv(e):"Unknown data type"}case r.ReturnDeclaration:return Rr(n,!1);case r.OutputMap:{const e=n.declaration;return Rr(e,!1)}}return"Unknown data type"}function oo(n){switch(n.declaration.id){case _e.Equal:return"is equal to";case _e.NotEqual:return"is not equal to";case _e.MoreThan:return"is greater than";case _e.MoreThanOrEqual:return"is greater than or equal to";case _e.LessThan:return"is less than";case _e.LessThanOrEqual:return"is less than or equal to";case _e.And:return"and";case _e.Or:return"or";case Nt.Empty:return"is empty";case Nt.NotEmpty:return"is not empty"}}function bv(n){return n.includes(V.HTTP_ENDPOINT)?"HTTP endpoint":n.includes(V.PERSISTED_ENTITY)?"Persisted entity":n.includes(V.CRON_JOB)?"Scheduled execution":n.includes(V.RELATIONAL_DATABASE)?"Relational database":"Entity"}function md(n){switch(n.name){case V.HTTP_ENDPOINT:return"HTTP endpoint";case V.PERSISTED_ENTITY:return"Persisted entity";case V.CRON_JOB:return"Scheduled execution";case V.RELATIONAL_DATABASE:return"Relational database"}return"Entity"}function Td(n){const e=rI(n);if(!e){const t=tI(n);return t.includes(V.HTTP_ENDPOINT)?"HTTP endpoint":t.includes(V.PERSISTED_ENTITY)?"Persisted entity":t.includes(V.CRON_JOB)?"Scheduled execution":t.includes(V.RELATIONAL_DATABASE)?"Relational database":S(n,n.project)+" entity"}return S(e,n.project)+" entity"}function gv(n){let e="Find ";return n.outputsDeclarations.forEach((t,i)=>{const a=ao(t),s=ov(a&&a.entity?S(a.entity,n.project):"unstructured data");i===0?e+=`${s} `:i===n.outputsDeclarations.length-1?e+=`and ${s} `:e+=`, ${s} `}),e}function vv(n){switch(n.name){case A.String:return"Text";case A.Number:return"Number";case A.Boolean:return"Boolean";case A.JSON:return"Data structure";case A.UUID:return"Unique identifier";case A.Date:return"Date";case A.EntityTemplate:return"Entity as template";case A.Enum:return"Enumeration";case A.File:return"File";case A.Null:return"Empty";case A.ActionDescriptor:return"Action descriptor";default:return n.name}}function Iv(n){switch(n.id){case Q.List:return"Loop over list items";case Q.ManualFlow:return"Manual flow control loop";case Q.ObjectKeys:return"Loop over object keys";case Q.ObjectValues:return"Loop over object values";case Q.Counted:return"Loop given number of times";case Q.String:return"Loop over text characters";case lt.Addition:return"Sum numbers";case lt.Substraction:return"Subtract numbers";case lt.Multiplication:return"Multiply numbers";case lt.Division:return"Divide numbers";case lt.Remainder:return"Get remainder of numbers";case lt.Exponentiation:return"Get exponent of numbers";case Ae.AddIndex:return"Add at index position";case Ae.DeleteFirst:return"Delete first character";case Ae.DeleteLast:return"Delete last character";case Ae.DeleteIndex:return"Delete at index position";case Ae.Join:return"Join texts";case Ae.ReplaceAllMatches:return"Replace all matches";case Ae.ReplaceFirst:return"Replace first match";case Ae.ReplaceLast:return"Replace last match";case Ae.Split:return"Split text";case Ae.ReplaceIndex:return"Replace at index position";case Ae.ReplaceSingleMatch:return"Replace single match";case Ae.GetFirst:return"Get first character";case Ae.GetLast:return"Get last character";case Ae.GetIndex:return"Get at index position";case Ae.Append:return"Add at the end";case Ae.Prepend:return"Add at the start";case Oe.Wait:return"Wait";case Oe.Parallel:return"Run in parallel";case Oe.Sequential:return"Run in sequence";case Xe.HttpRequest:return"HTTP request";case Ze.CreateNewInstance:return"Create new copy of entity";case W.AddIndex:return"Add item at index position";case W.DeleteFirst:return"Delete first item";case W.DeleteLast:return"Delete last item";case W.DeleteIndex:return"Delete item at index position";case W.Join:return"Join lists";case W.ReplaceAllMatches:return"Replace all matches";case W.ReplaceFirst:return"Replace first match";case W.ReplaceLast:return"Replace last match";case W.Split:return"Split list";case W.ReplaceIndex:return"Replace at index position";case W.ReplaceSingleMatch:return"Replace single match";case W.GetFirst:return"Get first item";case W.GetLast:return"Get last item";case W.GetIndex:return"Get item at index position";case W.Append:return"Add item at the end";case W.Prepend:return"Add item at the start";case on.PROJECT_PUBLICATION_COMPLETED:return"Project publication completed";default:return(n.name.slice(0,1).toUpperCase()+n.name.slice(1)).replaceAll("-"," ")}}function S(n,e){var t;if(r.FunctionDeclaration===n.type){const i=n.name;if(Object.values(Ot).includes(i))switch(i){case Ot.AbortExecution:return"Abort execution";case Ot.DeletePersistedEntity:return"Delete persisted entity";case Ot.SoftDeletePersistedEntity:return"Soft delete persisted entity";default:return io(n.type).replaceAll("-"," ")}return i}if(r.BuiltInBaseEntity===n.type)return bv([n.name]);if(Zd.includes(n.type)&&n.type!==r.ActionDescriptor)return n.name;switch(n.type){case r.Search:return gv(n);case r.Operation:case r.InternalCall:case r.Loop:const i=Mt(n.declaration,e);return S(i,e);case r.ActionDescriptor:return Iv(n);case r.BreakStatement:const a=Mt(n.parent,e);return`Stop loop ${S(a,e)}`;case r.ContinueStatement:const s=Mt(n.parent,e);return`Execute next iteration of ${S(s,e)}`;case r.FunctionCall:return Mt(n.declaration,e).name;case r.Condition:{const l=n;if((t=n.inputs)!=null&&t.length){const p=S(l.inputs[0],l.project);if(l.inputs[1]){const y=l.inputs[1].declaration.name;return`If ${p} ${oo(l)} ${y}`}return`If ${p} ${oo(l)}`}else return`If ${oo(l)}`}case r.ReturnStatement:{const l=Mt(n.parent,e);return`Output of ${S(l,e)}`}case r.InputMap:if(n.declaration){const l=Mt(n.declaration,e);return S(l,e)||""}else return n.name||"";case r.VariableInstance:{const l=Mt(n.declaration,e);return S(l,e)||""}case r.OutputMap:if(n.declaration){const l=Mt(n.declaration,e);return(l==null?void 0:l.name)||""}else return"";case r.PrimitiveEntity:case r.PrimitiveValue:return vv(n);default:return io(n.type).replaceAll("-"," ")}}function lo(n,e){const t=[];n.name||t.push(new E({id:`${n.id}--${D.EmptyName}`,message:`Entity with id "${n.id}" and type "${n.type}" has an empty name. Please provide a 'name' string.`,severity:T.Error,code:D.EmptyName,issue:null}));const i=e.entities.filter(a=>a.name===n.name);return i.length&&t.push(new E({id:`${n.id}--${D.NameNotUniqueInScope}`,message:`Entity with id "${n.id}" and type "${n.type}" has a name "${n.name}" that is not unique in the project. Entity with id "${i[0].id}" has the same name.
|
|
14
14
|
Please provide a unique 'name' string.`,severity:T.Error,code:D.NameNotUniqueInScope,issue:null})),t}function Ed(n,e){const t=[];n.name||t.push(new E({id:`${n.id}--${D.EmptyName}`,message:`Entity with id "${n.id}" and type "${n.type}" has an empty name. Please provide a 'name' string.`,severity:T.Error,code:D.EmptyName,issue:null}));const i=n.parent?C(n.parent):null;let a=e;i&&(a=e.get(i));const s=[];a.type===r.CustomEntity?s.push(...a.methods.map(l=>l)):a.type===r.Project?s.push(...a.functions.map(l=>l)):a.type===r.Loop?a.body&&s.push(a.body):a.type===r.InstalledProject&&s.push(...a.functions.map(l=>l));const o=s.filter(l=>l.name===n.name);return o.length&&t.push(new E({id:`${n.id}--${D.NameNotUniqueInScope}`,message:`Entity with id "${n.id}" and type "${n.type}" has a name "${n.name}" that is not unique in ${a.type===r.Project?"the globally declared project scope":"its parent entity"}. Entity with id "${o[0].id}" has the same name.
|
|
15
15
|
Please provide a unique 'name' string.`,severity:T.Error,code:D.NameNotUniqueInScope,issue:null})),t}function Rd(n,e){const t=[];n.name||t.push(new E({id:`${n.id}--${D.EmptyName}`,message:`Entity with id "${n.id}" and type "${n.type}" has an empty name. Please provide a 'name' string.`,severity:T.Error,code:D.EmptyName,issue:null}));const i=n.parent&&Mt(n.parent,e)||e;if(!i)t.push(new E({id:`${n.id}--parent-reference--${h.ReferencedEntityNotFound}`,message:`The entity with id '${n.parent}' that isn't yet found in the project. Perhaps it should be created first. Or perhaps the ID is incorrect.`,severity:T.Error,code:h.ReferencedEntityNotFound,issue:null}));else{const s=fd(i).filter(o=>o.name===n.name);s.length&&t.push(new E({id:`${n.id}--${D.NameNotUniqueInScope}`,message:`Entity with id "${n.id}" and type "${n.type}" has a name "${n.name}" that is not unique in its scope or higher scopes. Entity with id "${s[0].id}" has the same name.
|
|
16
16
|
Please provide a unique 'name' string.`,severity:T.Error,code:D.NameNotUniqueInScope,issue:null}))}return t}function bd(n,e){const t=[];n.name||t.push(new E({id:`${n.id}--${D.EmptyName}`,message:`Entity with id "${n.id}" and type "${n.type}" has an empty name. Please provide a 'name' string.`,severity:T.Error,code:D.EmptyName,issue:null}));const i=C(n.parent);if(!i)t.push(new E({id:`${n.id}--parent-reference--${h.InvalidReferenceObjectStructure}`,message:`Reference object at 'parent' property for entity with id "${n.id}" and type "${n.type}" is not a valid reference. A reference needs to be a 'id' string of an existing entity in the project.`,severity:T.Error,code:h.InvalidReferenceObjectStructure,issue:null}));else{const a=e.get(i);if(!a)t.push(new E({id:`${n.id}--parent-reference--${h.ReferencedEntityNotFound}`,message:`The entity with id '${i}' that isn't yet found in the project. Perhaps it should be created first. Or perhaps the ID is incorrect.`,severity:T.Error,code:h.ReferencedEntityNotFound,issue:null}));else{const o=a.properties.filter(l=>l.name===n.name);o.length&&t.push(new E({id:`${n.id}--${D.NameNotUniqueInScope}`,message:`Entity with id "${n.id}" and type "${n.type}" has a name "${n.name}" that is not unique among all properties in the parent entity. Entity with id "${o[0].id}" has the same name.
|
|
@@ -34,7 +34,7 @@ ${Jn}`,issue:null}))}}}const o=i.parent&&t.get(i.parent)||t.getBuiltIn(i.parent)
|
|
|
34
34
|
The entitities of type '${L(f,"', '","' and '")}' can only have one 'data-type' child under the 'dataType' property so no 'parentRelationType' is needed.`,issue:null})),o.dataType)){const m=(p=o.dataType)==null?void 0:p.id;a.push(new E({id:`${e.id}--${h.NewEntityWouldOverriteExisting}`,code:h.NewEntityWouldOverriteExisting,severity:T.Error,message:`The entity with id '${e.id}' and type '${e.type}', cannot be added as a child to the entity with id '${i.parent}' and type '${y}', because it already has a 'data-type' child with id '${m}'.
|
|
35
35
|
The entitities of type '${L(f,"', '","' and '")}' can only have one 'data-type' child under the 'dataType' property. You can inspect the existing data-type entity with the 'describe_entity' action. Like so:
|
|
36
36
|
${an({describe_entity:m})}
|
|
37
|
-
Alternatively you can update the entity with 'update' action. Or replace it by first removing it and then creating a new one.`,issue:null}))}y===r.ActionDescriptor&&(!i.parentRelationType||!(i.parentRelationType===Ue.DynamicArgumentTypes||i.parentRelationType===Ue.DynamicReturnTypes))&&a.push(new E({id:`${e.id}--${h.InvalidParentRelationType}`,code:h.InvalidParentRelationType,severity:T.Error,message:`The entity with id '${e.id}' and type '${e.type}', must have a 'parentRelationType' property set to either 'dynamic-argument-types' or 'dynamic-return-types' when being added as a child to an entity of type 'action-descriptor'.`,issue:null})),y===r.DataType&&(!i.parentRelationType||!(i.parentRelationType===Ue.AndDataTypeGroup||i.parentRelationType===Ue.OrDataTypeGroup))&&a.push(new E({id:`${e.id}--${h.InvalidParentRelationType}`,code:h.InvalidParentRelationType,severity:T.Error,message:`The entity with id '${e.id}' and type '${e.type}', must have a 'parentRelationType' property set to either 'or-data-type-group' or 'and-data-type-group' when being added as a child to an entity of type 'data-type'.`,issue:null}))}return{errors:a,modifiedData:i}}validateGeneratedUpdate(e){return{errors:[],modifiedData:e}}addSelfToProject(){const e=[this];return this.parent.type===r.DataType?this.parentRelationType===Ue.AndDataTypeGroup?this.parent.addToAndGroup(this):this.parentRelationType===Ue.OrDataTypeGroup&&this.parent.addToOrGroup(this):this.parent.type===r.ActionDescriptor?this.parentRelationType===Ue.DynamicArgumentTypes?this.parent.setDynamicArgumentTypes(this):this.parentRelationType===Ue.DynamicReturnTypes&&this.parent.setDynamicReturnTypes(this):this.parent.setDataType(this),e.push(this.parent),{affected:v(e),self:this}}setParent(e){return this.parent=e,this}removeChildGroup(e){if(this.andChildrenGroup){const t=this.andChildrenGroup.findIndex(i=>i.id===e.id);t!==-1&&this.andChildrenGroup.splice(t,1)}if(this.orChildrenGroup){const t=this.orChildrenGroup.findIndex(i=>i.id===e.id);t!==-1&&this.orChildrenGroup.splice(t,1)}return this}initChildren(){if(this.initialized)return this;if(this.initialized=!0,this.initialData.defaultValue&&(this.defaultValue=R(this.initialData.defaultValue,this.project),this.defaultValue.setParent(this),this.defaultValue.initChildren()),this.initialData.entity)if(this.initialData.entity.type===r.GenericReference){const e=this.project.findSubscribedInstanceFromReference(this.initialData.entity);this.entity=e}else this.entity=R(this.initialData.entity,this.project);return this.initialData.andChildrenGroup&&(this.andChildrenGroup=this.initialData.andChildrenGroup.map(e=>R(e,this.project))),this.initialData.orChildrenGroup&&(this.orChildrenGroup=this.initialData.orChildrenGroup.map(e=>R(e,this.project))),this}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}sync(e){return this.version=e.version||this.version,this.isNullable=e.isNullable||this.isNullable,this.isList=e.isList||this.isList,this.constant=e.constant||this.constant,this.asType=e.asType||this.asType,this.options=e.options||this.options,this.parentRelationType=e.parentRelationType||this.parentRelationType,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){const i=[],a=[];if(t.has(this.id))return{affected:[],removed:[]};if(t.add(this.id),a.push(this),this.unsubscribe(),this.defaultValue){const{affected:s,removed:o}=this.defaultValue.remove({ignoreUpstream:!0,seenEntities:t});i.push(...s),a.push(...o)}if(this.entity&&this.entity.type===r.CustomEntity&&this.entity.parent===this){const{affected:s,removed:o}=this.entity.remove({ignoreUpstream:!0,seenEntities:t});i.push(...s),a.push(...o)}if(!e){this.parent.type===r.DataType&&this.parent.removeChildGroup(this);const s=this.parent;if(s.type===r.DataType){if(this.parentRelationType===Ue.AndDataTypeGroup){if(Array.isArray(s.andChildrenGroup)){const o=s.andChildrenGroup.findIndex(l=>l.id===this.id);o!==-1&&s.andChildrenGroup.splice(o,1)}}else if(this.parentRelationType===Ue.OrDataTypeGroup&&Array.isArray(s.orChildrenGroup)){const o=s.orChildrenGroup.findIndex(l=>l.id===this.id);o!==-1&&s.orChildrenGroup.splice(o,1)}}else if(s.type===r.ActionDescriptor){const o=this.parent;this.parentRelationType===Ue.DynamicArgumentTypes?o.removeDynamicArgumentTypes():this.parentRelationType===Ue.DynamicReturnTypes&&o.removeDynamicReturnTypes()}else this.parent.removeDataType();i.push(s)}return{affected:v(i),removed:v(a)}}restore({seenEntities:e}={seenEntities:new Set}){const t=[];if(e.has(this.id))return{affected:[],self:this};if(e.add(this.id),this.subscribe(),this.defaultValue){const{affected:i}=this.defaultValue.restore({seenEntities:e});t.push(...i)}if(this.entity&&this.entity.type===r.CustomEntity&&this.entity.parent===this){const{affected:i}=this.entity.restore({seenEntities:e});t.push(...i)}if(this.parent.type===r.DataType){const i=this.parent;Array.isArray(i.andChildrenGroup)&&i.andChildrenGroup.push(this)}if(this.parent.type===r.DataType){const i=this.parent;this.parentRelationType===Ue.AndDataTypeGroup?Array.isArray(i.andChildrenGroup)&&i.andChildrenGroup.push(this):this.parentRelationType===Ue.OrDataTypeGroup&&Array.isArray(i.orChildrenGroup)&&i.orChildrenGroup.push(this)}else if(this.parent.type===r.ActionDescriptor){const i=this.parent;this.parentRelationType===Ue.DynamicArgumentTypes?i.setDynamicArgumentTypes(this):this.parentRelationType===Ue.DynamicReturnTypes&&i.setDynamicReturnTypes(this)}else{const i=this.parent;i.setDataType(this),t.push(i)}return{affected:t,self:this}}toFlat(e=new Set){var i,a,s;return e.has(this.id)?[]:(e.add(this.id),[this,...((i=this.andChildrenGroup)==null?void 0:i.flatMap(o=>o.toFlat(e)))||[],...((a=this.orChildrenGroup)==null?void 0:a.flatMap(o=>o.toFlat(e)))||[],...((s=this.entity)==null?void 0:s.toFlat(e))||[]])}toFlatIds(e=new Set){var i,a,s;return e.has(this.id)?[]:(e.add(this.id),[this.id,...((i=this.andChildrenGroup)==null?void 0:i.flatMap(o=>o.toFlatIds(e)))||[],...((a=this.orChildrenGroup)==null?void 0:a.flatMap(o=>o.toFlatIds(e)))||[],...((s=this.entity)==null?void 0:s.toFlatIds(e))||[]])}toJSON(){var e,t,i,a;return{id:this.id,version:this.version,type:this.type,isNullable:this.isNullable,options:this.options,isList:this.isList,constant:this.constant,asType:this.asType,defaultValue:((e=this.defaultValue)==null?void 0:e.toJSON())||null,like:this.like,parentRelationType:this.parentRelationType,andChildrenGroup:((t=this.andChildrenGroup)==null?void 0:t.map(s=>s.toJSON()))||null,orChildrenGroup:((i=this.orChildrenGroup)==null?void 0:i.map(s=>s.toJSON()))||null,entity:((a=this.entity)==null?void 0:a.toReference())||null,parent:this.parent.toReference()}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){var e,t,i,a;return{id:this.id,version:this.version,type:this.type,isList:this.isList,isNullable:this.isNullable,options:this.options,constant:this.constant,asType:this.asType,parentRelationType:this.parentRelationType,like:this.like,defaultValue:((e=this.defaultValue)==null?void 0:e.toReference())||null,andChildrenGroup:((t=this.andChildrenGroup)==null?void 0:t.map(s=>s.toReference()))||null,orChildrenGroup:((i=this.orChildrenGroup)==null?void 0:i.map(s=>s.toReference()))||null,entity:((a=this.entity)==null?void 0:a.toReference())||null,parent:this.parent.toReference()}}toFlatJSON(e=new Set){var i,a,s,o;return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...((i=this.defaultValue)==null?void 0:i.toFlatJSON(e))||[],...((a=this.andChildrenGroup)==null?void 0:a.flatMap(l=>l.toFlatJSON(e)))||[],...((s=this.orChildrenGroup)==null?void 0:s.flatMap(l=>l.toFlatJSON(e)))||[],...((o=this.entity)==null?void 0:o.toFlatJSON(e))||[]])}toGenerationTarget(){var e;return{id:this.id,type:this.type,isNullable:this.isNullable,options:this.options,isList:this.isList,constant:this.constant,like:this.like,parentRelationType:this.parentRelationType,asType:this.asType,entity:((e=this.entity)==null?void 0:e.id)||null,parent:this.parent.id}}toFlatGenerationTarget(e=new Set){var i,a,s;return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...((i=this.defaultValue)==null?void 0:i.toFlatGenerationTarget(e))||[],...((a=this.andChildrenGroup)==null?void 0:a.flatMap(o=>o.toFlatGenerationTarget(e)))||[],...((s=this.orChildrenGroup)==null?void 0:s.flatMap(o=>o.toFlatGenerationTarget(e)))||[],...this.entity&&this.entity.type==r.CustomEntity&&this.entity.parent===this&&this.entity.toFlatGenerationTarget(e)||[]])}clearErrors(){var e,t,i,a;return this.errors=[],(e=this.defaultValue)==null||e.clearErrors(),(t=this.andChildrenGroup)==null||t.forEach(s=>s.clearErrors()),(i=this.orChildrenGroup)==null||i.forEach(s=>s.clearErrors()),this.inferred&&((a=this.entity)==null||a.clearErrors()),this}validate(){const e=L9(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors]}getShallowErrors(){return this.errors}clone(e=null,t=null,i=!0){var b,g,I,P;const a=this.toJSON(),s=t||Ke(mv(this),r.DataType,this.project),o=s.split("-id"),l=o[o.length-1||0]||s;a.id=s;const p=Ut(a,this.project);e&&p.setParent(e),i&&p.subscribe(),p.initChildren();const y=(b=this.defaultValue)==null?void 0:b.clone(p,l+"-default-value-id",i);p.defaultValue=y||null;const f=(g=this.andChildrenGroup)==null?void 0:g.map((B,Y)=>B.clone(this,l+"-and-group-data-type-"+Y+"-id",i)),m=(I=this.orChildrenGroup)==null?void 0:I.map((B,Y)=>B.clone(this,l+"-or-group-data-type-"+Y+"-id",i));if(p.andChildrenGroup=f||null,p.orChildrenGroup=m||null,this.entity&&this.entity.type===r.CustomEntity&&((P=this.entity)==null?void 0:P.parent)===this){const B=this.entity.clone(p,l+"-inferred-entity-id",i);p.setEntity(B)}else this.entity&&p.setEntity(this.entity);return p}merge(e){const t=[],i=[],a=[];return this.asType!==(e==null?void 0:e.asType)&&(this.sync({asType:e==null?void 0:e.asType}),t.push(this)),this.isNullable!==(e==null?void 0:e.isNullable)&&(this.sync({isNullable:e==null?void 0:e.isNullable}),t.push(this)),this.isList!==!(e!=null&&e.isList)&&(this.sync({isList:e==null?void 0:e.isList}),t.push(this)),this.constant!==(e==null?void 0:e.constant)&&(this.sync({constant:e==null?void 0:e.constant}),t.push(this)),this.like!==(e==null?void 0:e.like)&&(this.sync({like:e==null?void 0:e.like}),t.push(this)),e!=null&&e.inferred,{updated:v(t),added:v(i),removed:v(a),self:this}}addToAndGroup(e){return this.andChildrenGroup||(this.andChildrenGroup=[]),this.andChildrenGroup.includes(e)||this.andChildrenGroup.push(e),this}addToOrGroup(e){return this.orChildrenGroup||(this.orChildrenGroup=[]),this.orChildrenGroup.includes(e)||this.orChildrenGroup.push(e),this}getDefaultValue(){return this.defaultValue}setDefaultValue(e){return this.defaultValue=e,this}setEntity(e){return this.entity=e,this}isResolved(){return[r.BuiltInBaseEntity,r.ActionDescriptor].includes(this.parent.type)||Yn(this.parent)?!0:!(!this.entity&&(!this.andChildrenGroup||!this.andChildrenGroup.length)&&(!this.orChildrenGroup||!this.orChildrenGroup.length))}inferFromInputs(e){var t;if(!this.inferred)return this;if(!this.entity&&e.length){const i={id:this.id+"--infered-entity",type:r.CustomEntity,version:1,name:S(this,this.project),description:((t=this.parent)==null?void 0:t.description)||null,static:!0,abstract:!1,properties:[],methods:[],extends:[],implements:[],abstractMethods:[],x:0,y:0,parent:this.toReference()},a=R(i,this.project);a.sync(i),a.setParent(this),a.initChildren(),this.setEntity(a)}return this.entity&&this.entity.inferFromInputs(e),this}};c(ye,"MUTABLE_BASE_PROPERTIES",["isNullable","isList","constant","asType","options","parentRelationType"]),c(ye,"INMUTABLE_BASE_PROPERTIES",["id","version","type"]),c(ye,"BASE_PROPERTIES",[...ye.MUTABLE_BASE_PROPERTIES,...ye.INMUTABLE_BASE_PROPERTIES]),c(ye,"MUTABLE_META_PROPERTIES",[...ye.MUTABLE_BASE_PROPERTIES,"inferred"]),c(ye,"INMUTABLE_META_PROPERTIES",[...ye.INMUTABLE_BASE_PROPERTIES]),c(ye,"META_PROPERTIES",[...ye.MUTABLE_META_PROPERTIES,...ye.INMUTABLE_META_PROPERTIES]),c(ye,"MUTABLE_UPSTREAM_PROPERTIES",["entity","andChildrenGroup","orChildrenGroup","parent"]),c(ye,"INMUTABLE_UPSTREAM_PROPERTIES",[]),c(ye,"UPSTREAM_PROPERTIES",[...ye.MUTABLE_UPSTREAM_PROPERTIES,...ye.INMUTABLE_UPSTREAM_PROPERTIES]),c(ye,"MUTABLE_DOWNSTREAM_PROPERTIES",["defaultValue"]),c(ye,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(ye,"DOWNSTREAM_PROPERTIES",[...ye.MUTABLE_DOWNSTREAM_PROPERTIES,...ye.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(ye,"PROPERTIES",[...ye.META_PROPERTIES,...ye.UPSTREAM_PROPERTIES,...ye.DOWNSTREAM_PROPERTIES]);let hi=ye;function F9(n){var l;const e=ax(),t=n.toJSON();e.safeParse(t).success;const a=U9(n),s=In(n),o=[...a,...s];if(n.id==="exec-sequentially-operation-call-id"){const p=H({id:`${n.id}--${_.PropertyImplementsNonAbstact}`,message:`Property "${S(n,n.project)}" with id "${n.id}" implements a non-abstract property "${S(n,n.project)}" with id "${n.id}".`,issue:null,severity:T.Error,code:_.PropertyImplementsNonAbstact,entity:n});o.push(p.error)}return n.outputs.forEach(p=>p.validate()),(l=n.error)==null||l.validate(),ne(n.errors,o)}function U9(n){const e=[];return n.inputs.forEach(t=>{t.validate()}),ne(n.errors,e)}const ie=class ie{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"x");c(this,"y");c(this,"type",r.Operation);c(this,"declaration");c(this,"inputs",[]);c(this,"outputs",[]);c(this,"process",null);c(this,"successCalls",[]);c(this,"errorCalls",[]);c(this,"error",null);c(this,"calledBySuccess",[]);c(this,"calledByError",[]);c(this,"calledByEntry",[]);c(this,"parent");c(this,"errors",[]);c(this,"project");c(this,"initialized",!1);this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.x=e.x,this.y=e.y}static fromGenerationTarget(e,t){let i=t;if(e.parent){const m=C(e.parent);i=t.get(m)}const a=C(e.declaration),s=t.get(a),o=e.calledByEntry.map(m=>{const b=C(m);return t.get(b)}),l=e.calledBySuccess.map(m=>{const b=C(m);return t.get(b)}),p=e.calledByError.map(m=>{const b=C(m);return t.get(b)}),y={id:e.id,version:1,type:r.Operation,declaration:s,calledByEntry:o,calledBySuccess:l,calledByError:p,errorCalls:[],successCalls:[],inputs:[],outputs:[],process:null,error:null,x:0,y:0,parent:i},f=R(y,t);return f.setParent(i),f.initChildren(),f}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[],s=je(i,{parent:{list:!1,types:[...ct,r.Project],optional:!0}},t);i=s.modifiedData,a.push(...s.errors,...Be(i));const o=C(i.declaration);if(o){const l=Nv(o,t);a.push(...l)}else{const l=`
|
|
37
|
+
Alternatively you can update the entity with 'update' action. Or replace it by first removing it and then creating a new one.`,issue:null}))}y===r.ActionDescriptor&&(!i.parentRelationType||!(i.parentRelationType===Ue.DynamicArgumentTypes||i.parentRelationType===Ue.DynamicReturnTypes))&&a.push(new E({id:`${e.id}--${h.InvalidParentRelationType}`,code:h.InvalidParentRelationType,severity:T.Error,message:`The entity with id '${e.id}' and type '${e.type}', must have a 'parentRelationType' property set to either 'dynamic-argument-types' or 'dynamic-return-types' when being added as a child to an entity of type 'action-descriptor'.`,issue:null})),y===r.DataType&&(!i.parentRelationType||!(i.parentRelationType===Ue.AndDataTypeGroup||i.parentRelationType===Ue.OrDataTypeGroup))&&a.push(new E({id:`${e.id}--${h.InvalidParentRelationType}`,code:h.InvalidParentRelationType,severity:T.Error,message:`The entity with id '${e.id}' and type '${e.type}', must have a 'parentRelationType' property set to either 'or-data-type-group' or 'and-data-type-group' when being added as a child to an entity of type 'data-type'.`,issue:null}))}return{errors:a,modifiedData:i}}validateGeneratedUpdate(e){return{errors:[],modifiedData:e}}addSelfToProject(){const e=[this];return this.parent.type===r.DataType?this.parentRelationType===Ue.AndDataTypeGroup?this.parent.addToAndGroup(this):this.parentRelationType===Ue.OrDataTypeGroup&&this.parent.addToOrGroup(this):this.parent.type===r.ActionDescriptor?this.parentRelationType===Ue.DynamicArgumentTypes?this.parent.setDynamicArgumentTypes(this):this.parentRelationType===Ue.DynamicReturnTypes&&this.parent.setDynamicReturnTypes(this):this.parent.setDataType(this),e.push(this.parent),{affected:v(e),self:this}}setParent(e){return this.parent=e,this}removeChildGroup(e){if(this.andChildrenGroup){const t=this.andChildrenGroup.findIndex(i=>i.id===e.id);t!==-1&&this.andChildrenGroup.splice(t,1)}if(this.orChildrenGroup){const t=this.orChildrenGroup.findIndex(i=>i.id===e.id);t!==-1&&this.orChildrenGroup.splice(t,1)}return this}initChildren(){if(this.initialized)return this;if(this.initialized=!0,this.initialData.defaultValue&&(this.defaultValue=R(this.initialData.defaultValue,this.project),this.defaultValue.setParent(this),this.defaultValue.initChildren()),this.initialData.entity)if(this.initialData.entity.type===r.GenericReference){const e=this.project.findSubscribedInstanceFromReference(this.initialData.entity);this.entity=e}else this.entity=R(this.initialData.entity,this.project);return this.initialData.andChildrenGroup&&(this.andChildrenGroup=this.initialData.andChildrenGroup.map(e=>R(e,this.project))),this.initialData.orChildrenGroup&&(this.orChildrenGroup=this.initialData.orChildrenGroup.map(e=>R(e,this.project))),this}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}sync(e){return this.version=e.version||this.version,this.isNullable=e.isNullable||this.isNullable,this.isList=e.isList||this.isList,this.constant=e.constant||this.constant,this.asType=e.asType||this.asType,this.options=e.options||this.options,this.parentRelationType=e.parentRelationType||this.parentRelationType,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){const i=[],a=[];if(t.has(this.id))return{affected:[],removed:[]};if(t.add(this.id),a.push(this),this.unsubscribe(),this.defaultValue){const{affected:s,removed:o}=this.defaultValue.remove({ignoreUpstream:!0,seenEntities:t});i.push(...s),a.push(...o)}if(this.entity&&this.entity.type===r.CustomEntity&&this.entity.parent===this){const{affected:s,removed:o}=this.entity.remove({ignoreUpstream:!0,seenEntities:t});i.push(...s),a.push(...o)}if(!e){this.parent.type===r.DataType&&this.parent.removeChildGroup(this);const s=this.parent;if(s.type===r.DataType){if(this.parentRelationType===Ue.AndDataTypeGroup){if(Array.isArray(s.andChildrenGroup)){const o=s.andChildrenGroup.findIndex(l=>l.id===this.id);o!==-1&&s.andChildrenGroup.splice(o,1)}}else if(this.parentRelationType===Ue.OrDataTypeGroup&&Array.isArray(s.orChildrenGroup)){const o=s.orChildrenGroup.findIndex(l=>l.id===this.id);o!==-1&&s.orChildrenGroup.splice(o,1)}}else if(s.type===r.ActionDescriptor){const o=this.parent;this.parentRelationType===Ue.DynamicArgumentTypes?o.removeDynamicArgumentTypes():this.parentRelationType===Ue.DynamicReturnTypes&&o.removeDynamicReturnTypes()}else this.parent.removeDataType();i.push(s)}return{affected:v(i),removed:v(a)}}restore({seenEntities:e}={seenEntities:new Set}){const t=[];if(e.has(this.id))return{affected:[],self:this};if(e.add(this.id),this.subscribe(),this.defaultValue){const{affected:i}=this.defaultValue.restore({seenEntities:e});t.push(...i)}if(this.entity&&this.entity.type===r.CustomEntity&&this.entity.parent===this){const{affected:i}=this.entity.restore({seenEntities:e});t.push(...i)}if(this.parent.type===r.DataType){const i=this.parent;Array.isArray(i.andChildrenGroup)&&i.andChildrenGroup.push(this)}if(this.parent.type===r.DataType){const i=this.parent;this.parentRelationType===Ue.AndDataTypeGroup?Array.isArray(i.andChildrenGroup)&&i.andChildrenGroup.push(this):this.parentRelationType===Ue.OrDataTypeGroup&&Array.isArray(i.orChildrenGroup)&&i.orChildrenGroup.push(this)}else if(this.parent.type===r.ActionDescriptor){const i=this.parent;this.parentRelationType===Ue.DynamicArgumentTypes?i.setDynamicArgumentTypes(this):this.parentRelationType===Ue.DynamicReturnTypes&&i.setDynamicReturnTypes(this)}else{const i=this.parent;i.setDataType(this),t.push(i)}return{affected:t,self:this}}toFlat(e=new Set){var i,a,s;return e.has(this.id)?[]:(e.add(this.id),[this,...((i=this.andChildrenGroup)==null?void 0:i.flatMap(o=>o.toFlat(e)))||[],...((a=this.orChildrenGroup)==null?void 0:a.flatMap(o=>o.toFlat(e)))||[],...((s=this.entity)==null?void 0:s.toFlat(e))||[]])}toFlatIds(e=new Set){var i,a,s;return e.has(this.id)?[]:(e.add(this.id),[this.id,...((i=this.andChildrenGroup)==null?void 0:i.flatMap(o=>o.toFlatIds(e)))||[],...((a=this.orChildrenGroup)==null?void 0:a.flatMap(o=>o.toFlatIds(e)))||[],...((s=this.entity)==null?void 0:s.toFlatIds(e))||[]])}toJSON(){var e,t,i,a;return{id:this.id,version:this.version,type:this.type,isNullable:this.isNullable,options:this.options,isList:this.isList,constant:this.constant,asType:this.asType,defaultValue:((e=this.defaultValue)==null?void 0:e.toJSON())||null,like:this.like,parentRelationType:this.parentRelationType,andChildrenGroup:((t=this.andChildrenGroup)==null?void 0:t.map(s=>s.toJSON()))||null,orChildrenGroup:((i=this.orChildrenGroup)==null?void 0:i.map(s=>s.toJSON()))||null,entity:((a=this.entity)==null?void 0:a.toReference())||null,parent:this.parent.toReference()}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){var e,t,i,a;return{id:this.id,version:this.version,type:this.type,isList:this.isList,isNullable:this.isNullable,options:this.options,constant:this.constant,asType:this.asType,parentRelationType:this.parentRelationType,like:this.like,defaultValue:((e=this.defaultValue)==null?void 0:e.toReference())||null,andChildrenGroup:((t=this.andChildrenGroup)==null?void 0:t.map(s=>s.toReference()))||null,orChildrenGroup:((i=this.orChildrenGroup)==null?void 0:i.map(s=>s.toReference()))||null,entity:((a=this.entity)==null?void 0:a.toReference())||null,parent:this.parent.toReference()}}toFlatJSON(e=new Set){var i,a,s,o;return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...((i=this.defaultValue)==null?void 0:i.toFlatJSON(e))||[],...((a=this.andChildrenGroup)==null?void 0:a.flatMap(l=>l.toFlatJSON(e)))||[],...((s=this.orChildrenGroup)==null?void 0:s.flatMap(l=>l.toFlatJSON(e)))||[],...((o=this.entity)==null?void 0:o.toFlatJSON(e))||[]])}toGenerationTarget(){var e;return{id:this.id,type:this.type,isNullable:this.isNullable,options:this.options,isList:this.isList,constant:this.constant,like:this.like,parentRelationType:this.parentRelationType,asType:this.asType,entity:((e=this.entity)==null?void 0:e.id)||null,parent:this.parent.id}}toFlatGenerationTarget(e=new Set){var i,a,s;return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...((i=this.defaultValue)==null?void 0:i.toFlatGenerationTarget(e))||[],...((a=this.andChildrenGroup)==null?void 0:a.flatMap(o=>o.toFlatGenerationTarget(e)))||[],...((s=this.orChildrenGroup)==null?void 0:s.flatMap(o=>o.toFlatGenerationTarget(e)))||[],...this.entity&&this.entity.type==r.CustomEntity&&this.entity.parent===this&&this.entity.toFlatGenerationTarget(e)||[]])}clearErrors(){var e,t,i,a;return this.errors=[],(e=this.defaultValue)==null||e.clearErrors(),(t=this.andChildrenGroup)==null||t.forEach(s=>s.clearErrors()),(i=this.orChildrenGroup)==null||i.forEach(s=>s.clearErrors()),this.inferred&&((a=this.entity)==null||a.clearErrors()),this}validate(){const e=L9(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors]}getShallowErrors(){return this.errors}clone(e=null,t=null,i=!0){var b,g,I,P;const a=this.toJSON(),s=t||Ke(Tv(this),r.DataType,this.project),o=s.split("-id"),l=o[o.length-1||0]||s;a.id=s;const p=Ut(a,this.project);e&&p.setParent(e),i&&p.subscribe(),p.initChildren();const y=(b=this.defaultValue)==null?void 0:b.clone(p,l+"-default-value-id",i);p.defaultValue=y||null;const f=(g=this.andChildrenGroup)==null?void 0:g.map((B,Y)=>B.clone(this,l+"-and-group-data-type-"+Y+"-id",i)),m=(I=this.orChildrenGroup)==null?void 0:I.map((B,Y)=>B.clone(this,l+"-or-group-data-type-"+Y+"-id",i));if(p.andChildrenGroup=f||null,p.orChildrenGroup=m||null,this.entity&&this.entity.type===r.CustomEntity&&((P=this.entity)==null?void 0:P.parent)===this){const B=this.entity.clone(p,l+"-inferred-entity-id",i);p.setEntity(B)}else this.entity&&p.setEntity(this.entity);return p}merge(e){const t=[],i=[],a=[];return this.asType!==(e==null?void 0:e.asType)&&(this.sync({asType:e==null?void 0:e.asType}),t.push(this)),this.isNullable!==(e==null?void 0:e.isNullable)&&(this.sync({isNullable:e==null?void 0:e.isNullable}),t.push(this)),this.isList!==!(e!=null&&e.isList)&&(this.sync({isList:e==null?void 0:e.isList}),t.push(this)),this.constant!==(e==null?void 0:e.constant)&&(this.sync({constant:e==null?void 0:e.constant}),t.push(this)),this.like!==(e==null?void 0:e.like)&&(this.sync({like:e==null?void 0:e.like}),t.push(this)),e!=null&&e.inferred,{updated:v(t),added:v(i),removed:v(a),self:this}}addToAndGroup(e){return this.andChildrenGroup||(this.andChildrenGroup=[]),this.andChildrenGroup.includes(e)||this.andChildrenGroup.push(e),this}addToOrGroup(e){return this.orChildrenGroup||(this.orChildrenGroup=[]),this.orChildrenGroup.includes(e)||this.orChildrenGroup.push(e),this}getDefaultValue(){return this.defaultValue}setDefaultValue(e){return this.defaultValue=e,this}setEntity(e){return this.entity=e,this}isResolved(){return[r.BuiltInBaseEntity,r.ActionDescriptor].includes(this.parent.type)||Yn(this.parent)?!0:!(!this.entity&&(!this.andChildrenGroup||!this.andChildrenGroup.length)&&(!this.orChildrenGroup||!this.orChildrenGroup.length))}inferFromInputs(e){var t;if(!this.inferred)return this;if(!this.entity&&e.length){const i={id:this.id+"--infered-entity",type:r.CustomEntity,version:1,name:S(this,this.project),description:((t=this.parent)==null?void 0:t.description)||null,static:!0,abstract:!1,properties:[],methods:[],extends:[],implements:[],abstractMethods:[],x:0,y:0,parent:this.toReference()},a=R(i,this.project);a.sync(i),a.setParent(this),a.initChildren(),this.setEntity(a)}return this.entity&&this.entity.inferFromInputs(e),this}};c(ye,"MUTABLE_BASE_PROPERTIES",["isNullable","isList","constant","asType","options","parentRelationType"]),c(ye,"INMUTABLE_BASE_PROPERTIES",["id","version","type"]),c(ye,"BASE_PROPERTIES",[...ye.MUTABLE_BASE_PROPERTIES,...ye.INMUTABLE_BASE_PROPERTIES]),c(ye,"MUTABLE_META_PROPERTIES",[...ye.MUTABLE_BASE_PROPERTIES,"inferred"]),c(ye,"INMUTABLE_META_PROPERTIES",[...ye.INMUTABLE_BASE_PROPERTIES]),c(ye,"META_PROPERTIES",[...ye.MUTABLE_META_PROPERTIES,...ye.INMUTABLE_META_PROPERTIES]),c(ye,"MUTABLE_UPSTREAM_PROPERTIES",["entity","andChildrenGroup","orChildrenGroup","parent"]),c(ye,"INMUTABLE_UPSTREAM_PROPERTIES",[]),c(ye,"UPSTREAM_PROPERTIES",[...ye.MUTABLE_UPSTREAM_PROPERTIES,...ye.INMUTABLE_UPSTREAM_PROPERTIES]),c(ye,"MUTABLE_DOWNSTREAM_PROPERTIES",["defaultValue"]),c(ye,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(ye,"DOWNSTREAM_PROPERTIES",[...ye.MUTABLE_DOWNSTREAM_PROPERTIES,...ye.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(ye,"PROPERTIES",[...ye.META_PROPERTIES,...ye.UPSTREAM_PROPERTIES,...ye.DOWNSTREAM_PROPERTIES]);let hi=ye;function F9(n){var l;const e=ax(),t=n.toJSON();e.safeParse(t).success;const a=U9(n),s=In(n),o=[...a,...s];if(n.id==="exec-sequentially-operation-call-id"){const p=H({id:`${n.id}--${_.PropertyImplementsNonAbstact}`,message:`Property "${S(n,n.project)}" with id "${n.id}" implements a non-abstract property "${S(n,n.project)}" with id "${n.id}".`,issue:null,severity:T.Error,code:_.PropertyImplementsNonAbstact,entity:n});o.push(p.error)}return n.outputs.forEach(p=>p.validate()),(l=n.error)==null||l.validate(),ne(n.errors,o)}function U9(n){const e=[];return n.inputs.forEach(t=>{t.validate()}),ne(n.errors,e)}const ie=class ie{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"x");c(this,"y");c(this,"type",r.Operation);c(this,"declaration");c(this,"inputs",[]);c(this,"outputs",[]);c(this,"process",null);c(this,"successCalls",[]);c(this,"errorCalls",[]);c(this,"error",null);c(this,"calledBySuccess",[]);c(this,"calledByError",[]);c(this,"calledByEntry",[]);c(this,"parent");c(this,"errors",[]);c(this,"project");c(this,"initialized",!1);this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.x=e.x,this.y=e.y}static fromGenerationTarget(e,t){let i=t;if(e.parent){const m=C(e.parent);i=t.get(m)}const a=C(e.declaration),s=t.get(a),o=e.calledByEntry.map(m=>{const b=C(m);return t.get(b)}),l=e.calledBySuccess.map(m=>{const b=C(m);return t.get(b)}),p=e.calledByError.map(m=>{const b=C(m);return t.get(b)}),y={id:e.id,version:1,type:r.Operation,declaration:s,calledByEntry:o,calledBySuccess:l,calledByError:p,errorCalls:[],successCalls:[],inputs:[],outputs:[],process:null,error:null,x:0,y:0,parent:i},f=R(y,t);return f.setParent(i),f.initChildren(),f}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[],s=je(i,{parent:{list:!1,types:[...ct,r.Project],optional:!0}},t);i=s.modifiedData,a.push(...s.errors,...Be(i));const o=C(i.declaration);if(o){const l=Vv(o,t);a.push(...l)}else{const l=`
|
|
38
38
|
All built-in 'action-descriptor' entity ids are:
|
|
39
39
|
- ${t.operationDeclarations.map(p=>`${p.id} (${S(p,t)})`).join(`
|
|
40
40
|
- `)}.
|
|
@@ -54,7 +54,7 @@ You shouldn't have to manually update a 'parent' property. The equivalent result
|
|
|
54
54
|
${To(t)}`,issue:null})):a.push(new E({id:`${e.id}--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`Entity of type '${e.type}' with id '${e.id}' has an 'declaration' property that isn't found in the project. The 'declaration' property must point to one of the built-in action descriptors reserved for '${r.Condition}' entities.
|
|
55
55
|
${To(t)}`,issue:null})):a.push(new E({id:`${e.id}--${D.InvalidObjectStructure}`,code:D.InvalidObjectStructure,severity:T.Error,message:`Entity of type '${e.type}' with id '${e.id}' is missing the 'declaration' property. This property is required for a '${e.type}' entity and must point to one of the built-in action descriptors reserved for '${r.Condition}' entities.
|
|
56
56
|
${To(t)}`,issue:null})),{errors:a,modifiedData:i}}validateGeneratedUpdate(e){const t=[];return e.parent&&t.push(new E({id:`${this.id}--${h.InvalidParentUpdate}`,code:h.InvalidParentUpdate,severity:T.Error,message:`Entity of type '${this.type}' with id '${this.id}' cannot have the 'parent' property updated. The 'parent' on a callable entity, is its scope. It scope is auto-calculated implicitly by the its caller.
|
|
57
|
-
If an entity is called by another, they must be in the same scope, which means they have the same parent.`,issue:null})),{errors:t,modifiedData:e}}addSelfToProject(){const e=[this];return this.parent===this.project&&this.project.addCondition(this),this.successCalls.forEach(t=>{t.addSuccessCaller(this),e.push(t)}),this.errorCalls.forEach(t=>{t.addErrorCaller(this),e.push(t)}),this.calledByEntry.forEach(t=>{t.addCall(this),e.push(t)}),this.calledBySuccess.forEach(t=>{t.addSuccessCall(this),e.push(t)}),this.calledByError.forEach(t=>{t.addErrorCall(this),e.push(t)}),{affected:v(e),self:this}}get calledBy(){return[...this.calledByEntry,...this.calledBySuccess,...this.calledByError]}removeInput(e){const t=this.inputs.findIndex(i=>i.id===e.id);return t>-1&&this.inputs.splice(t,1),this}addInput(e){return this.inputs.includes(e)?this:(this.inputs.push(e),this)}addOutput(e){return this}removeOutput(e){return this}addSuccessCaller(e){return this.calledBySuccess.find(t=>t.id===e.id)||this.calledBySuccess.push(e),this}addErrorCaller(e){return this.calledByError.find(t=>t.id===e.id)||this.calledByError.push(e),this}addEntryCaller(e){return this.calledByEntry.find(t=>t.id===e.id)||this.calledByEntry.push(e),this}addErrorCall(e){return this.errorCalls.push(e),this}addSuccessCall(e){return this.successCalls.push(e),this}removeCall(e){const t=this.successCalls.findIndex(a=>a.id===e.id);t>-1&&this.successCalls.splice(t,1);const i=this.errorCalls.findIndex(a=>a.id===e.id);return i>-1&&this.errorCalls.splice(i,1),this}removeCaller(e){return this.calledBySuccess=this.calledBySuccess.filter(t=>t.id!==e.id),this.calledByError=this.calledByError.filter(t=>t.id!==e.id),this.calledByEntry=this.calledByEntry.filter(t=>t.id!==e.id),this}setParent(e){return this.parent=e,this}initChildren(){return this.initialized?this:(this.initialized=!0,this.declaration=R(this.initialData.declaration,this.project),this.successCalls=this.initialData.successCalls.map(e=>{const t=R(e,this.project);return t.addSuccessCaller(this),[r.BreakStatement,r.ContinueStatement].includes(t.type)?(t.setParent(this.parent.parent),t.initChildren()):t.type!==r.InternalCall&&(t.setParent(this.parent),t.initChildren()),t}),this.errorCalls=this.initialData.errorCalls.map(e=>{const t=R(e,this.project);return t.addErrorCaller(this),[r.BreakStatement,r.ContinueStatement].includes(t.type)?(t.setParent(this.parent.parent),t.initChildren()):t.type!==r.InternalCall&&(t.setParent(this.parent),t.initChildren()),t}),this.inputs=this.initialData.inputs.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this)}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}sync(e){return this.version=e.version||this.version,this.x=e.x||this.x,this.y=e.y||this.y,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){const i=[],a=[];return t.has(this.id)?{affected:[],removed:[]}:(t.add(this.id),a.push(this),this.unsubscribe(),this.inputs.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.successCalls.forEach(s=>{i.push(s),s.removeCaller(this)}),this.errorCalls.forEach(s=>{i.push(s),s.removeCaller(this)}),e||this.calledBy.forEach(s=>{i.push(s),s.removeCall(this)}),{affected:v(i),removed:v(a)})}restore({seenEntities:e}={seenEntities:new Set}){const t=[];return e.has(this.id)?{affected:[],self:this}:(e.add(this.id),this.subscribe(),this.inputs.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.successCalls.forEach(i=>{t.push(i),i.addSuccessCaller(this)}),this.errorCalls.forEach(i=>{t.push(i),i.addErrorCaller(this)}),this.calledBySuccess.forEach(i=>{t.push(i),i.addSuccessCall(this)}),this.calledByError.forEach(i=>{t.push(i),i.addErrorCall(this)}),this.calledByEntry.forEach(i=>{t.push(i),i.addCall(this)}),{affected:t,self:this})}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.inputs.flatMap(i=>i.toFlat(e)),...this.successCalls.flatMap(i=>i.toFlat(e)),...this.errorCalls.flatMap(i=>i.toFlat(e)),...this.calledBy.flatMap(i=>i.toFlat(e))])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.inputs.flatMap(i=>i.toFlatIds(e)),...this.successCalls.flatMap(i=>i.toFlatIds(e)),...this.errorCalls.flatMap(i=>i.toFlatIds(e)),...this.calledBy.flatMap(i=>i.toFlatIds(e))])}toJSON(){return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,declaration:this.declaration.toJSON(),successCalls:this.successCalls.map(e=>e.toJSON()),errorCalls:this.errorCalls.map(e=>e.toJSON()),calledBySuccess:this.calledBySuccess.map(e=>e.toReference()),calledByError:this.calledByError.map(e=>e.toReference()),calledByEntry:this.calledByEntry.map(e=>e.toReference()),inputs:this.inputs.map(e=>e.toJSON()),parent:this.parent.toReference()}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,declaration:this.declaration.toReference(),inputs:this.inputs.map(e=>e.toReference()),successCalls:this.successCalls.map(e=>e.toReference()),errorCalls:this.errorCalls.map(e=>e.toReference()),calledBySuccess:this.calledBySuccess.map(e=>e.toReference()),calledByError:this.calledByError.map(e=>e.toReference()),calledByEntry:this.calledByEntry.map(e=>e.toReference()),parent:this.parent.toReference()}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.inputs.flatMap(i=>i.toFlatJSON(e)),...this.successCalls.flatMap(i=>i.toFlatJSON(e)),...this.errorCalls.flatMap(i=>i.toFlatJSON(e)),...this.calledBy.flatMap(i=>i.toFlatJSON(e))])}toGenerationTarget(){const e=this.parent.type===r.Project?void 0:this.parent.id;return{id:this.id,type:this.type,declaration:this.declaration.id,calledByEntry:this.calledByEntry.map(t=>t.id),calledBySuccess:this.calledBySuccess.map(t=>t.id),calledByError:this.calledByError.map(t=>t.id),parent:e}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.inputs.flatMap(i=>i.toFlatGenerationTarget(e)),...this.successCalls.flatMap(i=>i.toFlatGenerationTarget(e)),...this.errorCalls.flatMap(i=>i.toFlatGenerationTarget(e))])}clearErrors(){return this.errors=[],this.inputs.forEach(e=>e.clearErrors()),this.successCalls.forEach(e=>e.clearErrors()),this.errorCalls.forEach(e=>e.clearErrors()),this}validate(){const e=j9(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors,...this.inputs.flatMap(t=>t.getErrors())]}getShallowErrors(){return this.errors}clone(e){return new he(this.toJSON(),this.project)}};c(he,"MUTABLE_BASE_PROPERTIES",["operator"]),c(he,"INMUTABLE_BASE_PROPERTIES",["id","version","type"]),c(he,"BASE_PROPERTIES",[...he.MUTABLE_BASE_PROPERTIES,...he.INMUTABLE_BASE_PROPERTIES]),c(he,"MUTABLE_META_PROPERTIES",["x","y"]),c(he,"INMUTABLE_META_PROPERTIES",[...he.INMUTABLE_BASE_PROPERTIES]),c(he,"META_PROPERTIES",[...he.MUTABLE_META_PROPERTIES,...he.INMUTABLE_META_PROPERTIES]),c(he,"MUTABLE_UPSTREAM_PROPERTIES",["calledBySuccess","calledByError","calledByEntry","parent"]),c(he,"INMUTABLE_UPSTREAM_PROPERTIES",[]),c(he,"UPSTREAM_PROPERTIES",[...he.MUTABLE_UPSTREAM_PROPERTIES,...he.INMUTABLE_UPSTREAM_PROPERTIES]),c(he,"MUTABLE_DOWNSTREAM_PROPERTIES",["successCalls","errorCalls","inputsDeclarations","inputs"]),c(he,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(he,"DOWNSTREAM_PROPERTIES",[...he.MUTABLE_DOWNSTREAM_PROPERTIES,...he.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(he,"PROPERTIES",[...he.META_PROPERTIES,...he.UPSTREAM_PROPERTIES,...he.DOWNSTREAM_PROPERTIES]);let Dr=he;class Iv{constructor(){c(this,"initialData")}}class q9{}class J9 extends Iv{}class W9{}class H9{}class Y9{}class Dd{}class z9 extends Dd{}class Z9 extends Dd{}class X9{}class ga{static initReadsValue(e){if(e.initialData.readsValue&&e.initialData.readsValue.type!==r.GenericReference)e.readsValue=R(e.initialData.readsValue,e.project);else if(e.initialData.readsValue&&e.initialData.readsValue.type===r.GenericReference){const t=Mt(e.initialData.readsValue,e.project);t&&(e.readsValue=t)}if(e.readsValue){if(xe.includes(e.readsValue.type)){let t=e.parent;ct.includes(t.type)||(t=t.parent),e.readsValue.setParent(t),e.readsValue.initChildren(),t.detachedChildren.includes(e)?t.replaceDetachedChild(e,e.readsValue):t.subscribeDetachedChild(e.readsValue)}e.readsValue.addValueReader(e)}return e.readsValue}}class va{static initWritesValues(e,t){const i=e.initialData.writesValues.reduce((s,o)=>{if(o.type===r.GenericReference||e.writesValues.some(p=>p.id===o.id))return s;const l=R(o,e.project);return l.setValueWriter(e),xe.includes(l.type)&&(l.setParent(t),l.initChildren()),[...s,l]},[]),a=[...e.writesValues];return e.writesValues=v([...a,...i]),e.writesValues}}class Q9{}function K9(n){var l;const e=Cx(),t=n.toJSON();e.safeParse(t).success,(l=n.dataType)==null||l.validate(),n.inputs.forEach(p=>p.validate()),n.outputs.forEach(p=>p.validate()),n.internalCalls.forEach(p=>p.validate());const s=[...In(n)];if(n.id==="random-company-employee-test-variable-id"){const p=H({id:`${n.id}--${_.PropertyImplementsNonAbstact}`,message:`Property "${S(n,n.project)}" with id "${n.id}" implements a non-abstract property "${S(n,n.project)}" with id "${n.id}".`,issue:null,severity:T.Error,code:_.PropertyImplementsNonAbstact,entity:n});s.push(p.error)}if(n.id==="company-dto-variable-one-id"){const p=H({id:`${n.id}--${_.PropertyImplementsNonAbstact}`,message:`Property "${S(n,n.project)}" with id "${n.id}" implements a non-abstract property "${S(n,n.project)}" with id "${n.id}".`,issue:null,severity:T.Error,code:_.PropertyImplementsNonAbstact,entity:n});s.push(p.error)}const o=Nd(n);return s.push(...o),ne(n.errors,s)}const se=class se{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"name");c(this,"description",null);c(this,"dataType",null);c(this,"x");c(this,"y");c(this,"type",r.VariableDeclaration);c(this,"writesValues",[]);c(this,"readsValue",null);c(this,"inputs",[]);c(this,"outputs",[]);c(this,"calledBySuccess",[]);c(this,"calledByError",[]);c(this,"calledByEntry",[]);c(this,"successCalls",[]);c(this,"errorCalls",[]);c(this,"internalCalls",[]);c(this,"parent");c(this,"variableInstances",[]);c(this,"errors",[]);c(this,"project");c(this,"initialized",!1);c(this,"suggestion",!1);this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.name=e.name,this.description=e.description,this.x=e.x,this.y=e.y}static fromGenerationTarget(e,t){let i=t;if(e.parent){const f=C(e.parent);i=t.get(f)}const a=e.calledByEntry.map(f=>{const m=C(f);return t.get(m)}),s=e.calledBySuccess.map(f=>{const m=C(f);return t.get(m)}),o=e.calledByError.map(f=>{const m=C(f);return t.get(m)});let l=null;if(e.readsValue){const f=C(e.readsValue);l=t.get(f)}const p={id:e.id,version:1,type:r.VariableDeclaration,name:e.name,description:e.description,calledByEntry:a,calledBySuccess:s,calledByError:o,dataType:null,errorCalls:[],successCalls:[],internalCalls:[],readsValue:l,inputs:[],outputs:[],writesValues:[],x:0,y:0,parent:i},y=R(p,t);return y.setParent(i),y.initChildren(),y}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[],s=je(i,{parent:{list:!1,types:[...ct,r.Project],optional:!0}},t);i=s.modifiedData;const o=Rd(i,t);return a.push(...s.errors,...o,...Be(i)),{errors:a,modifiedData:i}}validateGeneratedUpdate(e){const t=[];let i=JSON.parse(JSON.stringify(e));const a=Da(i,this);return i=a.modifiedData,t.push(...a.errors),e.parent&&t.push(new E({id:`${this.id}--${h.InvalidParentUpdate}`,code:h.InvalidParentUpdate,severity:T.Error,message:`Entity of type '${this.type}' with id '${this.id}' cannot have the 'parent' property updated. The 'parent' on a callable entity, is its scope. It scope is auto-calculated implicitly by the its caller.
|
|
57
|
+
If an entity is called by another, they must be in the same scope, which means they have the same parent.`,issue:null})),{errors:t,modifiedData:e}}addSelfToProject(){const e=[this];return this.parent===this.project&&this.project.addCondition(this),this.successCalls.forEach(t=>{t.addSuccessCaller(this),e.push(t)}),this.errorCalls.forEach(t=>{t.addErrorCaller(this),e.push(t)}),this.calledByEntry.forEach(t=>{t.addCall(this),e.push(t)}),this.calledBySuccess.forEach(t=>{t.addSuccessCall(this),e.push(t)}),this.calledByError.forEach(t=>{t.addErrorCall(this),e.push(t)}),{affected:v(e),self:this}}get calledBy(){return[...this.calledByEntry,...this.calledBySuccess,...this.calledByError]}removeInput(e){const t=this.inputs.findIndex(i=>i.id===e.id);return t>-1&&this.inputs.splice(t,1),this}addInput(e){return this.inputs.includes(e)?this:(this.inputs.push(e),this)}addOutput(e){return this}removeOutput(e){return this}addSuccessCaller(e){return this.calledBySuccess.find(t=>t.id===e.id)||this.calledBySuccess.push(e),this}addErrorCaller(e){return this.calledByError.find(t=>t.id===e.id)||this.calledByError.push(e),this}addEntryCaller(e){return this.calledByEntry.find(t=>t.id===e.id)||this.calledByEntry.push(e),this}addErrorCall(e){return this.errorCalls.push(e),this}addSuccessCall(e){return this.successCalls.push(e),this}removeCall(e){const t=this.successCalls.findIndex(a=>a.id===e.id);t>-1&&this.successCalls.splice(t,1);const i=this.errorCalls.findIndex(a=>a.id===e.id);return i>-1&&this.errorCalls.splice(i,1),this}removeCaller(e){return this.calledBySuccess=this.calledBySuccess.filter(t=>t.id!==e.id),this.calledByError=this.calledByError.filter(t=>t.id!==e.id),this.calledByEntry=this.calledByEntry.filter(t=>t.id!==e.id),this}setParent(e){return this.parent=e,this}initChildren(){return this.initialized?this:(this.initialized=!0,this.declaration=R(this.initialData.declaration,this.project),this.successCalls=this.initialData.successCalls.map(e=>{const t=R(e,this.project);return t.addSuccessCaller(this),[r.BreakStatement,r.ContinueStatement].includes(t.type)?(t.setParent(this.parent.parent),t.initChildren()):t.type!==r.InternalCall&&(t.setParent(this.parent),t.initChildren()),t}),this.errorCalls=this.initialData.errorCalls.map(e=>{const t=R(e,this.project);return t.addErrorCaller(this),[r.BreakStatement,r.ContinueStatement].includes(t.type)?(t.setParent(this.parent.parent),t.initChildren()):t.type!==r.InternalCall&&(t.setParent(this.parent),t.initChildren()),t}),this.inputs=this.initialData.inputs.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this)}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}sync(e){return this.version=e.version||this.version,this.x=e.x||this.x,this.y=e.y||this.y,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){const i=[],a=[];return t.has(this.id)?{affected:[],removed:[]}:(t.add(this.id),a.push(this),this.unsubscribe(),this.inputs.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.successCalls.forEach(s=>{i.push(s),s.removeCaller(this)}),this.errorCalls.forEach(s=>{i.push(s),s.removeCaller(this)}),e||this.calledBy.forEach(s=>{i.push(s),s.removeCall(this)}),{affected:v(i),removed:v(a)})}restore({seenEntities:e}={seenEntities:new Set}){const t=[];return e.has(this.id)?{affected:[],self:this}:(e.add(this.id),this.subscribe(),this.inputs.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.successCalls.forEach(i=>{t.push(i),i.addSuccessCaller(this)}),this.errorCalls.forEach(i=>{t.push(i),i.addErrorCaller(this)}),this.calledBySuccess.forEach(i=>{t.push(i),i.addSuccessCall(this)}),this.calledByError.forEach(i=>{t.push(i),i.addErrorCall(this)}),this.calledByEntry.forEach(i=>{t.push(i),i.addCall(this)}),{affected:t,self:this})}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.inputs.flatMap(i=>i.toFlat(e)),...this.successCalls.flatMap(i=>i.toFlat(e)),...this.errorCalls.flatMap(i=>i.toFlat(e)),...this.calledBy.flatMap(i=>i.toFlat(e))])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.inputs.flatMap(i=>i.toFlatIds(e)),...this.successCalls.flatMap(i=>i.toFlatIds(e)),...this.errorCalls.flatMap(i=>i.toFlatIds(e)),...this.calledBy.flatMap(i=>i.toFlatIds(e))])}toJSON(){return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,declaration:this.declaration.toJSON(),successCalls:this.successCalls.map(e=>e.toJSON()),errorCalls:this.errorCalls.map(e=>e.toJSON()),calledBySuccess:this.calledBySuccess.map(e=>e.toReference()),calledByError:this.calledByError.map(e=>e.toReference()),calledByEntry:this.calledByEntry.map(e=>e.toReference()),inputs:this.inputs.map(e=>e.toJSON()),parent:this.parent.toReference()}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,declaration:this.declaration.toReference(),inputs:this.inputs.map(e=>e.toReference()),successCalls:this.successCalls.map(e=>e.toReference()),errorCalls:this.errorCalls.map(e=>e.toReference()),calledBySuccess:this.calledBySuccess.map(e=>e.toReference()),calledByError:this.calledByError.map(e=>e.toReference()),calledByEntry:this.calledByEntry.map(e=>e.toReference()),parent:this.parent.toReference()}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.inputs.flatMap(i=>i.toFlatJSON(e)),...this.successCalls.flatMap(i=>i.toFlatJSON(e)),...this.errorCalls.flatMap(i=>i.toFlatJSON(e)),...this.calledBy.flatMap(i=>i.toFlatJSON(e))])}toGenerationTarget(){const e=this.parent.type===r.Project?void 0:this.parent.id;return{id:this.id,type:this.type,declaration:this.declaration.id,calledByEntry:this.calledByEntry.map(t=>t.id),calledBySuccess:this.calledBySuccess.map(t=>t.id),calledByError:this.calledByError.map(t=>t.id),parent:e}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.inputs.flatMap(i=>i.toFlatGenerationTarget(e)),...this.successCalls.flatMap(i=>i.toFlatGenerationTarget(e)),...this.errorCalls.flatMap(i=>i.toFlatGenerationTarget(e))])}clearErrors(){return this.errors=[],this.inputs.forEach(e=>e.clearErrors()),this.successCalls.forEach(e=>e.clearErrors()),this.errorCalls.forEach(e=>e.clearErrors()),this}validate(){const e=j9(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors,...this.inputs.flatMap(t=>t.getErrors())]}getShallowErrors(){return this.errors}clone(e){return new he(this.toJSON(),this.project)}};c(he,"MUTABLE_BASE_PROPERTIES",["operator"]),c(he,"INMUTABLE_BASE_PROPERTIES",["id","version","type"]),c(he,"BASE_PROPERTIES",[...he.MUTABLE_BASE_PROPERTIES,...he.INMUTABLE_BASE_PROPERTIES]),c(he,"MUTABLE_META_PROPERTIES",["x","y"]),c(he,"INMUTABLE_META_PROPERTIES",[...he.INMUTABLE_BASE_PROPERTIES]),c(he,"META_PROPERTIES",[...he.MUTABLE_META_PROPERTIES,...he.INMUTABLE_META_PROPERTIES]),c(he,"MUTABLE_UPSTREAM_PROPERTIES",["calledBySuccess","calledByError","calledByEntry","parent"]),c(he,"INMUTABLE_UPSTREAM_PROPERTIES",[]),c(he,"UPSTREAM_PROPERTIES",[...he.MUTABLE_UPSTREAM_PROPERTIES,...he.INMUTABLE_UPSTREAM_PROPERTIES]),c(he,"MUTABLE_DOWNSTREAM_PROPERTIES",["successCalls","errorCalls","inputsDeclarations","inputs"]),c(he,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(he,"DOWNSTREAM_PROPERTIES",[...he.MUTABLE_DOWNSTREAM_PROPERTIES,...he.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(he,"PROPERTIES",[...he.META_PROPERTIES,...he.UPSTREAM_PROPERTIES,...he.DOWNSTREAM_PROPERTIES]);let Dr=he;class Dv{constructor(){c(this,"initialData")}}class q9{}class J9 extends Dv{}class W9{}class H9{}class Y9{}class Dd{}class z9 extends Dd{}class Z9 extends Dd{}class X9{}class ga{static initReadsValue(e){if(e.initialData.readsValue&&e.initialData.readsValue.type!==r.GenericReference)e.readsValue=R(e.initialData.readsValue,e.project);else if(e.initialData.readsValue&&e.initialData.readsValue.type===r.GenericReference){const t=Mt(e.initialData.readsValue,e.project);t&&(e.readsValue=t)}if(e.readsValue){if(xe.includes(e.readsValue.type)){let t=e.parent;ct.includes(t.type)||(t=t.parent),e.readsValue.setParent(t),e.readsValue.initChildren(),t.detachedChildren.includes(e)?t.replaceDetachedChild(e,e.readsValue):t.subscribeDetachedChild(e.readsValue)}e.readsValue.addValueReader(e)}return e.readsValue}}class va{static initWritesValues(e,t){const i=e.initialData.writesValues.reduce((s,o)=>{if(o.type===r.GenericReference||e.writesValues.some(p=>p.id===o.id))return s;const l=R(o,e.project);return l.setValueWriter(e),xe.includes(l.type)&&(l.setParent(t),l.initChildren()),[...s,l]},[]),a=[...e.writesValues];return e.writesValues=v([...a,...i]),e.writesValues}}class Q9{}function K9(n){var l;const e=Cx(),t=n.toJSON();e.safeParse(t).success,(l=n.dataType)==null||l.validate(),n.inputs.forEach(p=>p.validate()),n.outputs.forEach(p=>p.validate()),n.internalCalls.forEach(p=>p.validate());const s=[...In(n)];if(n.id==="random-company-employee-test-variable-id"){const p=H({id:`${n.id}--${_.PropertyImplementsNonAbstact}`,message:`Property "${S(n,n.project)}" with id "${n.id}" implements a non-abstract property "${S(n,n.project)}" with id "${n.id}".`,issue:null,severity:T.Error,code:_.PropertyImplementsNonAbstact,entity:n});s.push(p.error)}if(n.id==="company-dto-variable-one-id"){const p=H({id:`${n.id}--${_.PropertyImplementsNonAbstact}`,message:`Property "${S(n,n.project)}" with id "${n.id}" implements a non-abstract property "${S(n,n.project)}" with id "${n.id}".`,issue:null,severity:T.Error,code:_.PropertyImplementsNonAbstact,entity:n});s.push(p.error)}const o=Nd(n);return s.push(...o),ne(n.errors,s)}const se=class se{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"name");c(this,"description",null);c(this,"dataType",null);c(this,"x");c(this,"y");c(this,"type",r.VariableDeclaration);c(this,"writesValues",[]);c(this,"readsValue",null);c(this,"inputs",[]);c(this,"outputs",[]);c(this,"calledBySuccess",[]);c(this,"calledByError",[]);c(this,"calledByEntry",[]);c(this,"successCalls",[]);c(this,"errorCalls",[]);c(this,"internalCalls",[]);c(this,"parent");c(this,"variableInstances",[]);c(this,"errors",[]);c(this,"project");c(this,"initialized",!1);c(this,"suggestion",!1);this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.name=e.name,this.description=e.description,this.x=e.x,this.y=e.y}static fromGenerationTarget(e,t){let i=t;if(e.parent){const f=C(e.parent);i=t.get(f)}const a=e.calledByEntry.map(f=>{const m=C(f);return t.get(m)}),s=e.calledBySuccess.map(f=>{const m=C(f);return t.get(m)}),o=e.calledByError.map(f=>{const m=C(f);return t.get(m)});let l=null;if(e.readsValue){const f=C(e.readsValue);l=t.get(f)}const p={id:e.id,version:1,type:r.VariableDeclaration,name:e.name,description:e.description,calledByEntry:a,calledBySuccess:s,calledByError:o,dataType:null,errorCalls:[],successCalls:[],internalCalls:[],readsValue:l,inputs:[],outputs:[],writesValues:[],x:0,y:0,parent:i},y=R(p,t);return y.setParent(i),y.initChildren(),y}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[],s=je(i,{parent:{list:!1,types:[...ct,r.Project],optional:!0}},t);i=s.modifiedData;const o=Rd(i,t);return a.push(...s.errors,...o,...Be(i)),{errors:a,modifiedData:i}}validateGeneratedUpdate(e){const t=[];let i=JSON.parse(JSON.stringify(e));const a=Da(i,this);return i=a.modifiedData,t.push(...a.errors),e.parent&&t.push(new E({id:`${this.id}--${h.InvalidParentUpdate}`,code:h.InvalidParentUpdate,severity:T.Error,message:`Entity of type '${this.type}' with id '${this.id}' cannot have the 'parent' property updated. The 'parent' on a callable entity, is its scope. It scope is auto-calculated implicitly by the its caller.
|
|
58
58
|
If an entity is called by another, they must be in the same scope, which means they have the same parent.
|
|
59
59
|
Specifically for variables, their scope is also calculated from their value readers and value writters.
|
|
60
60
|
You shouldn't have to manually update a 'parent' property. The equivalent result is to change its value readers, value writters, or callers.`,issue:null})),{errors:t,modifiedData:i}}addSelfToProject(){const e=[this];return this.parent===this.project&&this.project.addVariableDeclaration(this),this.readsValue&&(this.readsValue.addValueReader(this),e.push(this.readsValue)),this.writesValues.forEach(t=>{t.setValueWriter(this),e.push(t)}),this.successCalls.forEach(t=>{t.addSuccessCaller(this),e.push(t)}),this.errorCalls.forEach(t=>{t.addErrorCaller(this),e.push(t)}),this.calledBySuccess.forEach(t=>{t.addSuccessCall(this),e.push(t)}),this.calledByError.forEach(t=>{t.addErrorCall(this),e.push(t)}),this.calledByEntry.forEach(t=>{t.addCall(this),e.push(t)}),{affected:v(e),self:this}}get calledBy(){return[...this.calledByEntry,...this.calledBySuccess,...this.calledByError]}get usedInputs(){return this.inputs.filter(e=>e.readsValue||e.defaultValue)}get unusedInputs(){return this.inputs.filter(e=>!e.readsValue&&!e.defaultValue)}get usedOutputs(){return this.outputs.filter(e=>e.writesValues.length)}get unusedOutputs(){return this.outputs.filter(e=>!e.writesValues.length)}get usedInternalCalls(){return this.internalCalls.filter(e=>!!e.calledBy.length)}get unusedInternalCalls(){return this.internalCalls.filter(e=>!e.calledBy.length)}removeInput(e){const t=this.inputs.findIndex(i=>i.id===e.id);return t>-1&&this.inputs.splice(t,1),this}addInput(e){return this.inputs.includes(e)?this:(this.inputs.push(e),this)}addOutput(e){return this.outputs.includes(e)?this:(this.outputs.push(e),this)}removeOutput(e){const t=this.outputs.findIndex(i=>i.id===e.id);return t>-1&&this.outputs.splice(t,1),this}addSuccessCaller(e){return this.calledBySuccess.find(t=>t.id===e.id)||this.calledBySuccess.push(e),this}addErrorCaller(e){return this.calledByError.find(t=>t.id===e.id)||this.calledByError.push(e),this}addEntryCaller(e){return this.calledByEntry.find(t=>t.id===e.id)||this.calledByEntry.push(e),this}addErrorCall(e){return this.errorCalls.push(e),this}addSuccessCall(e){return this.successCalls.push(e),this}removeCall(e){const t=this.successCalls.findIndex(a=>a.id===e.id);t>-1&&this.successCalls.splice(t,1);const i=this.errorCalls.findIndex(a=>a.id===e.id);return i>-1&&this.errorCalls.splice(i,1),this}removeCaller(e){return this.calledBySuccess=this.calledBySuccess.filter(t=>t.id!==e.id),this.calledByError=this.calledByError.filter(t=>t.id!==e.id),this.calledByEntry=this.calledByEntry.filter(t=>t.id!==e.id),this}addValueReader(e){return this.writesValues.includes(e)?this:(this.writesValues.push(e),this)}removeValueReader(e){return this.writesValues=this.writesValues.filter(t=>t.id!==e.id),this}setParent(e){return this.parent=e,this}initChildren(){return this.initialized?this:(this.initialized=!0,this.initialData.dataType&&(this.dataType=R(this.initialData.dataType,this.project),this.dataType.setParent(this),this.dataType.initChildren()),va.initWritesValues(this,this.parent),ga.initReadsValue(this),this.successCalls=this.initialData.successCalls.map(e=>{const t=R(e,this.project);return t.addSuccessCaller(this),[r.BreakStatement,r.ContinueStatement].includes(t.type)?(t.setParent(this.parent.parent),t.initChildren()):t.type!==r.InternalCall&&(t.setParent(this.parent),t.initChildren()),t}),this.errorCalls=this.initialData.errorCalls.map(e=>{const t=R(e,this.project);return t.addErrorCaller(this),[r.BreakStatement,r.ContinueStatement].includes(t.type)?(t.setParent(this.parent.parent),t.initChildren()):t.type!==r.InternalCall&&(t.setParent(this.parent),t.initChildren()),t}),this.initialData.inputs.forEach(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),this.addInput(t),t}),this.initialData.outputs.forEach(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),this.addOutput(t),t}),this.initialData.internalCalls.forEach(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),this.addInternalCall(t),t}),this.generateUnusedInputs(),this.generateUnusedOutputs(),this.generateUnusedInternalCalls(),(!this.dataType||this.dataType.inferred)&&this.inferDataTypeAndSyncInstancesInputsAndOutputs(),this)}setValueWriter(e){return this.readsValue=e,this}removeValueWriter(){return this.readsValue=null,this}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}subscribeInstance(e){return this.variableInstances.includes(e)?this:(this.variableInstances.push(e),this)}removeInstance(e){return this.variableInstances=this.variableInstances.filter(t=>t.id!==e.id),this}getMasterInputWithValueWritterFromAllInstances(e){return v([...this.inputs,...this.variableInstances.flatMap(a=>a.inputs)]).find(a=>S(a,this.project)===S(e,this.project)&&!!a.readsValue)||e}inferDataTypeAndSyncInstancesInputsAndOutputs(){var i,a;if(!this.dataType){const s=R({id:this.id+"--infered-data-type",version:1,type:r.DataType,isList:!1,isNullable:!1,andChildrenGroup:null,orChildrenGroup:null,asType:!1,entity:null,constant:!1,like:!1,defaultValue:null,parent:this.toReference()},this.project);s.inferred=!0,s.setParent(this),s.initChildren(),this.setDataType(s)}if(this.readsValue){const s=(i=this.readsValue.getDataType())==null?void 0:i.clone(this);return s&&(s.inferred=!0,this.setDataType(s)),this}const e=v([...this.inputs,...this.variableInstances.flatMap(s=>s.inputs)]),t=[];return e.forEach(s=>{t.find(l=>S(l,this.project)===S(s,this.project))||t.push(s)}),t.length?((a=this.dataType)==null||a.inferFromInputs(t),this.dataType?(this.generateUnusedInputs(),this.generateUnusedOutputs(),this.variableInstances.forEach(s=>{s.generateUnusedInputs(),s.generateUnusedOutputs()}),this):this):this}sync(e){return this.version=e.version||this.version,this.name=e.name||this.name,this.description=e.description||this.description,this.x=e.x||this.x,this.y=e.y||this.y,this}async load(){return this}async create(){return this}async update(e){return this.sync(e),Sa(e,this),this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){const i=[],a=[];if(t.has(this.id))return{affected:[],removed:[]};if(t.add(this.id),a.push(this),this.unsubscribe(),this.readsValue&&(i.push(this.readsValue),this.readsValue.removeValueReader(this)),this.writesValues.forEach(s=>{i.push(s),s.readsValue=null}),this.inputs.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.outputs.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.successCalls.forEach(s=>{i.push(s),s.removeCaller(this)}),this.errorCalls.forEach(s=>{i.push(s),s.removeCaller(this)}),this.internalCalls.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.dataType){const{affected:s,removed:o}=this.dataType.remove({ignoreUpstream:!0,seenEntities:t});i.push(...s),a.push(...o)}return e||this.calledBy.forEach(s=>{i.push(s),s.removeCall(this)}),{affected:v(i),removed:v(a)}}restore({seenEntities:e}={seenEntities:new Set}){this.subscribe();const t=[];if(this.readsValue&&(t.push(this.readsValue),this.readsValue.addValueReader(this)),this.writesValues.forEach(i=>{t.push(i),i.setValueWriter(this)}),this.inputs.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.outputs.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.successCalls.forEach(i=>{t.push(i),i.addSuccessCaller(this)}),this.errorCalls.forEach(i=>{t.push(i),i.addErrorCaller(this)}),this.internalCalls.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.dataType){const{affected:i}=this.dataType.restore({seenEntities:e});t.push(...i)}return this.calledBySuccess.forEach(i=>{t.push(i),i.addSuccessCall(this)}),this.calledByError.forEach(i=>{t.push(i),i.addErrorCall(this)}),this.calledByEntry.forEach(i=>{t.push(i),i.addCall(this)}),{affected:v(t),self:this}}toFlat(e=new Set){var i;return e.has(this.id)?[]:(e.add(this.id),[this,...((i=this.dataType)==null?void 0:i.toFlat(e))||[],...this.writesValues.flatMap(a=>a.toFlat(e)),...this.successCalls.flatMap(a=>a.toFlat(e)),...this.errorCalls.flatMap(a=>a.toFlat(e)),...this.inputs.flatMap(a=>a.toFlat(e)),...this.outputs.flatMap(a=>a.toFlat(e)),...this.internalCalls.flatMap(a=>a.toFlat(e))])}toFlatIds(e=new Set){var i;return e.has(this.id)?[]:(e.add(this.id),[this.id,...((i=this.dataType)==null?void 0:i.toFlatIds(e))||[],...this.writesValues.flatMap(a=>a.toFlatIds(e)),...this.successCalls.flatMap(a=>a.toFlatIds(e)),...this.errorCalls.flatMap(a=>a.toFlatIds(e)),...this.inputs.flatMap(a=>a.toFlatIds(e)),...this.outputs.flatMap(a=>a.toFlatIds(e)),...this.internalCalls.flatMap(a=>a.toFlatIds(e))])}toJSON(){var e,t;return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,dataType:((e=this.dataType)==null?void 0:e.toJSON())||null,readsValue:((t=this.readsValue)==null?void 0:t.toReference())||null,writesValues:this.writesValues.map(i=>i.toJSON()),inputs:this.inputs.map(i=>i.toJSON()),outputs:this.outputs.map(i=>i.toJSON()),successCalls:this.successCalls.map(i=>i.toJSON()),errorCalls:this.errorCalls.map(i=>i.toJSON()),internalCalls:this.internalCalls.map(i=>i.toJSON()),calledBySuccess:this.calledBySuccess.map(i=>i.toReference()),calledByError:this.calledByError.map(i=>i.toReference()),calledByEntry:this.calledByEntry.map(i=>i.toReference()),parent:this.parent.toReference(),x:this.x,y:this.y}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){var e,t;return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,x:this.x,y:this.y,dataType:((e=this.dataType)==null?void 0:e.toReference())||null,readsValue:((t=this.readsValue)==null?void 0:t.toReference())||null,writesValues:this.writesValues.map(i=>i.toReference()),inputs:this.inputs.map(i=>i.toReference()),outputs:this.outputs.map(i=>i.toReference()),successCalls:this.successCalls.map(i=>i.toReference()),errorCalls:this.errorCalls.map(i=>i.toReference()),calledBySuccess:this.calledBySuccess.map(i=>i.toReference()),calledByError:this.calledByError.map(i=>i.toReference()),calledByEntry:this.calledByEntry.map(i=>i.toReference()),internalCalls:this.internalCalls.map(i=>i.toReference()),parent:this.parent.toReference()}}toFlatJSON(e=new Set){var i;return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...((i=this.dataType)==null?void 0:i.toFlatJSON(e))||[],...this.writesValues.flatMap(a=>a.toFlatJSON(e)),...this.successCalls.flatMap(a=>a.toFlatJSON(e)),...this.errorCalls.flatMap(a=>a.toFlatJSON(e)),...this.inputs.flatMap(a=>a.toFlatJSON(e)),...this.outputs.flatMap(a=>a.toFlatJSON(e)),...this.internalCalls.flatMap(a=>a.toFlatJSON(e))])}toGenerationTarget(){const e=this.parent.type===r.Project?void 0:this.parent.id;return{id:this.id,type:this.type,name:this.name,description:this.description,calledByEntry:this.calledByEntry.map(t=>t.id),calledBySuccess:this.calledBySuccess.map(t=>t.id),calledByError:this.calledByError.map(t=>t.id),parent:e}}toFlatGenerationTarget(e=new Set){var i;return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...((i=this.dataType)==null?void 0:i.toFlatGenerationTarget(e))||[],...this.writesValues.flatMap(a=>a.toFlatGenerationTarget(e)),...this.successCalls.flatMap(a=>a.toFlatGenerationTarget(e)),...this.errorCalls.flatMap(a=>a.toFlatGenerationTarget(e)),...this.inputs.flatMap(a=>a.toFlatGenerationTarget(e)),...this.outputs.flatMap(a=>a.toFlatGenerationTarget(e)),...this.internalCalls.flatMap(a=>a.toFlatGenerationTarget(e))])}clearErrors(){var e;return this.errors=[],this.inputs.forEach(t=>t.clearErrors()),this.outputs.forEach(t=>t.clearErrors()),this.successCalls.forEach(t=>t.clearErrors()),this.errorCalls.forEach(t=>t.clearErrors()),this.internalCalls.forEach(t=>t.clearErrors()),(e=this.dataType)==null||e.clearErrors(),this}validate(){const e=K9(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){var t,i;return[...this.errors,...((t=this.dataType)==null?void 0:t.getErrors())||[],...this.inputs.flatMap(a=>a.getErrors()),...this.internalCalls.flatMap(a=>a.getErrors()),...this.outputs.flatMap(a=>a.getErrors()),...((i=this.readsValue)==null?void 0:i.getErrors())||[]]}getShallowErrors(){return this.errors}getDefaultValue(){var e;return((e=this.dataType)==null?void 0:e.defaultValue)||null}clone(e){return new se(this.toJSON(),this.project)}addInternalCall(e){return this.internalCalls.find(t=>t===e)||this.internalCalls.push(e),this}createInstance(e=this.project,t={}){const i={id:t.id||w.UUID.uuid(),version:t.version||1,type:r.VariableInstance,parent:e.toReference(),successCalls:t.successCalls||[],errorCalls:t.errorCalls||[],inputs:t.inputs||[],outputs:t.outputs||[],writesValues:t.writesValues||[],internalCalls:t.internalCalls||[],readsValue:t.readsValue||null,calledByEntry:t.calledByEntry||[],calledBySuccess:t.calledBySuccess||[],calledByError:t.calledByError||[],declaration:this.toJSON(),x:0,y:0},a=R(i,this.project);return a.setParent(e),a.initChildren(),e===this.project&&this.project.addVariableInstance(a),a}generateUnusedInputs(){if(this.dataType)if(this.dataType.entity){if([r.CustomEntity,r.PrimitiveEntity,r.BuiltInBaseEntity].includes(this.dataType.entity.type)){const e=[...this.dataType.entity.properties,...this.dataType.entity.extendedProperties];e.filter(s=>!s.getDataType()).forEach(s=>{const o=this.inputs.find(y=>S(y,this.project)===S(s,this.project));if(!o)return;const l=this.getMasterInputWithValueWritterFromAllInstances(o);if(!l)return;const p=rn(l);s.setDataType(p),o.setDeclaration(s)}),e.filter(s=>!this.inputs.find(o=>{var l;return((l=o.declaration)==null?void 0:l.id)===s.id})).forEach(s=>{const o={id:w.UUID.uuid(),version:1,type:r.InputMap,parent:this.toReference(),name:null,description:null,declaration:s,defaultValue:null,index:s.index,readsValue:null},l=R(o,this.project);return l.setParent(this),l.initChildren(),l.suggestion=!0,this.addInput(l),l}),this.inputs.filter(s=>!s.declaration).forEach(s=>{const o=e.find(l=>S(l,this.project)===S(s,this.project));o&&s.setDeclaration(o)})}}else return[];else return[];return[]}generateUnusedOutputs(){if(this.dataType)if(this.dataType.entity){if([r.CustomEntity,r.PrimitiveEntity,r.BuiltInBaseEntity].includes(this.dataType.entity.type))return[...this.dataType.entity.properties,...this.dataType.entity.extendedProperties].filter(i=>!this.outputs.find(a=>a.declaration===i)).map(i=>{const a={id:w.UUID.uuid(),version:1,type:r.OutputMap,parent:this.toReference(),declaration:i,index:i.index,writesValues:[]},s=R(a,this.project);return s.setParent(this),s.initChildren(),s.suggestion=!0,this.addOutput(s),s})}else return[];else return[];return[]}generateUnusedInternalCalls(){if(this.dataType)if(this.dataType.entity){if([r.CustomEntity,r.PrimitiveEntity,r.BuiltInBaseEntity].includes(this.dataType.entity.type))return[...this.dataType.entity.getAllInteractiveMethods()].filter(i=>!this.internalCalls.find(s=>{var l,p,y,f,m;return(((l=s.declaration)==null?void 0:l.id)||((y=(p=s.initialData)==null?void 0:p.declaration)==null?void 0:y.entityId)||((m=(f=s.initialData)==null?void 0:f.declaration)==null?void 0:m.id))===i.id})).map(i=>{const a=i.createInternalCall(this);return a.suggestion=!0,this.addInternalCall(a),a})}else return[];else return[];return[]}setDataType(e){return this.dataType=e,this}removeDataType(){return this.dataType=null,this}getDataType(){return(!this.dataType||this.dataType.inferred)&&this.inferDataTypeAndSyncInstancesInputsAndOutputs(),this.dataType||null}getUnusedInputs(){return this.inputs.filter(e=>e.suggestion||!e.readsValue&&!e.defaultValue)}getUnusedOutputs(){return this.outputs.filter(e=>e.suggestion||!e.writesValues.length)}getUsedInputs(){return this.inputs.filter(e=>!e.suggestion&&(e.readsValue||e.defaultValue))}getUsedOutputs(){return this.outputs.filter(e=>!e.suggestion&&e.writesValues.length)}};c(se,"MUTABLE_BASE_PROPERTIES",["name","description"]),c(se,"INMUTABLE_BASE_PROPERTIES",["id","type","version"]),c(se,"BASE_PROPERTIES",[...se.MUTABLE_BASE_PROPERTIES,...se.INMUTABLE_BASE_PROPERTIES]),c(se,"MUTABLE_META_PROPERTIES",[...se.MUTABLE_BASE_PROPERTIES,"x","y"]),c(se,"INMUTABLE_META_PROPERTIES",[...se.INMUTABLE_BASE_PROPERTIES]),c(se,"META_PROPERTIES",[...se.MUTABLE_META_PROPERTIES,...se.INMUTABLE_META_PROPERTIES]),c(se,"MUTABLE_UPSTREAM_PROPERTIES",["calledBySuccess","calledByError","calledByEntry","readsValue"]),c(se,"INMUTABLE_UPSTREAM_PROPERTIES",["parent","dataType"]),c(se,"UPSTREAM_PROPERTIES",[...se.MUTABLE_UPSTREAM_PROPERTIES,...se.INMUTABLE_UPSTREAM_PROPERTIES]),c(se,"MUTABLE_DOWNSTREAM_PROPERTIES",["writesValues","inputs","outputs","successCalls","errorCalls","internalCalls"]),c(se,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(se,"DOWNSTREAM_PROPERTIES",[...se.MUTABLE_DOWNSTREAM_PROPERTIES,...se.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(se,"PROPERTIES",[...se.META_PROPERTIES,...se.UPSTREAM_PROPERTIES,...se.DOWNSTREAM_PROPERTIES]);let Pr=se;function e3(n){const e=Nx(),t=n.toJSON();e.safeParse(t).success,n.inputs.forEach(l=>l.validate()),n.outputs.forEach(l=>l.validate()),n.internalCalls.forEach(l=>l.validate());const s=[...In(n)];if(n.id==="exec-sequentially-result-variable-id"){const l=H({id:`${n.id}--${_.PropertyImplementsNonAbstact}`,message:`Property "${S(n,n.project)}" with id "${n.id}" implements a non-abstract property "${S(n,n.project)}" with id "${n.id}".`,issue:null,severity:T.Error,code:_.PropertyImplementsNonAbstact,entity:n});s.push(l.error)}const o=Nd(n);return s.push(...o),ne(n.errors,s)}const oe=class oe{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"x");c(this,"y");c(this,"type",r.VariableInstance);c(this,"writesValues",[]);c(this,"readsValue",null);c(this,"declaration");c(this,"inputs",[]);c(this,"outputs",[]);c(this,"calledBySuccess",[]);c(this,"calledByError",[]);c(this,"calledByEntry",[]);c(this,"successCalls",[]);c(this,"errorCalls",[]);c(this,"internalCalls",[]);c(this,"project");c(this,"errors",[]);c(this,"parent");c(this,"initialized",!1);c(this,"suggestion",!1);this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.x=e.x,this.y=e.y}static fromGenerationTarget(e,t){let i=t;if(e.parent){const b=C(e.parent);i=t.get(b)}const a=C(e.declaration),s=t.get(a),o=e.calledByEntry.map(b=>{const g=C(b);return t.get(g)}),l=e.calledBySuccess.map(b=>{const g=C(b);return t.get(g)}),p=e.calledByError.map(b=>{const g=C(b);return t.get(g)});let y=null;if(e.readsValue){const b=C(e.readsValue);y=t.get(b)}const f={id:e.id,version:1,type:r.VariableInstance,declaration:s.toReference(),calledByEntry:o,calledBySuccess:l,calledByError:p,errorCalls:[],successCalls:[],internalCalls:[],readsValue:y,inputs:[],outputs:[],writesValues:[],x:0,y:0,parent:i},m=R(f,t);return m.setParent(i),m.initChildren(),m}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[],s=je(i,{parent:{list:!1,types:[...ct,r.Project],optional:!0},declaration:{list:!1,types:[r.VariableDeclaration]}},t);return i=s.modifiedData,a.push(...s.errors,...Be(i)),{errors:a,modifiedData:i}}validateGeneratedUpdate(e){const t=[];let i=JSON.parse(JSON.stringify(e));const a=Da(i,this);return i=a.modifiedData,t.push(...a.errors),e.parent&&t.push(new E({id:`${this.id}--${h.InvalidParentUpdate}`,code:h.InvalidParentUpdate,severity:T.Error,message:`Entity of type '${this.type}' with id '${this.id}' cannot have the 'parent' property updated. The 'parent' on a callable entity, is its scope. It scope is auto-calculated implicitly by the its caller.
|
|
@@ -159,7 +159,7 @@ You shouldn't have to manually update a 'parent' property.
|
|
|
159
159
|
Specifically for return statements the parent needs to always be the 'function-declaration' or 'global-event' that contains it.`,issue:null})),{errors:t,modifiedData:e}}addSelfToProject(){const e=[this];return this.calledByEntry.forEach(t=>{t.addCall(this),e.push(t)}),this.calledBySuccess.forEach(t=>{t.addSuccessCall(this),e.push(t)}),this.calledByError.forEach(t=>{t.addErrorCall(this),e.push(t)}),this.parent.addReturnStatement(this),e.push(this.parent),{affected:v(e),self:this}}get calledBy(){return[...this.calledByEntry,...this.calledBySuccess,...this.calledByError]}addSuccessCaller(e){return this.calledBySuccess.find(t=>t.id===e.id)||this.calledBySuccess.push(e),this}addErrorCaller(e){return this.calledByError.find(t=>t.id===e.id)||this.calledByError.push(e),this}addEntryCaller(e){return this.calledByEntry.find(t=>t.id===e.id)||this.calledByEntry.push(e),this}removeCaller(e){return this.calledBySuccess=this.calledBySuccess.filter(t=>t.id!==e.id),this.calledByError=this.calledByError.filter(t=>t.id!==e.id),this.calledByEntry=this.calledByEntry.filter(t=>t.id!==e.id),this}addOutputDeclaration(e){return this.outputs.find(t=>t.id===e.id)||this.outputs.push(e),this}removeOutputDeclaration(e){return this.outputs=this.outputs.filter(t=>t.id!==e.id),this}setParent(e){return this.parent=e,this}initChildren(){return this.initialized?this:(this.initialized=!0,this.outputs=this.initialData.outputs.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this.initialData.throws&&(this.throws=R(this.initialData.throws,this.project),this.throws.setParent(this),this.throws.initChildren()),this.parent.addReturnStatement(this),this)}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}sync(e){return this.version=e.version||this.version,this.x=e.x||this.x,this.y=e.y||this.y,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){const i=[],a=[];if(t.has(this.id))return{affected:[],removed:[]};if(t.add(this.id),a.push(this),this.unsubscribe(),this.outputs.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.throws){const{affected:s,removed:o}=this.throws.remove({ignoreUpstream:!0,seenEntities:t});i.push(...s),a.push(...o)}return this.parent.removeReturnStatement(this),e||this.calledBy.forEach(s=>{i.push(s),s.removeCall(this)}),{affected:v(i),removed:v(a)}}restore({seenEntities:e}={seenEntities:new Set}){const t=[];if(e.has(this.id))return{affected:[],self:this};if(e.add(this.id),this.subscribe(),this.outputs.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.throws){const{affected:i}=this.throws.restore({seenEntities:e});t.push(...i)}return this.parent.addReturnStatement(this),this.calledBySuccess.forEach(i=>{t.push(i),i.addSuccessCall(this)}),this.calledByError.forEach(i=>{t.push(i),i.addErrorCall(this)}),this.calledByEntry.forEach(i=>{t.push(i),i.addCall(this)}),{affected:v(t),self:this}}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.outputs.flatMap(i=>i.toFlat(e)),...this.throws?this.throws.toFlat(e):[]])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.outputs.flatMap(i=>i.toFlatIds(e)),...this.throws?this.throws.toFlatIds(e):[]])}toJSON(){var e,t;return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,calledBySuccess:this.calledBySuccess.map(i=>i.toReference()),calledByError:this.calledByError.map(i=>i.toReference()),calledByEntry:this.calledByEntry.map(i=>i.toReference()),outputs:this.outputs.map(i=>i.toJSON()),parent:((e=this.parent)==null?void 0:e.toReference())||null,throws:((t=this.throws)==null?void 0:t.toJSON())||null}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){var e,t;return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,outputs:this.outputs.map(i=>i.toReference()),calledBySuccess:this.calledBySuccess.map(i=>i.toReference()),calledByError:this.calledByError.map(i=>i.toReference()),calledByEntry:this.calledByEntry.map(i=>i.toReference()),throws:((e=this.throws)==null?void 0:e.toReference())||null,parent:((t=this.parent)==null?void 0:t.toReference())||null}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.outputs.flatMap(i=>i.toFlatJSON(e)),...this.throws?this.throws.toFlatJSON(e):[]])}toGenerationTarget(){return{id:this.id,type:this.type,calledByEntry:this.calledByEntry.map(e=>e.id),calledByError:this.calledByError.map(e=>e.id),calledBySuccess:this.calledBySuccess.map(e=>e.id),parent:this.parent.id}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.outputs.flatMap(i=>i.toFlatGenerationTarget(e)),...this.throws?this.throws.toFlatGenerationTarget(e):[]])}clearErrors(){var e;return this.errors=[],this.outputs.forEach(t=>t.clearErrors()),(e=this.throws)==null||e.clearErrors(),this}validate(){const e=f3(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors,...this.outputs.flatMap(t=>t.getErrors())]}getShallowErrors(){return this.errors}clone(e){return new ot(this.toJSON(),this.project)}};c(ot,"MUTABLE_BASE_PROPERTIES",[]),c(ot,"INMUTABLE_BASE_PROPERTIES",["id","version","type"]),c(ot,"BASE_PROPERTIES",[...Tt.MUTABLE_BASE_PROPERTIES,...Tt.INMUTABLE_BASE_PROPERTIES]),c(ot,"MUTABLE_META_PROPERTIES",["x","y"]),c(ot,"INMUTABLE_META_PROPERTIES",[...Tt.INMUTABLE_BASE_PROPERTIES]),c(ot,"META_PROPERTIES",[...Tt.MUTABLE_META_PROPERTIES,...Tt.INMUTABLE_META_PROPERTIES]),c(ot,"MUTABLE_UPSTREAM_PROPERTIES",["calledBySuccess","calledByError","calledByEntry","parent"]),c(ot,"INMUTABLE_UPSTREAM_PROPERTIES",[]),c(ot,"UPSTREAM_PROPERTIES",[...Tt.MUTABLE_UPSTREAM_PROPERTIES,...Tt.INMUTABLE_UPSTREAM_PROPERTIES]),c(ot,"MUTABLE_DOWNSTREAM_PROPERTIES",["outputs","throws"]),c(ot,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(ot,"DOWNSTREAM_PROPERTIES",[...Tt.MUTABLE_DOWNSTREAM_PROPERTIES,...Tt.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(ot,"PROPERTIES",[..._t.META_PROPERTIES,..._t.UPSTREAM_PROPERTIES,..._t.DOWNSTREAM_PROPERTIES]);let Br=ot;function T3(n){var s;const e=BU(),t=n.toJSON();e.safeParse(t).success,n.outputs.forEach(o=>o.validate()),(s=n.throws)==null||s.validate();const a=[];return ne(n.errors,a)}const ge=class ge{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"x");c(this,"y");c(this,"type",r.BreakStatement);c(this,"outputs",[]);c(this,"calledBySuccess",[]);c(this,"calledByError",[]);c(this,"calledByEntry",[]);c(this,"throws",null);c(this,"project");c(this,"errors",[]);c(this,"parent");c(this,"initialized",!1);c(this,"suggestion",!1);this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.x=e.x,this.y=e.y}static fromGenerationTarget(e,t){const i=C(e.parent),a=t.get(i),s=e.calledByEntry.map(f=>{const m=C(f);return t.get(m)}),o=e.calledBySuccess.map(f=>{const m=C(f);return t.get(m)}),l=e.calledByError.map(f=>{const m=C(f);return t.get(m)}),p={id:e.id,version:1,type:r.BreakStatement,x:0,y:0,outputs:[],calledBySuccess:o,calledByError:l,calledByEntry:s,throws:null,parent:a},y=R(p,t);return y.setParent(a),y.initChildren(),y}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[],s=je(i,{parent:{list:!1,types:[r.Loop]}},t);return i=s.modifiedData,a.push(...s.errors,...Be(i)),{errors:a,modifiedData:i}}validateGeneratedUpdate(e){const t=[];return e.parent&&t.push(new E({id:`${this.id}--${h.InvalidParentUpdate}`,code:h.InvalidParentUpdate,severity:T.Error,message:`Entity of type '${this.type}' with id '${this.id}' cannot have the 'parent' property updated. The 'parent' on a callable entity, is its scope. It scope is auto-calculated implicitly by the its caller.
|
|
160
160
|
If an entity is called by another, they must be in the same scope, which means they have the same parent.
|
|
161
161
|
You shouldn't have to manually update a 'parent' property.
|
|
162
|
-
Specifically for break statements the parent needs to always be the 'loop' entity that contains it.`,issue:null})),{errors:t,modifiedData:e}}addSelfToProject(){const e=[this];return this.calledByEntry.forEach(t=>{t.addCall(this),e.push(t)}),this.calledBySuccess.forEach(t=>{t.addSuccessCall(this),e.push(t)}),this.calledByError.forEach(t=>{t.addErrorCall(this),e.push(t)}),this.parent.addBreakStatement(this),e.push(this.parent),{affected:v(e),self:this}}get calledBy(){return[...this.calledByEntry,...this.calledBySuccess,...this.calledByError]}addSuccessCaller(e){return this.calledBySuccess.find(t=>t.id===e.id)||this.calledBySuccess.push(e),this}addErrorCaller(e){return this.calledByError.find(t=>t.id===e.id)||this.calledByError.push(e),this}addEntryCaller(e){return this.calledByEntry.find(t=>t.id===e.id)||this.calledByEntry.push(e),this}removeCaller(e){return this.calledBySuccess=this.calledBySuccess.filter(t=>t.id!==e.id),this.calledByError=this.calledByError.filter(t=>t.id!==e.id),this.calledByEntry=this.calledByEntry.filter(t=>t.id!==e.id),this}addOutputDeclaration(e){return this.outputs.find(t=>t.id===e.id)||this.outputs.push(e),this}removeOutputDeclaration(e){return this.outputs=this.outputs.filter(t=>t.id!==e.id),this}setParent(e){return this.parent=e,this}initChildren(){return this.initialized?this:(this.initialized=!0,this.outputs=this.initialData.outputs.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this.initialData.throws&&(this.throws=R(this.initialData.throws,this.project),this.throws.setParent(this),this.throws.initChildren()),this.parent.addBreakStatement(this),this)}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}sync(e){return this.version=e.version||this.version,this.x=e.x||this.x,this.y=e.y||this.y,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){const i=[],a=[];if(t.has(this.id))return{affected:[],removed:[]};if(t.add(this.id),a.push(this),this.unsubscribe(),this.outputs.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.throws){const{affected:s,removed:o}=this.throws.remove({ignoreUpstream:!0,seenEntities:t});i.push(...s),a.push(...o)}return this.parent.removeBreakStatement(this),e||this.calledBy.forEach(s=>{i.push(s),s.removeCall(this)}),{affected:v(i),removed:v(a)}}restore({seenEntities:e}={seenEntities:new Set}){const t=[];if(e.has(this.id))return{affected:[],self:this};if(e.add(this.id),this.subscribe(),this.outputs.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.throws){const{affected:i}=this.throws.restore({seenEntities:e});t.push(...i)}return this.parent.addBreakStatement(this),this.calledBySuccess.forEach(i=>{t.push(i),i.addSuccessCall(this)}),this.calledByError.forEach(i=>{t.push(i),i.addErrorCall(this)}),this.calledByEntry.forEach(i=>{t.push(i),i.addCall(this)}),{affected:v(t),self:this}}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.outputs.flatMap(i=>i.toFlat(e)),...this.throws?this.throws.toFlat(e):[]])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.outputs.flatMap(i=>i.toFlatIds(e)),...this.throws?this.throws.toFlatIds(e):[]])}toJSON(){var e,t;return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,outputs:this.outputs.map(i=>i.toJSON()),calledBySuccess:this.calledBySuccess.map(i=>i.toReference()),calledByError:this.calledByError.map(i=>i.toReference()),calledByEntry:this.calledByEntry.map(i=>i.toReference()),parent:((e=this.parent)==null?void 0:e.toReference())||null,throws:((t=this.throws)==null?void 0:t.toJSON())||null}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){var e,t;return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,outputs:this.outputs.map(i=>i.toReference()),calledBySuccess:this.calledBySuccess.map(i=>i.toReference()),calledByError:this.calledByError.map(i=>i.toReference()),calledByEntry:this.calledByEntry.map(i=>i.toReference()),throws:((e=this.throws)==null?void 0:e.toReference())||null,parent:((t=this.parent)==null?void 0:t.toReference())||null}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.outputs.flatMap(i=>i.toFlatJSON(e)),...this.throws?this.throws.toFlatJSON(e):[]])}toGenerationTarget(){return{id:this.id,type:this.type,calledByEntry:this.calledByEntry.map(e=>e.id),calledByError:this.calledByError.map(e=>e.id),calledBySuccess:this.calledBySuccess.map(e=>e.id),parent:this.parent.id}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.outputs.flatMap(i=>i.toFlatGenerationTarget(e)),...this.throws?this.throws.toFlatGenerationTarget(e):[]])}clearErrors(){var e;return this.errors=[],this.outputs.forEach(t=>t.clearErrors()),(e=this.throws)==null||e.clearErrors(),this}validate(){const e=T3(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors,...this.outputs.flatMap(t=>t.getErrors()),...this.throws?this.throws.getErrors():[]]}getShallowErrors(){return this.errors}clone(e){return new ge(this.toJSON(),this.project)}};c(ge,"MUTABLE_BASE_PROPERTIES",[]),c(ge,"INMUTABLE_BASE_PROPERTIES",["id","version","type"]),c(ge,"BASE_PROPERTIES",[...ge.MUTABLE_BASE_PROPERTIES,...ge.INMUTABLE_BASE_PROPERTIES]),c(ge,"MUTABLE_META_PROPERTIES",["x","y"]),c(ge,"INMUTABLE_META_PROPERTIES",[...ge.INMUTABLE_BASE_PROPERTIES]),c(ge,"META_PROPERTIES",[...ge.MUTABLE_META_PROPERTIES,...ge.INMUTABLE_META_PROPERTIES]),c(ge,"MUTABLE_UPSTREAM_PROPERTIES",["calledBySuccess","calledByError","calledByEntry","parent"]),c(ge,"INMUTABLE_UPSTREAM_PROPERTIES",[]),c(ge,"UPSTREAM_PROPERTIES",[...ge.MUTABLE_UPSTREAM_PROPERTIES,...ge.INMUTABLE_UPSTREAM_PROPERTIES]),c(ge,"MUTABLE_DOWNSTREAM_PROPERTIES",["outputs","throws"]),c(ge,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(ge,"DOWNSTREAM_PROPERTIES",[...ge.MUTABLE_DOWNSTREAM_PROPERTIES,...ge.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(ge,"PROPERTIES",[...ge.META_PROPERTIES,...ge.UPSTREAM_PROPERTIES,...ge.DOWNSTREAM_PROPERTIES]);let Ei=ge;function E3(n){var s,o;const e=
|
|
162
|
+
Specifically for break statements the parent needs to always be the 'loop' entity that contains it.`,issue:null})),{errors:t,modifiedData:e}}addSelfToProject(){const e=[this];return this.calledByEntry.forEach(t=>{t.addCall(this),e.push(t)}),this.calledBySuccess.forEach(t=>{t.addSuccessCall(this),e.push(t)}),this.calledByError.forEach(t=>{t.addErrorCall(this),e.push(t)}),this.parent.addBreakStatement(this),e.push(this.parent),{affected:v(e),self:this}}get calledBy(){return[...this.calledByEntry,...this.calledBySuccess,...this.calledByError]}addSuccessCaller(e){return this.calledBySuccess.find(t=>t.id===e.id)||this.calledBySuccess.push(e),this}addErrorCaller(e){return this.calledByError.find(t=>t.id===e.id)||this.calledByError.push(e),this}addEntryCaller(e){return this.calledByEntry.find(t=>t.id===e.id)||this.calledByEntry.push(e),this}removeCaller(e){return this.calledBySuccess=this.calledBySuccess.filter(t=>t.id!==e.id),this.calledByError=this.calledByError.filter(t=>t.id!==e.id),this.calledByEntry=this.calledByEntry.filter(t=>t.id!==e.id),this}addOutputDeclaration(e){return this.outputs.find(t=>t.id===e.id)||this.outputs.push(e),this}removeOutputDeclaration(e){return this.outputs=this.outputs.filter(t=>t.id!==e.id),this}setParent(e){return this.parent=e,this}initChildren(){return this.initialized?this:(this.initialized=!0,this.outputs=this.initialData.outputs.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this.initialData.throws&&(this.throws=R(this.initialData.throws,this.project),this.throws.setParent(this),this.throws.initChildren()),this.parent.addBreakStatement(this),this)}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}sync(e){return this.version=e.version||this.version,this.x=e.x||this.x,this.y=e.y||this.y,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){const i=[],a=[];if(t.has(this.id))return{affected:[],removed:[]};if(t.add(this.id),a.push(this),this.unsubscribe(),this.outputs.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.throws){const{affected:s,removed:o}=this.throws.remove({ignoreUpstream:!0,seenEntities:t});i.push(...s),a.push(...o)}return this.parent.removeBreakStatement(this),e||this.calledBy.forEach(s=>{i.push(s),s.removeCall(this)}),{affected:v(i),removed:v(a)}}restore({seenEntities:e}={seenEntities:new Set}){const t=[];if(e.has(this.id))return{affected:[],self:this};if(e.add(this.id),this.subscribe(),this.outputs.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.throws){const{affected:i}=this.throws.restore({seenEntities:e});t.push(...i)}return this.parent.addBreakStatement(this),this.calledBySuccess.forEach(i=>{t.push(i),i.addSuccessCall(this)}),this.calledByError.forEach(i=>{t.push(i),i.addErrorCall(this)}),this.calledByEntry.forEach(i=>{t.push(i),i.addCall(this)}),{affected:v(t),self:this}}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.outputs.flatMap(i=>i.toFlat(e)),...this.throws?this.throws.toFlat(e):[]])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.outputs.flatMap(i=>i.toFlatIds(e)),...this.throws?this.throws.toFlatIds(e):[]])}toJSON(){var e,t;return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,outputs:this.outputs.map(i=>i.toJSON()),calledBySuccess:this.calledBySuccess.map(i=>i.toReference()),calledByError:this.calledByError.map(i=>i.toReference()),calledByEntry:this.calledByEntry.map(i=>i.toReference()),parent:((e=this.parent)==null?void 0:e.toReference())||null,throws:((t=this.throws)==null?void 0:t.toJSON())||null}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){var e,t;return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,outputs:this.outputs.map(i=>i.toReference()),calledBySuccess:this.calledBySuccess.map(i=>i.toReference()),calledByError:this.calledByError.map(i=>i.toReference()),calledByEntry:this.calledByEntry.map(i=>i.toReference()),throws:((e=this.throws)==null?void 0:e.toReference())||null,parent:((t=this.parent)==null?void 0:t.toReference())||null}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.outputs.flatMap(i=>i.toFlatJSON(e)),...this.throws?this.throws.toFlatJSON(e):[]])}toGenerationTarget(){return{id:this.id,type:this.type,calledByEntry:this.calledByEntry.map(e=>e.id),calledByError:this.calledByError.map(e=>e.id),calledBySuccess:this.calledBySuccess.map(e=>e.id),parent:this.parent.id}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.outputs.flatMap(i=>i.toFlatGenerationTarget(e)),...this.throws?this.throws.toFlatGenerationTarget(e):[]])}clearErrors(){var e;return this.errors=[],this.outputs.forEach(t=>t.clearErrors()),(e=this.throws)==null||e.clearErrors(),this}validate(){const e=T3(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors,...this.outputs.flatMap(t=>t.getErrors()),...this.throws?this.throws.getErrors():[]]}getShallowErrors(){return this.errors}clone(e){return new ge(this.toJSON(),this.project)}};c(ge,"MUTABLE_BASE_PROPERTIES",[]),c(ge,"INMUTABLE_BASE_PROPERTIES",["id","version","type"]),c(ge,"BASE_PROPERTIES",[...ge.MUTABLE_BASE_PROPERTIES,...ge.INMUTABLE_BASE_PROPERTIES]),c(ge,"MUTABLE_META_PROPERTIES",["x","y"]),c(ge,"INMUTABLE_META_PROPERTIES",[...ge.INMUTABLE_BASE_PROPERTIES]),c(ge,"META_PROPERTIES",[...ge.MUTABLE_META_PROPERTIES,...ge.INMUTABLE_META_PROPERTIES]),c(ge,"MUTABLE_UPSTREAM_PROPERTIES",["calledBySuccess","calledByError","calledByEntry","parent"]),c(ge,"INMUTABLE_UPSTREAM_PROPERTIES",[]),c(ge,"UPSTREAM_PROPERTIES",[...ge.MUTABLE_UPSTREAM_PROPERTIES,...ge.INMUTABLE_UPSTREAM_PROPERTIES]),c(ge,"MUTABLE_DOWNSTREAM_PROPERTIES",["outputs","throws"]),c(ge,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(ge,"DOWNSTREAM_PROPERTIES",[...ge.MUTABLE_DOWNSTREAM_PROPERTIES,...ge.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(ge,"PROPERTIES",[...ge.META_PROPERTIES,...ge.UPSTREAM_PROPERTIES,...ge.DOWNSTREAM_PROPERTIES]);let Ei=ge;function E3(n){var s,o;const e=Fb(),t=n.toJSON();e.safeParse(t).success,n.fixedArguments.flatMap(l=>l.validate()),n.fixedReturns.flatMap(l=>l.validate()),(s=n.dynamicArgumentTypes)==null||s.validate(),(o=n.dynamicReturnTypes)==null||o.validate();const a=[];return ne(n.errors,a)}const ve=class ve{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"name");c(this,"description",null);c(this,"argumentsType");c(this,"returnsType");c(this,"type",r.ActionDescriptor);c(this,"fixedArguments",[]);c(this,"fixedReturns",[]);c(this,"error",null);c(this,"dynamicArgumentTypes",null);c(this,"dynamicReturnTypes",null);c(this,"implementation",null);c(this,"parent",null);c(this,"errors",[]);c(this,"project");c(this,"initialized",!1);this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.name=e.name,this.description=e.description,this.argumentsType=e.argumentsType,this.returnsType=e.returnsType}static fromGenerationTarget(e,t){let i=null;if(e.parent){const o=C(e.parent);i=t.get(o)}const a={id:e.id,version:1,name:e.name,type:r.ActionDescriptor,description:e.description,dynamicArgumentTypes:null,dynamicReturnTypes:null,argumentsType:e.argumentsType,returnsType:e.returnsType,fixedArguments:[],fixedReturns:[],error:null,parent:i},s=R(a,t);return i&&s.setParent(i),s.initChildren(),s}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[],s=je(i,{parent:{list:!1,types:[r.CustomEntity,r.DataType]}},t);i=s.modifiedData;const o=i.parent?t.get(i.parent):null;if(o&&o.type===r.CustomEntity){const l=o,y=Hn(l).filter(f=>!f.interactive);if(y.length){let f=y.length>1?`The entity of type '${e.type}' with id '${e.id}' can't be added to the 'parent' entity with id '${l.id}' because it extends or implements multiple '${r.BuiltInBaseEntity}' entities that are non-interactive ("${L(y.map(m=>S(m,m.project)),'", "','" and "')}").`:`The entity of type '${e.type}' with id '${e.id}' can't be added to the 'parent' entity with id '${l.id}' because it extends or implements a '${r.BuiltInBaseEntity}' entity that is non-interactive ("${S(y[0],y[0].project)}").`;f+=`
|
|
163
163
|
${Jn}`,a.push(new E({id:`${e.id}--${h.NonInteractiveEntityReferenced}`,code:h.NonInteractiveEntityReferenced,severity:T.Error,message:f,issue:null}))}}else if(o&&o.type===r.DataType){const l=o;l.entity&&a.push(new E({id:`${e.id}--${h.NewEntityWouldOverriteExisting}`,code:h.NewEntityWouldOverriteExisting,severity:T.Error,message:`The entity of type '${e.type}' with id '${e.id}' can't be added to the 'parent' entity with id '${l.id}' because it already has an 'entity' child. Data type entities can only have one 'entity' as children.
|
|
164
164
|
You can inspect the existing 'entity' field with the 'describe_entity' action. Like so:
|
|
165
165
|
${an({describe_entity:l.entity.id})}
|
|
@@ -189,21 +189,21 @@ ${qn}`,severity:T.Error,code:h.InvalidInmutablePropertyOverride,issue:null}))),t
|
|
|
189
189
|
If you need to update this property, you should delete the entity and create a new one with the updated value.`,severity:T.Error,code:h.InvalidInmutablePropertyOverride,issue:null})),i=!0)}),(a.DOWNSTREAM_PROPERTIES||[]).forEach(B=>{n[B]&&!fa(n[B])&&(t.push(new E({id:`${e.id}--${h.InvalidDownstreamPropertyOverride}`,message:`Entity of type "${e.type}" with id "${e.id}" cannot have the property "${B}" set directly. It is a downstream property that points to a downstream nested entity.
|
|
190
190
|
All downstream references are managed by the downstream entity. Entities only manage their own upstream references.
|
|
191
191
|
To modify '${B}', target the entity that it points to and its equivalent property.`,severity:T.Error,code:h.InvalidDownstreamPropertyOverride,issue:null})),i=!0)}),(a.INMUTABLE_UPSTREAM_PROPERTIES||[]).forEach(B=>{n[B]&&!fa(n[B])&&(t.push(new E({id:`${e.id}--${h.InvalidInmutablePropertyOverride}`,message:`Entity of type "${e.type}" with id "${e.id}" cannot have the property "${B}" updated. It is an inmutable property that is set only when the entity is created.
|
|
192
|
-
If you need to update this property, you should delete the entity and create a new one with the updated value.`,severity:T.Error,code:h.InvalidInmutablePropertyOverride,issue:null})),i=!0)});const P=a.PROPERTIES||[];P.length>0&&Object.keys(n).forEach(B=>{P.includes(B)||t.push(new E({id:`${e.id}--${h.UnrecognizedProperty}`,message:`Entity of type "${e.type}" with id "${e.id}" has an unrecognized property "${B}" that will be ignored.`,severity:T.Warning,code:h.UnrecognizedProperty,issue:null}))})}if(t.length)return{errors:t,modifiedData:null,messageAddition:i?co(e):""};const s=
|
|
192
|
+
If you need to update this property, you should delete the entity and create a new one with the updated value.`,severity:T.Error,code:h.InvalidInmutablePropertyOverride,issue:null})),i=!0)});const P=a.PROPERTIES||[];P.length>0&&Object.keys(n).forEach(B=>{P.includes(B)||t.push(new E({id:`${e.id}--${h.UnrecognizedProperty}`,message:`Entity of type "${e.type}" with id "${e.id}" has an unrecognized property "${B}" that will be ignored.`,severity:T.Warning,code:h.UnrecognizedProperty,issue:null}))})}if(t.length)return{errors:t,modifiedData:null,messageAddition:i?co(e):""};const s=Pv(e),o=s==null?void 0:s.partial(),l=o==null?void 0:o.safeParse(n),p={...n,id:e.id,type:e.type},y=Pd(p,l);if(t.push(...y),t.length)return{errors:t,modifiedData:null,messageAddition:i?co(e):""};const m=e.validateGeneratedUpdate(n);return{errors:[...t,...m.errors],modifiedData:m.modifiedData,messageAddition:i?co(e):""}}function Pv(n){switch(n.type){case r.PrimitiveValue:return Ls();case r.CustomEntity:return xc();case r.PrimitiveEntity:return Ls();case r.FunctionDeclaration:return Fc();case r.GlobalEvent:return Js();case r.DataType:return wc();case r.Property:return fc();case r.FunctionCall:return Ic();case r.Condition:return Dc();case r.Operation:return ks();case r.VariableDeclaration:return Mc();case r.VariableInstance:return Nc();case r.OutputMap:return vc();case r.ReturnDeclaration:return Rc();case r.ArgumentDeclaration:return Gc();case r.InputMap:return Oc();case r.Project:return Uc();case r.InstalledProject:return Vx();case r.ActionDescriptor:return Fs();case r.ReturnStatement:return Ec();case r.Loop:return Fs();case r.Search:return Pc();case r.ValueDescriptor:return hc();case r.BuiltInBaseEntity:return mc();case r.InternalCall:return Sc();case r.ContinueStatement:return Tc();case r.BreakStatement:return bc();default:return null}}function Av(n){switch(n.type){case r.PrimitiveValue:return cx();case r.CustomEntity:return A8();case r.PrimitiveEntity:return Z4();case r.FunctionDeclaration:return T8();case r.GlobalEvent:return kx();case r.DataType:return vx();case r.Property:return eU();case r.FunctionCall:return $U();case r.Condition:return xU();case r.Operation:return rx();case r.VariableDeclaration:return Sx();case r.VariableInstance:return _x();case r.OutputMap:return _U();case r.ReturnDeclaration:return DU();case r.ArgumentDeclaration:return y8();case r.InputMap:return KU();case r.Project:return v8();case r.InstalledProject:return Lx();case r.ActionDescriptor:return cU();case r.ReturnStatement:return bU();case r.Loop:return pU();case r.Search:return JU();case r.ValueDescriptor:return W4();case r.BuiltInBaseEntity:return aU();case r.InternalCall:return zU();case r.ContinueStatement:return mU();case r.BreakStatement:return OU();default:return null}}function uo(n){const e=[];xn(n)||e.push(new E({id:`${n}--${h.InvalidReferenceObjectStructure}`,message:`Reference object with id "${n}" is not an object. References should be objects with exactly 4 properties: 'entityId', 'entityType', 'id', and 'type'.`,severity:T.Error,code:h.InvalidReferenceObjectStructure,issue:null}));const t=n.id||"reference-to--"+(n.entityId||"unknown"),i=`Reference object ${n.id?`with id "${n.id}"`:`to entity with id "${n.entityId}" and type "${n.entityType}"`}`;return n.entityId||e.push(new E({id:`${t}--${h.InvalidReferenceObjectStructure}`,message:`${i} is missing an 'entityId' property.`,severity:T.Error,code:h.InvalidReferenceObjectStructure,issue:null})),n.entityType||e.push(new E({id:`${t}--${h.InvalidReferenceObjectStructure}`,message:`${i} is missing an 'entityType' property.`,severity:T.Error,code:h.InvalidReferenceObjectStructure,issue:null})),n.id||e.push(new E({id:`${t}--${h.MissingIdProperty}`,message:`${i} is missing an 'id' property.`,severity:T.Error,code:h.MissingIdProperty,issue:null})),n.type||e.push(new E({id:`${t}--${h.MissingTypeProperty}`,message:`${i} is missing a 'type' property.`,severity:T.Error,code:h.MissingTypeProperty,issue:null})),e}function Pd(n,e){return e.success?[]:e.error.issues.map(t=>new E({id:`${n.id}--${D.InvalidObjectStructure}`,message:`Entity of type "${n.type}" and with id "${n.id}", has an invalid structure: ${Y8(t).toString().replace("Validation error: ","")}`,severity:T.Error,code:D.InvalidObjectStructure,issue:t}))}function Be(n,e){const t=[],i=Av(n);if(i){const s=i.safeParse(n);t.push(...Pd(n,s))}const a=Io(n.type);if(a){(a.DOWNSTREAM_PROPERTIES||[]).forEach(l=>{n[l]&&!fa(n[l])&&t.push(new E({id:`${n.id}--${h.InvalidDownstreamPropertyOverride}`,message:`Entity of type "${n.type}" with id "${n.id}" cannot have the property "${l}" set directly. It is a downstream property that points to a downstream nested entity.
|
|
193
193
|
All downstream references are managed by the downstream entity. Entities only manage their own upstream references.
|
|
194
194
|
To modify '${l}', target the entity that it points to and its equivalent property.`,severity:T.Error,code:h.InvalidDownstreamPropertyOverride,issue:null}))});const o=a.PROPERTIES||[];o.length>0&&Object.keys(n).forEach(l=>{o.includes(l)||t.push(new E({id:`${n.id}--${h.UnrecognizedProperty}`,message:`Entity of type "${n.type}" with id "${n.id}" has an unrecognized property "${l}" that will be ignored.`,severity:T.Warning,code:h.UnrecognizedProperty,issue:null}))})}return t}function v3(n,e){const t=[];if(!n.parent)return t;const i=e.get(n.parent);return i?(Gr.includes(i==null?void 0:i.type)?t.push(new E({id:`${n.id}--${h.BuiltInEntityParent}`,message:`Entity of type "${n.type}" with id "${n.id}" cannot have the parent with id "${i.id}", because it is a built in entity. Built in entities cannot be modified.`,severity:T.Error,code:h.BuiltInEntityParent,issue:null})):i.type===r.ActionDescriptor&&e.get(n.parent)&&t.push(new E({id:`${n.id}--${h.BuiltInEntityParent}`,message:`Entity of type "${n.type}" with id "${n.id}" cannot have the parent with id "${i.id}", because it is a built in entity. Built in entities cannot be modified. Action descriptors are only sometimes built in, other times they are managed by the user.`,severity:T.Error,code:h.BuiltInEntityParent,issue:null})),t):[]}function Ad(n,e,t){const i=[],a=n[e.key];if(!a)return i.push(new E({id:`${n.id}--${e.key}--${D.InvalidObjectStructure}`,message:`Entity of type "${n.type}" with id "${n.id}" is missing a reference to a "${e.key}" entity. The '${e.key}' property of a "${n.type}" entity can be ${L(e.types,", "," or ")}.`,severity:T.Error,code:D.InvalidObjectStructure,issue:null})),{entityState:null,errors:i};let s=null;if(typeof a=="string")s=a;else{const l=uo(a);i.push(...l),l.length===0&&(s=a.entityId)}if(!s)return{entityState:null,errors:i};if(n.id===s)return i.push(new E({id:`${n.id}--${s}--${h.SelfReference}`,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to itself at '${e.key}'. This is not allowed. Change the reference string or the 'entityId' property of the reference object.`,severity:T.Error,code:h.SelfReference,issue:null})),{entityState:null,errors:i};const o=t.get(s)||t.getBuiltIn(s);return o?e.types.includes(o.type)||i.push(new E({id:`${n.id}--${s}--${h.InvalidReference}`,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to "${s}" at '${e.key}' that isn't pointing to an entity of type '${L(e.types,"', '","' or '")}'.`,severity:T.Error,code:h.InvalidReference,issue:null})):i.push(new E({id:`${n.id}--${s}--${h.ReferencedEntityNotFound}`,message:`Entity of type "${n.type}" with id "${n.id}", is referencing an entity with id "${s}" at '${e.key}' that isn't yet found in the project. Perhaps it should be created first. Or perhaps the ID is incorrect.`,severity:T.Error,code:h.ReferencedEntityNotFound,issue:null})),{entityState:o,errors:i}}function po(n,e,t){const i=[],a=n[e];return a?Array.isArray(a)?{entities:a.map(o=>{let l=null;if(typeof o=="string")l=o;else{const y=uo(o);i.push(...y),y.length===0&&(l=o.entityId)}if(!l)return{entityState:null,errors:[new E({id:`${n.id}--${e}--${h.InvalidReference}`,message:`Entity of type "${n.type}" with id "${n.id}", has a missing reference at '${e}'. A reference needs to be a 'id' string of an existing entity in the project.`,severity:T.Error,code:h.InvalidReference,issue:null})]};const p=t.get(l)||t.getBuiltIn(l);return p?{entityState:p,errors:[]}:(i.push(new E({id:`${n.id}--${l}--${h.ReferencedEntityNotFound}`,message:`Entity of type "${n.type}" with id "${n.id}", is referencing an entity with id "${l}" at '${e}' that isn't yet found in the project. Perhaps it should be created first. Or perhaps the ID is incorrect.`,severity:T.Error,code:h.ReferencedEntityNotFound,issue:null})),{entityState:null,errors:i})}),errors:[]}:(i.push(new E({id:`${n.id}--${e}--${D.InvalidObjectStructure}`,message:`Entity of type "${n.type}" with id "${n.id}" has an invalid structure for the "${e}" property. It should be an array of references.`,severity:T.Error,code:D.InvalidObjectStructure,issue:null})),{entities:[],errors:i}):(i.push(new E({id:`${n.id}--${e}--${D.InvalidObjectStructure}`,message:`Entity of type "${n.type}" with id "${n.id}" is missing a list of references to "${e}" entities.`,severity:T.Error,code:D.InvalidObjectStructure,issue:null})),{entities:[],errors:i})}function Sd(n,e,t){const i=[],a=Ad(n,e,t);if(a.errors.length>0)return a.errors;if(a.entityState){const s=a.entityState;e.types.includes(s.type)||i.push(new E({id:`${n.id}--${s.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to "${e.key}" that isn't pointing to an entity of type '${L(e.types,"', '","' or '")}'.`,issue:null})),n.id===s.id&&i.push(new E({id:`${n.id}--${s.id}--${h.SelfReference}`,code:h.SelfReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to itself at '${e.key}'. This is not allowed. Change the reference string or the 'entityId' property of the reference object.`,issue:null}))}return i}function L(n,e,t){if(n.length===1)return n[0];if(n.length===2)return n.join(t);{const i=n.pop();return`${n.join(e)}${t}${i}`}}const jn=`Pass-through callable entities are entities that need to be called by another caller, then they execute some internal logic and when finished, it can call other callable entities with the "calledBySuccess" property or "calledByError" property based on whether their internal execution was successful or an error ocurred respectively.
|
|
195
|
-
All pass-through callable entities are: ${L($e,", "," and ")}.`,Ia=`Entry point entities are the entities which start the execution of a logic chain. They are ${L(Me,", "," and ")}.They aren't explicitly called by any entities. Rather, they can be called implicitly by the system, or as a function-call somewhere else in the case of a function-declaration. `,
|
|
195
|
+
All pass-through callable entities are: ${L($e,", "," and ")}.`,Ia=`Entry point entities are the entities which start the execution of a logic chain. They are ${L(Me,", "," and ")}.They aren't explicitly called by any entities. Rather, they can be called implicitly by the system, or as a function-call somewhere else in the case of a function-declaration. `,Sv=`Caller entities are entities that can call other entities. Regarless of whether they are entry-point entities or pass-through callable entities. All caller entity types are: ${L(ln,", "," and ")}.`,I3=`Callable entities are entities that can be called by other entities. They can be called by an entry-point, a success caller, or an error caller.
|
|
196
196
|
All callable entity types are: ${L(Pn,", "," and ")}.`,qn=`Caller to callee relationships can be updated with the 'add_caller' and 'remove_caller' generation action with the properties: 'callerEntityId', a 'calleeEntityId'. For adding a caller, you can optionally add a boolean property 'fromError' (if the caller calls when an error occured in its execution).
|
|
197
197
|
Either of these two actions will only affect the one relationship between the given caller and callee and ignore any others present in either entity.`,Od=`Break and continue statements need to have exactly one 'return-declaration' entity each. It represents the result of the current iteration of the loop. It can have any name and have any 'data-type' but it needs to be identical among all statements in the same loop.
|
|
198
198
|
Meaning, if the return declaration in one 'break-statement' is named 'result' and has a 'data-type' of 'number', all other 'break-statements' and 'continue-statements' in the same loop need to have a 'return-declaration' with the same name and 'data-type'.`,D3=`Return statements need to be identical inside the same scope. For example if a 'return-statement' belongs to a function, with multiple branches of logic, leading to multiple 'return-statement' entities, all of them need to have the exact same amount of 'return-declaration' entities, sharing the same name and an equivalent 'data-type' entity.
|
|
199
199
|
Furthermore, some 'function-declarations' and all 'global-events' might be implementing a base 'action-descriptor' entity, which defines exactly the shape and number of the return declarations.`,Cd=`A variable without a data type which reads an-untyped object value, or has object properties written into it as input-map writes, will infere its data-type. This means that a 'data-type' will be created, with an implicitly declared 'custom-entity' as its 'entity' property, defining the structure of the object.
|
|
200
|
-
This data type entity is what will define which properties are available to be read from the variable or any of its instances as 'output-map' entities.`,Jn=`Entities of type '${r.BuiltInBaseEntity}' that have the 'interactive' property set to false cannot be used programmatically during runtime. They can't be used as data types or instanciated in variables. Their methods can't be called by the code, and are only called by the system in the background. Their properties' values are constant and set only once when declared. They also can't be extended with unrecognized properties or methods that aren't part of the base out-of-the-box entity.`,Bd=`Entities that read values from other entities, can be connected with entities that write values to them. Value reading entity types are: '${L(zn,"', '","' and '")}'.`,
|
|
200
|
+
This data type entity is what will define which properties are available to be read from the variable or any of its instances as 'output-map' entities.`,Jn=`Entities of type '${r.BuiltInBaseEntity}' that have the 'interactive' property set to false cannot be used programmatically during runtime. They can't be used as data types or instanciated in variables. Their methods can't be called by the code, and are only called by the system in the background. Their properties' values are constant and set only once when declared. They also can't be extended with unrecognized properties or methods that aren't part of the base out-of-the-box entity.`,Bd=`Entities that read values from other entities, can be connected with entities that write values to them. Value reading entity types are: '${L(zn,"', '","' and '")}'.`,Ov=`Entities that write values to other entities, can be connected with entities that read values from them. Value writing entity types are: '${L(Ve,"', '","' and '")}'.`,wd=`A property entity, is neither a value reading, or a value writting entity, but they are often confused with one.
|
|
201
201
|
A 'property' can have a default value through its nested 'data-type' entity.
|
|
202
202
|
The 'property' entity only represents the data field in the declaration, and it can't write or read values.
|
|
203
203
|
When a 'custom-entity' is instantiated as a variable, any writes or reads to its properties are done through 'input-map's and 'output-map's.`,yo=`Some entities can hold values during runtime, they often can be given a hardcoded "default value" either directly or on their declarations, and can be connected to other entities that write or read values to and from them. Entities that can hold values are: '${L(Yd,"', '","' and '")}'.
|
|
204
204
|
Some entities with values can both write and read values, while others can only do one of the two.
|
|
205
205
|
${Bd}
|
|
206
|
-
${
|
|
206
|
+
${Ov}.
|
|
207
207
|
${wd}`,_d=`To establish a connection of a reader and writter value during the generation process you can use the 'connect_values' generation action, like so:
|
|
208
208
|
\`\`\`json
|
|
209
209
|
{
|
|
@@ -223,7 +223,7 @@ ${typeof n=="string"?n:JSON.stringify(n,null,2)}
|
|
|
223
223
|
...All the properties you want to update
|
|
224
224
|
}
|
|
225
225
|
}
|
|
226
|
-
}`;return an(i)}default:return""}}function
|
|
226
|
+
}`;return an(i)}default:return""}}function Cv(n,e){const t=JSON.parse(JSON.stringify(n)),i=[];if(Me.includes(e.type))i.push(new E({id:`${n.id}--${e.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Warning,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to an entry-point entity at 'calledBySuccess' with id "${e.id}".
|
|
227
227
|
Entry-point entities can only be referenced as 'calledByEntry'.
|
|
228
228
|
${Ia}
|
|
229
229
|
We have moved the reference to 'calledByEntry' for you.`,issue:null})),t.calledByEntry.push(e.id),t.calledBySuccess=t.calledBySuccess.filter(a=>a!==e.id);else if(Ne.includes(e.type)){const a=e.calledBy||[],s=a.length?`
|
|
@@ -234,7 +234,7 @@ Termination entities are ${L(Ne,", "," and ")}.${s}`,issue:null}))}else if(!$e.i
|
|
|
234
234
|
${jn}`,issue:null}));else if(!ln.includes(e.type))return i.push(new E({id:`${n.id}--${e.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to a caller entity at 'calledBySuccess' with id "${e.id}" that isn't a caller entity.
|
|
235
235
|
All caller entity types are: ${L(ln,", "," and ")}.
|
|
236
236
|
For the 'calledBySuccess' property, you specifically need to reference a pass-through callable entity.
|
|
237
|
-
${jn}`,issue:null})),{errors:i,modifiedData:t};return{errors:i,modifiedData:t}}function
|
|
237
|
+
${jn}`,issue:null})),{errors:i,modifiedData:t};return{errors:i,modifiedData:t}}function Bv(n,e){const t=[];if(Me.includes(e.type))t.push(new E({id:`${n.id}--${e.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to an entry-point entity at 'calledByError' with id "${e.id}".
|
|
238
238
|
Entry-point entities can only be referenced as 'calledByEntry'.
|
|
239
239
|
${Ia}`,issue:null}));else if(Ne.includes(e.type)){const i=e.calledBy||[],a=i.length?`
|
|
240
240
|
|
|
@@ -244,7 +244,7 @@ Termination entities are ${L(Ne,", "," and ")}.${a}`,issue:null}))}else if(!$e.i
|
|
|
244
244
|
${jn}`,issue:null}));else if(!ln.includes(e.type))return t.push(new E({id:`${n.id}--${e.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to a caller entity at 'calledByError' with id "${e.id}" that isn't a caller entity.
|
|
245
245
|
All caller entity types are: ${L(ln,", "," and ")}.
|
|
246
246
|
For the 'calledByError' property, you specifically need to reference a pass-through callable entity.
|
|
247
|
-
${jn}`,issue:null})),t;return t}function
|
|
247
|
+
${jn}`,issue:null})),t;return t}function wv(n,e){const t=[];if(Ne.includes(e.type)){const i=e.calledBy||[],a=i.length?`
|
|
248
248
|
|
|
249
249
|
This ${e.type} is called by ${L(i.map(s=>`${s.type} with id "${s.id}"`),", "," and ")} entities. You can reference ${i.length>1?"one of them":"it"} instead to execute this entity before the end of the logic.`:"";t.push(new E({id:`${n.id}--${e.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to a '${e.type}' entity at 'calledByEntry' with id "${e.id}".
|
|
250
250
|
${e.type} entities are the last entity to be executed in a logic chain, and they don't call any other entities.
|
|
@@ -255,18 +255,18 @@ ${Ia}.
|
|
|
255
255
|
We have moved the reference to 'calledBySuccess' for you.`,issue:null}));else if(!ln.includes(e.type))return t.push(new E({id:`${n.id}--${e.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to a caller entity at 'calledByEntry' with id "${e.id}" that isn't a caller entity.
|
|
256
256
|
All caller entity types are: ${L(ln,", "," and ")}.
|
|
257
257
|
For the 'calledByEntry' property, you specifically need to reference a pass-through callable entity.
|
|
258
|
-
${jn}`,issue:null})),t;return t}function
|
|
258
|
+
${jn}`,issue:null})),t;return t}function _v(n,e){const t=[];let i=JSON.parse(JSON.stringify(n));if(Pn.includes(i.type)){if(i.calledBySuccess){const s=po(i,"calledBySuccess",e);s.errors.length===0?s.entities.forEach(o=>{if(o.errors.length){t.push(...o.errors);return}const l=Cv(i,o.entityState);i=l.modifiedData,t.push(...l.errors)}):t.push(...s.errors)}if(i.calledByError){const s=po(i,"calledByError",e);s.errors.length===0?s.entities.forEach(o=>{if(o.errors.length){t.push(...o.errors);return}const l=Bv(i,o.entityState);t.push(...l)}):t.push(...s.errors)}if(i.calledByEntry){const s=po(i,"calledByEntry",e);s.errors.length===0?(s.entities.forEach(o=>{if(o.errors.length){t.push(...o.errors);return}const l=wv(i,o.entityState);t.push(...l)}),t.push(...t)):t.push(...s.errors)}const a=[...i.calledBySuccess||[],...i.calledByError||[],...i.calledByEntry||[]];if(a.length){const s=[...new Set(a)];a.length!==s.length&&t.push(new E({id:`${i.id}--${h.DuplicateReference}`,code:h.DuplicateReference,severity:T.Warning,message:`Entity of type "${i.type}" with id "${i.id}" has duplicate caller references. Each caller reference should be unique. Duplicate caller reference will be ignored.`,issue:null}));const o=Rt(i,e);i.type===r.ReturnStatement&&o&&!Me.includes(o.type)?t.push(new E({id:`${i.id}--${h.IncompatibleScope}`,code:h.IncompatibleScope,severity:T.Error,message:`Entity of type "${i.type}" with id "${i.id}" has an explicitly set parent, but it isn't a '${L(Me,"', '","' or '")}' entity. A return statement's parent should always be resolved to a function declaration or global event.${ho}`,issue:null})):i.type===r.ContinueStatement&&o&&o.type!==r.Loop?t.push(new E({id:`${i.id}--${h.IncompatibleScope}`,code:h.IncompatibleScope,severity:T.Error,message:`Entity of type "${i.type}" with id "${i.id}" has an explicitly set parent, but it isn't a '${r.Loop}' entity. A continue statement's parent should always be resolved to a loop entity.${ho}`,issue:null})):i.type===r.BreakStatement&&o&&o.type!==r.Loop&&t.push(new E({id:`${i.id}--${h.IncompatibleScope}`,code:h.IncompatibleScope,severity:T.Error,message:`Entity of type "${i.type}" with id "${i.id}" has an explicitly set parent, but it isn't a '${r.Loop}' entity. A break statement's parent should always be resolved to a loop entity.${ho}`,issue:null}));const l=[],p=[];let y=null;if(s.forEach(f=>{const m=e.get(f);if(!m){t.push(new E({id:`${i.id}--${f}--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to a caller entity with id "${f}" that doesn't exist in the project.`,issue:null}));return}const b=Rt(m,e);if(o)Aa(o,b,e)?(Ne.includes(i.type)&&((i.calledBySuccess||[]).find(I=>I===m.id)?(m.successCalls||[]).find(B=>Ne.includes(B.type))&&t.push(new E({id:`${i.id}--${m.id}--${D.UnreachableEntity}`,code:D.UnreachableEntity,severity:T.Error,message:`Entity of type "${i.type}" with id "${i.id}" is being called by an entity of type "${m.type}" with id "${m.id}" that already calls a termination statement.
|
|
259
259
|
The new termination statement is redundant because both entities would be called from the same parent caller branch "successCalls", at the same time.`,issue:null})):(i.calledByError||[]).find(I=>I===m.id)?(m.errorCalls||[]).find(B=>Ne.includes(B.type))&&t.push(new E({id:`${i.id}--${m.id}--${D.UnreachableEntity}`,code:D.UnreachableEntity,severity:T.Error,message:`Entity of type "${i.type}" with id "${i.id}" is being called by an entity of type "${m.type}" with id "${m.id}" that already calls a termination statement.
|
|
260
260
|
The new termination statement is redundant because both entities would be called from the same parent caller branch "errorCalls", at the same time.`,issue:null})):(i.calledByEntry||[]).find(I=>I===m.id)&&(m.calls||[]).find(B=>Ne.includes(B.type))&&t.push(new E({id:`${i.id}--${m.id}--${D.UnreachableEntity}`,code:D.UnreachableEntity,severity:T.Error,message:`Entity of type "${i.type}" with id "${i.id}" is being called by an entity of type "${m.type}" with id "${m.id}" that already calls a termination statement.
|
|
261
261
|
The new termination statement is redundant because both entities would be called from the same parent caller branch (entry-point), at the same time.`,issue:null}))),l.push({caller:m,scope:b})):p.push({caller:m,scope:b,errors:[new E({id:`${i.id}--${m.id}--${h.CallerWithIncompatibleScope}`,code:h.CallerWithIncompatibleScope,severity:T.Warning,message:`Entity of type "${i.type}" with id "${i.id}" is being called by an entity of type "${m.type}" with id "${m.id}" that is in a different scope. The caller entity should be in the same scope or a higher valid scope. Or all callers should share the global project scope with the entity they call.`,issue:null})]});else if(!y)y=b;else{const{compatible:g}=Aa(y,b,e);g?(Ne.includes(i.type)&&((i.calledBySuccess||[]).find(I=>I===m.id)?(m.successCalls||[]).find(B=>Ne.includes(B.type))&&t.push(new E({id:`${i.id}--${m.id}--${D.UnreachableEntity}`,code:D.UnreachableEntity,severity:T.Error,message:`Entity of type "${i.type}" with id "${i.id}" is being called by an entity of type "${m.type}" with id "${m.id}" that already calls a termination statement.
|
|
262
262
|
The new termination statement is redundant because both entities would be called from the same parent caller branch "successCalls", at the same time.`,issue:null})):(i.calledByError||[]).find(I=>I===m.id)?(m.errorCalls||[]).find(B=>Ne.includes(B.type))&&t.push(new E({id:`${i.id}--${m.id}--${D.UnreachableEntity}`,code:D.UnreachableEntity,severity:T.Error,message:`Entity of type "${i.type}" with id "${i.id}" is being called by an entity of type "${m.type}" with id "${m.id}" that already calls a termination statement.
|
|
263
263
|
The new termination statement is redundant because both entities would be called from the same parent caller branch "errorCalls", at the same time.`,issue:null})):(i.calledByEntry||[]).find(I=>I===m.id)&&(m.calls||[]).find(B=>Ne.includes(B.type))&&t.push(new E({id:`${i.id}--${m.id}--${D.UnreachableEntity}`,code:D.UnreachableEntity,severity:T.Error,message:`Entity of type "${i.type}" with id "${i.id}" is being called by an entity of type "${m.type}" with id "${m.id}" that already calls a termination statement.
|
|
264
|
-
The new termination statement is redundant because both entities would be called from the same parent caller branch (entry-point), at the same time.`,issue:null}))),l.push({caller:m,scope:b})):p.push({caller:m,scope:b,errors:[new E({id:`${i.id}--${m.id}--${h.CallerWithIncompatibleScope}`,code:h.CallerWithIncompatibleScope,severity:T.Warning,message:`Entity of type "${i.type}" with id "${i.id}" has multiple caller, but not all of them have compatible scopes. Caller of type "${m.type}" with id "${m.id}" is in a different scope than caller of type "${y.type}" with id "${y.id}". All callers should be in the same scope or a higher valid scope. Or all callers should share the global project scope.`,issue:null})]})}}),p.length)p.forEach(f=>{t.push(...f.errors)});else if(l.length&&!o&&Co.includes(i.type)){const f=l.filter(m=>m.scope!==e);if(f.length){const m=
|
|
264
|
+
The new termination statement is redundant because both entities would be called from the same parent caller branch (entry-point), at the same time.`,issue:null}))),l.push({caller:m,scope:b})):p.push({caller:m,scope:b,errors:[new E({id:`${i.id}--${m.id}--${h.CallerWithIncompatibleScope}`,code:h.CallerWithIncompatibleScope,severity:T.Warning,message:`Entity of type "${i.type}" with id "${i.id}" has multiple caller, but not all of them have compatible scopes. Caller of type "${m.type}" with id "${m.id}" is in a different scope than caller of type "${y.type}" with id "${y.id}". All callers should be in the same scope or a higher valid scope. Or all callers should share the global project scope.`,issue:null})]})}}),p.length)p.forEach(f=>{t.push(...f.errors)});else if(l.length&&!o&&Co.includes(i.type)){const f=l.filter(m=>m.scope!==e);if(f.length){const m=cI(f.map(b=>b.scope));i.parent=m.id}else i.parent=e.id}}else{let s=`Entity of type "${i.type}" with id "${i.id}" isn't called by any other entity. Callable entities only get executed if they have a list of references from either 'calledByEntry', 'calledBySuccess' or 'calledByError'.
|
|
265
265
|
To add a caller, use the 'add_caller' action with the properties: 'callerEntityId', a 'calleeEntityId', and optionally a boolean 'fromError' (if the caller calls when an error occured in its execution).`;i.type===r.ReturnStatement?s+=`
|
|
266
266
|
Return statements need to have a caller when created, since their purpose is to terminate a call chain.`:i.type===r.ContinueStatement?s+=`
|
|
267
267
|
Continue statements need to have a caller when created, since they are used to skip the rest of the current iteration of a loop and can't be detached from a call chain.`:i.type===r.BreakStatement&&(s+=`
|
|
268
268
|
Break statements need to have a caller when created, since they are used to exit a loop and can't be detached from a call chain.`),s+=`
|
|
269
|
-
${
|
|
269
|
+
${Sv}`,Ne.includes(i.type)||(s+=`
|
|
270
270
|
It is recommended to have a caller reference already at the moment of creation in the payload of the generation action.`),t.push(new E({id:`${i.id}--${D.MissingCaller}`,code:D.MissingCaller,severity:Ne.includes(i.type)?T.Error:T.Warning,message:s,issue:null}))}}return{errors:t,modifiedData:i}}function Md(n,e){const t=[];if(e.type===r.PrimitiveValue){const o=e.parent;let l=!1;if(o.type===r.InputMap)t.push(new E({id:`${n.id}--${e.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to a value writting entity at 'readsValue' with id "${e.id}" that is a primitive value entity. Primitive value entities aren't value writting entities.
|
|
271
271
|
All value writting entity types are: ${L(Ve,", "," and ")}.
|
|
272
272
|
|
|
@@ -289,7 +289,7 @@ ${wd}`,issue:null})):a.push(new E({id:`${o.id}--${h.InvalidReference}`,code:h.In
|
|
|
289
289
|
${Bd}`,issue:null})),delete s.readsValue);o.writesValues&&(Ve.includes(o.type)?a.push(new E({id:`${o.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Warning,message:`Entity of type "${o.type}" with id "${o.id}" has a 'writesValues' property. This property is managed by the downstream entity, the value reader, and should not be present in the payload of the generation action.
|
|
290
290
|
${_d}`,issue:null})):a.push(new E({id:`${o.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Warning,message:`Entity of type "${o.type}" with id "${o.id}" has a 'writesValues' property. This property is managed by the downstream entity, the value reader, and should not be present in the payload of the generation action.
|
|
291
291
|
${yo}
|
|
292
|
-
${_d}`,issue:null})),delete s.writesValues);const p=
|
|
292
|
+
${_d}`,issue:null})),delete s.writesValues);const p=_v(o,t);delete s.calledByError,delete s.calledBySuccess,delete s.calledByEntry,a.push(...p.errors),o=p.modifiedData}const l=Object.entries(s);for(const[p,y]of l){const f=y.types,m=y.optional,b=o[p];if(!b){m||a.push(new E({id:`${o.id}--${p}--${D.InvalidObjectStructure}`,code:D.InvalidObjectStructure,severity:T.Error,message:`Entity of type "${o.type}" with id "${o.id}" is missing a reference to a "${p}" entity. The '${p}' property of a "${o.type}" entity can be ${L(f,", "," or ")}`,issue:null}));continue}if(y.list)if(Array.isArray(b))for(const g of b){const I=Sd(o,{key:p,types:f,optional:m},t);a.push(...I)}else{a.push(new E({id:`${o.id}--${p}--${h.ContainsSingleButShouldBeReferenceList}`,code:h.ContainsSingleButShouldBeReferenceList,severity:T.Error,message:`Entity of type "${o.type}" with id "${o.id}", should have a property "${p}" which is a list, but it isn't.`,issue:null}));continue}else if(Array.isArray(b)){a.push(new E({id:`${o.id}--${p}--${h.ContainsListButShouldReferenceSingle}`,code:h.ContainsListButShouldReferenceSingle,severity:T.Error,message:`Entity of type "${o.type}" with id "${o.id}", should have a property "${p}" which holds a single reference, but it is a list.`,issue:null}));continue}else{const g=Sd(o,{key:p,types:f,optional:m},t);a.push(...g)}}return{errors:a,modifiedData:o}}function A3(n,e,t="calledBy"){const i=[];if(!n)return[];const a=e.get(n);if(!a)return i.push(new E({id:`${n}--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`Entity with id "${n}" referenced in '${t}' property not found in the project. Perhaps it should be created first? Perhaps it is the wrong ID?`,issue:null})),i;if([...$e,...Me].includes(a.type))return[];if(Ne.includes(a.type)){const s=a.calledBy||[],o=s.length?`
|
|
293
293
|
|
|
294
294
|
This ${a.type} is called by ${L(s.map(l=>`${l.type} with id "${l.id}"`),", "," and ")} entities. You can reference ${s.length>1?"one of them":"it"} instead to execute this entity before the end of the logic.`:"";i.push(new E({id:`last-action--${a.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Error,message:`Entity with id '${a.id}' referenced in '${t}' property is of type '${a.type}'.
|
|
295
295
|
${a.type} entities are the last entity to be executed in a logic chain, and they don't call any other entities.
|
|
@@ -313,7 +313,7 @@ All value writting entity types are: ${L(Ve,", "," and ")}.
|
|
|
313
313
|
|
|
314
314
|
This data type entity belongs to a ${s.type} entity with id "${s.id}". ${s.type} entities are value writting entities. Is that what you meant to reference?`,issue:null})):t.push(new E({id:`last-action--${i.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Error,message:`The 'readsValue' property references an entity with id "${i.id}" that is a primitive value entity. Primitive value entities can't be referenced as value writting entities.
|
|
315
315
|
All value writting entity types are: ${L(Ve,", "," and ")}.`,issue:null}))}else Ve.includes(i.type)||t.push(new E({id:`last-action--${i.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Error,message:`The 'readsValue' property references an entity with id "${i.id}" that isn't a value writting entity.
|
|
316
|
-
All value writting entity types are: ${L(Ve,", "," and ")}.`,issue:null}));return t}function
|
|
316
|
+
All value writting entity types are: ${L(Ve,", "," and ")}.`,issue:null}));return t}function Mv(n){return n.functions.length?`All global 'function-declaration' entity ids are:
|
|
317
317
|
- ${n.functions.map(t=>`${t.id} (${S(t,n)})`).join(`
|
|
318
318
|
- `)}.`:"The project currently has no global 'function-declaration' entities that can be called as 'function-call' entities."}function fo(n){return`All reserved action decriptor ids for '${r.GlobalEvent}' entities are:
|
|
319
319
|
- ${n.globalEventActionDescriptors.map(e=>`${e.id} (${S(e,n)})`).join(`
|
|
@@ -323,7 +323,7 @@ All value writting entity types are: ${L(Ve,", "," and ")}.`,issue:null}));retur
|
|
|
323
323
|
- ${n.operationDeclarations.map(e=>`${e.id} (${S(e,n)})`).join(`
|
|
324
324
|
- `)}`}function To(n){return`All reserved action decriptor ids for '${r.Condition}' entities are:
|
|
325
325
|
- ${n.conditionDeclarations.map(e=>`${e.id} (${S(e,n)})`).join(`
|
|
326
|
-
- `)}`}function
|
|
326
|
+
- `)}`}function Nv(n,e){const t=[];if(!n)return[];const i=e.get(n),a=Mv(e);if(!i)t.push(new E({id:`last-action--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`The entity with id '${n}' that isn't yet found in the project. Perhaps it should be created first. Or perhaps the ID is incorrect.`,issue:null}));else if(i.type===r.ActionDescriptor)t.push(new E({id:`last-action--${h.InvalidFunctionDeclarationForFunctionCall}`,code:h.InvalidFunctionDeclarationForFunctionCall,severity:T.Error,message:`The 'functionDeclarationId' reference is pointing to entity with id '${n}' which is of type '${i.type}' entity. If you meant to reference an 'action-descriptor', you can use the 'implement_operation' generation action instead.
|
|
327
327
|
Otherwise, if you were trying to implement a 'function-call' from a globally declarated 'function-declaration':
|
|
328
328
|
${a}`,issue:null}));else if(i.type!==r.FunctionDeclaration)t.push(new E({id:`last-action--${h.InvalidFunctionDeclarationForFunctionCall}`,code:h.InvalidFunctionDeclarationForFunctionCall,severity:T.Error,message:`The 'functionDeclarationId' reference is pointing to entity with id '${n}' which is of type '${i.type}' entity. Only 'function-declaration' entities can be implemented as function calls.
|
|
329
329
|
${a}`,issue:null}));else if(i.parent.type===r.CustomEntity){const o=Hn(i.parent).filter(p=>!p.interactive);let l="";o.length&&(l=`
|
|
@@ -332,7 +332,7 @@ ${Jn}`),t.push(new E({id:`last-action--${h.InvalidFunctionDeclarationForFunction
|
|
|
332
332
|
If you want to call a method of a custom entity, use a '${r.InternalCall}' entity on any variable which is an instance of that custom entity.
|
|
333
333
|
${a}${l}`,issue:null}))}else i.parent.type===r.Loop?t.push(new E({id:`last-action--${h.InvalidFunctionDeclarationForFunctionCall}`,code:h.InvalidFunctionDeclarationForFunctionCall,severity:T.Error,message:`The function declaration entity with id '${n}' is the body of the 'loop' with id '${i.parent.id}'. Only globally declared, standalone functions can be implemented as function calls.
|
|
334
334
|
If you want to execute the logic of a loop's body you can call the loop entity itself anf the body will be executed once for each iteration.
|
|
335
|
-
${a}`,issue:null})):i.parent.type!==r.Project&&t.push(new E({id:`last-action--${h.InvalidFunctionDeclarationForFunctionCall}`,code:h.InvalidFunctionDeclarationForFunctionCall,severity:T.Error,message:`The function declaration entity with id '${n}' has a 'parent' entity which isn't the root project. Only globally declared, standalone functions can be implemented as function calls.${a}`,issue:null}));return t}function
|
|
335
|
+
${a}`,issue:null})):i.parent.type!==r.Project&&t.push(new E({id:`last-action--${h.InvalidFunctionDeclarationForFunctionCall}`,code:h.InvalidFunctionDeclarationForFunctionCall,severity:T.Error,message:`The function declaration entity with id '${n}' has a 'parent' entity which isn't the root project. Only globally declared, standalone functions can be implemented as function calls.${a}`,issue:null}));return t}function Vv(n,e){const t=[];if(!n)return[];const i=e.getBuiltIn(n),a=`
|
|
336
336
|
All built-in 'action-descriptor' entities that define 'operation' entity, are (IDs):
|
|
337
337
|
- ${e.operationDeclarations.map(s=>`${s.id} (${S(s,e)}).`).join(`
|
|
338
338
|
- `)}
|
|
@@ -343,7 +343,7 @@ All built-in 'action-descriptor' entities that define 'condition' entity, are (I
|
|
|
343
343
|
`;return i?i.type===r.FunctionDeclaration?t.push(new E({id:`last-action--${h.InvalidActionDescriptorForCondition}`,code:h.InvalidActionDescriptorForCondition,severity:T.Error,message:`The entity with id '${n}' is of type '${i.type}' entity. Only 'action-descriptor' entities can be implemented as conditions instances.${a}`,issue:null})):i.type===r.ActionDescriptor?e.conditionDeclarations.find(o=>o.id===n)||t.push(new E({id:`last-action--${h.InvalidActionDescriptorForOperation}`,code:h.InvalidActionDescriptorForOperation,severity:T.Error,message:`The entity with id '${n}' is of type '${i.type}' entity but it isn't one of the allowed condition descriptors.${a}`,issue:null})):i.type!==r.ActionDescriptor&&t.push(new E({id:`last-action--${h.InvalidActionDescriptorForCondition}`,code:h.InvalidActionDescriptorForCondition,severity:T.Error,message:`The entity with id '${n}' is of type '${i.type}' entity. Only 'action-descriptor' entities can be implemented as conditions instances.${a}`,issue:null})):t.push(new E({id:`last-action--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`The entity with id '${n}' that isn't yet found in the project.${a}`,issue:null})),t}function w3(n,e){const t=[];if(!n)return[];const i=e.getBuiltIn(n),a=`
|
|
344
344
|
All built-in 'action-descriptor' entities that define 'loop' entity, are (IDs):
|
|
345
345
|
- ${e.loopDeclarations.map(s=>`${s.id} (${S(s,e)}).`).join(`
|
|
346
|
-
- `)}`;return i?i.type===r.FunctionDeclaration?t.push(new E({id:`last-action--${h.InvalidActionDescriptorForLoop}`,code:h.InvalidActionDescriptorForLoop,severity:T.Error,message:`The entity with id '${n}' is of type '${i.type}' entity. Only 'action-descriptor' entities can be implemented as loops instances.${a}`,issue:null})):i.type===r.ActionDescriptor?e.loopDeclarations.find(o=>o.id===n)||t.push(new E({id:`last-action--${h.InvalidActionDescriptorForOperation}`,code:h.InvalidActionDescriptorForOperation,severity:T.Error,message:`The entity with id '${n}' is of type '${i.type}' entity but it isn't one of the allowed loop descriptors.${a}`,issue:null})):i.type!==r.ActionDescriptor&&t.push(new E({id:`last-action--${h.InvalidActionDescriptorForLoop}`,code:h.InvalidActionDescriptorForLoop,severity:T.Error,message:`The entity with id '${n}' is of type '${i.type}' entity. Only 'action-descriptor' entities can be implemented as loops instances.${a}`,issue:null})):t.push(new E({id:`last-action--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`The entity with id '${n}' that isn't yet found in the project.${a}`,issue:null})),t}function
|
|
346
|
+
- `)}`;return i?i.type===r.FunctionDeclaration?t.push(new E({id:`last-action--${h.InvalidActionDescriptorForLoop}`,code:h.InvalidActionDescriptorForLoop,severity:T.Error,message:`The entity with id '${n}' is of type '${i.type}' entity. Only 'action-descriptor' entities can be implemented as loops instances.${a}`,issue:null})):i.type===r.ActionDescriptor?e.loopDeclarations.find(o=>o.id===n)||t.push(new E({id:`last-action--${h.InvalidActionDescriptorForOperation}`,code:h.InvalidActionDescriptorForOperation,severity:T.Error,message:`The entity with id '${n}' is of type '${i.type}' entity but it isn't one of the allowed loop descriptors.${a}`,issue:null})):i.type!==r.ActionDescriptor&&t.push(new E({id:`last-action--${h.InvalidActionDescriptorForLoop}`,code:h.InvalidActionDescriptorForLoop,severity:T.Error,message:`The entity with id '${n}' is of type '${i.type}' entity. Only 'action-descriptor' entities can be implemented as loops instances.${a}`,issue:null})):t.push(new E({id:`last-action--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`The entity with id '${n}' that isn't yet found in the project.${a}`,issue:null})),t}function $v(n,e,t){var p,y,f,m;if(t.compatible)return"";const i=`entity of type "${n.type}" with id "${n.id}"`,a=`entity with id "${n.id}"`,s=`entity of type "${e.type}" with id "${e.id}"`,o=`entity with id "${e.id}"`,l=io(`${i} and ${s} have incompatible data types and cannot be connected as value-reader and value-writter.`);return t.type===Lt.AIsListBIsNot?`${l}
|
|
347
347
|
${a} is a list, but ${o} is not. A list can't be connected to a single value.`:t.type===Lt.BIsListAIsNot?`${l}
|
|
348
348
|
${a} is not a list, but ${o} is. A single value can't be connected to a list.`:t.type===Lt.AIsNullableBIsNot?`${l}
|
|
349
349
|
${a} is nullable, but ${o} is not. A nullable value can't be connected to a non-nullable value since an empty value might be incorrectly provided.`:t.type===Lt.BIsNullableAIsNot?`${l}
|
|
@@ -353,21 +353,21 @@ ${a} is not a template, but ${o} is. A data type that provides an entity as a "t
|
|
|
353
353
|
Their 'entity' property is of different types. They must be of the same type to be connected. For example, the 'entity' can be a '${r.CustomEntity}' or a '${r.PrimitiveEntity}'.`:t.type===Lt.IncompatibleCustomEntities?`${l}
|
|
354
354
|
Both point to custom entities, but they are not compatible to be connected. They must be either the same custom entity, or a custom entity that has equivalent shape, which includes the same properties all with compatible data types with the properties in the counterpart entity.`:t.type===Lt.IncompatiblePrimitiveEntities?`${l}
|
|
355
355
|
${a} is of primitive type '${((p=n.getDataType())==null?void 0:p.entity).name}' and ${o} is of primitive type '${((y=e.getDataType())==null?void 0:y.entity).name}'. They must be of the same primitive type to be connected.`:t.type===Lt.IncompatibleBuiltInBaseEntities?`${l}
|
|
356
|
-
Both point to a built-in-base-entity. But${a} is of built-in base type '${((f=n.getDataType())==null?void 0:f.entity).name}' and ${o} is of built-in base type '${((m=e.getDataType())==null?void 0:m.entity).name}'. They must be of the same built-in base type to be connected.`:l}function Da(n,e){const t=[];if(n.readsValue){const i=e.project.get(C(n.readsValue));if(e.project.getBuiltIn(C(n.readsValue)))t.push(new E({id:`${e.id}--${h.InvalidBuiltInEntityReference}`,code:h.InvalidBuiltInEntityReference,severity:T.Error,message:`The entity of type '${e.type}' with id '${e.id}' cannot update 'readsValue' to a built-in entity with id '${n.readsValue}'. Only user-created entities can be referenced.`,issue:null}));else if(!i)t.push(new E({id:`${e.id}--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`The entity of type '${e.type}' with id '${e.id}' cannot update 'readsValue' to entity with id '${n.readsValue}' because the entity was not found in the project state.`,issue:null}));else{const s=Yn(i);if(s)t.push(new E({id:`${e.id}--${h.InvalidBuiltInEntityReference}`,code:h.InvalidBuiltInEntityReference,severity:T.Error,message:`The entity of type '${e.type}' with id '${e.id}' cannot update 'readsValue' to entity with id '${n.readsValue}' because the entity belongs to a built-in '${s.type}' entity with id '${s.id}' (${S(s,e.project)}) higher up in the tree.`,issue:null}));else{const o=Md({...e.toGenerationTarget(),...n},i);t.push(...o);const l=Ht(e.getDataType(),i.getDataType());l.compatible||t.push(new E({id:`${e.id}--${D.ReaderWriterIncompatibleDataType}`,code:D.ReaderWriterIncompatibleDataType,severity:T.Error,message
|
|
356
|
+
Both point to a built-in-base-entity. But${a} is of built-in base type '${((f=n.getDataType())==null?void 0:f.entity).name}' and ${o} is of built-in base type '${((m=e.getDataType())==null?void 0:m.entity).name}'. They must be of the same built-in base type to be connected.`:l}function Da(n,e){const t=[];if(n.readsValue){const i=e.project.get(C(n.readsValue));if(e.project.getBuiltIn(C(n.readsValue)))t.push(new E({id:`${e.id}--${h.InvalidBuiltInEntityReference}`,code:h.InvalidBuiltInEntityReference,severity:T.Error,message:`The entity of type '${e.type}' with id '${e.id}' cannot update 'readsValue' to a built-in entity with id '${n.readsValue}'. Only user-created entities can be referenced.`,issue:null}));else if(!i)t.push(new E({id:`${e.id}--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`The entity of type '${e.type}' with id '${e.id}' cannot update 'readsValue' to entity with id '${n.readsValue}' because the entity was not found in the project state.`,issue:null}));else{const s=Yn(i);if(s)t.push(new E({id:`${e.id}--${h.InvalidBuiltInEntityReference}`,code:h.InvalidBuiltInEntityReference,severity:T.Error,message:`The entity of type '${e.type}' with id '${e.id}' cannot update 'readsValue' to entity with id '${n.readsValue}' because the entity belongs to a built-in '${s.type}' entity with id '${s.id}' (${S(s,e.project)}) higher up in the tree.`,issue:null}));else{const o=Md({...e.toGenerationTarget(),...n},i);t.push(...o);const l=Ht(e.getDataType(),i.getDataType());l.compatible||t.push(new E({id:`${e.id}--${D.ReaderWriterIncompatibleDataType}`,code:D.ReaderWriterIncompatibleDataType,severity:T.Error,message:$v(e,i,l),issue:null}))}}}return{errors:t,modifiedData:n}}function In(n){const e=[];if(n.parent===n.project)n.calledBy.length||e.push(new cr({id:`${n.id}--${_.DisconnectedCallableEntity}`,code:_.DisconnectedCallableEntity,severity:T.Warning,message:`This '${n.type}' entity "${S(n,n.project)}" with id "${n.id}" is globally declared and isn't called by any other entity.
|
|
357
357
|
Globally declared callable entities will not be part of any logic execution when the project is published.
|
|
358
358
|
To useful to the project when it is published, entities need to be called by a chain of logic that traces itself back to an entry point. Entry points can be either '${r.GlobalEvent}' or '${r.FunctionDeclaration}'.
|
|
359
359
|
The only use for declaring global callable entities is for a 'variable-declaration' entity to be available globally in the project's scope, since its instances can be used inside lower scopes.
|
|
360
360
|
Or for a logic that the user is going to manually test themselves by clicking on the user-interface.`,issue:null,entity:n}));else{const t=Oa(n);if(!t.reachable){let i=`This '${n.type}' entity "${S(n,n.project)}" with id "${n.id}" is not reachable from the project's closest entry point '${t.entryPoint.type}' "${S(t.entryPoint,n.project)}".`;i+=`
|
|
361
361
|
This is because there are termination statements in the call chain before reaching this '${n.type}'.
|
|
362
362
|
If a caller entity calls a termination statement, it will always prevent all other calls from executing.`;let a=`
|
|
363
|
-
This '${n.type}' is blocked `;t.blocks.forEach((s,o)=>{const l=s.blockedByCaller,p=s.blockedByCalling;o===0?a+="by ":o===t.blocks.length-1&&(a+="and by "),a+=`its ancestor "${S(l,n.project)}" with id "${l.id}" that calls a '${p.type}' entity with id "${p.id}"`,o<t.blocks.length-1?a+=", ":a+="."}),e.push(new cr({id:`${n.id}--${D.UnreachableEntity}`,code:D.UnreachableEntity,severity:T.Warning,message:`${i}${a}`,issue:null,entity:n}))}}return ne(n.errors,e)}function Nd(n){const e=[];if(!n.internalCalls.length)return e;if(n.readsValue){const t=H({id:`${n.id}--${_.VariableReadsValueAndInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" reads a value. A variable with internal calls can't read a value.`,issue:null,severity:T.Error,code:_.VariableReadsValueAndInternalCall,entity:n});e.push(t.error)}if(n.writesValues.length){const t=H({id:`${n.id}--${_.VariableWritesValuesAndInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" writes values. A variable with internal calls can't write a value.`,issue:null,severity:T.Error,code:_.VariableWritesValuesAndInternalCall,entity:n});e.push(t.error)}if(n.getUsedInputs().length){const t=H({id:`${n.id}--${_.VariableHasInputsAndInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" has inputs. A variable with internal calls can't have inputs.`,issue:null,severity:T.Error,code:_.VariableHasInputsAndInternalCall,entity:n});e.push(t.error)}if(n.getUsedOutputs().length){const t=H({id:`${n.id}--${_.VariableHasOutputsAndInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" has outputs. A variable with internal calls can't have outputs.`,issue:null,severity:T.Error,code:_.VariableHasOutputsAndInternalCall,entity:n});e.push(t.error)}if(n.calledBy.length){const t=H({id:`${n.id}--${_.VariableIsCalledAndHasInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" is called by other entities. A variable with internal calls can't be called by other entities.`,issue:null,severity:T.Error,code:_.VariableIsCalledAndHasInternalCall,entity:n});e.push(t.error)}if([...n.successCalls,...n.errorCalls].length){const t=H({id:`${n.id}--${_.VariableCallsOthersAndHasInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" calls other entities. A variable with internal calls can't call other entities.`,issue:null,severity:T.Error,code:_.VariableCallsOthersAndHasInternalCall,entity:n});e.push(t.error)}return e}function _3(n){var o;const e=GU(),t=n.toJSON();e.safeParse(t).success,n.inputs.forEach(l=>l.validate()),n.outputs.forEach(l=>l.validate()),(o=n.error)==null||o.validate();const s=[...In(n)];return ne(n.errors,s)}const De=class De{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"x");c(this,"y");c(this,"type",r.FunctionCall);c(this,"successCalls",[]);c(this,"errorCalls",[]);c(this,"process",null);c(this,"declaration");c(this,"inputs",[]);c(this,"outputs",[]);c(this,"calledBySuccess",[]);c(this,"calledByError",[]);c(this,"calledByEntry",[]);c(this,"error",null);c(this,"parent");c(this,"errors",[]);c(this,"project");c(this,"initialized",!1);this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.x=e.x,this.y=e.y}static fromGenerationTarget(e,t){let i=t;if(e.parent){const m=C(e.parent);i=t.get(m)}const a=C(e.declaration),s=t.get(a),o=e.calledByEntry.map(m=>{const b=C(m);return t.get(b)}),l=e.calledBySuccess.map(m=>{const b=C(m);return t.get(b)}),p=e.calledByError.map(m=>{const b=C(m);return t.get(b)}),y={id:e.id,version:1,type:r.FunctionCall,declaration:s.toReference(),calledByEntry:o,calledBySuccess:l,calledByError:p,errorCalls:[],successCalls:[],inputs:[],outputs:[],process:null,error:null,x:0,y:0,parent:i},f=R(y,t);return f.setParent(i),f.initChildren(),f}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[],s=je(i,{parent:{list:!1,types:[...ct,r.Project],optional:!0}},t);i=s.modifiedData,a.push(...s.errors,...Be(i));const o=C(i.declaration);if(o){const l=
|
|
363
|
+
This '${n.type}' is blocked `;t.blocks.forEach((s,o)=>{const l=s.blockedByCaller,p=s.blockedByCalling;o===0?a+="by ":o===t.blocks.length-1&&(a+="and by "),a+=`its ancestor "${S(l,n.project)}" with id "${l.id}" that calls a '${p.type}' entity with id "${p.id}"`,o<t.blocks.length-1?a+=", ":a+="."}),e.push(new cr({id:`${n.id}--${D.UnreachableEntity}`,code:D.UnreachableEntity,severity:T.Warning,message:`${i}${a}`,issue:null,entity:n}))}}return ne(n.errors,e)}function Nd(n){const e=[];if(!n.internalCalls.length)return e;if(n.readsValue){const t=H({id:`${n.id}--${_.VariableReadsValueAndInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" reads a value. A variable with internal calls can't read a value.`,issue:null,severity:T.Error,code:_.VariableReadsValueAndInternalCall,entity:n});e.push(t.error)}if(n.writesValues.length){const t=H({id:`${n.id}--${_.VariableWritesValuesAndInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" writes values. A variable with internal calls can't write a value.`,issue:null,severity:T.Error,code:_.VariableWritesValuesAndInternalCall,entity:n});e.push(t.error)}if(n.getUsedInputs().length){const t=H({id:`${n.id}--${_.VariableHasInputsAndInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" has inputs. A variable with internal calls can't have inputs.`,issue:null,severity:T.Error,code:_.VariableHasInputsAndInternalCall,entity:n});e.push(t.error)}if(n.getUsedOutputs().length){const t=H({id:`${n.id}--${_.VariableHasOutputsAndInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" has outputs. A variable with internal calls can't have outputs.`,issue:null,severity:T.Error,code:_.VariableHasOutputsAndInternalCall,entity:n});e.push(t.error)}if(n.calledBy.length){const t=H({id:`${n.id}--${_.VariableIsCalledAndHasInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" is called by other entities. A variable with internal calls can't be called by other entities.`,issue:null,severity:T.Error,code:_.VariableIsCalledAndHasInternalCall,entity:n});e.push(t.error)}if([...n.successCalls,...n.errorCalls].length){const t=H({id:`${n.id}--${_.VariableCallsOthersAndHasInternalCall}`,message:`Variable "${S(n,n.project)}" with id "${n.id}" calls other entities. A variable with internal calls can't call other entities.`,issue:null,severity:T.Error,code:_.VariableCallsOthersAndHasInternalCall,entity:n});e.push(t.error)}return e}function _3(n){var o;const e=GU(),t=n.toJSON();e.safeParse(t).success,n.inputs.forEach(l=>l.validate()),n.outputs.forEach(l=>l.validate()),(o=n.error)==null||o.validate();const s=[...In(n)];return ne(n.errors,s)}const De=class De{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"x");c(this,"y");c(this,"type",r.FunctionCall);c(this,"successCalls",[]);c(this,"errorCalls",[]);c(this,"process",null);c(this,"declaration");c(this,"inputs",[]);c(this,"outputs",[]);c(this,"calledBySuccess",[]);c(this,"calledByError",[]);c(this,"calledByEntry",[]);c(this,"error",null);c(this,"parent");c(this,"errors",[]);c(this,"project");c(this,"initialized",!1);this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.x=e.x,this.y=e.y}static fromGenerationTarget(e,t){let i=t;if(e.parent){const m=C(e.parent);i=t.get(m)}const a=C(e.declaration),s=t.get(a),o=e.calledByEntry.map(m=>{const b=C(m);return t.get(b)}),l=e.calledBySuccess.map(m=>{const b=C(m);return t.get(b)}),p=e.calledByError.map(m=>{const b=C(m);return t.get(b)}),y={id:e.id,version:1,type:r.FunctionCall,declaration:s.toReference(),calledByEntry:o,calledBySuccess:l,calledByError:p,errorCalls:[],successCalls:[],inputs:[],outputs:[],process:null,error:null,x:0,y:0,parent:i},f=R(y,t);return f.setParent(i),f.initChildren(),f}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[],s=je(i,{parent:{list:!1,types:[...ct,r.Project],optional:!0}},t);i=s.modifiedData,a.push(...s.errors,...Be(i));const o=C(i.declaration);if(o){const l=Nv(o,t);a.push(...l)}else{const l=t.functions.length?`
|
|
364
364
|
All global 'function-declaration' entity ids are:
|
|
365
365
|
- ${t.functions.map(p=>`${p.id} (${S(p,t)})`).join(`
|
|
366
366
|
- `)}.`:`
|
|
367
367
|
The project currently has no global 'function-declaration' entities that can be called as 'function-call' entities.`;a.push(new E({id:`${i.id}--${h.InvalidReference}`,code:h.InvalidReference,severity:T.Error,message:`Entity of type "${r.FunctionCall}" with id "${i.id}", has an invalid reference at the 'declaration' property. The 'declaration' property must be a valid reference to an 'function-declaration' entity.
|
|
368
368
|
References can either be an ID string or an object with exacly four properties: 'id', 'entityId', 'entityType', 'type'.${l}`,issue:null}))}return{errors:a,modifiedData:i}}validateGeneratedUpdate(e){const t=[];return e.parent&&t.push(new E({id:`${this.id}--${h.InvalidParentUpdate}`,code:h.InvalidParentUpdate,severity:T.Error,message:`Entity of type '${this.type}' with id '${this.id}' cannot have the 'parent' property updated. The 'parent' on a callable entity, is its scope. It scope is auto-calculated implicitly by the its caller.
|
|
369
369
|
If an entity is called by another, they must be in the same scope, which means they have the same parent.
|
|
370
|
-
You shouldn't have to manually update a 'parent' property. The equivalent result is to change its callers, the value writters of its inputs, or the value readers of its outputs.`,issue:null})),{errors:t,modifiedData:e}}addSelfToProject(){var t;const e=[this];return this.parent===this.project&&this.project.addFunctionCall(this),(t=this.process)==null||t.writesValues.forEach(i=>{i.setValueWriter(this.process),e.push(i)}),this.successCalls.forEach(i=>{i.addSuccessCaller(this),e.push(i)}),this.errorCalls.forEach(i=>{i.addErrorCaller(this),e.push(i)}),this.calledBySuccess.forEach(i=>{i.addSuccessCall(this),e.push(i)}),this.calledByError.forEach(i=>{i.addErrorCall(this),e.push(i)}),this.calledByEntry.forEach(i=>{i.addCall(this),e.push(i)}),{affected:v(e),self:this}}get calledBy(){return[...this.calledByEntry,...this.calledBySuccess,...this.calledByError]}removeInput(e){const t=this.inputs.findIndex(i=>i.id===e.id);return t>-1&&this.inputs.splice(t,1),this}addInput(e){return this.inputs.includes(e)?this:(this.inputs.push(e),this)}addOutput(e){return this.outputs.includes(e)?this:(this.outputs.push(e),this)}removeOutput(e){const t=this.outputs.findIndex(i=>i.id===e.id);return t>-1&&this.outputs.splice(t,1),this}addValueReader(e){var t;return(t=this.process)==null||t.addValueReader(e),this}removeValueReader(e){var t;return(t=this.process)==null||t.removeValueReader(e),this}addSuccessCaller(e){return this.calledBySuccess.find(t=>t.id===e.id)||this.calledBySuccess.push(e),this}addErrorCaller(e){return this.calledByError.find(t=>t.id===e.id)||this.calledByError.push(e),this}addEntryCaller(e){return this.calledByEntry.find(t=>t.id===e.id)||this.calledByEntry.push(e),this}addErrorCall(e){return this.errorCalls.push(e),this}addSuccessCall(e){return this.successCalls.push(e),this}removeCall(e){const t=this.successCalls.findIndex(a=>a.id===e.id);t>-1&&this.successCalls.splice(t,1);const i=this.errorCalls.findIndex(a=>a.id===e.id);return i>-1&&this.errorCalls.splice(i,1),this}removeCaller(e){return this.calledBySuccess=this.calledBySuccess.filter(t=>t.id!==e.id),this.calledByError=this.calledByError.filter(t=>t.id!==e.id),this.calledByEntry=this.calledByEntry.filter(t=>t.id!==e.id),this}setParent(e){return this.parent=e,this}initChildren(){if(this.initialized)return this;if(this.initialized=!0,this.initialData.declaration.type===r.FunctionDeclaration){const e=R(this.initialData.declaration,this.project);this.declaration=e}else{const e=C(this.initialData.declaration),t=this.project.get(e);this.declaration=t}return this.successCalls=this.initialData.successCalls.map(e=>{const t=R(e,this.project);return t.addSuccessCaller(this),[r.BreakStatement,r.ContinueStatement].includes(t.type)?(t.setParent(this.parent.parent),t.initChildren()):t.type!==r.InternalCall&&(t.setParent(this.parent),t.initChildren()),t}),this.errorCalls=this.initialData.errorCalls.map(e=>{const t=R(e,this.project);return t.addErrorCaller(this),[r.BreakStatement,r.ContinueStatement].includes(t.type)?(t.setParent(this.parent.parent),t.initChildren()):t.type!==r.InternalCall&&(t.setParent(this.parent),t.initChildren()),t}),this.inputs=this.initialData.inputs.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this.initOutputs(),this.initialData.process&&(this.process=R(this.initialData.process,this.project),this.process.setParent(this),this.process.initChildren()),this.initialData.error&&(this.error=R(this.initialData.error,this.project),this.error.setParent(this),this.error.initChildren()),this}initOutputs(){const e=[];this.outputs=this.initialData.outputs.map(s=>{const o=R(s,this.project);return e.push(o.index),o.setParent(this),o.initChildren(),o});const i=Fd(this).filter(s=>!this.outputs.find(o=>o.declaration.id===s.id));i.sort((s,o)=>s.index-o.index);const a=i.map((s,o)=>{const l=e.includes(s.index)?this.outputs.length-1+o:s.index,p={id:w.UUID.uuid(),type:r.OutputMap,version:1,declaration:s,index:l,parent:this,writesValues:[]},y=R(p,this.project);return y.setParent(this),y.initChildren(),y});return this.outputs.push(...a),this}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}sync(e){return this.version=e.version||this.version,this.x=e.x||this.x,this.y=e.y||this.y,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){var s;const i=[],a=[];if(t.has(this.id))return{affected:[],removed:[]};if(t.add(this.id),a.push(this),this.unsubscribe(),this.process){const{affected:o,removed:l}=(s=this.process)==null?void 0:s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}if(this.inputs.forEach(o=>{const{affected:l,removed:p}=o.remove({ignoreUpstream:!0,seenEntities:t});i.push(...l),a.push(...p)}),this.outputs.forEach(o=>{const{affected:l,removed:p}=o.remove({ignoreUpstream:!0,seenEntities:t});i.push(...l),a.push(...p)}),this.error){const{affected:o,removed:l}=this.error.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}return this.successCalls.forEach(o=>{i.push(o),o.removeCaller(this)}),this.errorCalls.forEach(o=>{i.push(o),o.removeCaller(this)}),e||this.calledBy.forEach(o=>{i.push(o),o.removeCall(this)}),{affected:v(i),removed:v(a)}}restore({seenEntities:e}={seenEntities:new Set}){const t=[];if(e.has(this.id))return{affected:[],self:this};if(e.add(this.id),this.subscribe(),this.process){const{affected:i}=this.process.restore({seenEntities:e});t.push(...i)}return this.inputs.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.outputs.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.successCalls.forEach(i=>{t.push(i),i.addSuccessCaller(this)}),this.errorCalls.forEach(i=>{t.push(i),i.addErrorCaller(this)}),this.calledBySuccess.forEach(i=>{t.push(i),i.addSuccessCall(this)}),this.calledByError.forEach(i=>{t.push(i),i.addErrorCall(this)}),this.calledByEntry.forEach(i=>{t.push(i),i.addCall(this)}),{affected:v(t),self:this}}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.successCalls.flatMap(i=>i.toFlat(e)),...this.errorCalls.flatMap(i=>i.toFlat(e)),...this.inputs.flatMap(i=>i.toFlat(e)),...this.outputs.flatMap(i=>i.toFlat(e)),...this.process?this.process.toFlat(e):[],...this.error?this.error.toFlat(e):[]])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.successCalls.flatMap(i=>i.toFlatIds(e)),...this.errorCalls.flatMap(i=>i.toFlatIds(e)),...this.inputs.flatMap(i=>i.toFlatIds(e)),...this.outputs.flatMap(i=>i.toFlatIds(e))])}toJSON(){var e,t;return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,successCalls:this.successCalls.map(i=>i.toJSON()),errorCalls:this.errorCalls.map(i=>i.toJSON()),calledBySuccess:this.calledBySuccess.map(i=>i.toReference()),calledByError:this.calledByError.map(i=>i.toReference()),calledByEntry:this.calledByEntry.map(i=>i.toReference()),process:(e=this.process)==null?void 0:e.toJSON(),declaration:this.declaration.toJSON(),inputs:this.inputs.map(i=>i.toJSON()),outputs:this.outputs.map(i=>i.toJSON()),parent:this.parent.toReference(),error:(t=this.error)==null?void 0:t.toJSON()}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,process:this.process?this.process.toReference():null,inputs:this.inputs.map(e=>e.toReference()),outputs:this.outputs.map(e=>e.toReference()),declaration:this.declaration.toReference(),successCalls:this.successCalls.map(e=>e.toReference()),errorCalls:this.errorCalls.map(e=>e.toReference()),calledBySuccess:this.calledBySuccess.map(e=>e.toReference()),calledByError:this.calledByError.map(e=>e.toReference()),calledByEntry:this.calledByEntry.map(e=>e.toReference()),error:this.error?this.error.toReference():null,parent:this.parent.toReference()}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.successCalls.flatMap(i=>i.toFlatJSON(e)),...this.errorCalls.flatMap(i=>i.toFlatJSON(e)),...this.inputs.flatMap(i=>i.toFlatJSON(e)),...this.outputs.flatMap(i=>i.toFlatJSON(e)),...this.process?this.process.toFlatJSON(e):[],...this.error?this.error.toFlatJSON(e):[]])}toGenerationTarget(){const e=this.parent.type===r.Project?void 0:this.parent.id;return{id:this.id,version:this.version,type:this.type,calledByEntry:this.calledByEntry.map(t=>t.id),calledBySuccess:this.calledBySuccess.map(t=>t.id),calledByError:this.calledByError.map(t=>t.id),declaration:this.declaration.id,parent:e}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.successCalls.flatMap(i=>i.toFlatGenerationTarget(e)),...this.errorCalls.flatMap(i=>i.toFlatGenerationTarget(e)),...this.inputs.flatMap(i=>i.toFlatGenerationTarget(e)),...this.outputs.flatMap(i=>i.toFlatGenerationTarget(e)),...this.process?this.process.toFlatGenerationTarget(e):[],...this.error?this.error.toFlatGenerationTarget(e):[]])}clearErrors(){var e,t;return this.errors=[],this.inputs.forEach(i=>i.clearErrors()),this.outputs.forEach(i=>i.clearErrors()),this.successCalls.forEach(i=>i.clearErrors()),this.errorCalls.forEach(i=>i.clearErrors()),(e=this.process)==null||e.clearErrors(),(t=this.error)==null||t.clearErrors(),this}validate(){const e=_3(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors,...this.inputs.flatMap(t=>t.getErrors()),...this.outputs.flatMap(t=>t.getErrors()),...this.error?this.error.getErrors():[],...this.process?this.process.getErrors():[]]}getShallowErrors(){return this.errors}clone(e){return new De(this.toJSON(),this.project)}};c(De,"MUTABLE_BASE_PROPERTIES",[]),c(De,"INMUTABLE_BASE_PROPERTIES",["id","version","type"]),c(De,"BASE_PROPERTIES",[...De.MUTABLE_BASE_PROPERTIES,...De.INMUTABLE_BASE_PROPERTIES]),c(De,"MUTABLE_META_PROPERTIES",["x","y"]),c(De,"INMUTABLE_META_PROPERTIES",[...De.INMUTABLE_BASE_PROPERTIES]),c(De,"META_PROPERTIES",[...De.MUTABLE_META_PROPERTIES,...De.INMUTABLE_META_PROPERTIES]),c(De,"MUTABLE_UPSTREAM_PROPERTIES",["calledBySuccess","calledByError","calledByEntry"]),c(De,"INMUTABLE_UPSTREAM_PROPERTIES",["declaration","parent"]),c(De,"UPSTREAM_PROPERTIES",[...De.MUTABLE_UPSTREAM_PROPERTIES,...De.INMUTABLE_UPSTREAM_PROPERTIES]),c(De,"MUTABLE_DOWNSTREAM_PROPERTIES",["successCalls","errorCalls","writesValues","inputs","outputs","error"]),c(De,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(De,"DOWNSTREAM_PROPERTIES",[...De.MUTABLE_DOWNSTREAM_PROPERTIES,...De.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(De,"PROPERTIES",[...De.META_PROPERTIES,...De.UPSTREAM_PROPERTIES,...De.DOWNSTREAM_PROPERTIES]);let _r=De;function $v(n){var e,t,i;switch(n.id){case x["built-in-base-entity"].BUILT_IN_PERSISTED_ENTITY_ENTITY.id:{const a=n.project.entities.filter(f=>!!f.implements.find(m=>m.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.id));if(a.find(f=>!!f.properties.find(m=>{var b;return m.implements&&m.implements.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.properties.default.id&&((b=m.getDefaultValue())==null?void 0:b.value)===!0}))){const m=a[0].properties.find(g=>g.implements&&g.implements.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.properties.default.id),b=(e=m==null?void 0:m.dataType)==null?void 0:e.defaultValue;if(b)b.value=!0;else if(m!=null&&m.dataType){const g=(t=m==null?void 0:m.dataType)==null?void 0:t.id.split("-id")[0],I=R({id:g+"-default-value-id",version:1,type:r.PrimitiveValue,name:A.EntityTemplate,autogeneration:null,value:!0,valueAsType:null,parent:m==null?void 0:m.dataType.toReference()},n.project);return I.setParent(m==null?void 0:m.dataType),I.initChildren(),I.addSelfToProject(),{newEntities:[I]}}return{newEntities:[]}}const o=n.project.get(x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.id),l=Eo(o,"Main database");if(l.errors.length>0)return{newEntities:[]};const p=l.implemented.properties.find(f=>f.implements&&f.implements.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.properties.default.id),y=(i=p==null?void 0:p.dataType)==null?void 0:i.defaultValue;if(y)y.value=!0;else if(p!=null&&p.dataType){const f=p==null?void 0:p.dataType.id.split("-id")[0],m=R({id:f+"-default-value-id",version:1,type:r.PrimitiveValue,name:A.EntityTemplate,autogeneration:null,value:!0,valueAsType:null,parent:p==null?void 0:p.dataType.toReference()},n.project);m.setParent(p==null?void 0:p.dataType),m.initChildren(),m.addSelfToProject()}return{newEntities:[l.implemented]}}}return{newEntities:[]}}function Lv(n){return n.implements.filter(t=>t.type===r.BuiltInBaseEntity).map(t=>{var i;switch(t.id){case x["built-in-base-entity"].BUILT_IN_PERSISTED_ENTITY_ENTITY.id:{const s=n.project.entities.filter(p=>p.implements.find(y=>y.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.id)).find(p=>!!p.properties.find(y=>{var f;return y.implements&&y.implements.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.properties.default.id&&((f=y.getDefaultValue())==null?void 0:f.value)===!0}));if(!s)return{newEntities:[]};const o=n.properties.find(p=>p.implements&&p.implements.id===x["built-in-base-entity"].BUILT_IN_PERSISTED_ENTITY_ENTITY.properties.database.id),l=(i=o==null?void 0:o.dataType)==null?void 0:i.defaultValue;if(o&&(o!=null&&o.dataType)&&!l){const p=o==null?void 0:o.dataType.id.split("-id")[0],y=R({id:p+"-default-value-id",version:1,type:r.PrimitiveValue,name:A.EntityTemplate,autogeneration:null,value:null,valueAsType:s,parent:o==null?void 0:o.dataType.toReference()},n.project);return y.setParent(o==null?void 0:o.dataType),y.initChildren(),y.addSelfToProject(),{newEntities:[y]}}return{newEntities:[]}}}}),{newEntities:[]}}function Eo(n,e,t){const i=t||Ke(e,r.CustomEntity,n.project),a=i.split("-id"),s=a[a.length-1||0]||i,o={id:i,version:1,name:e,type:r.CustomEntity,description:null,static:!1,abstract:!1,properties:[],methods:[],abstractMethods:[],extends:[],implements:[n],x:0,y:0,parent:n.project},l=lo(o,n.project);if(l.length>0)return{errors:l,implemented:null,entitiesChanges:{new:[],updated:[],deleted:[]}};const p=$v(n),y=R(o,n.project);y.setParent(n.project),y.initChildren();const f=n.properties.map(g=>{const I=s+"-"+Ke(S(g,n.project),r.Property,n.project),P=g.clone(y,I);return P.abstract=!1,P.implements=g,P.setParent(y),y.addProperty(P),P}),m=n.abstractMethods.map(g=>{const I=s+Ke(g.name,r.FunctionDeclaration,n.project),P=g.implementAsFunctionDeclaration(I),B={id:I+"-parent-ref-id",type:r.GenericReference,entityId:i,entityType:r.CustomEntity},Y={...P,implements:g,parent:B},G=R(Y,n.project);return y.addMethod(G),G.setParent(y),G.initChildren(),G.implements=g,G});o.properties=f,o.methods=m;const b=Lv(y);return{implemented:y,errors:[],entitiesChanges:{new:[y,...p.newEntities,...b.newEntities],updated:[y],deleted:[]}}}function Ro(n,e){const t=Mr(n);if(t.length===0)return{list:[],last:null};let i=null;return{list:t.flatMap(s=>{if(s===e)return i=s,[s];const o=Ro(s,e);return o.last&&(i=o.last),[s,...o.list]}),last:i}}function Gv(n,e,t=new Set){const i=Wn(n),a=Wn(e),s=i.filter(p=>!a.includes(p)),o=i.filter(p=>a.includes(p)),l=s.reduce((p,y)=>t.has(y.id)?p:(t.add(y.id),v([...p,...Gv(y,e,t)])),[]);return v([...o,...l])}function Pa(n,e){const t=Ro(n,e);return t.last===e&&t.list.length>0&&t.list[0]!==e}function M3(n,e){return!!Ro(n,e).last}function N3(n){if(Me.includes(n.type))return n;if([...Pn,r.VariableDeclaration].includes(n.type)){const e=n.parent;return Me.includes(e.type)?e:null}return null}function Vd(n,e){if(!n||!e)throw new Error("Both entities must be defined to find a common ancestor");if(n===e)return n;const t=n.parent;if(t){if(t===e)return e;if(t.type===r.Project)return null}else return null;const i=e.parent;if(i){if(i===n)return n;if(i.type===r.Project)return null}else return null;return Vd(t,i)}function ze(n){if(Bo.includes(n.type)){if(n.type===r.FunctionDeclaration){const e=n.parent;if(e.type===r.CustomEntity)return e}return n}else{const e=n.parent;return e?ze(e):null}}function V3(n){return n.type===r.VariableDeclaration?[n]:$e.includes(n.type)?[...n.inputs,...n.outputs||[]]:n.type===r.ReturnStatement?n.outputs:Lr.includes(n.type)||n.type===r.FunctionDeclaration?n.inputs:[]}function $3(n){const e=Wn(n),t=[],i=[];zd.includes(n.type)&&t.push(...$d(n));const a=e.filter(s=>{const o=t.includes(s);return o?!1:Pn.includes(s.type)&&!o?(i.push(s),!1):!0});return t.sort((s,o)=>Pa(o,s)?-1:0),i.sort((s,o)=>Pa(o,s)?-1:0),[...t,...i,...a]}function Fv(n){return[...n].sort((e,t)=>Pa(t,e)?-1:0)}function L3(n){const e=Fv(n),t=[];return e.forEach(i=>{const a=t[t.length-1];if(a){const s=a[a.length-1];Pa(i,s)?t.push([i]):a.push(i)}else t.push([i])}),t}function Et(n){const e=n.map(t=>ze(t));return v(e)}function $d(n){return $e.includes(n.type)?[...Et(n.successCalls),...Et(n.errorCalls)]:Me.includes(n.type)?Et(n.calls):[]}function G3(n,e){return $d(n).includes(e)}function Ld(n){return n.writesValues||[]}function F3(n,e){return Ld(n).includes(e)}function Uv(n){var e;return xe.includes((e=n==null?void 0:n.readsValue)==null?void 0:e.type)?n.readsValue:null}function U3(n){return n.writesValues}function xv(n=[]){return n.map(Uv).filter(e=>!!e)}function bo(n=[]){return n.map(e=>e.writesValues).flat().filter(e=>xe.includes(e.type))}function kv(n=[]){return n.map(e=>e.readsValue).filter(e=>!!e&&xe.includes(e.type))}function jv(n){return xe.includes(n.type)?n:null}function qv(n){return n.writesValues.map(jv).filter(e=>!!e)}function Jv(n=[]){return n.reduce((e,t)=>t.type===r.OutputMap?[...e,...qv(t)]:e,[])}function Se(n){return $e.includes(n.type)?[...sn(Et(n.successCalls)),...sn(Et(n.errorCalls))]:Me.includes(n.type)?sn(Et(n.calls)):[]}function x3(n){return $e.includes(n.type)?[...sn(Et(n.successCalls)),...sn(Et(n.errorCalls))]:Me.includes(n.type)?sn(Et(n.calls)):[]}function Wv(n,e=new Set){return n.writesValues.filter(i=>xe.includes(i.type)&&!e.has(i.id)).reduce((i,a)=>e.has(a.id)?i:[...i,...te(a,e)],[])}function Hv(n,e=new Set){var i;return(((i=n.readsValue)==null?void 0:i.writesValues)||[]).filter(a=>xe.includes(a.type)&&!e.has(a.id)).reduce((a,s)=>e.has(s.id)?a:[...a,...te(s,e)],[])}function te(n,e=new Set){if(e.has(n.id))return[];if(n.type===r.ReturnStatement)return kv(n.outputs).reduce((i,a)=>[...i,...te(a,e)],[]);if(n.type===r.FunctionCall||n.type===r.Operation||n.type===r.Condition)return[...Se(n).reduce((s,o)=>{const l=ze(o);return[...s,...te(l||o,e)]},[]),...xv(n.inputs),...Jv(n.outputs)].reduce((s,o)=>[...s,...te(o,e)],[]);if(Lr.includes(n.type)){const t=bo(n.inputs),a=Se(n).reduce((s,o)=>{const l=ze(o);return[...s,...te(l||o,e)]},[]);return t.push(...a),t.reduce((s,o)=>[...s,...te(o,e)],[])}if(n.type===r.FunctionDeclaration){const t=[...bo(n.inputs)],a=Se(n).reduce((s,o)=>{const l=ze(o);return[...s,...te(l||o,e)]},[]);return t.push(...a),t.reduce((s,o)=>[...s,...te(o)],[])}if(xe.includes(n.type)){e.add(n.id);const i=Se(n).reduce((a,s)=>{const o=ze(s);return[...a,...te(o||s,e)]},[]);return[n,...i,...Hv(n,e),...Wv(n,e)]}return[]}function At(n,e=new Set){return e.has(n.id)?[]:(e.add(n.id),[...Wn(n).reduce((a,s)=>[...a,s,...At(s,e)],[])])}function sn(n){return n.reduce((e,t)=>t.type===r.ReturnStatement||t.type===r.ContinueStatement||t.type===r.BreakStatement?[...e,t]:[...e,t,...Se(t)],[])}function Yv(n){const e=n.entities||[],t=[...e,...n.functions||[],...n.events||[],...n.projects||[]],i=e.reduce((p,y)=>[...p,...y.properties],[]),a=e.reduce((p,y)=>[...p,...y.methods],[]),s=a.reduce((p,y)=>[...p,...bo(y.inputs),...sn(Et(y.calls)),...y.returnStatements],[]),o=n.functions.reduce((p,y)=>[...p,...sn(Et(y.calls)),...y.returnStatements],[]),l=n.events.reduce((p,y)=>[...p,...sn(Et(y.calls)),...y.returnStatements],[]);return[...t,...i,...a,...s,...o,...l]}function zv(n,e){return e.filter(i=>{if(!i)return!1;switch(i.type){case r.FunctionCall:return i.inputs.find(a=>a.id===n.id)!==void 0||i.outputs.find(a=>a.id===n.id)!==void 0;case r.Condition:return i.successCalls.find(a=>a.id===n.id)!==void 0||i.errorCalls.find(a=>a.id===n.id)!==void 0||i.inputs.find(a=>a.id===n.id)!==void 0;case r.Operation:return i.outputs.find(a=>a.id===n.id)!==void 0;case r.VariableDeclaration:return $e.includes(n.type)?Zv(n).find(s=>{var o;return((o=s.readsValue)==null?void 0:o.id)===i.id})!==void 0:!1;case r.CustomEntity:return i.properties.find(a=>a.id===n.id)!==void 0||i.methods.find(a=>a.id===n.id)!==void 0;case r.FunctionDeclaration:return i.inputs.find(a=>a.id===n.id)!==void 0||(i.returnStatements.map(a=>a.outputs).flat()||[]).find(a=>a.id===n.id)!==void 0;default:return!1}})}function k3(n){const e=Yv(n.project);return zv(n,e)}function Mr(n){const e=[];if(Pn.includes(n.type)){n.calledBy.forEach(a=>{const s=ze(a);s&&e.push(s)});const i=[...n.inputs||[],...n.outputs||[]].map(a=>Ud(a)).filter(a=>a!==null);e.push(...v(i))}if(xe.includes(n.type)){const t=Ud(n);t&&e.push(t)}return v(e)}function Gd(n){return n.type===r.FunctionCall||n.type===r.InternalCall?n.declaration.inputs:[r.Operation,r.Condition,r.Loop].includes(n.type)?n.declaration.fixedArguments:n.type===r.FunctionDeclaration||Lr.includes(n.type)?n.inputs:n.type===r.Search?n.inputsDeclarations:[]}function j3(n,e){return e.type===r.Condition?e.inputs.find(t=>t.declaration.id===n.id):e.type===r.FunctionCall||e.type===r.Operation?e.inputs.find(t=>t.declaration.id===n.id):null}function Zv(n){return $e.includes(n.type)?n.inputs:[]}function Fd(n){var e;return n.type===r.FunctionCall?((e=n.declaration.returnStatements[0])==null?void 0:e.outputs)||[]:[r.Operation,r.Condition,r.Loop].includes(n.type)?n.declaration.fixedReturns:n.type===r.Search?n.outputsDeclarations:Ne.includes(n.type)?n.outputs:[]}function q3(n,e){return e.type===r.Condition?null:e.type===r.FunctionCall||e.type===r.Operation?e.outputs.find(t=>t.declaration.id===n.id):null}function J3(n){return n.type===r.Condition?[]:$e.includes(n.type)?n.outputs:[]}function Ud(n){const e=n.readsValue;return e?ze(e):null}function Xv(n){const e=n.internalCalls||[];return v(Et(v(e.flatMap(t=>[...t.successCalls,...t.errorCalls]))))}function Ri(n){const e=Ld(n),t=[];return e.forEach(i=>{if(xe.includes(i.type))t.push(i);else if(i.type===r.InputMap){const a=i.parent;t.push(a)}}),t}function v(n){const e=new Set;return n.filter(t=>!t||e.has(t.id)?!1:(e.add(t.id),!0))}function Wn(n,e=!1){const t=[];if(n.type===r.Project&&t.push(...(n==null?void 0:n.entities)||[],...(n==null?void 0:n.functions)||[],...(n==null?void 0:n.variableDeclarations)||[],...(n==null?void 0:n.variableInstances)||[],...(n==null?void 0:n.searches)||[],...(n==null?void 0:n.loops)||[],...(n==null?void 0:n.operations)||[],...(n==null?void 0:n.conditions)||[],...(n==null?void 0:n.functionCalls)||[],...(n==null?void 0:n.events)||[],...(n==null?void 0:n.projects)||[]),ct.includes(n.type)&&t.push(...(n==null?void 0:n.detachedChildren)||[]),n.type===r.CustomEntity){const i=[...n.suggestedMethods,...n.methods].flatMap(a=>a.collapsed&&e?[]:Wn(a));t.push(...i)}if(n.type===r.Condition){const i=n.successCalls.map(s=>ze(s)),a=n.errorCalls.map(s=>ze(s));t.push(...i,...a)}if(Lr.includes(n.type)){if(n.collapsed&&e)return[];const i=n.inputs.map(s=>Ri(s)).flat(),a=n.calls.map(s=>ze(s));t.push(...v(i),...a)}if($e.includes(n.type)&&n.type!==r.Condition){const i=n==null?void 0:n.outputs.map(o=>Ri(o)).flat(),a=n.successCalls.map(o=>ze(o)),s=n.errorCalls.map(o=>ze(o));t.push(...v(i),...a,...s)}if(xe.includes(n.type)){const i=Ri(n),a=Xv(n);t.push(...i,...a)}if(n.type===r.Loop){const i=n.outputs.map(o=>Ri(o)).flat();if(n.body){const o=Wn(n.body,e);t.push(...o)}const a=n.errorCalls.map(o=>ze(o)),s=n.successCalls.map(o=>ze(o));t.push(...v(i),...s,...a)}if(n.type===r.FunctionDeclaration){if(n.collapsed&&e)return[];const i=n.inputs.map(s=>Ri(s)).flat(),a=n.calls.map(s=>ze(s));t.push(...v(i),...a)}return v(t)}function Qv(n,e=!1){const t=Wn(n,e),i=[...t,...t.reduce((a,s)=>[...a,...Qv(s,e)],[])];return v(i)}function Kv(n){const e=Mr(n),t=[...e,...e.reduce((i,a)=>[...i,...Kv(a)],[])];return v(t)}function go(n){return n.implements.reduce((e,t)=>t.type===r.CustomEntity?[...e,r.CustomEntity,...go(t),...vo(t)]:[...e,t.name],[])}function vo(n){return n.extends.reduce((e,t)=>t.type===r.CustomEntity?[...e,r.CustomEntity,...vo(t),...go(t)]:[...e,t.name],[])}function xd(n){return n.extends.reduce((e,t)=>t.type===r.CustomEntity?[...e,t,...xd(t),...kd(t)]:[...e,t],[])}function kd(n){return n.implements.reduce((e,t)=>t.type===r.CustomEntity?[...e,t,...kd(t),...xd(t)]:[...e,t],[])}function eI(n){return[...vo(n),...go(n)].filter((t,i,a)=>a.indexOf(t)===i)}function tI(n){return n.implements.length===0&&n.extends.length===0?null:n.implements.find(i=>i.type===r.BuiltInBaseEntity&&i.name===V.PERSISTED_ENTITY)?n:[...n.implements,...n.extends].reduce((i,a)=>{if(a.type===r.CustomEntity){const s=tI(a);if(s)return s}return i},null)}function W3(n){const e=n.extends.find(t=>t.type===r.BuiltInBaseEntity);return e&&e.type===r.BuiltInBaseEntity?e:null}function H3(n){const e=n.implements.find(t=>t.type===r.BuiltInBaseEntity);return e&&e.type===r.BuiltInBaseEntity?e:null}function nI(n){const e=n.extends.find(t=>t.type===r.CustomEntity);return e&&e.type===r.CustomEntity?e:null}function Hn(n){const e=[...n.implements,...n.extends].reduce((t,i)=>i.type===r.BuiltInBaseEntity?[...t,i]:i.type===r.CustomEntity?[...t,...Hn(i)]:t,[]);return v(e)}function jd(n){return n.type===r.PrimitiveEntity?!0:n.type===r.BuiltInBaseEntity?n.interactive:!Hn(n).find(i=>!i.interactive)}function Y3(n){return n.parent===n.project&&n.project.variableDeclarations.includes(n)}function qd(n){return n.parent!==n.project?!1:r.VariableDeclaration===n.type?n.project.variableDeclarations.includes(n):r.VariableInstance===n.type?n.project.variableInstances.includes(n):r.FunctionCall===n.type?n.project.functionCalls.includes(n):r.Condition===n.type?n.project.conditions.includes(n):r.Operation===n.type?n.project.operations.includes(n):r.Loop===n.type?n.project.loops.includes(n):r.Search===n.type?n.project.searches.includes(n):!1}function rI(n){if([...Me,r.CustomEntity,r.InstalledProject,r.Project].includes(n.type)||qd(n))return!1;const e=Mr(n);return e.length===0?!0:e.some(t=>rI(t))}function Jd(n){return[...Me,r.CustomEntity,r.InstalledProject,r.Project].includes(n.type)||qd(n)?!1:Mr(n).length===0}function iI(n,e=0){if(Jd(n)){const t=Mr(n);return t.length===0?n:t.map(a=>iI(a,e+1)).reduce((a,s)=>a?s&&s.x<a.x?s:a:s,null)}return null}function aI(n){const e=[];if(Jd(n))e.push(n);else return[];return Mr(n).forEach(i=>{e.push(...aI(i))}),e}function sI(n){return n.type===r.FunctionDeclaration&&n.parent!==n.project&&!![r.CustomEntity,r.Loop,r.InstalledProject].includes(n.parent.type)}function z3(n,e){const t=new Map;return n.forEach(i=>{t.set(i.id,i)}),e.forEach(i=>{t.set(i.id,i)}),Array.from(t.values())}function Io(n){switch(n){case r.CustomEntity:return Nr;case r.FunctionDeclaration:return gr;case r.VariableDeclaration:return Pr;case r.VariableInstance:return Ar;case r.FunctionCall:return _r;case r.Operation:return vr;case r.Condition:return Dr;case r.ReturnStatement:return Br;case r.Loop:return Ir;case r.Search:return Sr;case r.InputMap:return gn;case r.OutputMap:return vn;case r.ArgumentDeclaration:return Cr;case r.ReturnDeclaration:return _t;case r.Property:return br;case r.InstalledProject:return Or;case r.Project:return w;case r.BuiltInBaseEntity:return Gt;default:return null}}function Rt(n,e){if(ct.includes(n.type))return n;if(Gr.includes(n.type))return null;const t=n.parent;if(!t)return null;if(t.type===r.GenericReference){const i=C(t);if(!i)return null;const a=e.get(i);return a?Rt(a,e):null}else return t===e?e:Rt(t,e)}function Wd(n,e){if(Gr.includes(n.type)||e.getAllBuiltInIds().includes(n.id))return null;const i=Mt(n.parent,e);return i?i===e?ct.includes(n.type)?n:null:i.type===r.CustomEntity?n:Wd(i,e):null}function Do(n,e,t){if(n===e||e===t||n===t)return!1;const i=Rt(e.parent,t);return i===n?!0:Do(i,e,t)}var Po=(n=>(n.SameBothLocal="same-both-local",n.AInB="a-in-b",n.BInA="b-in-a",n.ParallelInCommonParent="parallel-in-common-parent",n.ParallelInProject="parallel-in-project",n.AIsGlobalBIsNot="a-is-global-b-is-not",n.BIsGlobalAIsNot="b-is-global-a-is-not",n.SameBothGlobal="same-both-global",n))(Po||{});function Aa(n,e,t){const i=Rt(n,t),a=Rt(e,t);if(!i)throw new Error("Could not find scope owner for the entity: "+n.id);if(!a)throw new Error("Could not find scope owner for the entity: "+e.id);if(i===a&&i.type!==r.Project)return{compatible:!0,type:"same-both-local",commonAncestorScope:i};if(i===a&&i.type===r.Project)return{compatible:!0,type:"same-both-global",commonAncestorScope:i};if(i.type===r.Project&&a.type!==r.Project)return{compatible:!1,type:"a-is-global-b-is-not",commonAncestorScope:i};if(i.type!==r.Project&&a.type===r.Project)return{compatible:!1,type:"b-is-global-a-is-not",commonAncestorScope:a};if(Do(i,a,t))return{compatible:!0,type:"b-in-a",commonAncestorScope:i};if(Do(a,i,t))return{compatible:!0,type:"a-in-b",commonAncestorScope:a};const l=Vd(i,a);return l===t?{compatible:!1,type:"parallel-in-project",commonAncestorScope:l}:l?{compatible:!1,type:"parallel-in-common-parent",commonAncestorScope:Rt(l,t)}:{compatible:!1,type:"parallel-in-project",commonAncestorScope:t}}function oI(n,e,t){const i=Aa(n,e,t);if(!i.compatible||i.type!=="same-both-local")return null;if(n===e)return n;let a=Rt(n.parent,t);if(a){if(a===e)return e;if(a.type===r.Project)return n}else return n;for(;a;){if(a){if(a===e)return e;if(a.type===r.Project)return n}else return n;a=Rt(a.parent,t)}let s=Rt(e.parent,t);if(s){if(s===n)return n;if(s.type===r.Project)return e}else return e;for(;s;){if(s){if(s===n)return n;if(s.type===r.Project)return e}else return e;s=Rt(s.parent,t)}return null}function lI(n){return n.length===0?null:n.length===1?n[0]:n.reduce((t,i)=>{const a=oI(t,i,i.project);return!a||a===i?t:i},n[0])}function Mt(n,e){let t;return typeof n=="string"?t=n:n.type===r.GenericReference?t=C(n):t=n.id,t===e.id?e:e.get(t)}function Yn(n){if(Gr.includes(n.type))return n;if(n.type===r.Project)return null;if(n.project.getAllBuiltInIds().includes(n.id))return n;const t=n.parent;return!t||t.type===r.Project?null:Yn(t)}function Sa(n,e){var t;if(n.readsValue){const i=Mt(n.readsValue,e.project);e.setValueWriter(i),i.addValueReader(e)}else n.readsValue===null&&((t=e.readsValue)==null||t.removeValueReader(e),e.readsValue=null);return e}function Oa(n){const e=[];function t(s,o){return e.some(l=>l.blockedByCaller===s&&l.blockedByCalling===o)}function i(s,o){t(s,o)||e.push({blockedByCaller:s,blockedByCalling:o})}const a=Wd(n,n.project);return n.calledBySuccess.forEach(s=>{[...s.successCalls||[]].forEach(p=>{Ne.includes(p.type)&&p!==n&&(Se(n).find(m=>m===p)||i(s,p))});let l;if($e.includes(s.type)&&(l=s),l){const p=Oa(l);p.reachable||Se(n).find(m=>m===s)||p.blocks.forEach(m=>{i(s,m.blockedByCalling)})}}),n.calledByError.forEach(s=>{[...s.errorCalls||[]].forEach(p=>{Ne.includes(p.type)&&p!==n&&(Se(n).find(m=>m===p)||i(s,p))});let l;if($e.includes(s.type)&&(l=s),l){const p=Oa(l);p.reachable||Se(n).find(m=>m===s)||p.blocks.forEach(m=>{i(s,m.blockedByCalling)})}}),n.calledByEntry.forEach(s=>{if([...s.calls||[]].forEach(p=>{Ne.includes(p.type)&&p!==n&&(Se(n).find(m=>m===p)||i(s,p))}),s===a)return;let l;if(s.type===r.FunctionDeclaration){const p=ze(s);if(p.type===r.CustomEntity)return;p.type===r.Loop&&(l=p)}if(l){const p=Oa(l);p.reachable||p.blocks.forEach(y=>{i(s,y.blockedByCalling)})}}),{reachable:e.length===0,entryPoint:a,blocks:e}}function Z3(n){return Bo.includes(n.type)?n.type===r.FunctionDeclaration?!sI(n):!0:!1}function X3(n){if(r.ActionDescriptor===n.type){if(n.project.operationDeclarations.find(s=>s.id===n.id))return r.Operation;if(n.project.globalEventActionDescriptors.find(s=>s.id===n.id))return r.GlobalEvent;if(n.project.loopDeclarations.find(s=>s.id===n.id))return r.Loop;if(n.project.conditionDeclarations.find(s=>s.id===n.id))return r.Condition}return n.type}function Q3(n,e){const t=[];if(n.parent)if(n.id===n.parent)t.push(new E({id:`${n.id}--${n.parent}--${h.SelfReference}`,code:h.SelfReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to itself at 'parent'. This is not allowed. Change the reference string or the 'entityId' property of the reference object.`,issue:null}));else{const i=e.get(n.parent);i?[r.Project,r.DataType].includes(i.type)||t.push(new E({id:`${n.id}--${n.parent}--${h.InvalidParentReference}`,code:h.InvalidParentReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a parent reference that isn't pointing to an entity of type 'project' or 'data-type'.`,issue:null})):t.push(new E({id:`${n.id}--${n.parent}--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", is referencing an entity with id "${n.parent}" that isn't yet found in the project. Perhaps it should be created first. Or perhaps the ID is incorrect.`,issue:null}))}return n.implements&&Array.isArray(n.implements)?n.implements.forEach(i=>{if(n.id===i){t.push(new E({id:`${n.id}--${i}--${h.SelfReference}`,code:h.SelfReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to itself at one of the 'implements' references. This is not allowed. Change the reference string or the 'entityId' property of the reference object.`,issue:null}));return}const a=e.get(i);a?[r.CustomEntity,r.BuiltInBaseEntity].includes(a.type)?a.abstract||t.push(new E({id:`${n.id}--${i}--${h.InvalidImplementsReference}`,code:h.InvalidImplementsReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has an 'implements' reference that isn't pointing to an abstract entity.`,issue:null})):t.push(new E({id:`${n.id}--${i}--${h.InvalidImplementsReference}`,code:h.InvalidImplementsReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has an 'implements' reference that isn't pointing to an entity of type 'custom-entity' or 'built-in-base-entity'.`,issue:null})):t.push(new E({id:`${n.id}--${i}--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", is referencing an entity with id "${i}" that isn't yet found in the project. Perhaps it should be created first. Or perhaps the ID is incorrect.`,issue:null}))}):t.push(new E({id:`${n.id}--${D.InvalidObjectStructure}`,code:D.InvalidObjectStructure,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has an 'implements' property that isn't an array.`,issue:null})),n.extends&&Array.isArray(n.extends)&&n.extends.forEach(i=>{const a=e.get(i);a?[r.CustomEntity,r.BuiltInBaseEntity].includes(a.type)?a.abstract&&t.push(new E({id:`${n.id}--${i}--${h.InvalidExtendsReference}`,code:h.InvalidExtendsReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has an 'extends' reference that isn't pointing to a non-abstract entity. Did you want to use the property 'implements', which holds a list of references to absract entities, instead?`,issue:null})):t.push(new E({id:`${n.id}--${i}--${h.InvalidExtendsReference}`,code:h.InvalidExtendsReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has an 'extends' reference that isn't pointing to an entity of type 'custom-entity' or 'built-in-base-entity'.`,issue:null})):t.push(new E({id:`${n.id}--${i}--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", is referencing an entity with id "${i}" that isn't yet found in the project. Perhaps it should be created first. Or perhaps the ID is incorrect.`,issue:null}))}),t}const Pe=class Pe{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"name");c(this,"description",null);c(this,"x");c(this,"y");c(this,"static");c(this,"abstract");c(this,"type",r.CustomEntity);c(this,"properties",[]);c(this,"methods",[]);c(this,"abstractMethods",[]);c(this,"extends",[]);c(this,"implements",[]);c(this,"project");c(this,"errors",[]);c(this,"parent");c(this,"initialized",!1);c(this,"suggestedProperties",[]);c(this,"suggestedMethods",[]);this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.name=e.name,this.x=e.x,this.y=e.y,this.static=e.static,this.abstract=e.abstract}static fromGenerationTarget(e,t){let i=t;if(e.parent){const p=C(e.parent);i=t.get(p)}const a=[];e.implements&&e.implements.forEach(p=>{a.push(t.get(p)||t.getBuiltIn(p))});const s=[];e.extends&&e.extends.forEach(p=>{s.push(t.get(p)||t.getBuiltIn(p))});const o={id:e.id,version:1,name:e.name,type:r.CustomEntity,description:e.description,static:e.static,abstract:e.abstract,properties:[],methods:[],abstractMethods:[],extends:s,implements:a,x:0,y:0,parent:i},l=R(o,t);return l.setParent(i),l.initChildren(),l}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[],s=Q3(i,t),o=lo(i,t);a.push(...s,...o,...Be(i));const l=i.parent?t.get(i.parent):null;if(l&&l.type===r.DataType){const p=l;p.entity&&a.push(new E({id:`${e.id}--${h.NewEntityWouldOverriteExisting}`,code:h.NewEntityWouldOverriteExisting,severity:T.Error,message:`The entity of type '${e.type}' with id '${e.id}' can't be added to the 'parent' entity with id '${p.id}' because it already has an 'entity' child. Data type entities can only have one 'entity' as children.
|
|
370
|
+
You shouldn't have to manually update a 'parent' property. The equivalent result is to change its callers, the value writters of its inputs, or the value readers of its outputs.`,issue:null})),{errors:t,modifiedData:e}}addSelfToProject(){var t;const e=[this];return this.parent===this.project&&this.project.addFunctionCall(this),(t=this.process)==null||t.writesValues.forEach(i=>{i.setValueWriter(this.process),e.push(i)}),this.successCalls.forEach(i=>{i.addSuccessCaller(this),e.push(i)}),this.errorCalls.forEach(i=>{i.addErrorCaller(this),e.push(i)}),this.calledBySuccess.forEach(i=>{i.addSuccessCall(this),e.push(i)}),this.calledByError.forEach(i=>{i.addErrorCall(this),e.push(i)}),this.calledByEntry.forEach(i=>{i.addCall(this),e.push(i)}),{affected:v(e),self:this}}get calledBy(){return[...this.calledByEntry,...this.calledBySuccess,...this.calledByError]}removeInput(e){const t=this.inputs.findIndex(i=>i.id===e.id);return t>-1&&this.inputs.splice(t,1),this}addInput(e){return this.inputs.includes(e)?this:(this.inputs.push(e),this)}addOutput(e){return this.outputs.includes(e)?this:(this.outputs.push(e),this)}removeOutput(e){const t=this.outputs.findIndex(i=>i.id===e.id);return t>-1&&this.outputs.splice(t,1),this}addValueReader(e){var t;return(t=this.process)==null||t.addValueReader(e),this}removeValueReader(e){var t;return(t=this.process)==null||t.removeValueReader(e),this}addSuccessCaller(e){return this.calledBySuccess.find(t=>t.id===e.id)||this.calledBySuccess.push(e),this}addErrorCaller(e){return this.calledByError.find(t=>t.id===e.id)||this.calledByError.push(e),this}addEntryCaller(e){return this.calledByEntry.find(t=>t.id===e.id)||this.calledByEntry.push(e),this}addErrorCall(e){return this.errorCalls.push(e),this}addSuccessCall(e){return this.successCalls.push(e),this}removeCall(e){const t=this.successCalls.findIndex(a=>a.id===e.id);t>-1&&this.successCalls.splice(t,1);const i=this.errorCalls.findIndex(a=>a.id===e.id);return i>-1&&this.errorCalls.splice(i,1),this}removeCaller(e){return this.calledBySuccess=this.calledBySuccess.filter(t=>t.id!==e.id),this.calledByError=this.calledByError.filter(t=>t.id!==e.id),this.calledByEntry=this.calledByEntry.filter(t=>t.id!==e.id),this}setParent(e){return this.parent=e,this}initChildren(){if(this.initialized)return this;if(this.initialized=!0,this.initialData.declaration.type===r.FunctionDeclaration){const e=R(this.initialData.declaration,this.project);this.declaration=e}else{const e=C(this.initialData.declaration),t=this.project.get(e);this.declaration=t}return this.successCalls=this.initialData.successCalls.map(e=>{const t=R(e,this.project);return t.addSuccessCaller(this),[r.BreakStatement,r.ContinueStatement].includes(t.type)?(t.setParent(this.parent.parent),t.initChildren()):t.type!==r.InternalCall&&(t.setParent(this.parent),t.initChildren()),t}),this.errorCalls=this.initialData.errorCalls.map(e=>{const t=R(e,this.project);return t.addErrorCaller(this),[r.BreakStatement,r.ContinueStatement].includes(t.type)?(t.setParent(this.parent.parent),t.initChildren()):t.type!==r.InternalCall&&(t.setParent(this.parent),t.initChildren()),t}),this.inputs=this.initialData.inputs.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this.initOutputs(),this.initialData.process&&(this.process=R(this.initialData.process,this.project),this.process.setParent(this),this.process.initChildren()),this.initialData.error&&(this.error=R(this.initialData.error,this.project),this.error.setParent(this),this.error.initChildren()),this}initOutputs(){const e=[];this.outputs=this.initialData.outputs.map(s=>{const o=R(s,this.project);return e.push(o.index),o.setParent(this),o.initChildren(),o});const i=Fd(this).filter(s=>!this.outputs.find(o=>o.declaration.id===s.id));i.sort((s,o)=>s.index-o.index);const a=i.map((s,o)=>{const l=e.includes(s.index)?this.outputs.length-1+o:s.index,p={id:w.UUID.uuid(),type:r.OutputMap,version:1,declaration:s,index:l,parent:this,writesValues:[]},y=R(p,this.project);return y.setParent(this),y.initChildren(),y});return this.outputs.push(...a),this}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}sync(e){return this.version=e.version||this.version,this.x=e.x||this.x,this.y=e.y||this.y,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){var s;const i=[],a=[];if(t.has(this.id))return{affected:[],removed:[]};if(t.add(this.id),a.push(this),this.unsubscribe(),this.process){const{affected:o,removed:l}=(s=this.process)==null?void 0:s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}if(this.inputs.forEach(o=>{const{affected:l,removed:p}=o.remove({ignoreUpstream:!0,seenEntities:t});i.push(...l),a.push(...p)}),this.outputs.forEach(o=>{const{affected:l,removed:p}=o.remove({ignoreUpstream:!0,seenEntities:t});i.push(...l),a.push(...p)}),this.error){const{affected:o,removed:l}=this.error.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}return this.successCalls.forEach(o=>{i.push(o),o.removeCaller(this)}),this.errorCalls.forEach(o=>{i.push(o),o.removeCaller(this)}),e||this.calledBy.forEach(o=>{i.push(o),o.removeCall(this)}),{affected:v(i),removed:v(a)}}restore({seenEntities:e}={seenEntities:new Set}){const t=[];if(e.has(this.id))return{affected:[],self:this};if(e.add(this.id),this.subscribe(),this.process){const{affected:i}=this.process.restore({seenEntities:e});t.push(...i)}return this.inputs.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.outputs.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.successCalls.forEach(i=>{t.push(i),i.addSuccessCaller(this)}),this.errorCalls.forEach(i=>{t.push(i),i.addErrorCaller(this)}),this.calledBySuccess.forEach(i=>{t.push(i),i.addSuccessCall(this)}),this.calledByError.forEach(i=>{t.push(i),i.addErrorCall(this)}),this.calledByEntry.forEach(i=>{t.push(i),i.addCall(this)}),{affected:v(t),self:this}}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.successCalls.flatMap(i=>i.toFlat(e)),...this.errorCalls.flatMap(i=>i.toFlat(e)),...this.inputs.flatMap(i=>i.toFlat(e)),...this.outputs.flatMap(i=>i.toFlat(e)),...this.process?this.process.toFlat(e):[],...this.error?this.error.toFlat(e):[]])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.successCalls.flatMap(i=>i.toFlatIds(e)),...this.errorCalls.flatMap(i=>i.toFlatIds(e)),...this.inputs.flatMap(i=>i.toFlatIds(e)),...this.outputs.flatMap(i=>i.toFlatIds(e))])}toJSON(){var e,t;return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,successCalls:this.successCalls.map(i=>i.toJSON()),errorCalls:this.errorCalls.map(i=>i.toJSON()),calledBySuccess:this.calledBySuccess.map(i=>i.toReference()),calledByError:this.calledByError.map(i=>i.toReference()),calledByEntry:this.calledByEntry.map(i=>i.toReference()),process:(e=this.process)==null?void 0:e.toJSON(),declaration:this.declaration.toJSON(),inputs:this.inputs.map(i=>i.toJSON()),outputs:this.outputs.map(i=>i.toJSON()),parent:this.parent.toReference(),error:(t=this.error)==null?void 0:t.toJSON()}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,type:this.type,x:this.x,y:this.y,process:this.process?this.process.toReference():null,inputs:this.inputs.map(e=>e.toReference()),outputs:this.outputs.map(e=>e.toReference()),declaration:this.declaration.toReference(),successCalls:this.successCalls.map(e=>e.toReference()),errorCalls:this.errorCalls.map(e=>e.toReference()),calledBySuccess:this.calledBySuccess.map(e=>e.toReference()),calledByError:this.calledByError.map(e=>e.toReference()),calledByEntry:this.calledByEntry.map(e=>e.toReference()),error:this.error?this.error.toReference():null,parent:this.parent.toReference()}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.successCalls.flatMap(i=>i.toFlatJSON(e)),...this.errorCalls.flatMap(i=>i.toFlatJSON(e)),...this.inputs.flatMap(i=>i.toFlatJSON(e)),...this.outputs.flatMap(i=>i.toFlatJSON(e)),...this.process?this.process.toFlatJSON(e):[],...this.error?this.error.toFlatJSON(e):[]])}toGenerationTarget(){const e=this.parent.type===r.Project?void 0:this.parent.id;return{id:this.id,version:this.version,type:this.type,calledByEntry:this.calledByEntry.map(t=>t.id),calledBySuccess:this.calledBySuccess.map(t=>t.id),calledByError:this.calledByError.map(t=>t.id),declaration:this.declaration.id,parent:e}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.successCalls.flatMap(i=>i.toFlatGenerationTarget(e)),...this.errorCalls.flatMap(i=>i.toFlatGenerationTarget(e)),...this.inputs.flatMap(i=>i.toFlatGenerationTarget(e)),...this.outputs.flatMap(i=>i.toFlatGenerationTarget(e)),...this.process?this.process.toFlatGenerationTarget(e):[],...this.error?this.error.toFlatGenerationTarget(e):[]])}clearErrors(){var e,t;return this.errors=[],this.inputs.forEach(i=>i.clearErrors()),this.outputs.forEach(i=>i.clearErrors()),this.successCalls.forEach(i=>i.clearErrors()),this.errorCalls.forEach(i=>i.clearErrors()),(e=this.process)==null||e.clearErrors(),(t=this.error)==null||t.clearErrors(),this}validate(){const e=_3(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors,...this.inputs.flatMap(t=>t.getErrors()),...this.outputs.flatMap(t=>t.getErrors()),...this.error?this.error.getErrors():[],...this.process?this.process.getErrors():[]]}getShallowErrors(){return this.errors}clone(e){return new De(this.toJSON(),this.project)}};c(De,"MUTABLE_BASE_PROPERTIES",[]),c(De,"INMUTABLE_BASE_PROPERTIES",["id","version","type"]),c(De,"BASE_PROPERTIES",[...De.MUTABLE_BASE_PROPERTIES,...De.INMUTABLE_BASE_PROPERTIES]),c(De,"MUTABLE_META_PROPERTIES",["x","y"]),c(De,"INMUTABLE_META_PROPERTIES",[...De.INMUTABLE_BASE_PROPERTIES]),c(De,"META_PROPERTIES",[...De.MUTABLE_META_PROPERTIES,...De.INMUTABLE_META_PROPERTIES]),c(De,"MUTABLE_UPSTREAM_PROPERTIES",["calledBySuccess","calledByError","calledByEntry"]),c(De,"INMUTABLE_UPSTREAM_PROPERTIES",["declaration","parent"]),c(De,"UPSTREAM_PROPERTIES",[...De.MUTABLE_UPSTREAM_PROPERTIES,...De.INMUTABLE_UPSTREAM_PROPERTIES]),c(De,"MUTABLE_DOWNSTREAM_PROPERTIES",["successCalls","errorCalls","writesValues","inputs","outputs","error"]),c(De,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(De,"DOWNSTREAM_PROPERTIES",[...De.MUTABLE_DOWNSTREAM_PROPERTIES,...De.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(De,"PROPERTIES",[...De.META_PROPERTIES,...De.UPSTREAM_PROPERTIES,...De.DOWNSTREAM_PROPERTIES]);let _r=De;function Lv(n){var e,t,i;switch(n.id){case x["built-in-base-entity"].BUILT_IN_PERSISTED_ENTITY_ENTITY.id:{const a=n.project.entities.filter(f=>!!f.implements.find(m=>m.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.id));if(a.find(f=>!!f.properties.find(m=>{var b;return m.implements&&m.implements.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.properties.default.id&&((b=m.getDefaultValue())==null?void 0:b.value)===!0}))){const m=a[0].properties.find(g=>g.implements&&g.implements.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.properties.default.id),b=(e=m==null?void 0:m.dataType)==null?void 0:e.defaultValue;if(b)b.value=!0;else if(m!=null&&m.dataType){const g=(t=m==null?void 0:m.dataType)==null?void 0:t.id.split("-id")[0],I=R({id:g+"-default-value-id",version:1,type:r.PrimitiveValue,name:A.EntityTemplate,autogeneration:null,value:!0,valueAsType:null,parent:m==null?void 0:m.dataType.toReference()},n.project);return I.setParent(m==null?void 0:m.dataType),I.initChildren(),I.addSelfToProject(),{newEntities:[I]}}return{newEntities:[]}}const o=n.project.get(x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.id),l=Eo(o,"Main database");if(l.errors.length>0)return{newEntities:[]};const p=l.implemented.properties.find(f=>f.implements&&f.implements.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.properties.default.id),y=(i=p==null?void 0:p.dataType)==null?void 0:i.defaultValue;if(y)y.value=!0;else if(p!=null&&p.dataType){const f=p==null?void 0:p.dataType.id.split("-id")[0],m=R({id:f+"-default-value-id",version:1,type:r.PrimitiveValue,name:A.EntityTemplate,autogeneration:null,value:!0,valueAsType:null,parent:p==null?void 0:p.dataType.toReference()},n.project);m.setParent(p==null?void 0:p.dataType),m.initChildren(),m.addSelfToProject()}return{newEntities:[l.implemented]}}}return{newEntities:[]}}function Gv(n){return n.implements.filter(t=>t.type===r.BuiltInBaseEntity).map(t=>{var i;switch(t.id){case x["built-in-base-entity"].BUILT_IN_PERSISTED_ENTITY_ENTITY.id:{const s=n.project.entities.filter(p=>p.implements.find(y=>y.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.id)).find(p=>!!p.properties.find(y=>{var f;return y.implements&&y.implements.id===x["built-in-base-entity"].BUILT_IN_RELATIONAL_DATABASE_ENTITY.properties.default.id&&((f=y.getDefaultValue())==null?void 0:f.value)===!0}));if(!s)return{newEntities:[]};const o=n.properties.find(p=>p.implements&&p.implements.id===x["built-in-base-entity"].BUILT_IN_PERSISTED_ENTITY_ENTITY.properties.database.id),l=(i=o==null?void 0:o.dataType)==null?void 0:i.defaultValue;if(o&&(o!=null&&o.dataType)&&!l){const p=o==null?void 0:o.dataType.id.split("-id")[0],y=R({id:p+"-default-value-id",version:1,type:r.PrimitiveValue,name:A.EntityTemplate,autogeneration:null,value:null,valueAsType:s,parent:o==null?void 0:o.dataType.toReference()},n.project);return y.setParent(o==null?void 0:o.dataType),y.initChildren(),y.addSelfToProject(),{newEntities:[y]}}return{newEntities:[]}}}}),{newEntities:[]}}function Eo(n,e,t){const i=t||Ke(e,r.CustomEntity,n.project),a=i.split("-id"),s=a[a.length-1||0]||i,o={id:i,version:1,name:e,type:r.CustomEntity,description:null,static:!1,abstract:!1,properties:[],methods:[],abstractMethods:[],extends:[],implements:[n],x:0,y:0,parent:n.project},l=lo(o,n.project);if(l.length>0)return{errors:l,implemented:null,entitiesChanges:{new:[],updated:[],deleted:[]}};const p=Lv(n),y=R(o,n.project);y.setParent(n.project),y.initChildren();const f=n.properties.map(g=>{const I=s+"-"+Ke(S(g,n.project),r.Property,n.project),P=g.clone(y,I);return P.abstract=!1,P.implements=g,P.setParent(y),y.addProperty(P),P}),m=n.abstractMethods.map(g=>{const I=s+Ke(g.name,r.FunctionDeclaration,n.project),P=g.implementAsFunctionDeclaration(I),B={id:I+"-parent-ref-id",type:r.GenericReference,entityId:i,entityType:r.CustomEntity},Y={...P,implements:g,parent:B},G=R(Y,n.project);return y.addMethod(G),G.setParent(y),G.initChildren(),G.implements=g,G});o.properties=f,o.methods=m;const b=Gv(y);return{implemented:y,errors:[],entitiesChanges:{new:[y,...p.newEntities,...b.newEntities],updated:[y],deleted:[]}}}function Ro(n,e){const t=Mr(n);if(t.length===0)return{list:[],last:null};let i=null;return{list:t.flatMap(s=>{if(s===e)return i=s,[s];const o=Ro(s,e);return o.last&&(i=o.last),[s,...o.list]}),last:i}}function Fv(n,e,t=new Set){const i=Wn(n),a=Wn(e),s=i.filter(p=>!a.includes(p)),o=i.filter(p=>a.includes(p)),l=s.reduce((p,y)=>t.has(y.id)?p:(t.add(y.id),v([...p,...Fv(y,e,t)])),[]);return v([...o,...l])}function Pa(n,e){const t=Ro(n,e);return t.last===e&&t.list.length>0&&t.list[0]!==e}function M3(n,e){return!!Ro(n,e).last}function N3(n){if(Me.includes(n.type))return n;if([...Pn,r.VariableDeclaration].includes(n.type)){const e=n.parent;return Me.includes(e.type)?e:null}return null}function Vd(n,e){if(!n||!e)throw new Error("Both entities must be defined to find a common ancestor");if(n===e)return n;const t=n.parent;if(t){if(t===e)return e;if(t.type===r.Project)return null}else return null;const i=e.parent;if(i){if(i===n)return n;if(i.type===r.Project)return null}else return null;return Vd(t,i)}function ze(n){if(Bo.includes(n.type)){if(n.type===r.FunctionDeclaration){const e=n.parent;if(e.type===r.CustomEntity)return e}return n}else{const e=n.parent;return e?ze(e):null}}function V3(n){return n.type===r.VariableDeclaration?[n]:$e.includes(n.type)?[...n.inputs,...n.outputs||[]]:n.type===r.ReturnStatement?n.outputs:Lr.includes(n.type)||n.type===r.FunctionDeclaration?n.inputs:[]}function $3(n){const e=Wn(n),t=[],i=[];zd.includes(n.type)&&t.push(...$d(n));const a=e.filter(s=>{const o=t.includes(s);return o?!1:Pn.includes(s.type)&&!o?(i.push(s),!1):!0});return t.sort((s,o)=>Pa(o,s)?-1:0),i.sort((s,o)=>Pa(o,s)?-1:0),[...t,...i,...a]}function Uv(n){return[...n].sort((e,t)=>Pa(t,e)?-1:0)}function L3(n){const e=Uv(n),t=[];return e.forEach(i=>{const a=t[t.length-1];if(a){const s=a[a.length-1];Pa(i,s)?t.push([i]):a.push(i)}else t.push([i])}),t}function Et(n){const e=n.map(t=>ze(t));return v(e)}function $d(n){return $e.includes(n.type)?[...Et(n.successCalls),...Et(n.errorCalls)]:Me.includes(n.type)?Et(n.calls):[]}function G3(n,e){return $d(n).includes(e)}function Ld(n){return n.writesValues||[]}function F3(n,e){return Ld(n).includes(e)}function xv(n){var e;return xe.includes((e=n==null?void 0:n.readsValue)==null?void 0:e.type)?n.readsValue:null}function U3(n){return n.writesValues}function kv(n=[]){return n.map(xv).filter(e=>!!e)}function bo(n=[]){return n.map(e=>e.writesValues).flat().filter(e=>xe.includes(e.type))}function jv(n=[]){return n.map(e=>e.readsValue).filter(e=>!!e&&xe.includes(e.type))}function qv(n){return xe.includes(n.type)?n:null}function Jv(n){return n.writesValues.map(qv).filter(e=>!!e)}function Wv(n=[]){return n.reduce((e,t)=>t.type===r.OutputMap?[...e,...Jv(t)]:e,[])}function Se(n){return $e.includes(n.type)?[...sn(Et(n.successCalls)),...sn(Et(n.errorCalls))]:Me.includes(n.type)?sn(Et(n.calls)):[]}function x3(n){return $e.includes(n.type)?[...sn(Et(n.successCalls)),...sn(Et(n.errorCalls))]:Me.includes(n.type)?sn(Et(n.calls)):[]}function Hv(n,e=new Set){return n.writesValues.filter(i=>xe.includes(i.type)&&!e.has(i.id)).reduce((i,a)=>e.has(a.id)?i:[...i,...te(a,e)],[])}function Yv(n,e=new Set){var i;return(((i=n.readsValue)==null?void 0:i.writesValues)||[]).filter(a=>xe.includes(a.type)&&!e.has(a.id)).reduce((a,s)=>e.has(s.id)?a:[...a,...te(s,e)],[])}function te(n,e=new Set){if(e.has(n.id))return[];if(n.type===r.ReturnStatement)return jv(n.outputs).reduce((i,a)=>[...i,...te(a,e)],[]);if(n.type===r.FunctionCall||n.type===r.Operation||n.type===r.Condition)return[...Se(n).reduce((s,o)=>{const l=ze(o);return[...s,...te(l||o,e)]},[]),...kv(n.inputs),...Wv(n.outputs)].reduce((s,o)=>[...s,...te(o,e)],[]);if(Lr.includes(n.type)){const t=bo(n.inputs),a=Se(n).reduce((s,o)=>{const l=ze(o);return[...s,...te(l||o,e)]},[]);return t.push(...a),t.reduce((s,o)=>[...s,...te(o,e)],[])}if(n.type===r.FunctionDeclaration){const t=[...bo(n.inputs)],a=Se(n).reduce((s,o)=>{const l=ze(o);return[...s,...te(l||o,e)]},[]);return t.push(...a),t.reduce((s,o)=>[...s,...te(o)],[])}if(xe.includes(n.type)){e.add(n.id);const i=Se(n).reduce((a,s)=>{const o=ze(s);return[...a,...te(o||s,e)]},[]);return[n,...i,...Yv(n,e),...Hv(n,e)]}return[]}function At(n,e=new Set){return e.has(n.id)?[]:(e.add(n.id),[...Wn(n).reduce((a,s)=>[...a,s,...At(s,e)],[])])}function sn(n){return n.reduce((e,t)=>t.type===r.ReturnStatement||t.type===r.ContinueStatement||t.type===r.BreakStatement?[...e,t]:[...e,t,...Se(t)],[])}function zv(n){const e=n.entities||[],t=[...e,...n.functions||[],...n.events||[],...n.projects||[]],i=e.reduce((p,y)=>[...p,...y.properties],[]),a=e.reduce((p,y)=>[...p,...y.methods],[]),s=a.reduce((p,y)=>[...p,...bo(y.inputs),...sn(Et(y.calls)),...y.returnStatements],[]),o=n.functions.reduce((p,y)=>[...p,...sn(Et(y.calls)),...y.returnStatements],[]),l=n.events.reduce((p,y)=>[...p,...sn(Et(y.calls)),...y.returnStatements],[]);return[...t,...i,...a,...s,...o,...l]}function Zv(n,e){return e.filter(i=>{if(!i)return!1;switch(i.type){case r.FunctionCall:return i.inputs.find(a=>a.id===n.id)!==void 0||i.outputs.find(a=>a.id===n.id)!==void 0;case r.Condition:return i.successCalls.find(a=>a.id===n.id)!==void 0||i.errorCalls.find(a=>a.id===n.id)!==void 0||i.inputs.find(a=>a.id===n.id)!==void 0;case r.Operation:return i.outputs.find(a=>a.id===n.id)!==void 0;case r.VariableDeclaration:return $e.includes(n.type)?Xv(n).find(s=>{var o;return((o=s.readsValue)==null?void 0:o.id)===i.id})!==void 0:!1;case r.CustomEntity:return i.properties.find(a=>a.id===n.id)!==void 0||i.methods.find(a=>a.id===n.id)!==void 0;case r.FunctionDeclaration:return i.inputs.find(a=>a.id===n.id)!==void 0||(i.returnStatements.map(a=>a.outputs).flat()||[]).find(a=>a.id===n.id)!==void 0;default:return!1}})}function k3(n){const e=zv(n.project);return Zv(n,e)}function Mr(n){const e=[];if(Pn.includes(n.type)){n.calledBy.forEach(a=>{const s=ze(a);s&&e.push(s)});const i=[...n.inputs||[],...n.outputs||[]].map(a=>Ud(a)).filter(a=>a!==null);e.push(...v(i))}if(xe.includes(n.type)){const t=Ud(n);t&&e.push(t)}return v(e)}function Gd(n){return n.type===r.FunctionCall||n.type===r.InternalCall?n.declaration.inputs:[r.Operation,r.Condition,r.Loop].includes(n.type)?n.declaration.fixedArguments:n.type===r.FunctionDeclaration||Lr.includes(n.type)?n.inputs:n.type===r.Search?n.inputsDeclarations:[]}function j3(n,e){return e.type===r.Condition?e.inputs.find(t=>t.declaration.id===n.id):e.type===r.FunctionCall||e.type===r.Operation?e.inputs.find(t=>t.declaration.id===n.id):null}function Xv(n){return $e.includes(n.type)?n.inputs:[]}function Fd(n){var e;return n.type===r.FunctionCall?((e=n.declaration.returnStatements[0])==null?void 0:e.outputs)||[]:[r.Operation,r.Condition,r.Loop].includes(n.type)?n.declaration.fixedReturns:n.type===r.Search?n.outputsDeclarations:Ne.includes(n.type)?n.outputs:[]}function q3(n,e){return e.type===r.Condition?null:e.type===r.FunctionCall||e.type===r.Operation?e.outputs.find(t=>t.declaration.id===n.id):null}function J3(n){return n.type===r.Condition?[]:$e.includes(n.type)?n.outputs:[]}function Ud(n){const e=n.readsValue;return e?ze(e):null}function Qv(n){const e=n.internalCalls||[];return v(Et(v(e.flatMap(t=>[...t.successCalls,...t.errorCalls]))))}function Ri(n){const e=Ld(n),t=[];return e.forEach(i=>{if(xe.includes(i.type))t.push(i);else if(i.type===r.InputMap){const a=i.parent;t.push(a)}}),t}function v(n){const e=new Set;return n.filter(t=>!t||e.has(t.id)?!1:(e.add(t.id),!0))}function Wn(n,e=!1){const t=[];if(n.type===r.Project&&t.push(...(n==null?void 0:n.entities)||[],...(n==null?void 0:n.functions)||[],...(n==null?void 0:n.variableDeclarations)||[],...(n==null?void 0:n.variableInstances)||[],...(n==null?void 0:n.searches)||[],...(n==null?void 0:n.loops)||[],...(n==null?void 0:n.operations)||[],...(n==null?void 0:n.conditions)||[],...(n==null?void 0:n.functionCalls)||[],...(n==null?void 0:n.events)||[],...(n==null?void 0:n.projects)||[]),ct.includes(n.type)&&t.push(...(n==null?void 0:n.detachedChildren)||[]),n.type===r.CustomEntity){const i=[...n.suggestedMethods,...n.methods].flatMap(a=>a.collapsed&&e?[]:Wn(a));t.push(...i)}if(n.type===r.Condition){const i=n.successCalls.map(s=>ze(s)),a=n.errorCalls.map(s=>ze(s));t.push(...i,...a)}if(Lr.includes(n.type)){if(n.collapsed&&e)return[];const i=n.inputs.map(s=>Ri(s)).flat(),a=n.calls.map(s=>ze(s));t.push(...v(i),...a)}if($e.includes(n.type)&&n.type!==r.Condition){const i=n==null?void 0:n.outputs.map(o=>Ri(o)).flat(),a=n.successCalls.map(o=>ze(o)),s=n.errorCalls.map(o=>ze(o));t.push(...v(i),...a,...s)}if(xe.includes(n.type)){const i=Ri(n),a=Qv(n);t.push(...i,...a)}if(n.type===r.Loop){const i=n.outputs.map(o=>Ri(o)).flat();if(n.body){const o=Wn(n.body,e);t.push(...o)}const a=n.errorCalls.map(o=>ze(o)),s=n.successCalls.map(o=>ze(o));t.push(...v(i),...s,...a)}if(n.type===r.FunctionDeclaration){if(n.collapsed&&e)return[];const i=n.inputs.map(s=>Ri(s)).flat(),a=n.calls.map(s=>ze(s));t.push(...v(i),...a)}return v(t)}function Kv(n,e=!1){const t=Wn(n,e),i=[...t,...t.reduce((a,s)=>[...a,...Kv(s,e)],[])];return v(i)}function eI(n){const e=Mr(n),t=[...e,...e.reduce((i,a)=>[...i,...eI(a)],[])];return v(t)}function go(n){return n.implements.reduce((e,t)=>t.type===r.CustomEntity?[...e,r.CustomEntity,...go(t),...vo(t)]:[...e,t.name],[])}function vo(n){return n.extends.reduce((e,t)=>t.type===r.CustomEntity?[...e,r.CustomEntity,...vo(t),...go(t)]:[...e,t.name],[])}function xd(n){return n.extends.reduce((e,t)=>t.type===r.CustomEntity?[...e,t,...xd(t),...kd(t)]:[...e,t],[])}function kd(n){return n.implements.reduce((e,t)=>t.type===r.CustomEntity?[...e,t,...kd(t),...xd(t)]:[...e,t],[])}function tI(n){return[...vo(n),...go(n)].filter((t,i,a)=>a.indexOf(t)===i)}function nI(n){return n.implements.length===0&&n.extends.length===0?null:n.implements.find(i=>i.type===r.BuiltInBaseEntity&&i.name===V.PERSISTED_ENTITY)?n:[...n.implements,...n.extends].reduce((i,a)=>{if(a.type===r.CustomEntity){const s=nI(a);if(s)return s}return i},null)}function W3(n){const e=n.extends.find(t=>t.type===r.BuiltInBaseEntity);return e&&e.type===r.BuiltInBaseEntity?e:null}function H3(n){const e=n.implements.find(t=>t.type===r.BuiltInBaseEntity);return e&&e.type===r.BuiltInBaseEntity?e:null}function rI(n){const e=n.extends.find(t=>t.type===r.CustomEntity);return e&&e.type===r.CustomEntity?e:null}function Hn(n){const e=[...n.implements,...n.extends].reduce((t,i)=>i.type===r.BuiltInBaseEntity?[...t,i]:i.type===r.CustomEntity?[...t,...Hn(i)]:t,[]);return v(e)}function jd(n){return n.type===r.PrimitiveEntity?!0:n.type===r.BuiltInBaseEntity?n.interactive:!Hn(n).find(i=>!i.interactive)}function Y3(n){return n.parent===n.project&&n.project.variableDeclarations.includes(n)}function qd(n){return n.parent!==n.project?!1:r.VariableDeclaration===n.type?n.project.variableDeclarations.includes(n):r.VariableInstance===n.type?n.project.variableInstances.includes(n):r.FunctionCall===n.type?n.project.functionCalls.includes(n):r.Condition===n.type?n.project.conditions.includes(n):r.Operation===n.type?n.project.operations.includes(n):r.Loop===n.type?n.project.loops.includes(n):r.Search===n.type?n.project.searches.includes(n):!1}function iI(n){if([...Me,r.CustomEntity,r.InstalledProject,r.Project].includes(n.type)||qd(n))return!1;const e=Mr(n);return e.length===0?!0:e.some(t=>iI(t))}function Jd(n){return[...Me,r.CustomEntity,r.InstalledProject,r.Project].includes(n.type)||qd(n)?!1:Mr(n).length===0}function aI(n,e=0){if(Jd(n)){const t=Mr(n);return t.length===0?n:t.map(a=>aI(a,e+1)).reduce((a,s)=>a?s&&s.x<a.x?s:a:s,null)}return null}function sI(n){const e=[];if(Jd(n))e.push(n);else return[];return Mr(n).forEach(i=>{e.push(...sI(i))}),e}function oI(n){return n.type===r.FunctionDeclaration&&n.parent!==n.project&&!![r.CustomEntity,r.Loop,r.InstalledProject].includes(n.parent.type)}function z3(n,e){const t=new Map;return n.forEach(i=>{t.set(i.id,i)}),e.forEach(i=>{t.set(i.id,i)}),Array.from(t.values())}function Io(n){switch(n){case r.CustomEntity:return Nr;case r.FunctionDeclaration:return gr;case r.VariableDeclaration:return Pr;case r.VariableInstance:return Ar;case r.FunctionCall:return _r;case r.Operation:return vr;case r.Condition:return Dr;case r.ReturnStatement:return Br;case r.Loop:return Ir;case r.Search:return Sr;case r.InputMap:return gn;case r.OutputMap:return vn;case r.ArgumentDeclaration:return Cr;case r.ReturnDeclaration:return _t;case r.Property:return br;case r.InstalledProject:return Or;case r.Project:return w;case r.BuiltInBaseEntity:return Gt;default:return null}}function Rt(n,e){if(ct.includes(n.type))return n;if(Gr.includes(n.type))return null;const t=n.parent;if(!t)return null;if(t.type===r.GenericReference){const i=C(t);if(!i)return null;const a=e.get(i);return a?Rt(a,e):null}else return t===e?e:Rt(t,e)}function Wd(n,e){if(Gr.includes(n.type)||e.getAllBuiltInIds().includes(n.id))return null;const i=Mt(n.parent,e);return i?i===e?ct.includes(n.type)?n:null:i.type===r.CustomEntity?n:Wd(i,e):null}function Do(n,e,t){if(n===e||e===t||n===t)return!1;const i=Rt(e.parent,t);return i===n?!0:Do(i,e,t)}var Po=(n=>(n.SameBothLocal="same-both-local",n.AInB="a-in-b",n.BInA="b-in-a",n.ParallelInCommonParent="parallel-in-common-parent",n.ParallelInProject="parallel-in-project",n.AIsGlobalBIsNot="a-is-global-b-is-not",n.BIsGlobalAIsNot="b-is-global-a-is-not",n.SameBothGlobal="same-both-global",n))(Po||{});function Aa(n,e,t){const i=Rt(n,t),a=Rt(e,t);if(!i)throw new Error("Could not find scope owner for the entity: "+n.id);if(!a)throw new Error("Could not find scope owner for the entity: "+e.id);if(i===a&&i.type!==r.Project)return{compatible:!0,type:"same-both-local",commonAncestorScope:i};if(i===a&&i.type===r.Project)return{compatible:!0,type:"same-both-global",commonAncestorScope:i};if(i.type===r.Project&&a.type!==r.Project)return{compatible:!1,type:"a-is-global-b-is-not",commonAncestorScope:i};if(i.type!==r.Project&&a.type===r.Project)return{compatible:!1,type:"b-is-global-a-is-not",commonAncestorScope:a};if(Do(i,a,t))return{compatible:!0,type:"b-in-a",commonAncestorScope:i};if(Do(a,i,t))return{compatible:!0,type:"a-in-b",commonAncestorScope:a};const l=Vd(i,a);return l===t?{compatible:!1,type:"parallel-in-project",commonAncestorScope:l}:l?{compatible:!1,type:"parallel-in-common-parent",commonAncestorScope:Rt(l,t)}:{compatible:!1,type:"parallel-in-project",commonAncestorScope:t}}function lI(n,e,t){const i=Aa(n,e,t);if(!i.compatible||i.type!=="same-both-local")return null;if(n===e)return n;let a=Rt(n.parent,t);if(a){if(a===e)return e;if(a.type===r.Project)return n}else return n;for(;a;){if(a){if(a===e)return e;if(a.type===r.Project)return n}else return n;a=Rt(a.parent,t)}let s=Rt(e.parent,t);if(s){if(s===n)return n;if(s.type===r.Project)return e}else return e;for(;s;){if(s){if(s===n)return n;if(s.type===r.Project)return e}else return e;s=Rt(s.parent,t)}return null}function cI(n){return n.length===0?null:n.length===1?n[0]:n.reduce((t,i)=>{const a=lI(t,i,i.project);return!a||a===i?t:i},n[0])}function Mt(n,e){let t;return typeof n=="string"?t=n:n.type===r.GenericReference?t=C(n):t=n.id,t===e.id?e:e.get(t)}function Yn(n){if(Gr.includes(n.type))return n;if(n.type===r.Project)return null;if(n.project.getAllBuiltInIds().includes(n.id))return n;const t=n.parent;return!t||t.type===r.Project?null:Yn(t)}function Sa(n,e){var t;if(n.readsValue){const i=Mt(n.readsValue,e.project);e.setValueWriter(i),i.addValueReader(e)}else n.readsValue===null&&((t=e.readsValue)==null||t.removeValueReader(e),e.readsValue=null);return e}function Oa(n){const e=[];function t(s,o){return e.some(l=>l.blockedByCaller===s&&l.blockedByCalling===o)}function i(s,o){t(s,o)||e.push({blockedByCaller:s,blockedByCalling:o})}const a=Wd(n,n.project);return n.calledBySuccess.forEach(s=>{[...s.successCalls||[]].forEach(p=>{Ne.includes(p.type)&&p!==n&&(Se(n).find(m=>m===p)||i(s,p))});let l;if($e.includes(s.type)&&(l=s),l){const p=Oa(l);p.reachable||Se(n).find(m=>m===s)||p.blocks.forEach(m=>{i(s,m.blockedByCalling)})}}),n.calledByError.forEach(s=>{[...s.errorCalls||[]].forEach(p=>{Ne.includes(p.type)&&p!==n&&(Se(n).find(m=>m===p)||i(s,p))});let l;if($e.includes(s.type)&&(l=s),l){const p=Oa(l);p.reachable||Se(n).find(m=>m===s)||p.blocks.forEach(m=>{i(s,m.blockedByCalling)})}}),n.calledByEntry.forEach(s=>{if([...s.calls||[]].forEach(p=>{Ne.includes(p.type)&&p!==n&&(Se(n).find(m=>m===p)||i(s,p))}),s===a)return;let l;if(s.type===r.FunctionDeclaration){const p=ze(s);if(p.type===r.CustomEntity)return;p.type===r.Loop&&(l=p)}if(l){const p=Oa(l);p.reachable||p.blocks.forEach(y=>{i(s,y.blockedByCalling)})}}),{reachable:e.length===0,entryPoint:a,blocks:e}}function Z3(n){return Bo.includes(n.type)?n.type===r.FunctionDeclaration?!oI(n):!0:!1}function X3(n){if(r.ActionDescriptor===n.type){if(n.project.operationDeclarations.find(s=>s.id===n.id))return r.Operation;if(n.project.globalEventActionDescriptors.find(s=>s.id===n.id))return r.GlobalEvent;if(n.project.loopDeclarations.find(s=>s.id===n.id))return r.Loop;if(n.project.conditionDeclarations.find(s=>s.id===n.id))return r.Condition}return n.type}function Q3(n,e){const t=[];if(n.parent)if(n.id===n.parent)t.push(new E({id:`${n.id}--${n.parent}--${h.SelfReference}`,code:h.SelfReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to itself at 'parent'. This is not allowed. Change the reference string or the 'entityId' property of the reference object.`,issue:null}));else{const i=e.get(n.parent);i?[r.Project,r.DataType].includes(i.type)||t.push(new E({id:`${n.id}--${n.parent}--${h.InvalidParentReference}`,code:h.InvalidParentReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a parent reference that isn't pointing to an entity of type 'project' or 'data-type'.`,issue:null})):t.push(new E({id:`${n.id}--${n.parent}--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", is referencing an entity with id "${n.parent}" that isn't yet found in the project. Perhaps it should be created first. Or perhaps the ID is incorrect.`,issue:null}))}return n.implements&&Array.isArray(n.implements)?n.implements.forEach(i=>{if(n.id===i){t.push(new E({id:`${n.id}--${i}--${h.SelfReference}`,code:h.SelfReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has a reference to itself at one of the 'implements' references. This is not allowed. Change the reference string or the 'entityId' property of the reference object.`,issue:null}));return}const a=e.get(i);a?[r.CustomEntity,r.BuiltInBaseEntity].includes(a.type)?a.abstract||t.push(new E({id:`${n.id}--${i}--${h.InvalidImplementsReference}`,code:h.InvalidImplementsReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has an 'implements' reference that isn't pointing to an abstract entity.`,issue:null})):t.push(new E({id:`${n.id}--${i}--${h.InvalidImplementsReference}`,code:h.InvalidImplementsReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has an 'implements' reference that isn't pointing to an entity of type 'custom-entity' or 'built-in-base-entity'.`,issue:null})):t.push(new E({id:`${n.id}--${i}--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", is referencing an entity with id "${i}" that isn't yet found in the project. Perhaps it should be created first. Or perhaps the ID is incorrect.`,issue:null}))}):t.push(new E({id:`${n.id}--${D.InvalidObjectStructure}`,code:D.InvalidObjectStructure,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has an 'implements' property that isn't an array.`,issue:null})),n.extends&&Array.isArray(n.extends)&&n.extends.forEach(i=>{const a=e.get(i);a?[r.CustomEntity,r.BuiltInBaseEntity].includes(a.type)?a.abstract&&t.push(new E({id:`${n.id}--${i}--${h.InvalidExtendsReference}`,code:h.InvalidExtendsReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has an 'extends' reference that isn't pointing to a non-abstract entity. Did you want to use the property 'implements', which holds a list of references to absract entities, instead?`,issue:null})):t.push(new E({id:`${n.id}--${i}--${h.InvalidExtendsReference}`,code:h.InvalidExtendsReference,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", has an 'extends' reference that isn't pointing to an entity of type 'custom-entity' or 'built-in-base-entity'.`,issue:null})):t.push(new E({id:`${n.id}--${i}--${h.ReferencedEntityNotFound}`,code:h.ReferencedEntityNotFound,severity:T.Error,message:`Entity of type "${n.type}" with id "${n.id}", is referencing an entity with id "${i}" that isn't yet found in the project. Perhaps it should be created first. Or perhaps the ID is incorrect.`,issue:null}))}),t}const Pe=class Pe{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"name");c(this,"description",null);c(this,"x");c(this,"y");c(this,"static");c(this,"abstract");c(this,"type",r.CustomEntity);c(this,"properties",[]);c(this,"methods",[]);c(this,"abstractMethods",[]);c(this,"extends",[]);c(this,"implements",[]);c(this,"project");c(this,"errors",[]);c(this,"parent");c(this,"initialized",!1);c(this,"suggestedProperties",[]);c(this,"suggestedMethods",[]);this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.name=e.name,this.x=e.x,this.y=e.y,this.static=e.static,this.abstract=e.abstract}static fromGenerationTarget(e,t){let i=t;if(e.parent){const p=C(e.parent);i=t.get(p)}const a=[];e.implements&&e.implements.forEach(p=>{a.push(t.get(p)||t.getBuiltIn(p))});const s=[];e.extends&&e.extends.forEach(p=>{s.push(t.get(p)||t.getBuiltIn(p))});const o={id:e.id,version:1,name:e.name,type:r.CustomEntity,description:e.description,static:e.static,abstract:e.abstract,properties:[],methods:[],abstractMethods:[],extends:s,implements:a,x:0,y:0,parent:i},l=R(o,t);return l.setParent(i),l.initChildren(),l}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[],s=Q3(i,t),o=lo(i,t);a.push(...s,...o,...Be(i));const l=i.parent?t.get(i.parent):null;if(l&&l.type===r.DataType){const p=l;p.entity&&a.push(new E({id:`${e.id}--${h.NewEntityWouldOverriteExisting}`,code:h.NewEntityWouldOverriteExisting,severity:T.Error,message:`The entity of type '${e.type}' with id '${e.id}' can't be added to the 'parent' entity with id '${p.id}' because it already has an 'entity' child. Data type entities can only have one 'entity' as children.
|
|
371
371
|
You can inspect the existing 'entity' field with the 'describe_entity' action. Like so:
|
|
372
372
|
${an({describe_entity:p.entity.id})}
|
|
373
|
-
Alternatively you can update the parent data-type entity with 'update' action to remove the existing value of the field.`,issue:null}))}return{errors:a,modifiedData:i}}get extendedProperties(){return v([...this.extends.reduce((e,t)=>[...[...t.properties,...t.extendedProperties].filter(a=>!a.abstract),...e],[]),...this.implements.reduce((e,t)=>[...[...t.properties,...t.extendedProperties].filter(a=>!a.abstract),...e],[])])}validateGeneratedUpdate(e){const t=[];return e.parent&&t.push(new E({id:`${this.id}--${h.InvalidParentUpdate}`,code:h.InvalidParentUpdate,severity:T.Error,message:`Entity of type '${this.type}' with id '${this.id}' cannot have the 'parent' property updated. The 'parent' on an '${this.type}', must be the root project as it is a globally declared entity.`,issue:null})),{errors:t,modifiedData:e}}addSelfToProject(){const e=[this];if(this.parent.type===r.DataType){const t=this.parent;t.entity=this,e.push(t)}else this.project.addCustomEntity(this);return{affected:v(e),self:this}}setParent(e){return this.parent=e,this}removeProperty(e){return this.properties=this.properties.filter(t=>t.id!==e.id),this}addMethod(e){return this.methods.includes(e)||(this.methods.push(e),this.suggestedMethods=this.suggestedMethods.filter(t=>t.name!==e.name)),this}removeMethod(e){return this.methods=this.methods.filter(t=>t.id!==e.id),this}addProperty(e){return this.properties.includes(e)||(this.properties.push(e),this.suggestedProperties=this.suggestedProperties.filter(t=>t.name!==e.name)),this}addSuggestedProperty(e){return this.suggestedProperties.includes(e)||this.suggestedProperties.push(e),this}addSuggestedMethod(e){return this.suggestedMethods.includes(e)||this.suggestedMethods.push(e),this}removeSuggestedProperty(e){return this.suggestedProperties=this.suggestedProperties.filter(t=>t.id!==e.id),this}removeSuggestedMethod(e){return this.suggestedMethods=this.suggestedMethods.filter(t=>t.id!==e.id),this}addAbstractMethod(e){return this.abstractMethods.includes(e)||this.abstractMethods.push(e),this}removeAbstractMethod(e){return this.abstractMethods=this.abstractMethods.filter(t=>t.id!==e.id),this}initChildren(){return this.initialized?this:(this.initialized=!0,this.properties=this.initialData.properties.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this.methods=this.initialData.methods.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this.abstractMethods=this.initialData.abstractMethods.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this.extends=this.initialData.extends.map(e=>R(e,this.project)),this.implements=this.initialData.implements.map(e=>R(e,this.project)),this.addSuggestions(),this)}addSuggestions(){return this.implements.forEach(e=>{w8(this,e).forEach(a=>{const s=a.toJSON();s.id=`_suggestion--parent--${this.id}--${a.id}`;const o=R(s,this.project);o.suggestion=!0,o.setParent(this),o.initChildren(),this.addSuggestedProperty(o)}),_8(this,e).forEach(a=>{const s=`_suggestion--parent--${this.id}--${a.id}`,o=a.implementAsFunctionDeclaration(s),l=R(o,this.project);if(l.suggestion=!0,l.setParent(this),l.initChildren(),l.inputs.forEach(p=>{p.suggestion=!0}),l.returnStatements.length){const p=l.returnStatements[0];p.suggestion=!0,p.outputs.forEach(y=>{y.suggestion=!0})}this.addSuggestedMethod(l)})}),this}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}sync(e){return this.version=e.version||this.version,this.name=e.name||this.name,this.x=e.x||this.x,this.y=e.y||this.y,this.static=e.static||this.static,this.abstract=e.abstract||this.abstract,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){const i=[],a=[];return t.has(this.id)?{affected:[],removed:[]}:(t.add(this.id),a.push(this),this.unsubscribe(),this.properties.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.methods.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.abstractMethods.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.suggestedProperties.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.suggestedMethods.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),{affected:v(i),removed:v(a)})}restore({seenEntities:e}={seenEntities:new Set}){const t=[];return e.has(this.id)?{affected:[],self:this}:(e.add(this.id),this.subscribe(),this.properties.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.methods.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.abstractMethods.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.suggestedProperties.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.suggestedMethods.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),{affected:v(t),self:this})}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.extends.flatMap(i=>i.toFlat(e)),...this.implements.flatMap(i=>i.toFlat(e)),...this.properties.flatMap(i=>i.toFlat(e)),...this.methods.flatMap(i=>i.toFlat(e)),...this.abstractMethods.flatMap(i=>i.toFlat(e))])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.extends.flatMap(i=>i.toFlatIds(e)),...this.implements.flatMap(i=>i.toFlatIds(e)),...this.properties.flatMap(i=>i.toFlatIds(e)),...this.methods.flatMap(i=>i.toFlatIds(e)),...this.abstractMethods.flatMap(i=>i.toFlatIds(e))])}toJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,x:this.x,y:this.y,static:this.static,abstract:this.abstract,properties:this.properties.map(e=>e.toJSON()),methods:this.methods.map(e=>e.toJSON()),abstractMethods:this.abstractMethods.map(e=>e.toJSON()),implements:this.implements.map(e=>e.toJSON()),extends:this.extends.map(e=>e.toJSON()),parent:this.parent.toReference()}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,name:this.name,description:this.description,type:this.type,x:this.x,y:this.y,static:this.static,abstract:this.abstract,properties:this.properties.map(e=>e.toReference()),methods:this.methods.map(e=>e.toReference()),abstractMethods:this.abstractMethods.map(e=>e.toReference()),implements:this.implements.map(e=>e.toReference()),extends:this.extends.map(e=>e.toReference()),parent:this.parent.toReference()}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.properties.flatMap(i=>i.toFlatJSON(e)),...this.methods.flatMap(i=>i.toFlatJSON(e)),...this.abstractMethods.flatMap(i=>i.toFlatJSON(e)),...this.implements.flatMap(i=>i.toFlatJSON(e)),...this.extends.flatMap(i=>i.toFlatJSON(e))])}toGenerationTarget(){const e=this.parent.type===r.Project?void 0:this.parent.id;return{id:this.id,name:this.name,description:this.description,type:this.type,static:this.static,abstract:this.abstract,extends:this.extends.map(t=>t.id),implements:this.implements.map(t=>t.id),parent:e}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.properties.flatMap(i=>i.toFlatGenerationTarget(e)),...this.methods.flatMap(i=>i.toFlatGenerationTarget(e)),...this.abstractMethods.flatMap(i=>i.toFlatGenerationTarget(e)),...this.implements.filter(i=>i.type===r.CustomEntity).flatMap(i=>i.toFlatGenerationTarget(e)),...this.implements.filter(i=>i.type===r.CustomEntity).flatMap(i=>i.toFlatGenerationTarget(e))])}clearErrors(){return this.errors=[],this.properties.forEach(e=>e.clearErrors()),this.methods.forEach(e=>e.clearErrors()),this.abstractMethods.forEach(e=>e.clearErrors()),this}validate(){return this.errors=B8(this),{success:!0,error:null,data:null}}getErrors(){return[...this.errors,...this.properties.flatMap(t=>t.getErrors()),...this.methods.flatMap(t=>t.getErrors()),...this.abstractMethods.flatMap(t=>t.getErrors())]}getShallowErrors(){return this.errors}clone(e=null,t=null,i=!0){var b,g,I;const a=this.toJSON(),s=t||Ke(S(this,this.project),r.CustomEntity,this.project);a.properties=[],a.methods=[],a.abstractMethods=[];const o=s.split("-id"),l=o[o.length-1||0]||s;a.id=s;const p=Ut(a,this.project);e&&p.setParent(e),i&&p.subscribe(),p.initChildren();const y=(b=this.properties)==null?void 0:b.map((P,B)=>P.clone(this,l+"-property-"+B+"-id",i));p.properties=y;const f=(g=this.methods)==null?void 0:g.map((P,B)=>P.clone(this,l+"-method-"+B+"-id",i));p.methods=f;const m=(I=this.abstractMethods)==null?void 0:I.map((P,B)=>P.clone(this,l+"-abstract-method-"+B+"-id",i));return p.abstractMethods=m,p}getFunctionDeclaration(e){return this.methods.find(t=>t.id===e)}implement(e,t){return Eo(this,e,t)}getAllInteractiveMethods(){const e=this.implements.filter(i=>i.type===r.CustomEntity||i.type===r.BuiltInBaseEntity&&i.interactive);return v([...this.methods,...this.extends.flatMap(i=>i.getAllInteractiveMethods()),...e.flatMap(i=>i.getAllInteractiveMethods())])}inferFromInputs(e){if(this.parent.type!==r.DataType||!this.parent.inferred)return this;const t=[];e.forEach(s=>{t.find(l=>S(l,this.project)===S(s,this.project))||t.push(s)});const i=this.properties.filter(s=>!s.getDataType());t.forEach(s=>{const o=i.find(m=>S(m,this.project)===S(s,this.project));if(!o)return;const p=Er(s.parent).getMasterInputWithValueWritterFromAllInstances(s),y=rn(p),f=y==null?void 0:y.clone(o,o.id+"--data-type",!0);f&&o.setDataType(f),s.setDeclaration(o)});const a=[];return t.forEach(s=>{if(!s.declaration){a.push(s);return}}),a.length===0?this:(a.forEach(s=>{const o=this.properties.find(g=>S(g,this.project)===S(s,this.project));if(o){if(s.setDeclaration(o),!o.getDataType()){const I=Er(s.parent).getMasterInputWithValueWritterFromAllInstances(s),P=rn(I),B=P==null?void 0:P.clone(o,o.id+"--data-type",!0);B&&o.setDataType(B)}return}const l={id:s.id+"--inferred-property",type:r.Property,version:1,name:S(s,this.project),description:s.description,static:!0,abstract:!1,private:!1,hidden:!1,required:!1,index:s.index,implements:null,dataType:null,parent:this.toReference()},p=R(l,this.project);p.setParent(this),p.initChildren();const f=Er(s.parent).getMasterInputWithValueWritterFromAllInstances(s),m=rn(f),b=m==null?void 0:m.clone(p,l.id+"--data-type",!0);return b&&p.setDataType(b),this.addProperty(p),s.setDeclaration(p),p}),this)}};c(Pe,"MUTABLE_BASE_PROPERTIES",["name","description","static","abstract"]),c(Pe,"INMUTABLE_BASE_PROPERTIES",["id","version","type"]),c(Pe,"BASE_PROPERTIES",[...Pe.MUTABLE_BASE_PROPERTIES,...Pe.INMUTABLE_BASE_PROPERTIES]),c(Pe,"MUTABLE_META_PROPERTIES",[...Pe.MUTABLE_BASE_PROPERTIES,"x","y"]),c(Pe,"INMUTABLE_META_PROPERTIES",[...Pe.INMUTABLE_BASE_PROPERTIES]),c(Pe,"META_PROPERTIES",[...Pe.MUTABLE_META_PROPERTIES,...Pe.INMUTABLE_META_PROPERTIES]),c(Pe,"MUTABLE_UPSTREAM_PROPERTIES",["extends","implements"]),c(Pe,"INMUTABLE_UPSTREAM_PROPERTIES",["parent"]),c(Pe,"UPSTREAM_PROPERTIES",[...Pe.MUTABLE_UPSTREAM_PROPERTIES,...Pe.INMUTABLE_UPSTREAM_PROPERTIES]),c(Pe,"MUTABLE_DOWNSTREAM_PROPERTIES",["properties","methods","abstractMethods"]),c(Pe,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(Pe,"DOWNSTREAM_PROPERTIES",[...Pe.MUTABLE_DOWNSTREAM_PROPERTIES,...Pe.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(Pe,"PROPERTIES",[...Pe.META_PROPERTIES,...Pe.UPSTREAM_PROPERTIES,...Pe.DOWNSTREAM_PROPERTIES]);let Nr=Pe;function K3(n){const e=oU(),t=n.toJSON();e.safeParse(t).success;const a=[];return ne(n.errors,a)}class Gt{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"name");c(this,"description",null);c(this,"type",r.BuiltInBaseEntity);c(this,"abstract",!1);c(this,"static");c(this,"properties",[]);c(this,"methods",[]);c(this,"abstractMethods",[]);c(this,"extends",[]);c(this,"interactive",!1);c(this,"errors",[]);c(this,"project");this.initialData=this.initialData||e,this.project=this.project||t,this.id=this.id||e.id,this.version=this.version||e.version,this.name=this.name||e.name,this.static=this.static||e.static,this.interactive=this.interactive||e.interactive,this.abstract=e.abstract,this.properties=this.initialData.properties.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.methods=this.initialData.methods.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.abstractMethods=this.initialData.abstractMethods.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.extends=this.initialData.extends.map(i=>R(i,this.project))}get extendedProperties(){return v(this.extends.reduce((e,t)=>{const i=[...t.properties,...t.extendedProperties].filter(a=>!a.abstract);return[...e,...i]},[]))}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}async load(){return this}remove(e={ignoreUpstream:!1,seenEntities:new Set}){return{affected:[],removed:[]}}restore({seenEntities:e}={seenEntities:new Set}){return{affected:[],self:this}}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.properties.flatMap(i=>i.toFlat(e)),...this.methods.flatMap(i=>i.toFlat(e)),...this.abstractMethods.flatMap(i=>i.toFlat(e)),...this.extends.flatMap(i=>i.toFlat(e))])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.properties.flatMap(i=>i.toFlatIds(e)),...this.methods.flatMap(i=>i.toFlatIds(e)),...this.abstractMethods.flatMap(i=>i.toFlatIds(e)),...this.extends.flatMap(i=>i.toFlatIds(e))])}toJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,abstract:this.abstract,static:this.static,interactive:this.interactive,properties:this.properties.map(e=>e.toJSON()),methods:this.methods.map(e=>e.toJSON()),abstractMethods:this.abstractMethods.map(e=>e.toJSON()),extends:this.extends.map(e=>e.toJSON())}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,abstract:this.abstract,static:this.static,interactive:this.interactive,properties:this.properties.map(e=>e.toReference()),methods:this.methods.map(e=>e.toReference()),abstractMethods:this.abstractMethods.map(e=>e.toReference()),extends:this.extends.map(e=>e.toReference())}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.properties.flatMap(i=>i.toFlatJSON(e)),...this.methods.flatMap(i=>i.toFlatJSON(e)),...this.abstractMethods.flatMap(i=>i.toFlatJSON(e))])}toGenerationTarget(){return{id:this.id,type:this.type,name:this.name,description:this.description,static:this.static,abstract:this.abstract,interactive:this.interactive,extends:this.extends.map(e=>e.id)}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.properties.flatMap(i=>i.toFlatGenerationTarget(e)),...this.methods.flatMap(i=>i.toFlatGenerationTarget(e)),...this.abstractMethods.flatMap(i=>i.toFlatGenerationTarget(e))])}clearErrors(){return this.errors=[],this.properties.forEach(e=>e.clearErrors()),this.methods.forEach(e=>e.clearErrors()),this.abstractMethods.forEach(e=>e.clearErrors()),this}validate(){const e=K3(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors,...this.properties.flatMap(t=>t.getErrors()),...this.methods.flatMap(t=>t.getErrors()),...this.abstractMethods.flatMap(t=>t.getErrors())]}getShallowErrors(){return this.errors}clone(){return new Gt(this.toJSON(),this.project)}implement(e,t){return Eo(this,e,t)}getAllInteractiveMethods(){const e=[];return this.interactive&&(e.push(...this.methods),this.extends.filter(i=>i.type===r.BuiltInBaseEntity&&i.interactive||i.type===r.PrimitiveEntity).forEach(i=>{i instanceof Gt&&e.push(...i.getAllInteractiveMethods())})),v(e)}}function e5(n){const e=Q4(),t=n.toJSON();e.safeParse(t).success;const a=[];return ne(n.errors,a)}class Ft{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"name");c(this,"description",null);c(this,"type",r.PrimitiveEntity);c(this,"static");c(this,"abstract");c(this,"properties",[]);c(this,"methods",[]);c(this,"abstractMethods",[]);c(this,"extends",[]);c(this,"errors",[]);c(this,"project");this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.name=e.name,this.static=e.static,this.abstract=e.abstract,this.properties=this.initialData.properties.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.methods=this.initialData.methods.map(i=>{const a=R(i,this.project);return a.parent=this,a}),this.abstractMethods=this.initialData.abstractMethods.map(i=>{const a=R(i,this.project);return a.parent=this,a})}get extendedProperties(){return v(this.extends.reduce((e,t)=>{const i=[...t.properties,...t.extendedProperties].filter(a=>!a.abstract);return[...e,...i]},[]))}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}async load(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){return{affected:[],removed:[]}}restore({seenEntities:e}={seenEntities:new Set}){return{affected:[],self:this}}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.properties.flatMap(i=>i.toFlat(e)),...this.methods.flatMap(i=>i.toFlat(e)),...this.abstractMethods.flatMap(i=>i.toFlat(e))])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.properties.flatMap(i=>i.toFlatIds(e)),...this.methods.flatMap(i=>i.toFlatIds(e)),...this.abstractMethods.flatMap(i=>i.toFlatIds(e))])}toJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,static:this.static,abstract:this.abstract,properties:this.properties.map(e=>e.toJSON()),methods:this.methods.map(e=>e.toJSON()),abstractMethods:this.abstractMethods.map(e=>e.toJSON()),extends:this.extends.map(e=>e.toJSON())}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,abstract:this.abstract,static:this.static,properties:this.properties.map(e=>e.toReference()),methods:this.methods.map(e=>e.toReference()),abstractMethods:this.abstractMethods.map(e=>e.toReference()),extends:this.extends.map(e=>e.toReference())}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.properties.flatMap(i=>i.toFlatJSON(e)),...this.methods.flatMap(i=>i.toFlatJSON(e)),...this.abstractMethods.flatMap(i=>i.toFlatJSON(e))])}toGenerationTarget(){return{id:this.id,type:this.type,name:this.name,description:this.description,static:this.static,abstract:this.abstract,extends:this.extends.map(e=>e.id)}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.properties.flatMap(i=>i.toFlatGenerationTarget(e)),...this.methods.flatMap(i=>i.toFlatGenerationTarget(e)),...this.abstractMethods.flatMap(i=>i.toFlatGenerationTarget(e))])}clearErrors(){return this.errors=[],this.properties.forEach(e=>e.clearErrors()),this.methods.forEach(e=>e.clearErrors()),this.abstractMethods.forEach(e=>e.clearErrors()),this}validate(){const e=e5(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors,...this.properties.flatMap(t=>t.getErrors()),...this.methods.flatMap(t=>t.getErrors()),...this.abstractMethods.flatMap(t=>t.getErrors())]}getShallowErrors(){return this.errors}clone(){return new Ft(this.toJSON(),this.project)}getAllInteractiveMethods(){const e=[];return e.push(...this.methods),this.extends.filter(i=>i.type===r.BuiltInBaseEntity&&i.interactive||i.type===r.PrimitiveEntity).forEach(i=>{i instanceof Gt&&e.push(...i.getAllInteractiveMethods())}),v(e)}}function Ut(n,e){if(!n)throw new Error("Entity is null");const t=e.findSubscribedInstance(n);switch(n.type){case r.PrimitiveValue:return t||new Ti(n,e);case r.CustomEntity:return t||new Nr(n,e);case r.PrimitiveEntity:return t||new Ft(n,e);case r.FunctionDeclaration:return t||new gr(n,e);case r.GlobalEvent:return t||new fi(n,e);case r.DataType:return t||new hi(n,e);case r.Property:return t||new br(n,e);case r.FunctionCall:return t||new _r(n,e);case r.Condition:return t||new Dr(n,e);case r.Operation:return t||new vr(n,e);case r.VariableDeclaration:return t||new Pr(n,e);case r.VariableInstance:return t||new Ar(n,e);case r.OutputMap:return t||new vn(n,e);case r.ReturnDeclaration:return t||new _t(n,e);case r.ArgumentDeclaration:return t||new Cr(n,e);case r.InputMap:return t||new gn(n,e);case r.Project:return t||new w(n);case r.InstalledProject:return t||new Or(n,e);case r.ActionDescriptor:return t||new Fe(n,e);case r.ReturnStatement:return t||new Br(n,e);case r.Loop:return t||new Ir(n,e);case r.Search:return t||new Sr(n,e);case r.ValueDescriptor:return t||new wr(n,e);case r.BuiltInBaseEntity:return t||new Gt(n,e);case r.InternalCall:return t||new mi(n,e);case r.ContinueStatement:return t||new Tt(n,e);case r.BreakStatement:return t||new Ei(n,e);default:throw new Error("Invalid entity type: "+n.type)}}function R(n,e){if(!n)throw new Error("Entity is null");const t=Ut(n,e);return t.subscribe(),t}function t5(n,e){if(!n)throw new Error("Entity is null");switch(n.type){case r.PrimitiveValue:return Ti.fromGenerationTarget(n,e);case r.CustomEntity:return Nr.fromGenerationTarget(n,e);case r.FunctionDeclaration:return gr.fromGenerationTarget(n,e);case r.GlobalEvent:return fi.fromGenerationTarget(n,e);case r.DataType:return hi.fromGenerationTarget(n,e);case r.Property:return br.fromGenerationTarget(n,e);case r.FunctionCall:return _r.fromGenerationTarget(n,e);case r.Condition:return Dr.fromGenerationTarget(n,e);case r.Operation:return vr.fromGenerationTarget(n,e);case r.VariableDeclaration:return Pr.fromGenerationTarget(n,e);case r.VariableInstance:return Ar.fromGenerationTarget(n,e);case r.OutputMap:return vn.fromGenerationTarget(n,e);case r.ReturnDeclaration:return _t.fromGenerationTarget(n,e);case r.ArgumentDeclaration:return Cr.fromGenerationTarget(n,e);case r.InputMap:return gn.fromGenerationTarget(n,e);case r.InstalledProject:return Or.fromGenerationTarget(n,e);case r.ReturnStatement:return Br.fromGenerationTarget(n,e);case r.Loop:return Ir.fromGenerationTarget(n,e);case r.Search:return Sr.fromGenerationTarget(n,e);case r.ActionDescriptor:return Fe.fromGenerationTarget(n,e);case r.ValueDescriptor:return wr.fromGenerationTarget(n,e);case r.InternalCall:return mi.fromGenerationTarget(n,e);case r.ContinueStatement:return Tt.fromGenerationTarget(n,e);case r.BreakStatement:return Ei.fromGenerationTarget(n,e);default:throw new Error("Invalid entity type: "+n.type)}}const K=class K{constructor(e){c(this,"initialData");c(this,"id");c(this,"version");c(this,"type",r.Project);c(this,"name",null);c(this,"description",null);c(this,"x");c(this,"y");c(this,"entities",[]);c(this,"projects",[]);c(this,"functions",[]);c(this,"events",[]);c(this,"variableDeclarations",[]);c(this,"variableInstances",[]);c(this,"conditions",[]);c(this,"operations",[]);c(this,"functionCalls",[]);c(this,"loops",[]);c(this,"searches",[]);c(this,"primitives",[]);c(this,"builtInBaseEntities",[]);c(this,"operationDeclarations",[]);c(this,"globalEventActionDescriptors",[]);c(this,"loopDeclarations",[]);c(this,"conditionDeclarations",[]);c(this,"valueDescriptors",[]);c(this,"dataTypes",[]);c(this,"project");c(this,"instances",{});c(this,"builtInInstances",{});c(this,"errors",[]);c(this,"references",[]);this.initialData=e,this.id=e.id,this.version=e.version,this.name=e.name,this.description=e.description,this.x=0,this.y=0;try{(!K.UUID||K.UUID.isBackup)&&(K.UUID=Es==null?void 0:Es()),K.UUID||(K.UUID={isBackup:!0,uuid:()=>Math.random().toString(36).substring(2,15)+Math.random().toString(36).substring(2,15),fromUUID:t=>t})}catch(t){console.error("Error initializing UUID module",t),K.UUID={isBackup:!0,uuid:()=>Math.random().toString(36).substring(2,15)+Math.random().toString(36).substring(2,15),fromUUID:i=>i}}}static injectUUIDModule(e){K.UUID=e}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[];return a.push(...Be(i)),{errors:a,modifiedData:i}}async inject(...e){return await Promise.all(e.map(t=>new Promise(async i=>{await t.init(this),i(null)}))),this}validateGeneratedUpdate(e){return{errors:[],modifiedData:e}}addSelfToProject(){return{affected:v([]),self:this}}get instancesList(){return Object.values(this.instances)}isOperationDeclaration(e){return this.operationDeclarations.includes(e)}isGlobalEventActionDescriptor(e){return this.globalEventActionDescriptors.includes(e)}isLoopDeclaration(e){return this.loopDeclarations.includes(e)}isConditionDeclaration(e){return this.conditionDeclarations.includes(e)}initChildren(){return this.entities=this.initialData.entities.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.projects=this.initialData.projects.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.functions=this.initialData.functions.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.events=this.initialData.events.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.variableDeclarations=this.initialData.variableDeclarations.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.variableInstances=this.initialData.variableInstances.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.conditions=this.initialData.conditions.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.operations=this.initialData.operations.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.functionCalls=this.initialData.functionCalls.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.loops=this.initialData.loops.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.searches=this.initialData.searches.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.attachOrphanReferences(),this.validate(),this}subscribeInstance(e){return(!this.instances[e.id]||this.instances[e.id]!==e)&&(this.instances[e.id]=e),this}subscribeBuiltInInstance(e){return(!this.builtInInstances[e.id]||this.builtInInstances[e.id]!==e)&&(this.builtInInstances[e.id]=e),this}subscribe(){return this}unsubscribe(){return this}unsubscribeInstance(e){return delete this.instances[e.id],this}findSubscribedInstance(e){return this.instances[e.id]||null}findSubscribedBuiltInInstance(e){return this.builtInInstances[e.id]||null}get(e){return this.instances[e]||this.builtInInstances[e]||null}getManaged(e){return this.instances[e]||null}getBuiltIn(e){return this.builtInInstances[e]||null}findSubscribedInstanceFromReference(e){return this.instances[e.entityId]||null}findSubscribedBuiltInInstanceFromReference(e){return this.builtInInstances[e.entityId]||null}sync(e){return this.version=e.version||this.version,this.name=e.name||this.name,this.description=e.description||this.description,this.x=e.x||this.x,this.y=e.y||this.y,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e}={ignoreUpstream:!1}){return{affected:[],removed:[]}}restore({seenEntities:e}={seenEntities:new Set}){return{affected:[],self:this}}getAllBuiltInIds(){const e=new Set;return[...this.primitives.flatMap(t=>t.toFlatIds(e)),...this.builtInBaseEntities.flatMap(t=>t.toFlatIds(e)),...this.operationDeclarations.flatMap(t=>t.toFlatIds(e)),...this.globalEventActionDescriptors.flatMap(t=>t.toFlatIds(e)),...this.loopDeclarations.flatMap(t=>t.toFlatIds(e)),...this.conditionDeclarations.flatMap(t=>t.toFlatIds(e)),...this.valueDescriptors.flatMap(t=>t.toFlatIds(e)),...this.dataTypes.flatMap(t=>t.toFlatIds(e))]}getAllBuiltIn(){const e=new Set;return[...this.primitives.flatMap(t=>t.toFlat(e)),...this.builtInBaseEntities.flatMap(t=>t.toFlat(e)),...this.operationDeclarations.flatMap(t=>t.toFlat(e)),...this.globalEventActionDescriptors.flatMap(t=>t.toFlat(e)),...this.loopDeclarations.flatMap(t=>t.toFlat(e)),...this.conditionDeclarations.flatMap(t=>t.toFlat(e)),...this.valueDescriptors.flatMap(t=>t.toFlat(e)),...this.dataTypes.flatMap(t=>t.toFlat(e))]}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[...this.entities.flatMap(i=>i.toFlat(e)),...this.functions.flatMap(i=>i.toFlat(e)),...this.events.flatMap(i=>i.toFlat(e)),...this.projects.flatMap(i=>i.toFlat(e)),...this.variableDeclarations.flatMap(i=>i.toFlat(e)),...this.variableInstances.flatMap(i=>i.toFlat(e)),...this.conditions.flatMap(i=>i.toFlat(e)),...this.operations.flatMap(i=>i.toFlat(e)),...this.functionCalls.flatMap(i=>i.toFlat(e)),...this.loops.flatMap(i=>i.toFlat(e)),...this.searches.flatMap(i=>i.toFlat(e))])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),Array.from(e))}toJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,entities:this.entities.map(e=>e.toJSON()),functions:this.functions.map(e=>e.toJSON()),events:this.events.map(e=>e.toJSON()),projects:this.projects.map(e=>e.toJSON()),variableDeclarations:this.variableDeclarations.map(e=>e.toJSON()),variableInstances:this.variableInstances.map(e=>e.toJSON()),conditions:this.conditions.map(e=>e.toJSON()),operations:this.operations.map(e=>e.toJSON()),functionCalls:this.functionCalls.map(e=>e.toJSON()),loops:this.loops.map(e=>e.toJSON()),searches:this.searches.map(e=>e.toJSON())}}toReference(){return{id:this.id+"--"+K.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,entities:this.entities.map(e=>e.toReference()),functions:this.functions.map(e=>e.toReference()),events:this.events.map(e=>e.toReference()),projects:this.projects.map(e=>e.toReference()),variableDeclarations:this.variableDeclarations.map(e=>e.toReference()),variableInstances:this.variableInstances.map(e=>e.toReference()),conditions:this.conditions.map(e=>e.toReference()),operations:this.operations.map(e=>e.toReference()),functionCalls:this.functionCalls.map(e=>e.toReference()),loops:this.loops.map(e=>e.toReference()),searches:this.searches.map(e=>e.toReference())}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[...this.entities.flatMap(i=>i.toFlatJSON(e)),...this.functions.flatMap(i=>i.toFlatJSON(e)),...this.events.flatMap(i=>i.toFlatJSON(e)),...this.projects.flatMap(i=>i.toFlatJSON(e)),...this.variableDeclarations.flatMap(i=>i.toFlatJSON(e)),...this.variableInstances.flatMap(i=>i.toFlatJSON(e)),...this.conditions.flatMap(i=>i.toFlatJSON(e)),...this.operations.flatMap(i=>i.toFlatJSON(e)),...this.functionCalls.flatMap(i=>i.toFlatJSON(e)),...this.loops.flatMap(i=>i.toFlatJSON(e)),...this.searches.flatMap(i=>i.toFlatJSON(e))])}toGenerationTarget(){return{id:this.id,type:this.type,name:this.name,description:this.description}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[...this.entities.flatMap(i=>i.toFlatGenerationTarget(e)),...this.functions.flatMap(i=>i.toFlatGenerationTarget(e)),...this.events.flatMap(i=>i.toFlatGenerationTarget(e)),...this.projects.flatMap(i=>i.toFlatGenerationTarget(e)),...this.variableDeclarations.flatMap(i=>i.toFlatGenerationTarget(e)),...this.variableInstances.flatMap(i=>i.toFlatGenerationTarget(e)),...this.conditions.flatMap(i=>i.toFlatGenerationTarget(e)),...this.operations.flatMap(i=>i.toFlatGenerationTarget(e)),...this.functionCalls.flatMap(i=>i.toFlatGenerationTarget(e)),...this.loops.flatMap(i=>i.toFlatGenerationTarget(e)),...this.searches.flatMap(i=>i.toFlatGenerationTarget(e))])}clearErrors(){return this.errors=[],this.entities.forEach(e=>e.clearErrors()),this.projects.forEach(e=>e.clearErrors()),this.functions.forEach(e=>e.clearErrors()),this.events.forEach(e=>e.clearErrors()),this.variableDeclarations.forEach(e=>e.clearErrors()),this.variableInstances.forEach(e=>e.clearErrors()),this.conditions.forEach(e=>e.clearErrors()),this.operations.forEach(e=>e.clearErrors()),this.functionCalls.forEach(e=>e.clearErrors()),this.loops.forEach(e=>e.clearErrors()),this.searches.forEach(e=>e.clearErrors()),this}validate(){const e=D8(),t=this.toJSON();return e.safeParse(t),this.validateChildren(),{success:!0,error:null,data:t}}validateChildren(){this.entities.forEach(e=>e.validate()),this.projects.forEach(e=>e.validate()),this.functions.forEach(e=>e.validate()),this.events.forEach(e=>e.validate()),this.variableDeclarations.forEach(e=>e.validate()),this.variableInstances.forEach(e=>e.validate()),this.conditions.forEach(e=>e.validate()),this.operations.forEach(e=>e.validate()),this.functionCalls.forEach(e=>e.validate()),this.loops.forEach(e=>e.validate()),this.searches.forEach(e=>e.validate())}getErrors(){return[...this.errors,...this.entities.flatMap(t=>t.getErrors()),...this.projects.flatMap(t=>t.getErrors()),...this.functions.flatMap(t=>t.getErrors()),...this.events.flatMap(t=>t.getErrors()),...this.variableDeclarations.flatMap(t=>t.getErrors()),...this.variableInstances.flatMap(t=>t.getErrors()),...this.conditions.flatMap(t=>t.getErrors()),...this.operations.flatMap(t=>t.getErrors()),...this.functionCalls.flatMap(t=>t.getErrors()),...this.loops.flatMap(t=>t.getErrors()),...this.searches.flatMap(t=>t.getErrors())]}getShallowErrors(){return this.errors}clone(){return new K(this.toJSON())}getCustomEntity(e){return this.entities.find(t=>t.id===e)||null}addCustomEntityFromTransfer(e){const t=R(e,this);return this.addCustomEntity(t),t}addCustomEntity(e){return this.entities.includes(e)||this.entities.push(e),e}addFunctionDeclarationFromTransfer(e){const t=R(e,this);return this.addFunctionDeclaration(t),t}addFunctionDeclaration(e){return this.functions.includes(e)||this.functions.push(e),e}addFunctionCallFromTransfer(e){const t=R(e,this);return this.addFunctionCall(t),t}addFunctionCall(e){return this.functionCalls.includes(e)||this.functionCalls.push(e),e}addVariableDeclarationFromTransfer(e){const t=R(e,this);return this.addVariableDeclaration(t),t}addVariableDeclaration(e){return this.variableDeclarations.includes(e)||this.variableDeclarations.push(e),e}addVariableInstanceFromTransfer(e){const t=R(e,this);return this.addVariableInstance(t),t}addVariableInstance(e){return this.variableInstances.includes(e)||this.variableInstances.push(e),e}addInstalledProjectFromTransfer(e){const t=R(e,this);return this.addInstalledProject(t),this}addInstalledProject(e){return this.projects.includes(e)||this.projects.push(e),this}addGlobalEventFromTransfer(e){const t=R(e,this);return this.addGlobalEvent(t),this}addGlobalEvent(e){return this.events.includes(e)||this.events.push(e),this}addConditionFromTransfer(e){const t=R(e,this);return this.addCondition(t),this}addCondition(e){return this.conditions.includes(e)||this.conditions.push(e),this}addOperationFromTransfer(e){const t=R(e,this);return this.addOperation(t),this}addOperation(e){return this.operations.includes(e)||this.operations.push(e),this}addLoopFromTransfer(e){const t=R(e,this);return this.addLoop(t),this}addLoop(e){return this.loops.includes(e)||this.loops.push(e),this}addSearchFromTransfer(e){const t=R(e,this);return this.addSearch(t),this}addSearch(e){return this.searches.includes(e)||this.searches.push(e),this}removeCustomEntity(e){const t=this.entities.findIndex(i=>i.id===e.id);if(t>-1){const i=this.entities[t];return this.entities.splice(t,1),i}return null}removeFunctionDeclaration(e){const t=this.functions.findIndex(i=>i.id===e.id);if(t>-1){const i=this.functions[t];return this.functions.splice(t,1),i}return null}removeExternalProject(e){const t=this.projects.findIndex(i=>i.id===e.id);if(t>-1){const i=this.projects[t];return this.projects.splice(t,1),i}return null}removeGlobalEvent(e){const t=this.events.findIndex(i=>i.id===e.id);if(t>-1){const i=this.events[t];return this.events.splice(t,1),i}return null}removeTopLevelVariableDeclaration(e){if(e.type!==r.VariableDeclaration)return null;const t=this.variableDeclarations.findIndex(i=>i.id===e.id);if(t>-1){const i=this.variableDeclarations[t];return this.variableDeclarations.splice(t,1),i}return null}getEntryPoints(){return[...this.functions,...this.events,...this.entities.flatMap(t=>t.methods)]}getFunctionDeclaration(e){return this.functions.find(t=>t.id===e)||null}getConditions(){return[...this.conditions,...this.getEntryPoints().reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Condition)]},[]),...this.functionCalls.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Condition)]},[]),...this.operations.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Condition)]},[]),...this.loops.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Condition)]},[]),...this.searches.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Condition)]},[])]}getOperations(){return[...this.operations,...this.getEntryPoints().reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Operation)]},[]),...this.functionCalls.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Operation)]},[]),...this.conditions.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Operation)]},[]),...this.loops.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Operation)]},[]),...this.searches.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Operation)]},[])]}getFunctionCalls(){return[...this.functionCalls,...this.getEntryPoints().reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.FunctionCall)]},[]),...this.conditions.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.FunctionCall)]},[]),...this.operations.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.FunctionCall)]},[]),...this.loops.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.FunctionCall)]},[]),...this.searches.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.FunctionCall)]},[])]}getVariables(){return[...this.variableDeclarations,...this.getEntryPoints().reduce((t,i)=>{const a=te(i);return[...t,...a]},[]),...this.functionCalls.reduce((t,i)=>{const a=te(i);return[...t,...a]},[]),...this.conditions.reduce((t,i)=>{const a=te(i);return[...t,...a]},[]),...this.operations.reduce((t,i)=>{const a=te(i);return[...t,...a]},[]),...this.loops.reduce((t,i)=>{const a=te(i);return[...t,...a]},[]),...this.searches.reduce((t,i)=>{const a=te(i);return[...t,...a]},[])]}getVariableInstances(){return[...this.variableInstances,...this.getEntryPoints().reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[]),...this.functionCalls.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[]),...this.conditions.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[]),...this.operations.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[]),...this.loops.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[]),...this.searches.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[])]}getVariableDeclarations(){return v([...this.variableDeclarations,...this.getEntryPoints().reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[]),...this.functionCalls.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[]),...this.conditions.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[]),...this.operations.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[]),...this.loops.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[]),...this.searches.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[])])}attachOrphanReferences(){const e=this.getVariableInstances(),t=this.getVariableDeclarations();return e.forEach(i=>{if(!i.declaration){const a=i.initialData,s=a.declaration.entityId||a.declaration.id,o=t.find(l=>l.id===s);o&&i.setDeclaration(o)}}),this}getBuiltInPersistedEntity(){return this.builtInBaseEntities.find(e=>e.name===V.PERSISTED_ENTITY)||null}};c(K,"UUID",{isBackup:!0,uuid:()=>Math.random().toString(36).substring(2,15)+Math.random().toString(36).substring(2,15),fromUUID:e=>e}),c(K,"MUTABLE_BASE_PROPERTIES",["name","description"]),c(K,"INMUTABLE_BASE_PROPERTIES",["id","type","version"]),c(K,"BASE_PROPERTIES",[...K.MUTABLE_BASE_PROPERTIES,...K.INMUTABLE_BASE_PROPERTIES]),c(K,"MUTABLE_META_PROPERTIES",[...K.MUTABLE_BASE_PROPERTIES,"x","y"]),c(K,"INMUTABLE_META_PROPERTIES",[...K.INMUTABLE_BASE_PROPERTIES]),c(K,"META_PROPERTIES",[...K.MUTABLE_META_PROPERTIES,...K.INMUTABLE_META_PROPERTIES]),c(K,"MUTABLE_UPSTREAM_PROPERTIES",[]),c(K,"INMUTABLE_UPSTREAM_PROPERTIES",["primitives","builtInBaseEntities","operationDeclarations","globalEventActionDescriptors","loopDeclarations","builtInInstances"]),c(K,"UPSTREAM_PROPERTIES",[...K.MUTABLE_UPSTREAM_PROPERTIES,...K.INMUTABLE_UPSTREAM_PROPERTIES]),c(K,"MUTABLE_DOWNSTREAM_PROPERTIES",["entities","projects","functions","events","variableDeclarations","variableInstances","conditions","operations","functionCalls","loops","searches"]),c(K,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(K,"DOWNSTREAM_PROPERTIES",[...K.MUTABLE_DOWNSTREAM_PROPERTIES,...K.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(K,"PROPERTIES",[...K.META_PROPERTIES,...K.UPSTREAM_PROPERTIES,...K.DOWNSTREAM_PROPERTIES]);let w=K;class cI extends Fe{constructor(t){super(xt,t);c(this,"id",Oe.Parallel);c(this,"name",Oe.Parallel);c(this,"description","Execute a list of actions one after the other");c(this,"version",1);c(this,"autoexecutable",!0);c(this,"initialData",xt);c(this,"type",r.ActionDescriptor);c(this,"fixedArguments",[]);c(this,"fixedReturns",[]);c(this,"error",null);c(this,"dynamicArgumentTypes",null);c(this,"dynamicReturnTypes",null);c(this,"project");this.project=t,this.fixedArguments=xt.fixedArguments.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.fixedReturns=xt.fixedReturns.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.error=xt.error?R(xt.error,this.project):null}}class dI extends Fe{constructor(t){super(dt,t);c(this,"id",dt.id);c(this,"name",dt.name);c(this,"description",dt.description);c(this,"version",dt.version);c(this,"autoexecutable",!1);c(this,"initialData",dt);c(this,"type",r.ActionDescriptor);c(this,"fixedArguments",[]);c(this,"fixedReturns",[]);c(this,"error",null);c(this,"dynamicArgumentTypes",null);c(this,"dynamicReturnTypes",null);c(this,"project");this.project=t,this.fixedArguments=dt.fixedArguments.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.fixedReturns=dt.fixedReturns.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.error=dt.error?R(dt.error,this.project):null}}class uI extends Fe{constructor(t){super(dn,t);c(this,"id",Oe.Sequential);c(this,"name",Oe.Sequential);c(this,"description","Execute a list of actions one after the other");c(this,"version",1);c(this,"autoexecutable",!0);c(this,"initialData",dn);c(this,"type",r.ActionDescriptor);c(this,"fixedArguments",[]);c(this,"fixedReturns",[]);c(this,"error",null);c(this,"dynamicArgumentTypes",null);c(this,"dynamicReturnTypes",null);c(this,"project");this.project=t,this.fixedArguments=dn.fixedArguments.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.fixedReturns=dn.fixedReturns.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.error=dn.error?R(dn.error,this.project):null}}function n5(n){const e=[new uI(n),new cI(n),new dI(n),new Fe(Ii,n),new Fe(Xn,n),new Fe(Qn,n),new Fe(Na,n),new Fe($o,n),new Fe(Fo,n),new Fe(Go,n),new Fe(wa,n),new Fe(gi,n)];return e.forEach(t=>{t.initChildren(),n.subscribeBuiltInInstance(t)}),n.operationDeclarations=e,e}class pI extends Gt{constructor(t){super(Le,t);c(this,"initialData");c(this,"id",V.PERSISTED_ENTITY);c(this,"version",1);c(this,"name",V.PERSISTED_ENTITY);c(this,"description",Le.description);c(this,"type",r.BuiltInBaseEntity);c(this,"abstract",Le.abstract);c(this,"static",Le.static);c(this,"properties",[]);c(this,"methods",[]);c(this,"abstractMethods",[]);c(this,"extends",[]);c(this,"errors",[]);c(this,"project");this.initialData=Le,this.project=t,this.id=Le.id,this.version=Le.version,this.name=Le.name,this.static=Le.static,this.abstract=Le.abstract,this.properties=this.initialData.properties.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.methods=this.initialData.methods.map(i=>{const a=R(i,this.project);return a.parent=this,a}),this.abstractMethods=this.initialData.abstractMethods.map(i=>{const a=R(i,this.project);return a.parent=this,a}),this.extends=this.initialData.extends.map(i=>R(i,this.project))}}function r5(n){const e=[new pI(n),new Gt(ka,n),new Gt(On,n),new Gt(rl,n),new Gt(xa,n)];return e.forEach(t=>{n.subscribeBuiltInInstance(t)}),n.builtInBaseEntities=e,e}function i5(n){const e=[new Ft(k,n),new Ft(An,n),new Ft(Ce,n),new Ft(et,n),new Ft(Sn,n),new Ft(cn,n),new Ft(Ba,n),new Ft(_o,n)];return e.forEach(t=>{n.subscribeBuiltInInstance(t)}),n.primitives=e,e}function a5(n){const e=[new Fe(Ha,n)];return e.forEach(t=>{t.initChildren(),n.subscribeBuiltInInstance(t)}),n.globalEventActionDescriptors=e,e}function s5(n){const e=[new Fe(Kn,n),new Fe(zo,n)];return e.forEach(t=>{t.initChildren(),n.subscribeBuiltInInstance(t)}),n.loopDeclarations=e,e}function o5(n){const e=[new wr(ol,n)];return e.forEach(t=>{t.initChildren(),n.subscribeBuiltInInstance(t)}),n.valueDescriptors=e,e}function l5(n){const e=[new Fe(er,n),new Fe(Ur,n)];return e.forEach(t=>{t.initChildren()}),n.conditionDeclarations=e,e}const Vr={},Ao={};async function c5(n,e={}){const t={...Ib};return t.id=n.id,e.empty?{data:{id:n.id,type:r.Project,version:1,name:null,description:null,projects:[],entities:[],operations:[],functions:[],variableDeclarations:[],variableInstances:[],functionCalls:[],conditions:[],loops:[],searches:[],events:[]}}:{data:t}}function yI(n){const e=new w(n);return i5(e),r5(e),n5(e),a5(e),s5(e),o5(e),l5(e),e.initChildren(),e}async function d5(n,e={}){if(n.id&&Vr[n.id])return Vr[n.id];if(n.id&&Ao[n.id])return await Ao[n.id],Vr[n.id];const t=c5(n,e);n.id&&(Ao[n.id]=t);const i=await t;if(i.data){const a=yI(i.data);return Vr[n.id]=a,n.id&&delete Ao[n.id],a}return null}function u5(n){return Vr[n.id]&&delete Vr[n.id],null}const p5="test_primitive_entities_export";u.AI_VALUE_CONNECTION_GENERATION_ACTION_EXPLANATION=_d,u.ActionDescriptorState=Fe,u.ActionDescriptorValuesType=U,u.ActionInputMapState=l3,u.ActionOutputMapState=u3,u.AppendToListOperationInputIds=vp,u.AppendToListOperationOutputIds=Ip,u.ArgumentDeclarationState=Cr,u.BREAK_AND_CONTINUE_STATEMENTS_RETURN_DECLARATIONS_EXPLANATION=Od,u.BUILT_IN_BASE_ENTITY_IDS=x,u.BUILT_IN_ENTITY_TYPES=Gr,u.BaseCanvasDraggableState=W9,u.BaseEntityNames=V,u.BaseState=J9,u.BaseValueDescriptorIds=wo,u.BreakStatementState=Ei,u.BuiltInBaseEntityState=Gt,u.CACHED_PROJECTS_BY_ID=Vr,u.CALLABLE_ENTITIES_EXPLANATION=I3,u.CALLABLE_TYPES=Pn,u.CALLER_ENTITIES_EXPLANATION=Av,u.CALLER_TYPES=ln,u.CALLS_UPDATE_EXPLANATION=qn,u.COMPARISON_CONDITIONS=Dm,u.CONDITIONS=qI,u.CUSTOM_ENTITY_OPERATIONS=Uy,u.CallableEntityClass=Y9,u.CallerEntityClass=Dd,u.ChildEntityState=H9,u.ComparisonOperatorTypes=_e,u.ConditionState=Dr,u.ContinueStatementState=Tt,u.CreateNewInputIds=yy,u.CreateNewOutputIds=hy,u.CustomEntityState=Nr,u.DRAGGABLE_CALLABLE_TYPES=Co,u.DRAGGABLE_CALLER_TYPES=zd,u.DRAGGABLE_ELEMENT_TYPES=Bo,u.DRAGGABLE_EXECUTABLE_TYPES=TI,u.DRAGGABLE_PASS_THROUGH_CALLABLE_TYPES=Oo,u.DataTypeCompatibilityTypes=Lt,u.DataTypeParentChildRelation=Ue,u.DataTypeState=hi,u.ENTITIES_WITH_VALLUES_EXPLANATION=yo,u.ENTITY_TYPES=EI,u.ENTITY_WITH_LOGIC_SCOPE_TYPES=ct,u.ENTITY_WITH_NAMES_TYPES=Zd,u.ENTITY_WITH_VALUE_TYPES=Yd,u.ENTRY_POINT_ENTITIES_EXPLANATION=Ia,u.ENTRY_POINT_TYPES=Me,u.EVENT_TYPES=Lr,u.EXECUTABLE_TYPES=mI,u.EXECUTION_OPERATIONS=py,u.EntityError=cr,u.EntityErrorSeverity=T,u.EntityGenerationError=E,u.EntityGenerationErrorCode=h,u.EntityInstanceErrorCode=_,u.EntityOperations=Ze,u.EntityType=r,u.EntityWithLogicScopeClass=Q9,u.EntityWithValueClass=X9,u.EntryPointEntityClass=z9,u.ExecutionOperations=Oe,u.FunctionCallState=_r,u.FunctionDeclarationState=gr,u.GLOBAL_EVENT_DECLARATIONS=JI,u.GetLastInListOperationInputIds=dp,u.GetLastInListOperationOutputIds=up,u.GlobalEventNames=on,u.GlobalEventState=fi,u.HTTPOperations=Xe,u.HTTP_OPERATIONS=bh,u.InputMapState=gn,u.InstalledProjectState=Or,u.InternalCallState=mi,u.JoinListOperationInputIds=Bu,u.JoinListOperationOutputIds=wu,u.JoinStringOperationInputIds=mu,u.JoinStringOperationOutputIds=Tu,u.LIST_OPERATIONS=$p,u.ListOperations=W,u.LoopState=Ir,u.LoopTypes=Q,u.NON_INTERACTIVE_BASE_ENTITIES_EXPLANATION=Jn,u.NUMBER_OPERATIONS=fu,u.NumberAdditionOperationInputIds=nu,u.NumberAdditionOperationOutputIds=ru,u.NumberOperations=lt,u.OPERATION_DECLARATIONS=gI,u.OperationState=vr,u.OutputMapParentChildRelation=Hd,u.OutputMapState=vn,u.PARENT_AUTO_CALCULATION_FROM_CALLER_EXPLANATION=ho,u.PASS_THROUGH_CALLABLE_ENTITIES_EXPLANATION=jn,u.PASS_THROUGH_CALLABLE_TYPES=$e,u.PROPERTY_NOT_VALUE_READER_WRITTER_EXPLANATION=wd,u.ParallelExecutionOperation=cI,u.ParallelExecutionOperationInputIds=Lp,u.ParallelExecutionOperationOutputIds=Gp,u.PassThroughCallableEntityClass=Z9,u.PersistedEntity=pI,u.PersistedEntityMethods=Ot,u.PrimitiveEntityState=Ft,u.PrimitiveTypes=A,u.PrimitiveValueState=Ti,u.ProjectState=w,u.PropertyState=br,u.RETURN_STATEMENT_RETURN_DECLARATIONS_EXPLANATION=D3,u.ReturnDeclarationState=_t,u.ReturnStatementState=Br,u.STANDALONE_CONDITIONS=Em,u.STRING_OPERATIONS=Cu,u.ScopeCompatibilityType=Po,u.SearchState=Sr,u.SequentialExecutionOperation=uI,u.SequentialExecutionOperationInputIds=ty,u.SequentialExecutionOperationOutputIds=ny,u.SharedEntityErrorCode=D,u.SharedStateFunctionality=Iv,u.SplitListOperationInputIds=Wu,u.SplitListOperationOutputIds=Hu,u.StandaloneOperatorTypes=Nt,u.StringOperations=Ae,u.TERMINATION_TYPES=Ne,u.USER_MANAGED_ENTITY_TYPES=RI,u.UserManagedEntityStateFunctionality=q9,u.VALUE_READING_ENTITIES_EXPLANATION=Bd,u.VALUE_READING_TYPES=zn,u.VALUE_WRITING_ENTITIES_EXPLANATION=Sv,u.VALUE_WRITING_TYPES=Ve,u.VARIABLE_DATA_TYPE_INFERRANCE_EXPLANATION=Cd,u.VARIABLE_TYPES=xe,u.ValidationInputIds=Ay,u.ValidationOutputIds=Sy,u.ValueAutogenerationType=qe,u.ValueDescriptorParentChildRelation=M,u.ValueDescriptorState=wr,u.ValueReadingEntityClass=ga,u.ValueWritingEntityClass=va,u.VariableDeclarationState=Pr,u.VariableInputMapState=o3,u.VariableInstanceState=Ar,u.VariableOutputMapState=d3,u.WaitOperation=dI,u.WaitOperationInputIds=Yp,u.WaitOperationOutputIds=zp,u._VALUE_READING_TYPES=hI,u._VALUE_WRITING_TYPES=fI,u.appendToListOperation=Na,u.appendToListOperationElementToAppendArgument=xo,u.appendToListOperationElementToAppendArgumentParentRef=wp,u.appendToListOperationElementToAppendArgumentRef=Ap,u.appendToListOperationError=Vp,u.appendToListOperationErrorParentRef=Np,u.appendToListOperationListArgument=Uo,u.appendToListOperationListArgumentParentRef=Bp,u.appendToListOperationListArgumentRef=Dp,u.appendToListOperationListDataType=Pp,u.appendToListOperationResultListDataType=Cp,u.appendToListOperationResultListReturn=Mp,u.appendToListOperationResultListReturnParentRef=_p,u.appendToListOperationResultListReturnRef=Op,u.appendToListOperationSecondListDataType=Sp,u.asGenerationActionExample=an,u.baseHttpRequestFunctionDeclaration=Ii,u.baseHttpRequestFunctionDeclarationErrorValueDescriptor=Yo,u.baseHttpRequestFunctionDeclarationErrorValueDescriptorDatatype=Rh,u.baseHttpRequestFunctionDeclarationErrorValueDescriptorRef=Eh,u.baseHttpRequestFunctionDeclarationRef=hh,u.baseHttpRequestFunctionDeclarationRefEight=mh,u.baseHttpRequestFunctionDeclarationRefFive=ph,u.baseHttpRequestFunctionDeclarationRefFour=uh,u.baseHttpRequestFunctionDeclarationRefNine=Th,u.baseHttpRequestFunctionDeclarationRefSeven=fh,u.baseHttpRequestFunctionDeclarationRefSix=yh,u.baseHttpRequestFunctionDeclarationRefThree=dh,u.baseHttpRequestFunctionDeclarationRefTwo=ch,u.booleanPrototype=An,u.capitalizeFirstLetter=io,u.checkAreCustomEntitiesCompatibleAsDataType=lv,u.checkAreDataTypesCompatible=Ht,u.checkArePropertiesCompatibleAsDataType=ov,u.checkIsBranchDependentButNotDirectlyOnBranch=Pa,u.checkIsBranchDependentOnBranch=M3,u.checkIsCallableEntityReachable=Oa,u.checkIsCanvasEntity=Z3,u.checkIsDetachedBranch=rI,u.checkIsDetachedBranchShallow=Jd,u.checkIsGlobalVariable=Y3,u.checkIsGloballyDeclared=qd,u.checkIsMethod=sI,u.checkIsNestedScope=Do,u.checkScopeCompatibility=Aa,u.createEntityError=H,u.createNewInstanceOperation=Xn,u.createNewInstanceOperationEntityToInstanciateArgument=gy,u.createNewInstanceOperationEntityToInstanciateArgumentRef=Ey,u.createNewInstanceOperationEntityToInstanciateDataType=Ry,u.createNewInstanceOperationError=Py,u.createNewInstanceOperationErrorParentRef=Dy,u.createNewInstanceOperationNewEntityDataArgument=bI,u.createNewInstanceOperationNewEntityDataArgumentDataType=Ty,u.createNewInstanceOperationNewEntityDataArgumentDataTypeParentRef=my,u.createNewInstanceOperationNewEntityDataArgumentParentRef=fy,u.createNewInstanceOperationOutputEntityDeclaration=Iy,u.createNewInstanceOperationOutputEntityDeclarationParentRef=vy,u.createNewInstanceOperationRef=by,u.createSemanticId=Ke,u.createStateFromGenerationTargetType=t5,u.createStateFromType=Ut,u.createStateFromTypeAndSubscribe=R,u.cronJobBuiltInBaseEntity=rl,u.cronJobBuiltInBaseEntityExpressionProperty=hm,u.cronJobBuiltInBaseEntityExpressionPropertyDataTypeRef=xI,u.cronJobBuiltInBaseEntityExpressionPropertyRef=pm,u.cronJobBuiltInBaseEntityRef=ym,u.cronJobTriggeredFunctionDeclarationBlueprint=nl,u.cronJobTriggeredFunctionDeclarationBlueprintParentRef=dm,u.customEntityToZodSchema=km,u.dataTypeCompatibilityToErrorExplanation=Vv,u.datePrototype=cn,u.dateValueAutogenerationSchema=pc,u.deletePersistedEntityMethod=tl,u.deletePersistedEntityMethodParentRef=kf,u.deleteRootProject=u5,u.endpointBuiltInBaseEntity=ka,u.endpointBuiltInBaseEntityRef=xh,u.endpointBuiltInBaseEntityRefFour=Bf,u.endpointBuiltInBaseEntityRefThree=Zh,u.endpointBuiltInBaseEntityRefTwo=Wh,u.endpointBuiltInCorsProperty=kh,u.endpointBuiltInCorsPropertyDataType=Uh,u.endpointBuiltInCorsPropertyDataTypeRef=Gh,u.endpointBuiltInCorsPropertyRef=Fh,u.endpointBuiltInMethodProperty=Xo,u.endpointBuiltInMethodPropertyDataType=zh,u.endpointBuiltInMethodPropertyDataTypeRef=Hh,u.endpointBuiltInMethodPropertyRef=Yh,u.endpointBuiltInPathProperty=Zo,u.endpointBuiltInPathPropertyDataType=Jh,u.endpointBuiltInPathPropertyDataTypeRef=jh,u.endpointBuiltInPathPropertyRef=qh,u.endpointPathParamsArgumentDeclaration=pf,u.endpointPathParamsArgumentDeclarationRef=of,u.endpointPathParamsVariableDataType=lf,u.endpointPathParamsVariableDataTypeRef=sf,u.endpointReachedTriggerActionDescriptor=Qo,u.endpointReachedTriggerActionDescriptorRef=cf,u.endpointReachedTriggerActionDescriptorRefFour=ff,u.endpointReachedTriggerActionDescriptorRefThree=yf,u.endpointReachedTriggerActionDescriptorRefTwo=uf,u.endpointRequestBodyArgumentDeclaration=mf,u.endpointRequestBodyArgumentDeclarationRef=ef,u.endpointRequestBodyVariableDataType=tf,u.endpointRequestHeadersArgumentDeclaration=df,u.endpointRequestHeadersArgumentDeclarationRef=Qh,u.endpointRequestHeadersVariableDataType=Kh,u.endpointRequestHeadersVariableDataTypeRef=Xh,u.endpointRequestQueryParamsArgumentDeclaration=hf,u.endpointRequestQueryParamsArgumentDeclarationRef=rf,u.endpointRequestQueryParamsVariableDataType=af,u.endpointRequestQueryParamsVariableDataTypeRef=nf,u.endpointResponseBodyDataType=Sf,u.endpointResponseBodyReturnDeclaration=Cf,u.endpointResponseBodyReturnDeclarationRef=Af,u.endpointResponseCodeDataType=Ef,u.endpointResponseCodeReturnDeclaration=bf,u.endpointResponseCodeReturnDeclarationRef=Tf,u.endpointResponseHeadersDataType=If,u.endpointResponseHeadersDataTypeRef=gf,u.endpointResponseHeadersReturnDeclaration=Pf,u.endpointResponseHeadersReturnDeclarationRef=vf,u.endpointReturnStatementRef=Rf,u.endpointReturnStatementRefThree=Of,u.endpointReturnStatementRefTwo=Df,u.enumOptionsProperty=tu,u.enumOptionsPropertyDataType=Kd,u.enumOptionsPropertyDataTypeRef=Xd,u.enumOptionsPropertyRef=Qd,u.enumPrototype=Sn,u.enumPrototypeRef=eu,u.executionBuiltInEntity=al,u.executionBuiltInEntityAbortMethod=il,u.executionBuiltInEntityAbortMethodParentRef=fm,u.filterOutDuplicateEntities=v,u.filterOutDuplicateErrors=j4,u.findReferenceToSelfInList=zv,u.findReferencesToSelfInProject=k3,u.flattenCalls=sn,u.flattenCanvasAncestorsUntil=Ro,u.flattenCustomEntityExtensionAndImplementationTypes=eI,u.flattenCustomEntityExtensionTypes=vo,u.flattenCustomEntityExtensions=xd,u.flattenCustomEntityImplementations=kd,u.flattenCustomEntityImplementionTypes=go,u.flattenDerivedCanvasEntities=At,u.flattenDetachedBranch=aI,u.flattenElementCalls=Se,u.flattenElementCallsOnTheSameScope=x3,u.flattenProjectElements=Yv,u.flattenRelatedCanvasElementsOnTheLeft=Kv,u.flattenRelatedCanvasElementsOnTheRight=Qv,u.flattenVariableReads=Hv,u.flattenVariableWrites=Wv,u.flattenVariables=te,u.fromZodParseToEntityGenerationErrors=Pd,u.generate=xP,u.generateActionExample=P3,u.generateExecutionDataType=P9,u.generateMutablePropertiesExplanation=co,u.generateRandomBoolean=hT,u.generateRandomDate=Wm,u.generateRandomDateAfter=jm,u.generateRandomDateBefore=qm,u.generateRandomDateBetweenRange=Jm,u.generateRandomNumber=cT,u.generateRandomNumberAfter=sT,u.generateRandomNumberBefore=oT,u.generateRandomNumberBetweenRange=lT,u.generateRandomText=yT,u.generateRandomTextAfter=dT,u.generateRandomTextBefore=uT,u.generateRandomTextBetweenRange=pT,u.generateUniqueUUID=aT,u.getAllActionDescriptorsForConditions=To,u.getAllActionDescriptorsForGlobalEvents=fo,u.getAllActionDescriptorsForLoops=mo,u.getAllActionDescriptorsForOperations=C3,u.getAllGloballyDeclaredFunctionDeclarationsExplanation=_v,u.getBaseBuiltInEntities=Hn,u.getBaseSchemaBasedOnType=Dv,u.getBuiltInEntityOwner=Yn,u.getCallableEntityReferenceSchema=We,u.getCallableEntityTypeSchema=Yb,u.getCallerEntityReferenceSchema=Yx,u.getCallerEntityTypeSchema=Hx,u.getCalls=$d,u.getCanvasEntitiesDerivedFromInternalCalls=Xv,u.getCanvasEntitiesDerivedFromWrites=Ri,u.getCanvasEntityDerivedFromValueReadingEntity=Ud,u.getCanvasEntityReferenceSchema=u8,u.getCanvasEntityTypeSchema=d8,u.getChildrenEntityWithValues=V3,u.getCommonAncestor=Vd,u.getCommonChildren=Gv,u.getDeclaration=Er,u.getDeepestScope=lI,u.getDraggableCallableEntityReferenceSchema=Zb,u.getDraggableCallableEntityTypeSchema=zb,u.getDraggableCallerEntityReferenceSchema=Zx,u.getDraggableCallerEntityTypeSchema=zx,u.getDraggableExecutableEntityReferenceSchema=e8,u.getDraggableExecutableEntityTypeSchema=Kx,u.getDraggablePassThroughCallableEntityReferenceSchema=Zs,u.getDraggablePassThroughCallableEntityTypeSchema=zs,u.getDraggablePlayableEntityReferenceSchema=a8,u.getDraggablePlayableEntityTypeSchema=i8,u.getEntityArgumentDeclarations=Gd,u.getEntityInputMaps=Zv,u.getEntityOutputMaps=J3,u.getEntityReferenceSchema=c8,u.getEntityReturnDeclarations=Fd,u.getEntityTypeSchema=l8,u.getEntityWithLogicScopeReferenceSchema=En,u.getEntityWithLogicScopeTypeSchema=t8,u.getEntityWithValueReferenceSchema=Hb,u.getEntityWithValueTypeSchema=Wx,u.getEntryPointEntityReferenceSchema=Je,u.getEntryPointEntityTypeSchema=Un,u.getEventEntityReferenceSchema=Hs,u.getEventEntityTypeSchema=Ws,u.getExecutableEntityReferenceSchema=Qx,u.getExecutableEntityTypeSchema=Xx,u.getExtendedBuiltInEntity=W3,u.getExtendedCustomEntity=nI,u.getGenerationTargetSchemaBasedOnType=Pv,u.getHeadIfPartOfDetachedBranch=iI,u.getHighestScope=oI,u.getImplementedBuiltInEntity=H3,u.getIsInteractive=jd,u.getLastInListOperation=Fo,u.getLastInListOperationError=gp,u.getLastInListOperationErrorParentRef=bp,u.getLastInListOperationInputListArgument=Tp,u.getLastInListOperationInputListArgumentParentRef=mp,u.getLastInListOperationInputListArgumentRef=pp,u.getLastInListOperationInputListDataType=yp,u.getLastInListOperationOutputElementDataType=fp,u.getLastInListOperationOutputElementReturn=Rp,u.getLastInListOperationOutputElementReturnParentRef=Ep,u.getLastInListOperationOutputElementReturnRef=hp,u.getLinkedEntitiesFromArgumentDeclaration=U3,u.getLowestPersistedEntityImplementation=tI,u.getParentCanvasEntities=Et,u.getParentCanvasEntity=ze,u.getParentEntryPoint=N3,u.getPassThroughCallableEntityReferenceSchema=de,u.getPassThroughCallableEntityTypeSchema=Ys,u.getPlayableEntityReferenceSchema=r8,u.getPlayableEntityTypeSchema=n8,u.getProject=d5,u.getPrototypeByType=Io,u.getReferenceEntityId=C,u.getReferencedEntitiesStateOrErrors=po,u.getReferencedEntityStateOrErrors=Ad,u.getRelatedCanvasElementsOnTheLeft=Mr,u.getRelatedCanvasElementsOnTheRight=Wn,u.getRootEntryPointScopeOwner=Wd,u.getScopeOwner=Rt,u.getTerminationReferenceSchema=o8,u.getTerminationTypeSchema=s8,u.getUsedArgFromDeclaration=j3,u.getUsedReturnFromDeclaration=q3,u.getValueReadingEntityReferenceSchema=Wb,u.getValueReadingEntityTypeSchema=Tn,u.getValueWritingEntityReferenceSchema=Jx,u.getValueWritingEntityTypeSchema=ua,u.getVariableFromInputMapping=Uv,u.getVariableFromReturnVariablePointer=jv,u.getVariableReferenceSchema=Fn,u.getVariableTypeSchema=pr,u.getVariablesFromArgumentDeclarations=bo,u.getVariablesFromInputMaps=xv,u.getVariablesFromOutputMapping=qv,u.getVariablesFromOutputMaps=Jv,u.getVariablesFromReturnDeclarations=kv,u.getVariablesInSameOrHigherScope=fd,u.getWrites=Ld,u.groupCallsBasedOnParallelizableExecution=L3,u.handleAfterEntityImplementationSideEffects=Lv,u.handleBeforeEntityImplementationSideEffects=$v,u.httpRequestBodyArgument=Ga,u.httpRequestBodyArgumentRef=Ky,u.httpRequestBodyDataType=eh,u.httpRequestHeadersArgument=La,u.httpRequestHeadersArgumentRef=Xy,u.httpRequestHeadersDataType=Qy,u.httpRequestMethodArgument=Va,u.httpRequestMethodArgumentRef=zy,u.httpRequestMethodDataType=Zy,u.httpRequestMethodDataTypeRef=Hy,u.httpRequestQueryParamsArgument=Wo,u.httpRequestQueryParamsArgumentRef=Jy,u.httpRequestQueryParamsDataType=Wy,u.httpRequestVariableURLArgument=$a,u.httpRequestVariableURLArgumentRef=jy,u.httpRequestVariableURLDataType=qy,u.httpRequestVariableURLDataTypeRef=xy,u.httpResponseBodyReturnDataType=lh,u.httpResponseBodyReturnDataTypeRef=sh,u.httpResponseBodyReturnReturn=vi,u.httpResponseBodyReturnReturnRef=oh,u.httpResponseCodeDataType=nh,u.httpResponseCodeReturn=Ho,u.httpResponseCodeReturnRef=th,u.httpResponseHeadersDataType=ah,u.httpResponseHeadersDataTypeRef=rh,u.httpResponseHeadersReturn=Fa,u.httpResponseHeadersReturnRef=ih,u.implement=Eo,u.inferArgumentDeclarationDataType=cv,u.inferDataType=rn,u.inferInputMapDataType=dv,u.inferOutputMapDataType=yv,u.inferReturnDeclarationDataType=hd,u.inferVariableDeclarationDataType=pv,u.inferVariableInstanceDataType=uv,u.initProject=yI,u.iterateOverListActionDescriptor=Kn,u.iterateOverListActionDescriptorListArgumentDeclaration=Sh,u.iterateOverListActionDescriptorListArgumentDeclarationDataType=Ph,u.iterateOverListActionDescriptorListArgumentDeclarationDataTypeParentRef=Dh,u.iterateOverListActionDescriptorListArgumentDeclarationParentRef=Ah,u.iterateOverListActionDescriptorReturnDeclaration=Ih,u.iterateOverListActionDescriptorReturnDeclarationParentRef=vh,u.joinListOperation=$o,u.joinListOperationError=Ju,u.joinListOperationErrorParentRef=qu,u.joinListOperationFirstListArgument=Fu,u.joinListOperationFirstListArgumentParentRef=Gu,u.joinListOperationFirstListArgumentRef=_u,u.joinListOperationFirstListDataType=Mu,u.joinListOperationResultListDataType=Lu,u.joinListOperationResultListReturn=ju,u.joinListOperationResultListReturnParentRef=ku,u.joinListOperationResultListReturnRef=$u,u.joinListOperationSecondListArgument=xu,u.joinListOperationSecondListArgumentParentRef=Uu,u.joinListOperationSecondListArgumentRef=Nu,u.joinListOperationSecondListDataType=Vu,u.joinListWithLastSeparator=L,u.joinStringOperation=gi,u.joinStringOperationError=Ou,u.joinStringOperationErrorParentRef=Su,u.joinStringOperationFirstStringArgument=_a,u.joinStringOperationFirstStringArgumentParentRef=Du,u.joinStringOperationFirstStringArgumentRef=Eu,u.joinStringOperationFirstStringDataType=Ru,u.joinStringOperationResultStringDataType=Iu,u.joinStringOperationResultStringReturn=bi,u.joinStringOperationResultStringReturnParentRef=Au,u.joinStringOperationResultStringReturnRef=vu,u.joinStringOperationSecondStringArgument=Ma,u.joinStringOperationSecondStringArgumentParentRef=Pu,u.joinStringOperationSecondStringArgumentRef=bu,u.joinStringOperationSecondStringDataType=gu,u.jsonPrototype=_o,u.keyValueParamBuiltInBaseEntity=xa,u.keyValueParamBuiltInBaseEntityNameProperty=Nh,u.keyValueParamBuiltInBaseEntityNamePropertyDataTypeRef=II,u.keyValueParamBuiltInBaseEntityNamePropertyParentRef=Mh,u.keyValueParamBuiltInBaseEntityNamePropertyRef=_h,u.keyValueParamBuiltInBaseEntityValueProperty=Lh,u.keyValueParamBuiltInBaseEntityValuePropertyDataTypeRef=PI,u.keyValueParamBuiltInBaseEntityValuePropertyParentRef=$h,u.keyValueParamBuiltInBaseEntityValuePropertyRef=Vh,u.lowercaseFirstLetter=sv,u.manualFlowActionDescriptor=zo,u.manualFlowActionDescriptorDeclarationReturnDeclaration=wh,u.manualFlowActionDescriptorDeclarationReturnDeclarationDataType=Ch,u.manualFlowActionDescriptorDeclarationReturnDeclarationDataTypeParentRef=Oh,u.manualFlowActionDescriptorDeclarationReturnDeclarationParentRef=Bh,u.mapActionDescriptorToTypeItRepresents=X3,u.mergeEntityErrorsList=q4,u.mergeListOfEntities=z3,u.methodDefaultValue=Yy,u.mockClientProject=Ib,u.moreThanOrEqualCondition=Ur,u.moreThanOrEqualConditionLeftHandArgument=gm,u.moreThanOrEqualConditionLeftHandArgumentParentRef=bm,u.moreThanOrEqualConditionRightHandArgument=Im,u.moreThanOrEqualConditionRightHandArgumentParentRef=vm,u.notEmptyCondition=er,u.notEmptyConditionArgument=Tm,u.notEmptyConditionRef=mm,u.numberAdditionOperation=wa,u.numberAdditionOperationError=hu,u.numberAdditionOperationErrorParentRef=yu,u.numberAdditionOperationFirstNumberArgument=Mo,u.numberAdditionOperationFirstNumberArgumentRef=iu,u.numberAdditionOperationFirstNumberDataType=au,u.numberAdditionOperationRef=du,u.numberAdditionOperationRefThree=pu,u.numberAdditionOperationRefTwo=uu,u.numberAdditionOperationResultNumberDataType=cu,u.numberAdditionOperationResultNumberReturn=Vo,u.numberAdditionOperationResultNumberReturnRef=lu,u.numberAdditionOperationSecondNumberArgument=No,u.numberAdditionOperationSecondNumberArgumentRef=su,u.numberAdditionOperationSecondNumberDataType=ou,u.numberPrototype=Ce,u.numberValueAutogenerationSchema=uc,u.parallelExecutionOperation=xt,u.parallelExecutionOperationError=Hp,u.parallelExecutionOperationErrorParentRef=Wp,u.parallelExecutionOperationListOfExecutionResultsDataType=jp,u.parallelExecutionOperationListOfExecutionResultsReturn=jo,u.parallelExecutionOperationListOfExecutionResultsReturnRef=kp,u.parallelExecutionOperationListOfFunctionsArgument=ko,u.parallelExecutionOperationListOfFunctionsArgumentDatatype=xp,u.parallelExecutionOperationListOfFunctionsArgumentRef=Up,u.parallelExecutionOperationListOfFunctionsBlueprint=Fp,u.parallelExecutionOperationRef=qp,u.parallelExecutionOperationRefThree=Jp,u.persistedBuiltInBaseEntity=Le,u.persistedBuiltInBaseEntityCreatedAtProperty=am,u.persistedBuiltInBaseEntityCreatedAtPropertyDataType=rm,u.persistedBuiltInBaseEntityCreatedAtPropertyDataTypeRef=FI,u.persistedBuiltInBaseEntityCreatedAtPropertyParentRef=im,u.persistedBuiltInBaseEntityCreatedAtPropertyRef=nm,u.persistedBuiltInBaseEntityDatabaseProperty=Pi,u.persistedBuiltInBaseEntityDatabasePropertyDataTypeRef=VI,u.persistedBuiltInBaseEntityDatabasePropertyParentRef=Hf,u.persistedBuiltInBaseEntityDatabasePropertyRef=Wf,u.persistedBuiltInBaseEntityDeletedAtProperty=tm,u.persistedBuiltInBaseEntityDeletedAtPropertyDataType=Kf,u.persistedBuiltInBaseEntityDeletedAtPropertyDataTypeRef=GI,u.persistedBuiltInBaseEntityDeletedAtPropertyParentRef=em,u.persistedBuiltInBaseEntityDeletedAtPropertyRef=Qf,u.persistedBuiltInBaseEntityIdentifierProperty=Xf,u.persistedBuiltInBaseEntityIdentifierPropertyDataTypeRef=Yf,u.persistedBuiltInBaseEntityIdentifierPropertyParentRef=Zf,u.persistedBuiltInBaseEntityIdentifierPropertyRef=zf,u.persistedBuiltInBaseEntityUpdatedAtProperty=cm,u.persistedBuiltInBaseEntityUpdatedAtPropertyDataType=om,u.persistedBuiltInBaseEntityUpdatedAtPropertyDataTypeRef=UI,u.persistedBuiltInBaseEntityUpdatedAtPropertyParentRef=lm,u.persistedBuiltInBaseEntityUpdatedAtPropertyRef=sm,u.processOutputGlobalValueDescriptorDataType=Am,u.processOutputGlobalValueDescriptorReturn=ol,u.processOutputGlobalValueDescriptorReturnRef=Pm,u.projectPublicationCompletedGlobalEvent=Ha,u.propertyToZodSchema=xm,u.relationalDatabaseBuiltInBaseEntity=On,u.relationalDatabaseBuiltInBaseEntityAutoscalingProperty=el,u.relationalDatabaseBuiltInBaseEntityAutoscalingPropertyDataTypeRef=Uf,u.relationalDatabaseBuiltInBaseEntityAutoscalingPropertyParentRef=xf,u.relationalDatabaseBuiltInBaseEntityAutoscalingPropertyRef=Ff,u.relationalDatabaseBuiltInBaseEntityDefaultProperty=Ko,u.relationalDatabaseBuiltInBaseEntityDefaultPropertyDataTypeRef=Lf,u.relationalDatabaseBuiltInBaseEntityDefaultPropertyRef=Gf,u.relationalDatabaseBuiltInBaseEntityIdentifierProperty=ja,u.relationalDatabaseBuiltInBaseEntityIdentifierPropertyDataTypeRef=wf,u.relationalDatabaseBuiltInBaseEntityIdentifierPropertyRef=_f,u.relationalDatabaseBuiltInBaseEntityMinSizeProperty=Wa,u.relationalDatabaseBuiltInBaseEntityMinSizePropertyDataTypeRef=Vf,u.relationalDatabaseBuiltInBaseEntityMinSizePropertyRef=$f,u.relationalDatabaseBuiltInBaseEntityPasswordProperty=Ja,u.relationalDatabaseBuiltInBaseEntityPasswordPropertyDataTypeRef=BI,u.relationalDatabaseBuiltInBaseEntityPasswordPropertyRef=Nf,u.relationalDatabaseBuiltInBaseEntityRef=Fr,u.relationalDatabaseBuiltInBaseEntityUsernameProperty=qa,u.relationalDatabaseBuiltInBaseEntityUsernamePropertyDataTypeRef=OI,u.relationalDatabaseBuiltInBaseEntityUsernamePropertyRef=Mf,u.resolveActionDescriptorName=vv,u.resolveBaseEntityName=Rv,u.resolveBuiltInBaseEntityDataTypeLabel=md,u.resolveConditionOperatorLabel=oo,u.resolveCustomEntityDataTypeLabel=Td,u.resolveDataType=ao,u.resolveDataTypeLabel=mv,u.resolveEntityDataTypeLabel=Ev,u.resolveEntityName=S,u.resolveFirstCallsSecond=G3,u.resolveFirstWritesSecond=F3,u.resolvePrimitiveEntityName=gv,u.resolvePropertyDataTypeLabel=Tv,u.resolveSearchName=bv,u.resolveVariableDataTypeLabel=C9,u.resolveVariableDeclarationDataTypeLabel=Rr,u.resolveVariableInstanceDataTypeLabel=fv,u.resolveVariableScope=A9,u.sequentialExecutionOperation=dn,u.sequentialExecutionOperationError=uy,u.sequentialExecutionOperationErrorParentRef=dy,u.sequentialExecutionOperationListOfExecutionResultsDataType=oy,u.sequentialExecutionOperationListOfExecutionResultsReturn=Jo,u.sequentialExecutionOperationListOfExecutionResultsReturnParentRef=cy,u.sequentialExecutionOperationListOfExecutionResultsReturnRef=sy,u.sequentialExecutionOperationListOfFunctionsArgument=qo,u.sequentialExecutionOperationListOfFunctionsArgumentDatatype=ay,u.sequentialExecutionOperationListOfFunctionsArgumentParentRef=ly,u.sequentialExecutionOperationListOfFunctionsArgumentRef=iy,u.sequentialExecutionOperationListOfFunctionsBlueprint=ry,u.softDeletePersistedEntityMethod=qf,u.softDeletePersistedEntityMethodParentRef=jf,u.sortCallsBasedOnExecutionDependencies=Fv,u.sortChildrenEntitiesBasedOnExecutionDependencies=$3,u.splitListOperation=Go,u.splitListOperationError=cp,u.splitListOperationErrorParentRef=lp,u.splitListOperationFirstOutputListDataType=Qu,u.splitListOperationFirstOutputListReturn=ip,u.splitListOperationFirstOutputListReturnParentRef=rp,u.splitListOperationFirstOutputListReturnRef=Lo,u.splitListOperationInputListArgument=ep,u.splitListOperationInputListArgumentParentRef=Ku,u.splitListOperationInputListArgumentRef=Yu,u.splitListOperationInputListDataType=zu,u.splitListOperationSecondOutputListDataType=ap,u.splitListOperationSecondOutputListReturn=op,u.splitListOperationSecondOutputListReturnParentRef=sp,u.splitListOperationSplitIndexArgument=np,u.splitListOperationSplitIndexArgumentParentRef=tp,u.splitListOperationSplitIndexArgumentRef=Zu,u.splitListOperationSplitIndexDataType=Xu,u.stringPrototype=k,u.stringValueAutogenerationSchema=dc,u.suggestNewIdForEntity=Id,u.test_primitive_entities_export=p5,u.toCamelCase=S9,u.toEntityState=Mt,u.toKebabCase=hv,u.toLowerCaseKebabCase=so,u.toPascalCase=O9,u.untypedObjectPrototype=et,u.updateErrorsList=ne,u.updateValueReader=Sa,u.urlDefaultValue=ky,u.uuidPrototype=Ba,u.validateArgumentDeclarationName=gd,u.validateCalledByErrorIdInAction=S3,u.validateCalledByIdInAction=A3,u.validateCallers=wv,u.validateConditionEntityDeclaration=B3,u.validateCustomEntityName=lo,u.validateDataOperation=Qn,u.validateDataOperationDataToValidateArgument=wy,u.validateDataOperationDataToValidateArgumentParentRef=By,u.validateDataOperationDataToValidateArgumentRef=Oy,u.validateDataOperationDataToValidateDataType=Cy,u.validateDataOperationEntityToMatchTypeArgument=Vy,u.validateDataOperationEntityToMatchTypeArgumentParentRef=Ny,u.validateDataOperationEntityToMatchTypeArgumentRef=_y,u.validateDataOperationEntityToMatchTypeDataType=My,u.validateDataOperationError=Fy,u.validateDataOperationErrorParentRef=Gy,u.validateDataOperationOutputEntityDeclaration=Ly,u.validateDataOperationOutputEntityDeclarationParentRef=$y,u.validateEntryCaller=Bv,u.validateErrorCaller=Cv,u.validateFunctionCallDeclaration=Mv,u.validateFunctionDeclarationName=Ed,u.validateGeneratedEntityParentIsNotBuiltInEntity=v3,u.validateGeneration=b3,u.validateGenerationTarget=Be,u.validateGenerationUpdate=g3,u.validateLoopEntityDeclaration=w3,u.validateName=B9,u.validateOperationEntityDeclaration=Nv,u.validatePropertyName=bd,u.validateReachability=In,u.validateReadsValueInActionPayload=O3,u.validateReferenceObject=uo,u.validateReferenceToOne=Sd,u.validateReferences=je,u.validateReturnDeclarationName=vd,u.validateSuccessCaller=Ov,u.validateValueReaderGenerationUpdate=Da,u.validateValueWritter=Md,u.validateVariableDeclarationName=Rd,u.validateVariableInternalCallUse=Nd,u.valueAutogenerationCurrentDateAndTimeSchema=Pb,u.valueAutogenerationGenericSchema=ws,u.valueAutogenerationOptions=yc,u.valueAutogenerationOptionsSchema=Db,u.valueAutogenerationRandomBooleanSchema=cc,u.valueAutogenerationRandomDateBetweenSchema=Nb,u.valueAutogenerationRandomDateFromSchema=_b,u.valueAutogenerationRandomDateSchema=Ns,u.valueAutogenerationRandomDateUntilSchema=Mb,u.valueAutogenerationRandomNumberBetweenSchema=Ob,u.valueAutogenerationRandomNumberFromSchema=Ab,u.valueAutogenerationRandomNumberSchema=_s,u.valueAutogenerationRandomNumberUntilSchema=Sb,u.valueAutogenerationRandomSchema=ia,u.valueAutogenerationRandomTextBetweenSchema=wb,u.valueAutogenerationRandomTextFromSchema=Cb,u.valueAutogenerationRandomTextSchema=Ms,u.valueAutogenerationRandomTextUntilSchema=Bb,u.valueAutogenerationRangeValueTypesSchema=ra,u.valueAutogenerationUniqueSchema=lc,u.waitOperation=dt,u.waitOperationMillisecondsNumberArgument=Zn,u.waitOperationMillisecondsNumberArgumentRef=Zp,u.waitOperationMillisecondsNumberDataType=Xp,u.waitOperationOperationError=ey,u.waitOperationOperationErrorParentRef=Kp,u.waitOperationRef=Qp,Object.defineProperty(u,Symbol.toStringTag,{value:"Module"})});
|
|
373
|
+
Alternatively you can update the parent data-type entity with 'update' action to remove the existing value of the field.`,issue:null}))}return{errors:a,modifiedData:i}}get extendedProperties(){return v([...this.extends.reduce((e,t)=>[...[...t.properties,...t.extendedProperties].filter(a=>!a.abstract),...e],[]),...this.implements.reduce((e,t)=>[...[...t.properties,...t.extendedProperties].filter(a=>!a.abstract),...e],[])])}validateGeneratedUpdate(e){const t=[];return e.parent&&t.push(new E({id:`${this.id}--${h.InvalidParentUpdate}`,code:h.InvalidParentUpdate,severity:T.Error,message:`Entity of type '${this.type}' with id '${this.id}' cannot have the 'parent' property updated. The 'parent' on an '${this.type}', must be the root project as it is a globally declared entity.`,issue:null})),{errors:t,modifiedData:e}}addSelfToProject(){const e=[this];if(this.parent.type===r.DataType){const t=this.parent;t.entity=this,e.push(t)}else this.project.addCustomEntity(this);return{affected:v(e),self:this}}setParent(e){return this.parent=e,this}removeProperty(e){return this.properties=this.properties.filter(t=>t.id!==e.id),this}addMethod(e){return this.methods.includes(e)||(this.methods.push(e),this.suggestedMethods=this.suggestedMethods.filter(t=>t.name!==e.name)),this}removeMethod(e){return this.methods=this.methods.filter(t=>t.id!==e.id),this}addProperty(e){return this.properties.includes(e)||(this.properties.push(e),this.suggestedProperties=this.suggestedProperties.filter(t=>t.name!==e.name)),this}addSuggestedProperty(e){return this.suggestedProperties.includes(e)||this.suggestedProperties.push(e),this}addSuggestedMethod(e){return this.suggestedMethods.includes(e)||this.suggestedMethods.push(e),this}removeSuggestedProperty(e){return this.suggestedProperties=this.suggestedProperties.filter(t=>t.id!==e.id),this}removeSuggestedMethod(e){return this.suggestedMethods=this.suggestedMethods.filter(t=>t.id!==e.id),this}addAbstractMethod(e){return this.abstractMethods.includes(e)||this.abstractMethods.push(e),this}removeAbstractMethod(e){return this.abstractMethods=this.abstractMethods.filter(t=>t.id!==e.id),this}initChildren(){return this.initialized?this:(this.initialized=!0,this.properties=this.initialData.properties.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this.methods=this.initialData.methods.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this.abstractMethods=this.initialData.abstractMethods.map(e=>{const t=R(e,this.project);return t.setParent(this),t.initChildren(),t}),this.extends=this.initialData.extends.map(e=>R(e,this.project)),this.implements=this.initialData.implements.map(e=>R(e,this.project)),this.addSuggestions(),this)}addSuggestions(){return this.implements.forEach(e=>{w8(this,e).forEach(a=>{const s=a.toJSON();s.id=`_suggestion--parent--${this.id}--${a.id}`;const o=R(s,this.project);o.suggestion=!0,o.setParent(this),o.initChildren(),this.addSuggestedProperty(o)}),_8(this,e).forEach(a=>{const s=`_suggestion--parent--${this.id}--${a.id}`,o=a.implementAsFunctionDeclaration(s),l=R(o,this.project);if(l.suggestion=!0,l.setParent(this),l.initChildren(),l.inputs.forEach(p=>{p.suggestion=!0}),l.returnStatements.length){const p=l.returnStatements[0];p.suggestion=!0,p.outputs.forEach(y=>{y.suggestion=!0})}this.addSuggestedMethod(l)})}),this}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}sync(e){return this.version=e.version||this.version,this.name=e.name||this.name,this.x=e.x||this.x,this.y=e.y||this.y,this.static=e.static||this.static,this.abstract=e.abstract||this.abstract,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){const i=[],a=[];return t.has(this.id)?{affected:[],removed:[]}:(t.add(this.id),a.push(this),this.unsubscribe(),this.properties.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.methods.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.abstractMethods.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.suggestedProperties.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),this.suggestedMethods.forEach(s=>{const{affected:o,removed:l}=s.remove({ignoreUpstream:!0,seenEntities:t});i.push(...o),a.push(...l)}),{affected:v(i),removed:v(a)})}restore({seenEntities:e}={seenEntities:new Set}){const t=[];return e.has(this.id)?{affected:[],self:this}:(e.add(this.id),this.subscribe(),this.properties.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.methods.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.abstractMethods.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.suggestedProperties.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),this.suggestedMethods.forEach(i=>{const{affected:a}=i.restore({seenEntities:e});t.push(...a)}),{affected:v(t),self:this})}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.extends.flatMap(i=>i.toFlat(e)),...this.implements.flatMap(i=>i.toFlat(e)),...this.properties.flatMap(i=>i.toFlat(e)),...this.methods.flatMap(i=>i.toFlat(e)),...this.abstractMethods.flatMap(i=>i.toFlat(e))])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.extends.flatMap(i=>i.toFlatIds(e)),...this.implements.flatMap(i=>i.toFlatIds(e)),...this.properties.flatMap(i=>i.toFlatIds(e)),...this.methods.flatMap(i=>i.toFlatIds(e)),...this.abstractMethods.flatMap(i=>i.toFlatIds(e))])}toJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,x:this.x,y:this.y,static:this.static,abstract:this.abstract,properties:this.properties.map(e=>e.toJSON()),methods:this.methods.map(e=>e.toJSON()),abstractMethods:this.abstractMethods.map(e=>e.toJSON()),implements:this.implements.map(e=>e.toJSON()),extends:this.extends.map(e=>e.toJSON()),parent:this.parent.toReference()}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,name:this.name,description:this.description,type:this.type,x:this.x,y:this.y,static:this.static,abstract:this.abstract,properties:this.properties.map(e=>e.toReference()),methods:this.methods.map(e=>e.toReference()),abstractMethods:this.abstractMethods.map(e=>e.toReference()),implements:this.implements.map(e=>e.toReference()),extends:this.extends.map(e=>e.toReference()),parent:this.parent.toReference()}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.properties.flatMap(i=>i.toFlatJSON(e)),...this.methods.flatMap(i=>i.toFlatJSON(e)),...this.abstractMethods.flatMap(i=>i.toFlatJSON(e)),...this.implements.flatMap(i=>i.toFlatJSON(e)),...this.extends.flatMap(i=>i.toFlatJSON(e))])}toGenerationTarget(){const e=this.parent.type===r.Project?void 0:this.parent.id;return{id:this.id,name:this.name,description:this.description,type:this.type,static:this.static,abstract:this.abstract,extends:this.extends.map(t=>t.id),implements:this.implements.map(t=>t.id),parent:e}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.properties.flatMap(i=>i.toFlatGenerationTarget(e)),...this.methods.flatMap(i=>i.toFlatGenerationTarget(e)),...this.abstractMethods.flatMap(i=>i.toFlatGenerationTarget(e)),...this.implements.filter(i=>i.type===r.CustomEntity).flatMap(i=>i.toFlatGenerationTarget(e)),...this.implements.filter(i=>i.type===r.CustomEntity).flatMap(i=>i.toFlatGenerationTarget(e))])}clearErrors(){return this.errors=[],this.properties.forEach(e=>e.clearErrors()),this.methods.forEach(e=>e.clearErrors()),this.abstractMethods.forEach(e=>e.clearErrors()),this}validate(){return this.errors=B8(this),{success:!0,error:null,data:null}}getErrors(){return[...this.errors,...this.properties.flatMap(t=>t.getErrors()),...this.methods.flatMap(t=>t.getErrors()),...this.abstractMethods.flatMap(t=>t.getErrors())]}getShallowErrors(){return this.errors}clone(e=null,t=null,i=!0){var b,g,I;const a=this.toJSON(),s=t||Ke(S(this,this.project),r.CustomEntity,this.project);a.properties=[],a.methods=[],a.abstractMethods=[];const o=s.split("-id"),l=o[o.length-1||0]||s;a.id=s;const p=Ut(a,this.project);e&&p.setParent(e),i&&p.subscribe(),p.initChildren();const y=(b=this.properties)==null?void 0:b.map((P,B)=>P.clone(this,l+"-property-"+B+"-id",i));p.properties=y;const f=(g=this.methods)==null?void 0:g.map((P,B)=>P.clone(this,l+"-method-"+B+"-id",i));p.methods=f;const m=(I=this.abstractMethods)==null?void 0:I.map((P,B)=>P.clone(this,l+"-abstract-method-"+B+"-id",i));return p.abstractMethods=m,p}getFunctionDeclaration(e){return this.methods.find(t=>t.id===e)}implement(e,t){return Eo(this,e,t)}getAllInteractiveMethods(){const e=this.implements.filter(i=>i.type===r.CustomEntity||i.type===r.BuiltInBaseEntity&&i.interactive);return v([...this.methods,...this.extends.flatMap(i=>i.getAllInteractiveMethods()),...e.flatMap(i=>i.getAllInteractiveMethods())])}inferFromInputs(e){if(this.parent.type!==r.DataType||!this.parent.inferred)return this;const t=[];e.forEach(s=>{t.find(l=>S(l,this.project)===S(s,this.project))||t.push(s)});const i=this.properties.filter(s=>!s.getDataType());t.forEach(s=>{const o=i.find(m=>S(m,this.project)===S(s,this.project));if(!o)return;const p=Er(s.parent).getMasterInputWithValueWritterFromAllInstances(s),y=rn(p),f=y==null?void 0:y.clone(o,o.id+"--data-type",!0);f&&o.setDataType(f),s.setDeclaration(o)});const a=[];return t.forEach(s=>{if(!s.declaration){a.push(s);return}}),a.length===0?this:(a.forEach(s=>{const o=this.properties.find(g=>S(g,this.project)===S(s,this.project));if(o){if(s.setDeclaration(o),!o.getDataType()){const I=Er(s.parent).getMasterInputWithValueWritterFromAllInstances(s),P=rn(I),B=P==null?void 0:P.clone(o,o.id+"--data-type",!0);B&&o.setDataType(B)}return}const l={id:s.id+"--inferred-property",type:r.Property,version:1,name:S(s,this.project),description:s.description,static:!0,abstract:!1,private:!1,hidden:!1,required:!1,index:s.index,implements:null,dataType:null,parent:this.toReference()},p=R(l,this.project);p.setParent(this),p.initChildren();const f=Er(s.parent).getMasterInputWithValueWritterFromAllInstances(s),m=rn(f),b=m==null?void 0:m.clone(p,l.id+"--data-type",!0);return b&&p.setDataType(b),this.addProperty(p),s.setDeclaration(p),p}),this)}};c(Pe,"MUTABLE_BASE_PROPERTIES",["name","description","static","abstract"]),c(Pe,"INMUTABLE_BASE_PROPERTIES",["id","version","type"]),c(Pe,"BASE_PROPERTIES",[...Pe.MUTABLE_BASE_PROPERTIES,...Pe.INMUTABLE_BASE_PROPERTIES]),c(Pe,"MUTABLE_META_PROPERTIES",[...Pe.MUTABLE_BASE_PROPERTIES,"x","y"]),c(Pe,"INMUTABLE_META_PROPERTIES",[...Pe.INMUTABLE_BASE_PROPERTIES]),c(Pe,"META_PROPERTIES",[...Pe.MUTABLE_META_PROPERTIES,...Pe.INMUTABLE_META_PROPERTIES]),c(Pe,"MUTABLE_UPSTREAM_PROPERTIES",["extends","implements"]),c(Pe,"INMUTABLE_UPSTREAM_PROPERTIES",["parent"]),c(Pe,"UPSTREAM_PROPERTIES",[...Pe.MUTABLE_UPSTREAM_PROPERTIES,...Pe.INMUTABLE_UPSTREAM_PROPERTIES]),c(Pe,"MUTABLE_DOWNSTREAM_PROPERTIES",["properties","methods","abstractMethods"]),c(Pe,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(Pe,"DOWNSTREAM_PROPERTIES",[...Pe.MUTABLE_DOWNSTREAM_PROPERTIES,...Pe.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(Pe,"PROPERTIES",[...Pe.META_PROPERTIES,...Pe.UPSTREAM_PROPERTIES,...Pe.DOWNSTREAM_PROPERTIES]);let Nr=Pe;function K3(n){const e=oU(),t=n.toJSON();e.safeParse(t).success;const a=[];return ne(n.errors,a)}class Gt{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"name");c(this,"description",null);c(this,"type",r.BuiltInBaseEntity);c(this,"abstract",!1);c(this,"static");c(this,"properties",[]);c(this,"methods",[]);c(this,"abstractMethods",[]);c(this,"extends",[]);c(this,"interactive",!1);c(this,"errors",[]);c(this,"project");this.initialData=this.initialData||e,this.project=this.project||t,this.id=this.id||e.id,this.version=this.version||e.version,this.name=this.name||e.name,this.static=this.static||e.static,this.interactive=this.interactive||e.interactive,this.abstract=e.abstract,this.properties=this.initialData.properties.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.methods=this.initialData.methods.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.abstractMethods=this.initialData.abstractMethods.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.extends=this.initialData.extends.map(i=>R(i,this.project))}get extendedProperties(){return v(this.extends.reduce((e,t)=>{const i=[...t.properties,...t.extendedProperties].filter(a=>!a.abstract);return[...e,...i]},[]))}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}async load(){return this}remove(e={ignoreUpstream:!1,seenEntities:new Set}){return{affected:[],removed:[]}}restore({seenEntities:e}={seenEntities:new Set}){return{affected:[],self:this}}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.properties.flatMap(i=>i.toFlat(e)),...this.methods.flatMap(i=>i.toFlat(e)),...this.abstractMethods.flatMap(i=>i.toFlat(e)),...this.extends.flatMap(i=>i.toFlat(e))])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.properties.flatMap(i=>i.toFlatIds(e)),...this.methods.flatMap(i=>i.toFlatIds(e)),...this.abstractMethods.flatMap(i=>i.toFlatIds(e)),...this.extends.flatMap(i=>i.toFlatIds(e))])}toJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,abstract:this.abstract,static:this.static,interactive:this.interactive,properties:this.properties.map(e=>e.toJSON()),methods:this.methods.map(e=>e.toJSON()),abstractMethods:this.abstractMethods.map(e=>e.toJSON()),extends:this.extends.map(e=>e.toJSON())}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,abstract:this.abstract,static:this.static,interactive:this.interactive,properties:this.properties.map(e=>e.toReference()),methods:this.methods.map(e=>e.toReference()),abstractMethods:this.abstractMethods.map(e=>e.toReference()),extends:this.extends.map(e=>e.toReference())}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.properties.flatMap(i=>i.toFlatJSON(e)),...this.methods.flatMap(i=>i.toFlatJSON(e)),...this.abstractMethods.flatMap(i=>i.toFlatJSON(e))])}toGenerationTarget(){return{id:this.id,type:this.type,name:this.name,description:this.description,static:this.static,abstract:this.abstract,interactive:this.interactive,extends:this.extends.map(e=>e.id)}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.properties.flatMap(i=>i.toFlatGenerationTarget(e)),...this.methods.flatMap(i=>i.toFlatGenerationTarget(e)),...this.abstractMethods.flatMap(i=>i.toFlatGenerationTarget(e))])}clearErrors(){return this.errors=[],this.properties.forEach(e=>e.clearErrors()),this.methods.forEach(e=>e.clearErrors()),this.abstractMethods.forEach(e=>e.clearErrors()),this}validate(){const e=K3(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors,...this.properties.flatMap(t=>t.getErrors()),...this.methods.flatMap(t=>t.getErrors()),...this.abstractMethods.flatMap(t=>t.getErrors())]}getShallowErrors(){return this.errors}clone(){return new Gt(this.toJSON(),this.project)}implement(e,t){return Eo(this,e,t)}getAllInteractiveMethods(){const e=[];return this.interactive&&(e.push(...this.methods),this.extends.filter(i=>i.type===r.BuiltInBaseEntity&&i.interactive||i.type===r.PrimitiveEntity).forEach(i=>{i instanceof Gt&&e.push(...i.getAllInteractiveMethods())})),v(e)}}function e5(n){const e=Q4(),t=n.toJSON();e.safeParse(t).success;const a=[];return ne(n.errors,a)}class Ft{constructor(e,t){c(this,"initialData");c(this,"id");c(this,"version");c(this,"name");c(this,"description",null);c(this,"type",r.PrimitiveEntity);c(this,"static");c(this,"abstract");c(this,"properties",[]);c(this,"methods",[]);c(this,"abstractMethods",[]);c(this,"extends",[]);c(this,"errors",[]);c(this,"project");this.initialData=e,this.project=t,this.id=e.id,this.version=e.version,this.name=e.name,this.static=e.static,this.abstract=e.abstract,this.properties=this.initialData.properties.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.methods=this.initialData.methods.map(i=>{const a=R(i,this.project);return a.parent=this,a}),this.abstractMethods=this.initialData.abstractMethods.map(i=>{const a=R(i,this.project);return a.parent=this,a})}get extendedProperties(){return v(this.extends.reduce((e,t)=>{const i=[...t.properties,...t.extendedProperties].filter(a=>!a.abstract);return[...e,...i]},[]))}subscribe(){return this.project.subscribeInstance(this),this}unsubscribe(){return this.project.unsubscribeInstance(this),this}async load(){return this}remove({ignoreUpstream:e,seenEntities:t}={ignoreUpstream:!1,seenEntities:new Set}){return{affected:[],removed:[]}}restore({seenEntities:e}={seenEntities:new Set}){return{affected:[],self:this}}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this,...this.properties.flatMap(i=>i.toFlat(e)),...this.methods.flatMap(i=>i.toFlat(e)),...this.abstractMethods.flatMap(i=>i.toFlat(e))])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.id,...this.properties.flatMap(i=>i.toFlatIds(e)),...this.methods.flatMap(i=>i.toFlatIds(e)),...this.abstractMethods.flatMap(i=>i.toFlatIds(e))])}toJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,static:this.static,abstract:this.abstract,properties:this.properties.map(e=>e.toJSON()),methods:this.methods.map(e=>e.toJSON()),abstractMethods:this.abstractMethods.map(e=>e.toJSON()),extends:this.extends.map(e=>e.toJSON())}}toReference(){return{id:this.id+"--"+w.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,abstract:this.abstract,static:this.static,properties:this.properties.map(e=>e.toReference()),methods:this.methods.map(e=>e.toReference()),abstractMethods:this.abstractMethods.map(e=>e.toReference()),extends:this.extends.map(e=>e.toReference())}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toShallowJSON(),...this.properties.flatMap(i=>i.toFlatJSON(e)),...this.methods.flatMap(i=>i.toFlatJSON(e)),...this.abstractMethods.flatMap(i=>i.toFlatJSON(e))])}toGenerationTarget(){return{id:this.id,type:this.type,name:this.name,description:this.description,static:this.static,abstract:this.abstract,extends:this.extends.map(e=>e.id)}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[this.toGenerationTarget(),...this.properties.flatMap(i=>i.toFlatGenerationTarget(e)),...this.methods.flatMap(i=>i.toFlatGenerationTarget(e)),...this.abstractMethods.flatMap(i=>i.toFlatGenerationTarget(e))])}clearErrors(){return this.errors=[],this.properties.forEach(e=>e.clearErrors()),this.methods.forEach(e=>e.clearErrors()),this.abstractMethods.forEach(e=>e.clearErrors()),this}validate(){const e=e5(this);return this.errors=e,{success:!0,error:null,data:this.toJSON()}}getErrors(){return[...this.errors,...this.properties.flatMap(t=>t.getErrors()),...this.methods.flatMap(t=>t.getErrors()),...this.abstractMethods.flatMap(t=>t.getErrors())]}getShallowErrors(){return this.errors}clone(){return new Ft(this.toJSON(),this.project)}getAllInteractiveMethods(){const e=[];return e.push(...this.methods),this.extends.filter(i=>i.type===r.BuiltInBaseEntity&&i.interactive||i.type===r.PrimitiveEntity).forEach(i=>{i instanceof Gt&&e.push(...i.getAllInteractiveMethods())}),v(e)}}function Ut(n,e){if(!n)throw new Error("Entity is null");const t=e.findSubscribedInstance(n);switch(n.type){case r.PrimitiveValue:return t||new Ti(n,e);case r.CustomEntity:return t||new Nr(n,e);case r.PrimitiveEntity:return t||new Ft(n,e);case r.FunctionDeclaration:return t||new gr(n,e);case r.GlobalEvent:return t||new fi(n,e);case r.DataType:return t||new hi(n,e);case r.Property:return t||new br(n,e);case r.FunctionCall:return t||new _r(n,e);case r.Condition:return t||new Dr(n,e);case r.Operation:return t||new vr(n,e);case r.VariableDeclaration:return t||new Pr(n,e);case r.VariableInstance:return t||new Ar(n,e);case r.OutputMap:return t||new vn(n,e);case r.ReturnDeclaration:return t||new _t(n,e);case r.ArgumentDeclaration:return t||new Cr(n,e);case r.InputMap:return t||new gn(n,e);case r.Project:return t||new w(n);case r.InstalledProject:return t||new Or(n,e);case r.ActionDescriptor:return t||new Fe(n,e);case r.ReturnStatement:return t||new Br(n,e);case r.Loop:return t||new Ir(n,e);case r.Search:return t||new Sr(n,e);case r.ValueDescriptor:return t||new wr(n,e);case r.BuiltInBaseEntity:return t||new Gt(n,e);case r.InternalCall:return t||new mi(n,e);case r.ContinueStatement:return t||new Tt(n,e);case r.BreakStatement:return t||new Ei(n,e);default:throw new Error("Invalid entity type: "+n.type)}}function R(n,e){if(!n)throw new Error("Entity is null");const t=Ut(n,e);return t.subscribe(),t}function t5(n,e){if(!n)throw new Error("Entity is null");switch(n.type){case r.PrimitiveValue:return Ti.fromGenerationTarget(n,e);case r.CustomEntity:return Nr.fromGenerationTarget(n,e);case r.FunctionDeclaration:return gr.fromGenerationTarget(n,e);case r.GlobalEvent:return fi.fromGenerationTarget(n,e);case r.DataType:return hi.fromGenerationTarget(n,e);case r.Property:return br.fromGenerationTarget(n,e);case r.FunctionCall:return _r.fromGenerationTarget(n,e);case r.Condition:return Dr.fromGenerationTarget(n,e);case r.Operation:return vr.fromGenerationTarget(n,e);case r.VariableDeclaration:return Pr.fromGenerationTarget(n,e);case r.VariableInstance:return Ar.fromGenerationTarget(n,e);case r.OutputMap:return vn.fromGenerationTarget(n,e);case r.ReturnDeclaration:return _t.fromGenerationTarget(n,e);case r.ArgumentDeclaration:return Cr.fromGenerationTarget(n,e);case r.InputMap:return gn.fromGenerationTarget(n,e);case r.InstalledProject:return Or.fromGenerationTarget(n,e);case r.ReturnStatement:return Br.fromGenerationTarget(n,e);case r.Loop:return Ir.fromGenerationTarget(n,e);case r.Search:return Sr.fromGenerationTarget(n,e);case r.ActionDescriptor:return Fe.fromGenerationTarget(n,e);case r.ValueDescriptor:return wr.fromGenerationTarget(n,e);case r.InternalCall:return mi.fromGenerationTarget(n,e);case r.ContinueStatement:return Tt.fromGenerationTarget(n,e);case r.BreakStatement:return Ei.fromGenerationTarget(n,e);default:throw new Error("Invalid entity type: "+n.type)}}const K=class K{constructor(e){c(this,"initialData");c(this,"id");c(this,"version");c(this,"type",r.Project);c(this,"name",null);c(this,"description",null);c(this,"x");c(this,"y");c(this,"entities",[]);c(this,"projects",[]);c(this,"functions",[]);c(this,"events",[]);c(this,"variableDeclarations",[]);c(this,"variableInstances",[]);c(this,"conditions",[]);c(this,"operations",[]);c(this,"functionCalls",[]);c(this,"loops",[]);c(this,"searches",[]);c(this,"primitives",[]);c(this,"builtInBaseEntities",[]);c(this,"operationDeclarations",[]);c(this,"globalEventActionDescriptors",[]);c(this,"loopDeclarations",[]);c(this,"conditionDeclarations",[]);c(this,"valueDescriptors",[]);c(this,"dataTypes",[]);c(this,"project");c(this,"instances",{});c(this,"builtInInstances",{});c(this,"errors",[]);c(this,"references",[]);this.initialData=e,this.id=e.id,this.version=e.version,this.name=e.name,this.description=e.description,this.x=0,this.y=0;try{(!K.UUID||K.UUID.isBackup)&&(K.UUID=Es==null?void 0:Es()),K.UUID||(K.UUID={isBackup:!0,uuid:()=>Math.random().toString(36).substring(2,15)+Math.random().toString(36).substring(2,15),fromUUID:t=>t})}catch(t){console.error("Error initializing UUID module",t),K.UUID={isBackup:!0,uuid:()=>Math.random().toString(36).substring(2,15)+Math.random().toString(36).substring(2,15),fromUUID:i=>i}}}static injectUUIDModule(e){K.UUID=e}static validateGenerationTarget(e,t){let i=JSON.parse(JSON.stringify(e));const a=[];return a.push(...Be(i)),{errors:a,modifiedData:i}}async inject(...e){return await Promise.all(e.map(t=>new Promise(async i=>{await t.init(this),i(null)}))),this}validateGeneratedUpdate(e){return{errors:[],modifiedData:e}}addSelfToProject(){return{affected:v([]),self:this}}get instancesList(){return Object.values(this.instances)}isOperationDeclaration(e){return this.operationDeclarations.includes(e)}isGlobalEventActionDescriptor(e){return this.globalEventActionDescriptors.includes(e)}isLoopDeclaration(e){return this.loopDeclarations.includes(e)}isConditionDeclaration(e){return this.conditionDeclarations.includes(e)}initChildren(){return this.entities=this.initialData.entities.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.projects=this.initialData.projects.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.functions=this.initialData.functions.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.events=this.initialData.events.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.variableDeclarations=this.initialData.variableDeclarations.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.variableInstances=this.initialData.variableInstances.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.conditions=this.initialData.conditions.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.operations=this.initialData.operations.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.functionCalls=this.initialData.functionCalls.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.loops=this.initialData.loops.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.searches=this.initialData.searches.map(e=>{const t=R(e,this);return t.setParent(this),t.initChildren(),t}),this.attachOrphanReferences(),this.validate(),this}subscribeInstance(e){return(!this.instances[e.id]||this.instances[e.id]!==e)&&(this.instances[e.id]=e),this}subscribeBuiltInInstance(e){return(!this.builtInInstances[e.id]||this.builtInInstances[e.id]!==e)&&(this.builtInInstances[e.id]=e),this}subscribe(){return this}unsubscribe(){return this}unsubscribeInstance(e){return delete this.instances[e.id],this}findSubscribedInstance(e){return this.instances[e.id]||null}findSubscribedBuiltInInstance(e){return this.builtInInstances[e.id]||null}get(e){return this.instances[e]||this.builtInInstances[e]||null}getManaged(e){return this.instances[e]||null}getBuiltIn(e){return this.builtInInstances[e]||null}findSubscribedInstanceFromReference(e){return this.instances[e.entityId]||null}findSubscribedBuiltInInstanceFromReference(e){return this.builtInInstances[e.entityId]||null}sync(e){return this.version=e.version||this.version,this.name=e.name||this.name,this.description=e.description||this.description,this.x=e.x||this.x,this.y=e.y||this.y,this}async load(){return this}async create(){return this}async update(e){return this}async delete(){return this}remove({ignoreUpstream:e}={ignoreUpstream:!1}){return{affected:[],removed:[]}}restore({seenEntities:e}={seenEntities:new Set}){return{affected:[],self:this}}getAllBuiltInIds(){const e=new Set;return[...this.primitives.flatMap(t=>t.toFlatIds(e)),...this.builtInBaseEntities.flatMap(t=>t.toFlatIds(e)),...this.operationDeclarations.flatMap(t=>t.toFlatIds(e)),...this.globalEventActionDescriptors.flatMap(t=>t.toFlatIds(e)),...this.loopDeclarations.flatMap(t=>t.toFlatIds(e)),...this.conditionDeclarations.flatMap(t=>t.toFlatIds(e)),...this.valueDescriptors.flatMap(t=>t.toFlatIds(e)),...this.dataTypes.flatMap(t=>t.toFlatIds(e))]}getAllBuiltIn(){const e=new Set;return[...this.primitives.flatMap(t=>t.toFlat(e)),...this.builtInBaseEntities.flatMap(t=>t.toFlat(e)),...this.operationDeclarations.flatMap(t=>t.toFlat(e)),...this.globalEventActionDescriptors.flatMap(t=>t.toFlat(e)),...this.loopDeclarations.flatMap(t=>t.toFlat(e)),...this.conditionDeclarations.flatMap(t=>t.toFlat(e)),...this.valueDescriptors.flatMap(t=>t.toFlat(e)),...this.dataTypes.flatMap(t=>t.toFlat(e))]}toFlat(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[...this.entities.flatMap(i=>i.toFlat(e)),...this.functions.flatMap(i=>i.toFlat(e)),...this.events.flatMap(i=>i.toFlat(e)),...this.projects.flatMap(i=>i.toFlat(e)),...this.variableDeclarations.flatMap(i=>i.toFlat(e)),...this.variableInstances.flatMap(i=>i.toFlat(e)),...this.conditions.flatMap(i=>i.toFlat(e)),...this.operations.flatMap(i=>i.toFlat(e)),...this.functionCalls.flatMap(i=>i.toFlat(e)),...this.loops.flatMap(i=>i.toFlat(e)),...this.searches.flatMap(i=>i.toFlat(e))])}toFlatIds(e=new Set){return e.has(this.id)?[]:(e.add(this.id),Array.from(e))}toJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,entities:this.entities.map(e=>e.toJSON()),functions:this.functions.map(e=>e.toJSON()),events:this.events.map(e=>e.toJSON()),projects:this.projects.map(e=>e.toJSON()),variableDeclarations:this.variableDeclarations.map(e=>e.toJSON()),variableInstances:this.variableInstances.map(e=>e.toJSON()),conditions:this.conditions.map(e=>e.toJSON()),operations:this.operations.map(e=>e.toJSON()),functionCalls:this.functionCalls.map(e=>e.toJSON()),loops:this.loops.map(e=>e.toJSON()),searches:this.searches.map(e=>e.toJSON())}}toReference(){return{id:this.id+"--"+K.UUID.uuid()+"--ref",type:r.GenericReference,entityId:this.id,entityType:this.type}}toShallowJSON(){return{id:this.id,version:this.version,type:this.type,name:this.name,description:this.description,entities:this.entities.map(e=>e.toReference()),functions:this.functions.map(e=>e.toReference()),events:this.events.map(e=>e.toReference()),projects:this.projects.map(e=>e.toReference()),variableDeclarations:this.variableDeclarations.map(e=>e.toReference()),variableInstances:this.variableInstances.map(e=>e.toReference()),conditions:this.conditions.map(e=>e.toReference()),operations:this.operations.map(e=>e.toReference()),functionCalls:this.functionCalls.map(e=>e.toReference()),loops:this.loops.map(e=>e.toReference()),searches:this.searches.map(e=>e.toReference())}}toFlatJSON(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[...this.entities.flatMap(i=>i.toFlatJSON(e)),...this.functions.flatMap(i=>i.toFlatJSON(e)),...this.events.flatMap(i=>i.toFlatJSON(e)),...this.projects.flatMap(i=>i.toFlatJSON(e)),...this.variableDeclarations.flatMap(i=>i.toFlatJSON(e)),...this.variableInstances.flatMap(i=>i.toFlatJSON(e)),...this.conditions.flatMap(i=>i.toFlatJSON(e)),...this.operations.flatMap(i=>i.toFlatJSON(e)),...this.functionCalls.flatMap(i=>i.toFlatJSON(e)),...this.loops.flatMap(i=>i.toFlatJSON(e)),...this.searches.flatMap(i=>i.toFlatJSON(e))])}toGenerationTarget(){return{id:this.id,type:this.type,name:this.name,description:this.description}}toFlatGenerationTarget(e=new Set){return e.has(this.id)?[]:(e.add(this.id),[...this.entities.flatMap(i=>i.toFlatGenerationTarget(e)),...this.functions.flatMap(i=>i.toFlatGenerationTarget(e)),...this.events.flatMap(i=>i.toFlatGenerationTarget(e)),...this.projects.flatMap(i=>i.toFlatGenerationTarget(e)),...this.variableDeclarations.flatMap(i=>i.toFlatGenerationTarget(e)),...this.variableInstances.flatMap(i=>i.toFlatGenerationTarget(e)),...this.conditions.flatMap(i=>i.toFlatGenerationTarget(e)),...this.operations.flatMap(i=>i.toFlatGenerationTarget(e)),...this.functionCalls.flatMap(i=>i.toFlatGenerationTarget(e)),...this.loops.flatMap(i=>i.toFlatGenerationTarget(e)),...this.searches.flatMap(i=>i.toFlatGenerationTarget(e))])}clearErrors(){return this.errors=[],this.entities.forEach(e=>e.clearErrors()),this.projects.forEach(e=>e.clearErrors()),this.functions.forEach(e=>e.clearErrors()),this.events.forEach(e=>e.clearErrors()),this.variableDeclarations.forEach(e=>e.clearErrors()),this.variableInstances.forEach(e=>e.clearErrors()),this.conditions.forEach(e=>e.clearErrors()),this.operations.forEach(e=>e.clearErrors()),this.functionCalls.forEach(e=>e.clearErrors()),this.loops.forEach(e=>e.clearErrors()),this.searches.forEach(e=>e.clearErrors()),this}validate(){const e=D8(),t=this.toJSON();return e.safeParse(t),this.validateChildren(),{success:!0,error:null,data:t}}validateChildren(){this.entities.forEach(e=>e.validate()),this.projects.forEach(e=>e.validate()),this.functions.forEach(e=>e.validate()),this.events.forEach(e=>e.validate()),this.variableDeclarations.forEach(e=>e.validate()),this.variableInstances.forEach(e=>e.validate()),this.conditions.forEach(e=>e.validate()),this.operations.forEach(e=>e.validate()),this.functionCalls.forEach(e=>e.validate()),this.loops.forEach(e=>e.validate()),this.searches.forEach(e=>e.validate())}getErrors(){return[...this.errors,...this.entities.flatMap(t=>t.getErrors()),...this.projects.flatMap(t=>t.getErrors()),...this.functions.flatMap(t=>t.getErrors()),...this.events.flatMap(t=>t.getErrors()),...this.variableDeclarations.flatMap(t=>t.getErrors()),...this.variableInstances.flatMap(t=>t.getErrors()),...this.conditions.flatMap(t=>t.getErrors()),...this.operations.flatMap(t=>t.getErrors()),...this.functionCalls.flatMap(t=>t.getErrors()),...this.loops.flatMap(t=>t.getErrors()),...this.searches.flatMap(t=>t.getErrors())]}getShallowErrors(){return this.errors}clone(){return new K(this.toJSON())}getCustomEntity(e){return this.entities.find(t=>t.id===e)||null}addCustomEntityFromTransfer(e){const t=R(e,this);return this.addCustomEntity(t),t}addCustomEntity(e){return this.entities.includes(e)||this.entities.push(e),e}addFunctionDeclarationFromTransfer(e){const t=R(e,this);return this.addFunctionDeclaration(t),t}addFunctionDeclaration(e){return this.functions.includes(e)||this.functions.push(e),e}addFunctionCallFromTransfer(e){const t=R(e,this);return this.addFunctionCall(t),t}addFunctionCall(e){return this.functionCalls.includes(e)||this.functionCalls.push(e),e}addVariableDeclarationFromTransfer(e){const t=R(e,this);return this.addVariableDeclaration(t),t}addVariableDeclaration(e){return this.variableDeclarations.includes(e)||this.variableDeclarations.push(e),e}addVariableInstanceFromTransfer(e){const t=R(e,this);return this.addVariableInstance(t),t}addVariableInstance(e){return this.variableInstances.includes(e)||this.variableInstances.push(e),e}addInstalledProjectFromTransfer(e){const t=R(e,this);return this.addInstalledProject(t),this}addInstalledProject(e){return this.projects.includes(e)||this.projects.push(e),this}addGlobalEventFromTransfer(e){const t=R(e,this);return this.addGlobalEvent(t),this}addGlobalEvent(e){return this.events.includes(e)||this.events.push(e),this}addConditionFromTransfer(e){const t=R(e,this);return this.addCondition(t),this}addCondition(e){return this.conditions.includes(e)||this.conditions.push(e),this}addOperationFromTransfer(e){const t=R(e,this);return this.addOperation(t),this}addOperation(e){return this.operations.includes(e)||this.operations.push(e),this}addLoopFromTransfer(e){const t=R(e,this);return this.addLoop(t),this}addLoop(e){return this.loops.includes(e)||this.loops.push(e),this}addSearchFromTransfer(e){const t=R(e,this);return this.addSearch(t),this}addSearch(e){return this.searches.includes(e)||this.searches.push(e),this}removeCustomEntity(e){const t=this.entities.findIndex(i=>i.id===e.id);if(t>-1){const i=this.entities[t];return this.entities.splice(t,1),i}return null}removeFunctionDeclaration(e){const t=this.functions.findIndex(i=>i.id===e.id);if(t>-1){const i=this.functions[t];return this.functions.splice(t,1),i}return null}removeExternalProject(e){const t=this.projects.findIndex(i=>i.id===e.id);if(t>-1){const i=this.projects[t];return this.projects.splice(t,1),i}return null}removeGlobalEvent(e){const t=this.events.findIndex(i=>i.id===e.id);if(t>-1){const i=this.events[t];return this.events.splice(t,1),i}return null}removeTopLevelVariableDeclaration(e){if(e.type!==r.VariableDeclaration)return null;const t=this.variableDeclarations.findIndex(i=>i.id===e.id);if(t>-1){const i=this.variableDeclarations[t];return this.variableDeclarations.splice(t,1),i}return null}getEntryPoints(){return[...this.functions,...this.events,...this.entities.flatMap(t=>t.methods)]}getFunctionDeclaration(e){return this.functions.find(t=>t.id===e)||null}getConditions(){return[...this.conditions,...this.getEntryPoints().reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Condition)]},[]),...this.functionCalls.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Condition)]},[]),...this.operations.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Condition)]},[]),...this.loops.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Condition)]},[]),...this.searches.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Condition)]},[])]}getOperations(){return[...this.operations,...this.getEntryPoints().reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Operation)]},[]),...this.functionCalls.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Operation)]},[]),...this.conditions.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Operation)]},[]),...this.loops.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Operation)]},[]),...this.searches.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.Operation)]},[])]}getFunctionCalls(){return[...this.functionCalls,...this.getEntryPoints().reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.FunctionCall)]},[]),...this.conditions.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.FunctionCall)]},[]),...this.operations.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.FunctionCall)]},[]),...this.loops.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.FunctionCall)]},[]),...this.searches.reduce((t,i)=>{const a=Se(i);return[...t,...a.filter(s=>s.type===r.FunctionCall)]},[])]}getVariables(){return[...this.variableDeclarations,...this.getEntryPoints().reduce((t,i)=>{const a=te(i);return[...t,...a]},[]),...this.functionCalls.reduce((t,i)=>{const a=te(i);return[...t,...a]},[]),...this.conditions.reduce((t,i)=>{const a=te(i);return[...t,...a]},[]),...this.operations.reduce((t,i)=>{const a=te(i);return[...t,...a]},[]),...this.loops.reduce((t,i)=>{const a=te(i);return[...t,...a]},[]),...this.searches.reduce((t,i)=>{const a=te(i);return[...t,...a]},[])]}getVariableInstances(){return[...this.variableInstances,...this.getEntryPoints().reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[]),...this.functionCalls.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[]),...this.conditions.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[]),...this.operations.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[]),...this.loops.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[]),...this.searches.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableInstance);return[...t,...s]},[])]}getVariableDeclarations(){return v([...this.variableDeclarations,...this.getEntryPoints().reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[]),...this.functionCalls.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[]),...this.conditions.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[]),...this.operations.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[]),...this.loops.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[]),...this.searches.reduce((t,i)=>{const s=te(i).filter(o=>o.type===r.VariableDeclaration);return[...t,...s]},[])])}attachOrphanReferences(){const e=this.getVariableInstances(),t=this.getVariableDeclarations();return e.forEach(i=>{if(!i.declaration){const a=i.initialData,s=a.declaration.entityId||a.declaration.id,o=t.find(l=>l.id===s);o&&i.setDeclaration(o)}}),this}getBuiltInPersistedEntity(){return this.builtInBaseEntities.find(e=>e.name===V.PERSISTED_ENTITY)||null}};c(K,"UUID",{isBackup:!0,uuid:()=>Math.random().toString(36).substring(2,15)+Math.random().toString(36).substring(2,15),fromUUID:e=>e}),c(K,"MUTABLE_BASE_PROPERTIES",["name","description"]),c(K,"INMUTABLE_BASE_PROPERTIES",["id","type","version"]),c(K,"BASE_PROPERTIES",[...K.MUTABLE_BASE_PROPERTIES,...K.INMUTABLE_BASE_PROPERTIES]),c(K,"MUTABLE_META_PROPERTIES",[...K.MUTABLE_BASE_PROPERTIES,"x","y"]),c(K,"INMUTABLE_META_PROPERTIES",[...K.INMUTABLE_BASE_PROPERTIES]),c(K,"META_PROPERTIES",[...K.MUTABLE_META_PROPERTIES,...K.INMUTABLE_META_PROPERTIES]),c(K,"MUTABLE_UPSTREAM_PROPERTIES",[]),c(K,"INMUTABLE_UPSTREAM_PROPERTIES",["primitives","builtInBaseEntities","operationDeclarations","globalEventActionDescriptors","loopDeclarations","builtInInstances"]),c(K,"UPSTREAM_PROPERTIES",[...K.MUTABLE_UPSTREAM_PROPERTIES,...K.INMUTABLE_UPSTREAM_PROPERTIES]),c(K,"MUTABLE_DOWNSTREAM_PROPERTIES",["entities","projects","functions","events","variableDeclarations","variableInstances","conditions","operations","functionCalls","loops","searches"]),c(K,"INMUTABLE_DOWNSTREAM_PROPERTIES",[]),c(K,"DOWNSTREAM_PROPERTIES",[...K.MUTABLE_DOWNSTREAM_PROPERTIES,...K.INMUTABLE_DOWNSTREAM_PROPERTIES]),c(K,"PROPERTIES",[...K.META_PROPERTIES,...K.UPSTREAM_PROPERTIES,...K.DOWNSTREAM_PROPERTIES]);let w=K;class dI extends Fe{constructor(t){super(xt,t);c(this,"id",Oe.Parallel);c(this,"name",Oe.Parallel);c(this,"description","Execute a list of actions one after the other");c(this,"version",1);c(this,"autoexecutable",!0);c(this,"initialData",xt);c(this,"type",r.ActionDescriptor);c(this,"fixedArguments",[]);c(this,"fixedReturns",[]);c(this,"error",null);c(this,"dynamicArgumentTypes",null);c(this,"dynamicReturnTypes",null);c(this,"project");this.project=t,this.fixedArguments=xt.fixedArguments.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.fixedReturns=xt.fixedReturns.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.error=xt.error?R(xt.error,this.project):null}}class uI extends Fe{constructor(t){super(dt,t);c(this,"id",dt.id);c(this,"name",dt.name);c(this,"description",dt.description);c(this,"version",dt.version);c(this,"autoexecutable",!1);c(this,"initialData",dt);c(this,"type",r.ActionDescriptor);c(this,"fixedArguments",[]);c(this,"fixedReturns",[]);c(this,"error",null);c(this,"dynamicArgumentTypes",null);c(this,"dynamicReturnTypes",null);c(this,"project");this.project=t,this.fixedArguments=dt.fixedArguments.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.fixedReturns=dt.fixedReturns.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.error=dt.error?R(dt.error,this.project):null}}class pI extends Fe{constructor(t){super(dn,t);c(this,"id",Oe.Sequential);c(this,"name",Oe.Sequential);c(this,"description","Execute a list of actions one after the other");c(this,"version",1);c(this,"autoexecutable",!0);c(this,"initialData",dn);c(this,"type",r.ActionDescriptor);c(this,"fixedArguments",[]);c(this,"fixedReturns",[]);c(this,"error",null);c(this,"dynamicArgumentTypes",null);c(this,"dynamicReturnTypes",null);c(this,"project");this.project=t,this.fixedArguments=dn.fixedArguments.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.fixedReturns=dn.fixedReturns.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.error=dn.error?R(dn.error,this.project):null}}function n5(n){const e=[new pI(n),new dI(n),new uI(n),new Fe(Ii,n),new Fe(Xn,n),new Fe(Qn,n),new Fe(Na,n),new Fe($o,n),new Fe(Fo,n),new Fe(Go,n),new Fe(wa,n),new Fe(gi,n)];return e.forEach(t=>{t.initChildren(),n.subscribeBuiltInInstance(t)}),n.operationDeclarations=e,e}class yI extends Gt{constructor(t){super(Le,t);c(this,"initialData");c(this,"id",V.PERSISTED_ENTITY);c(this,"version",1);c(this,"name",V.PERSISTED_ENTITY);c(this,"description",Le.description);c(this,"type",r.BuiltInBaseEntity);c(this,"abstract",Le.abstract);c(this,"static",Le.static);c(this,"properties",[]);c(this,"methods",[]);c(this,"abstractMethods",[]);c(this,"extends",[]);c(this,"errors",[]);c(this,"project");this.initialData=Le,this.project=t,this.id=Le.id,this.version=Le.version,this.name=Le.name,this.static=Le.static,this.abstract=Le.abstract,this.properties=this.initialData.properties.map(i=>{const a=R(i,this.project);return a.setParent(this),a.initChildren(),a}),this.methods=this.initialData.methods.map(i=>{const a=R(i,this.project);return a.parent=this,a}),this.abstractMethods=this.initialData.abstractMethods.map(i=>{const a=R(i,this.project);return a.parent=this,a}),this.extends=this.initialData.extends.map(i=>R(i,this.project))}}function r5(n){const e=[new yI(n),new Gt(ka,n),new Gt(On,n),new Gt(rl,n),new Gt(xa,n)];return e.forEach(t=>{n.subscribeBuiltInInstance(t)}),n.builtInBaseEntities=e,e}function i5(n){const e=[new Ft(k,n),new Ft(An,n),new Ft(Ce,n),new Ft(et,n),new Ft(Sn,n),new Ft(cn,n),new Ft(Ba,n),new Ft(_o,n)];return e.forEach(t=>{n.subscribeBuiltInInstance(t)}),n.primitives=e,e}function a5(n){const e=[new Fe(Ha,n)];return e.forEach(t=>{t.initChildren(),n.subscribeBuiltInInstance(t)}),n.globalEventActionDescriptors=e,e}function s5(n){const e=[new Fe(Kn,n),new Fe(zo,n)];return e.forEach(t=>{t.initChildren(),n.subscribeBuiltInInstance(t)}),n.loopDeclarations=e,e}function o5(n){const e=[new wr(ol,n)];return e.forEach(t=>{t.initChildren(),n.subscribeBuiltInInstance(t)}),n.valueDescriptors=e,e}function l5(n){const e=[new Fe(er,n),new Fe(Ur,n)];return e.forEach(t=>{t.initChildren()}),n.conditionDeclarations=e,e}const Vr={},Ao={};async function c5(n,e={}){const t={...Db};return t.id=n.id,e.empty?{data:{id:n.id,type:r.Project,version:1,name:null,description:null,projects:[],entities:[],operations:[],functions:[],variableDeclarations:[],variableInstances:[],functionCalls:[],conditions:[],loops:[],searches:[],events:[]}}:{data:t}}function hI(n){const e=new w(n);return i5(e),r5(e),n5(e),a5(e),s5(e),o5(e),l5(e),e.initChildren(),e}async function d5(n,e={}){if(n.id&&Vr[n.id])return Vr[n.id];if(n.id&&Ao[n.id])return await Ao[n.id],Vr[n.id];const t=c5(n,e);n.id&&(Ao[n.id]=t);const i=await t;if(i.data){const a=hI(i.data);return Vr[n.id]=a,n.id&&delete Ao[n.id],a}return null}function u5(n){return Vr[n.id]&&delete Vr[n.id],null}const p5="test_primitive_entities_export";u.AI_VALUE_CONNECTION_GENERATION_ACTION_EXPLANATION=_d,u.ActionDescriptorState=Fe,u.ActionDescriptorValuesType=U,u.ActionInputMapState=l3,u.ActionOutputMapState=u3,u.AppendToListOperationInputIds=vp,u.AppendToListOperationOutputIds=Ip,u.ArgumentDeclarationState=Cr,u.BREAK_AND_CONTINUE_STATEMENTS_RETURN_DECLARATIONS_EXPLANATION=Od,u.BUILT_IN_BASE_ENTITY_IDS=x,u.BUILT_IN_ENTITY_TYPES=Gr,u.BaseCanvasDraggableState=W9,u.BaseEntityNames=V,u.BaseState=J9,u.BaseValueDescriptorIds=wo,u.BreakStatementState=Ei,u.BuiltInBaseEntityState=Gt,u.CACHED_PROJECTS_BY_ID=Vr,u.CALLABLE_ENTITIES_EXPLANATION=I3,u.CALLABLE_TYPES=Pn,u.CALLER_ENTITIES_EXPLANATION=Sv,u.CALLER_TYPES=ln,u.CALLS_UPDATE_EXPLANATION=qn,u.COMPARISON_CONDITIONS=Pm,u.CONDITIONS=qI,u.CUSTOM_ENTITY_OPERATIONS=xy,u.CallableEntityClass=Y9,u.CallerEntityClass=Dd,u.ChildEntityState=H9,u.ComparisonOperatorTypes=_e,u.ConditionState=Dr,u.ContinueStatementState=Tt,u.CreateNewInputIds=yy,u.CreateNewOutputIds=hy,u.CustomEntityState=Nr,u.DRAGGABLE_CALLABLE_TYPES=Co,u.DRAGGABLE_CALLER_TYPES=zd,u.DRAGGABLE_ELEMENT_TYPES=Bo,u.DRAGGABLE_EXECUTABLE_TYPES=EI,u.DRAGGABLE_PASS_THROUGH_CALLABLE_TYPES=Oo,u.DataTypeCompatibilityTypes=Lt,u.DataTypeParentChildRelation=Ue,u.DataTypeState=hi,u.ENTITIES_WITH_VALLUES_EXPLANATION=yo,u.ENTITY_TYPES=RI,u.ENTITY_WITH_LOGIC_SCOPE_TYPES=ct,u.ENTITY_WITH_NAMES_TYPES=Zd,u.ENTITY_WITH_VALUE_TYPES=Yd,u.ENTRY_POINT_ENTITIES_EXPLANATION=Ia,u.ENTRY_POINT_TYPES=Me,u.EVENT_TYPES=Lr,u.EXECUTABLE_TYPES=TI,u.EXECUTION_OPERATIONS=py,u.EntityError=cr,u.EntityErrorSeverity=T,u.EntityGenerationError=E,u.EntityGenerationErrorCode=h,u.EntityInstanceErrorCode=_,u.EntityOperations=Ze,u.EntityType=r,u.EntityWithLogicScopeClass=Q9,u.EntityWithValueClass=X9,u.EntryPointEntityClass=z9,u.ExecutionOperations=Oe,u.FunctionCallState=_r,u.FunctionDeclarationState=gr,u.GLOBAL_EVENT_DECLARATIONS=JI,u.GetLastInListOperationInputIds=dp,u.GetLastInListOperationOutputIds=up,u.GlobalEventNames=on,u.GlobalEventState=fi,u.HTTPOperations=Xe,u.HTTP_OPERATIONS=gh,u.InputMapState=gn,u.InstalledProjectState=Or,u.InternalCallState=mi,u.JoinListOperationInputIds=Bu,u.JoinListOperationOutputIds=wu,u.JoinStringOperationInputIds=mu,u.JoinStringOperationOutputIds=Tu,u.LIST_OPERATIONS=$p,u.ListOperations=W,u.LoopState=Ir,u.LoopTypes=Q,u.NON_INTERACTIVE_BASE_ENTITIES_EXPLANATION=Jn,u.NUMBER_OPERATIONS=fu,u.NumberAdditionOperationInputIds=nu,u.NumberAdditionOperationOutputIds=ru,u.NumberOperations=lt,u.OPERATION_DECLARATIONS=gI,u.OperationState=vr,u.OutputMapParentChildRelation=Hd,u.OutputMapState=vn,u.PARENT_AUTO_CALCULATION_FROM_CALLER_EXPLANATION=ho,u.PASS_THROUGH_CALLABLE_ENTITIES_EXPLANATION=jn,u.PASS_THROUGH_CALLABLE_TYPES=$e,u.PROPERTY_NOT_VALUE_READER_WRITTER_EXPLANATION=wd,u.ParallelExecutionOperation=dI,u.ParallelExecutionOperationInputIds=Lp,u.ParallelExecutionOperationOutputIds=Gp,u.PassThroughCallableEntityClass=Z9,u.PersistedEntity=yI,u.PersistedEntityMethods=Ot,u.PrimitiveEntityState=Ft,u.PrimitiveTypes=A,u.PrimitiveValueState=Ti,u.ProjectState=w,u.PropertyState=br,u.RETURN_STATEMENT_RETURN_DECLARATIONS_EXPLANATION=D3,u.ReturnDeclarationState=_t,u.ReturnStatementState=Br,u.STANDALONE_CONDITIONS=Rm,u.STRING_OPERATIONS=Cu,u.ScopeCompatibilityType=Po,u.SearchState=Sr,u.SequentialExecutionOperation=pI,u.SequentialExecutionOperationInputIds=ty,u.SequentialExecutionOperationOutputIds=ny,u.SharedEntityErrorCode=D,u.SharedStateFunctionality=Dv,u.SplitListOperationInputIds=Wu,u.SplitListOperationOutputIds=Hu,u.StandaloneOperatorTypes=Nt,u.StringOperations=Ae,u.TERMINATION_TYPES=Ne,u.USER_MANAGED_ENTITY_TYPES=bI,u.UserManagedEntityStateFunctionality=q9,u.VALUE_READING_ENTITIES_EXPLANATION=Bd,u.VALUE_READING_TYPES=zn,u.VALUE_WRITING_ENTITIES_EXPLANATION=Ov,u.VALUE_WRITING_TYPES=Ve,u.VARIABLE_DATA_TYPE_INFERRANCE_EXPLANATION=Cd,u.VARIABLE_TYPES=xe,u.ValidationInputIds=Sy,u.ValidationOutputIds=Oy,u.ValueAutogenerationType=qe,u.ValueDescriptorParentChildRelation=M,u.ValueDescriptorState=wr,u.ValueReadingEntityClass=ga,u.ValueWritingEntityClass=va,u.VariableDeclarationState=Pr,u.VariableInputMapState=o3,u.VariableInstanceState=Ar,u.VariableOutputMapState=d3,u.WaitOperation=uI,u.WaitOperationInputIds=Yp,u.WaitOperationOutputIds=zp,u._VALUE_READING_TYPES=fI,u._VALUE_WRITING_TYPES=mI,u.appendToListOperation=Na,u.appendToListOperationElementToAppendArgument=xo,u.appendToListOperationElementToAppendArgumentParentRef=wp,u.appendToListOperationElementToAppendArgumentRef=Ap,u.appendToListOperationError=Vp,u.appendToListOperationErrorParentRef=Np,u.appendToListOperationListArgument=Uo,u.appendToListOperationListArgumentParentRef=Bp,u.appendToListOperationListArgumentRef=Dp,u.appendToListOperationListDataType=Pp,u.appendToListOperationResultListDataType=Cp,u.appendToListOperationResultListReturn=Mp,u.appendToListOperationResultListReturnParentRef=_p,u.appendToListOperationResultListReturnRef=Op,u.appendToListOperationSecondListDataType=Sp,u.asGenerationActionExample=an,u.baseHttpRequestFunctionDeclaration=Ii,u.baseHttpRequestFunctionDeclarationErrorValueDescriptor=Yo,u.baseHttpRequestFunctionDeclarationErrorValueDescriptorDatatype=bh,u.baseHttpRequestFunctionDeclarationErrorValueDescriptorRef=Rh,u.baseHttpRequestFunctionDeclarationRef=fh,u.baseHttpRequestFunctionDeclarationRefEight=Th,u.baseHttpRequestFunctionDeclarationRefFive=yh,u.baseHttpRequestFunctionDeclarationRefFour=ph,u.baseHttpRequestFunctionDeclarationRefNine=Eh,u.baseHttpRequestFunctionDeclarationRefSeven=mh,u.baseHttpRequestFunctionDeclarationRefSix=hh,u.baseHttpRequestFunctionDeclarationRefThree=uh,u.baseHttpRequestFunctionDeclarationRefTwo=dh,u.booleanPrototype=An,u.capitalizeFirstLetter=io,u.checkAreCustomEntitiesCompatibleAsDataType=cv,u.checkAreDataTypesCompatible=Ht,u.checkArePropertiesCompatibleAsDataType=lv,u.checkIsBranchDependentButNotDirectlyOnBranch=Pa,u.checkIsBranchDependentOnBranch=M3,u.checkIsCallableEntityReachable=Oa,u.checkIsCanvasEntity=Z3,u.checkIsDetachedBranch=iI,u.checkIsDetachedBranchShallow=Jd,u.checkIsGlobalVariable=Y3,u.checkIsGloballyDeclared=qd,u.checkIsMethod=oI,u.checkIsNestedScope=Do,u.checkScopeCompatibility=Aa,u.createEntityError=H,u.createNewInstanceOperation=Xn,u.createNewInstanceOperationEntityToInstanciateArgument=vy,u.createNewInstanceOperationEntityToInstanciateArgumentRef=Ry,u.createNewInstanceOperationEntityToInstanciateDataType=by,u.createNewInstanceOperationError=Ay,u.createNewInstanceOperationErrorParentRef=Py,u.createNewInstanceOperationNewEntityDataArgument=Ey,u.createNewInstanceOperationNewEntityDataArgumentDataType=Ty,u.createNewInstanceOperationNewEntityDataArgumentDataTypeParentRef=my,u.createNewInstanceOperationNewEntityDataArgumentParentRef=fy,u.createNewInstanceOperationOutputEntityDeclaration=Dy,u.createNewInstanceOperationOutputEntityDeclarationParentRef=Iy,u.createNewInstanceOperationRef=gy,u.createSemanticId=Ke,u.createStateFromGenerationTargetType=t5,u.createStateFromType=Ut,u.createStateFromTypeAndSubscribe=R,u.cronJobBuiltInBaseEntity=rl,u.cronJobBuiltInBaseEntityExpressionProperty=fm,u.cronJobBuiltInBaseEntityExpressionPropertyDataTypeRef=xI,u.cronJobBuiltInBaseEntityExpressionPropertyRef=ym,u.cronJobBuiltInBaseEntityRef=hm,u.cronJobTriggeredFunctionDeclarationBlueprint=nl,u.cronJobTriggeredFunctionDeclarationBlueprintParentRef=um,u.customEntityToZodSchema=jm,u.dataTypeCompatibilityToErrorExplanation=$v,u.datePrototype=cn,u.dateValueAutogenerationSchema=pc,u.deletePersistedEntityMethod=tl,u.deletePersistedEntityMethodParentRef=jf,u.deleteRootProject=u5,u.endpointBuiltInBaseEntity=ka,u.endpointBuiltInBaseEntityRef=kh,u.endpointBuiltInBaseEntityRefFour=wf,u.endpointBuiltInBaseEntityRefThree=Xh,u.endpointBuiltInBaseEntityRefTwo=Hh,u.endpointBuiltInCorsProperty=jh,u.endpointBuiltInCorsPropertyDataType=xh,u.endpointBuiltInCorsPropertyDataTypeRef=Fh,u.endpointBuiltInCorsPropertyRef=Uh,u.endpointBuiltInMethodProperty=Xo,u.endpointBuiltInMethodPropertyDataType=Zh,u.endpointBuiltInMethodPropertyDataTypeRef=Yh,u.endpointBuiltInMethodPropertyRef=zh,u.endpointBuiltInPathProperty=Zo,u.endpointBuiltInPathPropertyDataType=Wh,u.endpointBuiltInPathPropertyDataTypeRef=qh,u.endpointBuiltInPathPropertyRef=Jh,u.endpointPathParamsArgumentDeclaration=yf,u.endpointPathParamsArgumentDeclarationRef=lf,u.endpointPathParamsVariableDataType=cf,u.endpointPathParamsVariableDataTypeRef=of,u.endpointReachedTriggerActionDescriptor=Qo,u.endpointReachedTriggerActionDescriptorRef=df,u.endpointReachedTriggerActionDescriptorRefFour=mf,u.endpointReachedTriggerActionDescriptorRefThree=hf,u.endpointReachedTriggerActionDescriptorRefTwo=pf,u.endpointRequestBodyArgumentDeclaration=Tf,u.endpointRequestBodyArgumentDeclarationRef=tf,u.endpointRequestBodyVariableDataType=nf,u.endpointRequestHeadersArgumentDeclaration=uf,u.endpointRequestHeadersArgumentDeclarationRef=Kh,u.endpointRequestHeadersVariableDataType=ef,u.endpointRequestHeadersVariableDataTypeRef=Qh,u.endpointRequestQueryParamsArgumentDeclaration=ff,u.endpointRequestQueryParamsArgumentDeclarationRef=af,u.endpointRequestQueryParamsVariableDataType=sf,u.endpointRequestQueryParamsVariableDataTypeRef=rf,u.endpointResponseBodyDataType=Of,u.endpointResponseBodyReturnDeclaration=Bf,u.endpointResponseBodyReturnDeclarationRef=Sf,u.endpointResponseCodeDataType=Rf,u.endpointResponseCodeReturnDeclaration=gf,u.endpointResponseCodeReturnDeclarationRef=Ef,u.endpointResponseHeadersDataType=Df,u.endpointResponseHeadersDataTypeRef=vf,u.endpointResponseHeadersReturnDeclaration=Af,u.endpointResponseHeadersReturnDeclarationRef=If,u.endpointReturnStatementRef=bf,u.endpointReturnStatementRefThree=Cf,u.endpointReturnStatementRefTwo=Pf,u.enumOptionsProperty=tu,u.enumOptionsPropertyDataType=Kd,u.enumOptionsPropertyDataTypeRef=Xd,u.enumOptionsPropertyRef=Qd,u.enumPrototype=Sn,u.enumPrototypeRef=eu,u.executionBuiltInEntity=al,u.executionBuiltInEntityAbortMethod=il,u.executionBuiltInEntityAbortMethodParentRef=mm,u.filterOutDuplicateEntities=v,u.filterOutDuplicateErrors=j4,u.findReferenceToSelfInList=Zv,u.findReferencesToSelfInProject=k3,u.flattenCalls=sn,u.flattenCanvasAncestorsUntil=Ro,u.flattenCustomEntityExtensionAndImplementationTypes=tI,u.flattenCustomEntityExtensionTypes=vo,u.flattenCustomEntityExtensions=xd,u.flattenCustomEntityImplementations=kd,u.flattenCustomEntityImplementionTypes=go,u.flattenDerivedCanvasEntities=At,u.flattenDetachedBranch=sI,u.flattenElementCalls=Se,u.flattenElementCallsOnTheSameScope=x3,u.flattenProjectElements=zv,u.flattenRelatedCanvasElementsOnTheLeft=eI,u.flattenRelatedCanvasElementsOnTheRight=Kv,u.flattenVariableReads=Yv,u.flattenVariableWrites=Hv,u.flattenVariables=te,u.fromZodParseToEntityGenerationErrors=Pd,u.generate=xP,u.generateActionExample=P3,u.generateExecutionDataType=P9,u.generateMutablePropertiesExplanation=co,u.generateRandomBoolean=fT,u.generateRandomDate=Hm,u.generateRandomDateAfter=qm,u.generateRandomDateBefore=Jm,u.generateRandomDateBetweenRange=Wm,u.generateRandomNumber=dT,u.generateRandomNumberAfter=oT,u.generateRandomNumberBefore=lT,u.generateRandomNumberBetweenRange=cT,u.generateRandomText=hT,u.generateRandomTextAfter=uT,u.generateRandomTextBefore=pT,u.generateRandomTextBetweenRange=yT,u.generateUniqueUUID=sT,u.getAllActionDescriptorsForConditions=To,u.getAllActionDescriptorsForGlobalEvents=fo,u.getAllActionDescriptorsForLoops=mo,u.getAllActionDescriptorsForOperations=C3,u.getAllGloballyDeclaredFunctionDeclarationsExplanation=Mv,u.getBaseBuiltInEntities=Hn,u.getBaseSchemaBasedOnType=Pv,u.getBuiltInEntityOwner=Yn,u.getCallableEntityReferenceSchema=We,u.getCallableEntityTypeSchema=zb,u.getCallerEntityReferenceSchema=Yx,u.getCallerEntityTypeSchema=Hx,u.getCalls=$d,u.getCanvasEntitiesDerivedFromInternalCalls=Qv,u.getCanvasEntitiesDerivedFromWrites=Ri,u.getCanvasEntityDerivedFromValueReadingEntity=Ud,u.getCanvasEntityReferenceSchema=u8,u.getCanvasEntityTypeSchema=d8,u.getChildrenEntityWithValues=V3,u.getCommonAncestor=Vd,u.getCommonChildren=Fv,u.getDeclaration=Er,u.getDeepestScope=cI,u.getDraggableCallableEntityReferenceSchema=Xb,u.getDraggableCallableEntityTypeSchema=Zb,u.getDraggableCallerEntityReferenceSchema=Zx,u.getDraggableCallerEntityTypeSchema=zx,u.getDraggableExecutableEntityReferenceSchema=e8,u.getDraggableExecutableEntityTypeSchema=Kx,u.getDraggablePassThroughCallableEntityReferenceSchema=Zs,u.getDraggablePassThroughCallableEntityTypeSchema=zs,u.getDraggablePlayableEntityReferenceSchema=a8,u.getDraggablePlayableEntityTypeSchema=i8,u.getEntityArgumentDeclarations=Gd,u.getEntityInputMaps=Xv,u.getEntityOutputMaps=J3,u.getEntityReferenceSchema=c8,u.getEntityReturnDeclarations=Fd,u.getEntityTypeSchema=l8,u.getEntityWithLogicScopeReferenceSchema=En,u.getEntityWithLogicScopeTypeSchema=t8,u.getEntityWithValueReferenceSchema=Yb,u.getEntityWithValueTypeSchema=Wx,u.getEntryPointEntityReferenceSchema=Je,u.getEntryPointEntityTypeSchema=Un,u.getEventEntityReferenceSchema=Hs,u.getEventEntityTypeSchema=Ws,u.getExecutableEntityReferenceSchema=Qx,u.getExecutableEntityTypeSchema=Xx,u.getExtendedBuiltInEntity=W3,u.getExtendedCustomEntity=rI,u.getGenerationTargetSchemaBasedOnType=Av,u.getHeadIfPartOfDetachedBranch=aI,u.getHighestScope=lI,u.getImplementedBuiltInEntity=H3,u.getIsInteractive=jd,u.getLastInListOperation=Fo,u.getLastInListOperationError=gp,u.getLastInListOperationErrorParentRef=bp,u.getLastInListOperationInputListArgument=Tp,u.getLastInListOperationInputListArgumentParentRef=mp,u.getLastInListOperationInputListArgumentRef=pp,u.getLastInListOperationInputListDataType=yp,u.getLastInListOperationOutputElementDataType=fp,u.getLastInListOperationOutputElementReturn=Rp,u.getLastInListOperationOutputElementReturnParentRef=Ep,u.getLastInListOperationOutputElementReturnRef=hp,u.getLinkedEntitiesFromArgumentDeclaration=U3,u.getLowestPersistedEntityImplementation=nI,u.getParentCanvasEntities=Et,u.getParentCanvasEntity=ze,u.getParentEntryPoint=N3,u.getPassThroughCallableEntityReferenceSchema=de,u.getPassThroughCallableEntityTypeSchema=Ys,u.getPlayableEntityReferenceSchema=r8,u.getPlayableEntityTypeSchema=n8,u.getProject=d5,u.getPrototypeByType=Io,u.getReferenceEntityId=C,u.getReferencedEntitiesStateOrErrors=po,u.getReferencedEntityStateOrErrors=Ad,u.getRelatedCanvasElementsOnTheLeft=Mr,u.getRelatedCanvasElementsOnTheRight=Wn,u.getRootEntryPointScopeOwner=Wd,u.getScopeOwner=Rt,u.getTerminationReferenceSchema=o8,u.getTerminationTypeSchema=s8,u.getUsedArgFromDeclaration=j3,u.getUsedReturnFromDeclaration=q3,u.getValueReadingEntityReferenceSchema=Hb,u.getValueReadingEntityTypeSchema=Tn,u.getValueWritingEntityReferenceSchema=Jx,u.getValueWritingEntityTypeSchema=ua,u.getVariableFromInputMapping=xv,u.getVariableFromReturnVariablePointer=qv,u.getVariableReferenceSchema=Fn,u.getVariableTypeSchema=pr,u.getVariablesFromArgumentDeclarations=bo,u.getVariablesFromInputMaps=kv,u.getVariablesFromOutputMapping=Jv,u.getVariablesFromOutputMaps=Wv,u.getVariablesFromReturnDeclarations=jv,u.getVariablesInSameOrHigherScope=fd,u.getWrites=Ld,u.groupCallsBasedOnParallelizableExecution=L3,u.handleAfterEntityImplementationSideEffects=Gv,u.handleBeforeEntityImplementationSideEffects=Lv,u.httpRequestBodyArgument=Ga,u.httpRequestBodyArgumentRef=eh,u.httpRequestBodyDataType=th,u.httpRequestHeadersArgument=La,u.httpRequestHeadersArgumentRef=Qy,u.httpRequestHeadersDataType=Ky,u.httpRequestMethodArgument=Va,u.httpRequestMethodArgumentRef=Zy,u.httpRequestMethodDataType=Xy,u.httpRequestMethodDataTypeRef=Yy,u.httpRequestQueryParamsArgument=Wo,u.httpRequestQueryParamsArgumentRef=Wy,u.httpRequestQueryParamsDataType=Hy,u.httpRequestVariableURLArgument=$a,u.httpRequestVariableURLArgumentRef=qy,u.httpRequestVariableURLDataType=Jy,u.httpRequestVariableURLDataTypeRef=ky,u.httpResponseBodyReturnDataType=ch,u.httpResponseBodyReturnDataTypeRef=oh,u.httpResponseBodyReturnReturn=vi,u.httpResponseBodyReturnReturnRef=lh,u.httpResponseCodeDataType=rh,u.httpResponseCodeReturn=Ho,u.httpResponseCodeReturnRef=nh,u.httpResponseHeadersDataType=sh,u.httpResponseHeadersDataTypeRef=ih,u.httpResponseHeadersReturn=Fa,u.httpResponseHeadersReturnRef=ah,u.implement=Eo,u.inferArgumentDeclarationDataType=dv,u.inferDataType=rn,u.inferInputMapDataType=uv,u.inferOutputMapDataType=hv,u.inferReturnDeclarationDataType=hd,u.inferVariableDeclarationDataType=yv,u.inferVariableInstanceDataType=pv,u.initProject=hI,u.iterateOverListActionDescriptor=Kn,u.iterateOverListActionDescriptorListArgumentDeclaration=Oh,u.iterateOverListActionDescriptorListArgumentDeclarationDataType=Ah,u.iterateOverListActionDescriptorListArgumentDeclarationDataTypeParentRef=Ph,u.iterateOverListActionDescriptorListArgumentDeclarationParentRef=Sh,u.iterateOverListActionDescriptorReturnDeclaration=Dh,u.iterateOverListActionDescriptorReturnDeclarationParentRef=Ih,u.joinListOperation=$o,u.joinListOperationError=Ju,u.joinListOperationErrorParentRef=qu,u.joinListOperationFirstListArgument=Fu,u.joinListOperationFirstListArgumentParentRef=Gu,u.joinListOperationFirstListArgumentRef=_u,u.joinListOperationFirstListDataType=Mu,u.joinListOperationResultListDataType=Lu,u.joinListOperationResultListReturn=ju,u.joinListOperationResultListReturnParentRef=ku,u.joinListOperationResultListReturnRef=$u,u.joinListOperationSecondListArgument=xu,u.joinListOperationSecondListArgumentParentRef=Uu,u.joinListOperationSecondListArgumentRef=Nu,u.joinListOperationSecondListDataType=Vu,u.joinListWithLastSeparator=L,u.joinStringOperation=gi,u.joinStringOperationError=Ou,u.joinStringOperationErrorParentRef=Su,u.joinStringOperationFirstStringArgument=_a,u.joinStringOperationFirstStringArgumentParentRef=Du,u.joinStringOperationFirstStringArgumentRef=Eu,u.joinStringOperationFirstStringDataType=Ru,u.joinStringOperationResultStringDataType=Iu,u.joinStringOperationResultStringReturn=bi,u.joinStringOperationResultStringReturnParentRef=Au,u.joinStringOperationResultStringReturnRef=vu,u.joinStringOperationSecondStringArgument=Ma,u.joinStringOperationSecondStringArgumentParentRef=Pu,u.joinStringOperationSecondStringArgumentRef=bu,u.joinStringOperationSecondStringDataType=gu,u.jsonPrototype=_o,u.keyValueParamBuiltInBaseEntity=xa,u.keyValueParamBuiltInBaseEntityNameProperty=Vh,u.keyValueParamBuiltInBaseEntityNamePropertyDataTypeRef=II,u.keyValueParamBuiltInBaseEntityNamePropertyParentRef=Nh,u.keyValueParamBuiltInBaseEntityNamePropertyRef=Mh,u.keyValueParamBuiltInBaseEntityValueProperty=Gh,u.keyValueParamBuiltInBaseEntityValuePropertyDataTypeRef=PI,u.keyValueParamBuiltInBaseEntityValuePropertyParentRef=Lh,u.keyValueParamBuiltInBaseEntityValuePropertyRef=$h,u.lowercaseFirstLetter=ov,u.manualFlowActionDescriptor=zo,u.manualFlowActionDescriptorDeclarationReturnDeclaration=_h,u.manualFlowActionDescriptorDeclarationReturnDeclarationDataType=Bh,u.manualFlowActionDescriptorDeclarationReturnDeclarationDataTypeParentRef=Ch,u.manualFlowActionDescriptorDeclarationReturnDeclarationParentRef=wh,u.mapActionDescriptorToTypeItRepresents=X3,u.mergeEntityErrorsList=q4,u.mergeListOfEntities=z3,u.methodDefaultValue=zy,u.mockClientProject=Db,u.moreThanOrEqualCondition=Ur,u.moreThanOrEqualConditionLeftHandArgument=vm,u.moreThanOrEqualConditionLeftHandArgumentParentRef=gm,u.moreThanOrEqualConditionRightHandArgument=Dm,u.moreThanOrEqualConditionRightHandArgumentParentRef=Im,u.notEmptyCondition=er,u.notEmptyConditionArgument=Em,u.notEmptyConditionRef=Tm,u.numberAdditionOperation=wa,u.numberAdditionOperationError=hu,u.numberAdditionOperationErrorParentRef=yu,u.numberAdditionOperationFirstNumberArgument=Mo,u.numberAdditionOperationFirstNumberArgumentRef=iu,u.numberAdditionOperationFirstNumberDataType=au,u.numberAdditionOperationRef=du,u.numberAdditionOperationRefThree=pu,u.numberAdditionOperationRefTwo=uu,u.numberAdditionOperationResultNumberDataType=cu,u.numberAdditionOperationResultNumberReturn=Vo,u.numberAdditionOperationResultNumberReturnRef=lu,u.numberAdditionOperationSecondNumberArgument=No,u.numberAdditionOperationSecondNumberArgumentRef=su,u.numberAdditionOperationSecondNumberDataType=ou,u.numberPrototype=Ce,u.numberValueAutogenerationSchema=uc,u.parallelExecutionOperation=xt,u.parallelExecutionOperationError=Hp,u.parallelExecutionOperationErrorParentRef=Wp,u.parallelExecutionOperationListOfExecutionResultsDataType=jp,u.parallelExecutionOperationListOfExecutionResultsReturn=jo,u.parallelExecutionOperationListOfExecutionResultsReturnRef=kp,u.parallelExecutionOperationListOfFunctionsArgument=ko,u.parallelExecutionOperationListOfFunctionsArgumentDatatype=xp,u.parallelExecutionOperationListOfFunctionsArgumentRef=Up,u.parallelExecutionOperationListOfFunctionsBlueprint=Fp,u.parallelExecutionOperationRef=qp,u.parallelExecutionOperationRefThree=Jp,u.persistedBuiltInBaseEntity=Le,u.persistedBuiltInBaseEntityCreatedAtProperty=sm,u.persistedBuiltInBaseEntityCreatedAtPropertyDataType=im,u.persistedBuiltInBaseEntityCreatedAtPropertyDataTypeRef=FI,u.persistedBuiltInBaseEntityCreatedAtPropertyParentRef=am,u.persistedBuiltInBaseEntityCreatedAtPropertyRef=rm,u.persistedBuiltInBaseEntityDatabaseProperty=Pi,u.persistedBuiltInBaseEntityDatabasePropertyDataTypeRef=VI,u.persistedBuiltInBaseEntityDatabasePropertyParentRef=Yf,u.persistedBuiltInBaseEntityDatabasePropertyRef=Hf,u.persistedBuiltInBaseEntityDeletedAtProperty=nm,u.persistedBuiltInBaseEntityDeletedAtPropertyDataType=em,u.persistedBuiltInBaseEntityDeletedAtPropertyDataTypeRef=GI,u.persistedBuiltInBaseEntityDeletedAtPropertyParentRef=tm,u.persistedBuiltInBaseEntityDeletedAtPropertyRef=Kf,u.persistedBuiltInBaseEntityIdentifierProperty=Qf,u.persistedBuiltInBaseEntityIdentifierPropertyDataTypeRef=zf,u.persistedBuiltInBaseEntityIdentifierPropertyParentRef=Xf,u.persistedBuiltInBaseEntityIdentifierPropertyRef=Zf,u.persistedBuiltInBaseEntityUpdatedAtProperty=dm,u.persistedBuiltInBaseEntityUpdatedAtPropertyDataType=lm,u.persistedBuiltInBaseEntityUpdatedAtPropertyDataTypeRef=UI,u.persistedBuiltInBaseEntityUpdatedAtPropertyParentRef=cm,u.persistedBuiltInBaseEntityUpdatedAtPropertyRef=om,u.processOutputGlobalValueDescriptorDataType=Sm,u.processOutputGlobalValueDescriptorReturn=ol,u.processOutputGlobalValueDescriptorReturnRef=Am,u.projectPublicationCompletedGlobalEvent=Ha,u.propertyToZodSchema=km,u.relationalDatabaseBuiltInBaseEntity=On,u.relationalDatabaseBuiltInBaseEntityAutoscalingProperty=el,u.relationalDatabaseBuiltInBaseEntityAutoscalingPropertyDataTypeRef=xf,u.relationalDatabaseBuiltInBaseEntityAutoscalingPropertyParentRef=kf,u.relationalDatabaseBuiltInBaseEntityAutoscalingPropertyRef=Uf,u.relationalDatabaseBuiltInBaseEntityDefaultProperty=Ko,u.relationalDatabaseBuiltInBaseEntityDefaultPropertyDataTypeRef=Gf,u.relationalDatabaseBuiltInBaseEntityDefaultPropertyRef=Ff,u.relationalDatabaseBuiltInBaseEntityIdentifierProperty=ja,u.relationalDatabaseBuiltInBaseEntityIdentifierPropertyDataTypeRef=_f,u.relationalDatabaseBuiltInBaseEntityIdentifierPropertyRef=Mf,u.relationalDatabaseBuiltInBaseEntityMinSizeProperty=Wa,u.relationalDatabaseBuiltInBaseEntityMinSizePropertyDataTypeRef=$f,u.relationalDatabaseBuiltInBaseEntityMinSizePropertyRef=Lf,u.relationalDatabaseBuiltInBaseEntityPasswordProperty=Ja,u.relationalDatabaseBuiltInBaseEntityPasswordPropertyDataTypeRef=BI,u.relationalDatabaseBuiltInBaseEntityPasswordPropertyRef=Vf,u.relationalDatabaseBuiltInBaseEntityRef=Fr,u.relationalDatabaseBuiltInBaseEntityUsernameProperty=qa,u.relationalDatabaseBuiltInBaseEntityUsernamePropertyDataTypeRef=OI,u.relationalDatabaseBuiltInBaseEntityUsernamePropertyRef=Nf,u.resolveActionDescriptorName=Iv,u.resolveBaseEntityName=bv,u.resolveBuiltInBaseEntityDataTypeLabel=md,u.resolveConditionOperatorLabel=oo,u.resolveCustomEntityDataTypeLabel=Td,u.resolveDataType=ao,u.resolveDataTypeLabel=Tv,u.resolveEntityDataTypeLabel=Rv,u.resolveEntityName=S,u.resolveFirstCallsSecond=G3,u.resolveFirstWritesSecond=F3,u.resolvePrimitiveEntityName=vv,u.resolvePropertyDataTypeLabel=Ev,u.resolveSearchName=gv,u.resolveVariableDataTypeLabel=C9,u.resolveVariableDeclarationDataTypeLabel=Rr,u.resolveVariableInstanceDataTypeLabel=mv,u.resolveVariableScope=A9,u.sequentialExecutionOperation=dn,u.sequentialExecutionOperationError=uy,u.sequentialExecutionOperationErrorParentRef=dy,u.sequentialExecutionOperationListOfExecutionResultsDataType=oy,u.sequentialExecutionOperationListOfExecutionResultsReturn=Jo,u.sequentialExecutionOperationListOfExecutionResultsReturnParentRef=cy,u.sequentialExecutionOperationListOfExecutionResultsReturnRef=sy,u.sequentialExecutionOperationListOfFunctionsArgument=qo,u.sequentialExecutionOperationListOfFunctionsArgumentDatatype=ay,u.sequentialExecutionOperationListOfFunctionsArgumentParentRef=ly,u.sequentialExecutionOperationListOfFunctionsArgumentRef=iy,u.sequentialExecutionOperationListOfFunctionsBlueprint=ry,u.softDeletePersistedEntityMethod=Jf,u.softDeletePersistedEntityMethodParentRef=qf,u.sortCallsBasedOnExecutionDependencies=Uv,u.sortChildrenEntitiesBasedOnExecutionDependencies=$3,u.splitListOperation=Go,u.splitListOperationError=cp,u.splitListOperationErrorParentRef=lp,u.splitListOperationFirstOutputListDataType=Qu,u.splitListOperationFirstOutputListReturn=ip,u.splitListOperationFirstOutputListReturnParentRef=rp,u.splitListOperationFirstOutputListReturnRef=Lo,u.splitListOperationInputListArgument=ep,u.splitListOperationInputListArgumentParentRef=Ku,u.splitListOperationInputListArgumentRef=Yu,u.splitListOperationInputListDataType=zu,u.splitListOperationSecondOutputListDataType=ap,u.splitListOperationSecondOutputListReturn=op,u.splitListOperationSecondOutputListReturnParentRef=sp,u.splitListOperationSplitIndexArgument=np,u.splitListOperationSplitIndexArgumentParentRef=tp,u.splitListOperationSplitIndexArgumentRef=Zu,u.splitListOperationSplitIndexDataType=Xu,u.stringPrototype=k,u.stringValueAutogenerationSchema=dc,u.suggestNewIdForEntity=Id,u.test_primitive_entities_export=p5,u.toCamelCase=S9,u.toEntityState=Mt,u.toKebabCase=fv,u.toLowerCaseKebabCase=so,u.toPascalCase=O9,u.untypedObjectPrototype=et,u.updateErrorsList=ne,u.updateValueReader=Sa,u.urlDefaultValue=jy,u.uuidPrototype=Ba,u.validateArgumentDeclarationName=gd,u.validateCalledByErrorIdInAction=S3,u.validateCalledByIdInAction=A3,u.validateCallers=_v,u.validateConditionEntityDeclaration=B3,u.validateCustomEntityName=lo,u.validateDataOperation=Qn,u.validateDataOperationDataToValidateArgument=_y,u.validateDataOperationDataToValidateArgumentParentRef=wy,u.validateDataOperationDataToValidateArgumentRef=Cy,u.validateDataOperationDataToValidateDataType=By,u.validateDataOperationEntityToMatchTypeArgument=$y,u.validateDataOperationEntityToMatchTypeArgumentParentRef=Vy,u.validateDataOperationEntityToMatchTypeArgumentRef=My,u.validateDataOperationEntityToMatchTypeDataType=Ny,u.validateDataOperationError=Uy,u.validateDataOperationErrorParentRef=Fy,u.validateDataOperationOutputEntityDeclaration=Gy,u.validateDataOperationOutputEntityDeclarationParentRef=Ly,u.validateEntryCaller=wv,u.validateErrorCaller=Bv,u.validateFunctionCallDeclaration=Nv,u.validateFunctionDeclarationName=Ed,u.validateGeneratedEntityParentIsNotBuiltInEntity=v3,u.validateGeneration=b3,u.validateGenerationTarget=Be,u.validateGenerationUpdate=g3,u.validateLoopEntityDeclaration=w3,u.validateName=B9,u.validateOperationEntityDeclaration=Vv,u.validatePropertyName=bd,u.validateReachability=In,u.validateReadsValueInActionPayload=O3,u.validateReferenceObject=uo,u.validateReferenceToOne=Sd,u.validateReferences=je,u.validateReturnDeclarationName=vd,u.validateSuccessCaller=Cv,u.validateValueReaderGenerationUpdate=Da,u.validateValueWritter=Md,u.validateVariableDeclarationName=Rd,u.validateVariableInternalCallUse=Nd,u.valueAutogenerationCurrentDateAndTimeSchema=Ab,u.valueAutogenerationGenericSchema=ws,u.valueAutogenerationOptions=yc,u.valueAutogenerationOptionsSchema=Pb,u.valueAutogenerationRandomBooleanSchema=cc,u.valueAutogenerationRandomDateBetweenSchema=Vb,u.valueAutogenerationRandomDateFromSchema=Mb,u.valueAutogenerationRandomDateSchema=Ns,u.valueAutogenerationRandomDateUntilSchema=Nb,u.valueAutogenerationRandomNumberBetweenSchema=Cb,u.valueAutogenerationRandomNumberFromSchema=Sb,u.valueAutogenerationRandomNumberSchema=_s,u.valueAutogenerationRandomNumberUntilSchema=Ob,u.valueAutogenerationRandomSchema=ia,u.valueAutogenerationRandomTextBetweenSchema=_b,u.valueAutogenerationRandomTextFromSchema=Bb,u.valueAutogenerationRandomTextSchema=Ms,u.valueAutogenerationRandomTextUntilSchema=wb,u.valueAutogenerationRangeValueTypesSchema=ra,u.valueAutogenerationUniqueSchema=lc,u.waitOperation=dt,u.waitOperationMillisecondsNumberArgument=Zn,u.waitOperationMillisecondsNumberArgumentRef=Zp,u.waitOperationMillisecondsNumberDataType=Xp,u.waitOperationOperationError=ey,u.waitOperationOperationErrorParentRef=Kp,u.waitOperationRef=Qp,Object.defineProperty(u,Symbol.toStringTag,{value:"Module"})});
|