PageSourceSearch

https://opal.ac/assets/js/3395.9156f797.js

js opal.ac collected 2026-10-04 00:23:26 UTC 11,140 bytes, 1 lines download raw bytes

1"use strict";(globalThis.webpackChunkdocumentation=globalThis.webpackChunkdocumentation||[]).push([[3395],{5796(e,t,n){function i(e,t){e.accDescr&&t.setAccDescription?.(e.accDescr),e.accTitle&&t.setAccTitle?.(e.accTitle),e.title&&t.setDiagramTitle?.(e.title)}n.d(t,{S:()=>i}),(0,n(7970).K2)(i,"populateCommonDb")},3395(e,t,n){n.d(t,{diagram:()=>ne});var i=n(5796),a=n(740),r=n(3316),o=n(7970),s=n(9953),l=n(7012),d="position frame",m="frame positioned",c="position relation",x="relation positioned",u=(0,o.K2)(function(e){o.Rm.debug("options str",e)},"setOptions"),f=(0,o.K2)(function(){return{}},"getOptions"),g=(0,o.K2)(function(){h(),(0,r.IU)()},"clear");function h(){w={}}(0,o.K2)(h,"reset");var b=r.UI.eventmodeling,p=(0,o.K2)(()=>(0,a.$t)({...b,...(0,r.zj)().eventmodeling}),"getConfig"),w={};function v(){let e=M;const{ast:t}=w,n=k();if(!t)throw new Error("No data for EventModel");return t.frames.forEach((i,a)=>{const r=A(i,t.dataEntities,n);let s;e=L(e,{$kind:d,index:a,frame:i,textProps:r}),O(i)?(o.Rm.debug("source frame",i.sourceFrames),s=t.frames.filter(e=>i.sourceFrames.some(t=>t.$refText===e.name)),s.forEach(t=>{e=L(e,{$kind:c,index:a,frame:i,sourceFrame:t})})):e=L(e,{$kind:c,index:a,frame:i})}),e={...e,sortedSwimlanesArray:W(e.swimlanes)},e}function y(e){w.ast=e}(0,o.K2)(v,"getState"),(0,o.K2)(y,"setAst");var P={swimlaneMinHeight:70,swimlanePadding:15,swimlaneGap:10,boxPadding:10,boxOverlap:90,boxDefaultY:0,boxMinWidth:80,boxMaxWidth:450,boxMinHeight:80,boxMaxHeight:750,contentStartX:250,textMaxWidth:430,boxTextFontWeight:"bold",boxTextPadding:10,swimlaneTextFontWeight:"bold",labelUiAutomation:"UI/Automation",labelUiAutomationPrefix:"UI/A: ",labelCommandReadModel:"Command/Read Model",labelCommandReadModelPrefix:"C/RM: ",labelEvents:"Events",labelEventsPrefix:"Stream: "};function k(){return P}(0,o.K2)(k,"getDiagramProps");var M={boxes:[],swimlanes:{},relations:[],maxR:0,sortedSwimlanesArray:[]};function K(e){const t=e.split(".");if(2===t.length)return t[0]}function S(e){const t=e.split(".");return 2===t.length?t[1]:e}function B(e,t){if(t&&0!==t.length)return Object.values(e).find(e=>e.namespace===t)}function F(e,t,n){return Math.max(t,...Object.keys(e).filter(e=>{const i=Number.parseInt(e);return i>t&&i<n}).map(e=>Number.parseInt(e)))+1}function R(e,t){const n=K(e.entityIdentifier),i=B(t,n);switch(e.modelEntityType){case"ui":case"pcr":case"processor":return i?{index:i.index,label:i.namespace||P.labelUiAutomation}:n?{index:F(t,0,100),label:P.labelUiAutomationPrefix+n}:{index:0,label:P.labelUiAutomation};case"rmo":case"readmodel":case"cmd":case"command":return i?{index:i.index,label:i.namespace||P.labelCommandReadModel}:n?{index:F(t,100,200),label:P.labelCommandReadModelPrefix+n}:{index:100,label:P.labelCommandReadModel};default:return i?{index:i.index,label:i.namespace||P.labelEvents}:n?{index:F(t,200,300),label:P.labelEventsPrefix+n}:{index:200,label:P.labelEvents}}}function $(e){const{themeVariables:t}=(0,r.zj)();switch(e.modelEntityType){case"ui":return{fill:t.emUiFill??"white",stroke:t.emUiStroke??"#dbdada"};case"pcr":case"processor":return{fill:t.emProcessorFill??"#edb3f6",stroke:t.emProcessorStroke??"#b88cbf"};case"rmo":case"readmodel":return{fill:t.emReadModelFill??"#d3f1a2",stroke:t.emReadModelStroke??"#a3b732"};case"cmd":case"command":return{fill:t.emCommandFill??"#bcd6fe",stroke:t.emCommandStroke??"#679ac3"};case"evt":case"event":return{fill:t.emEventFill??"#ffb778",stroke:t.emEventStroke??"#c19a0f"};default:return{fill:"red",stroke:"black"}}}function A(e,t,n){const i=(0,r.zj)(),s=(0,r.jZ)(S(e.entityIdentifier)??"",i);let l;const d={fontSize:16,fontWeight:700,fontFamily:'"trebuchet ms", verdana, arial, sans-serif',joinWith:"<br/>"};let m=`<b>${(0,a.bH)(s,n.textMaxWidth,d)}</b>`;if(e.dataInlineValue&&(l=e.dataInlineValue,l=l.substring(l.indexOf("{")+1),l=l.substring(0,l.lastIndexOf("}")-1),l=(0,r.jZ)(l,i),l=(0,a.bH)(l,n.textMaxWidth,d),l=l.replaceAll(" ","&nbsp;")),e.dataReference){const o=t.find(t=>t.name===e.dataReference?.$refText);o&&(l=o.dataBlockValue,l=l.substring(l.indexOf("{\n")+2),l=l.substring(0,l.lastIndexOf("}")-1),l=(0,r.jZ)(l,i),l=(0,a.bH)(l,n.textMaxWidth,d),l=l.replaceAll(" ","&nbsp;"),l+="<br/>")}const c=void 0!==l;c&&(m+=`<br/><br/><code style="text-align: left; display: block;max-width:${n.textMaxWidth}px">${l}</code>`);const x={fontSize:d.fontSize,fontWeight:d.fontWeight,fontFamily:d.fontFamily},u=(0,a.PX)(m,x),f={content:m,width:c?u.width/3:u.width,height:u.height};return o.Rm.debug(`[${e.name}] ${e.entityIdentifier} text`,f),f}function E(e,t){const n=t,i=$(n.frame),a={width:n.textProps.width+2*P.boxTextPadding,height:n.textProps.height+2*P.boxTextPadding};return[{$kind:m,frame:n.frame,index:n.index,visual:i,dimension:a,textProps:n.textProps}]}function T(e,t,n){return void 0===t?P.contentStartX:t.index===e.index&&e.r?e.r+P.boxPadding:void 0===n?P.contentStartX:n.r-P.boxOverlap+P.boxPadding}function D(e,t){const n=[...e.map(e=>e.r),t];return Math.max(...n)}function W(e){return Object.values(e).sort((e,t)=>
1e.index-t.index)}function H(e,t){const n=t,i=R(n.frame,e.swimlanes);let a;a=i.index in e.swimlanes?e.swimlanes[i.index]:{index:i.index,label:i.label,r:0,y:i.index*P.swimlaneMinHeight+P.swimlaneGap,height:P.swimlaneMinHeight,maxHeight:P.swimlaneMinHeight};const r=e.boxes.length>0?e.boxes[e.boxes.length-1]:void 0,o=void 0!==e.previousSwimlaneNumber?e.swimlanes[e.previousSwimlaneNumber]:void 0,s={width:Math.max(P.boxMinWidth,Math.min(P.boxMaxWidth,n.dimension.width))+2*P.boxPadding,height:Math.max(P.boxMinHeight,Math.min(P.boxMaxHeight,n.dimension.height))+2*P.boxPadding},l=T(a,o,r),d=l+s.width+P.boxPadding,m=D(Object.values(e.swimlanes),d);a.r=l+s.width,a.maxHeight=Math.max(a.maxHeight,s.height),a.height=Math.max(P.swimlaneMinHeight,a.maxHeight)+2*P.swimlanePadding;const c={x:l,y:P.swimlanePadding+a.y,r:d,dimension:s,leftSibling:!1,swimlane:a,visual:n.visual,text:n.textProps.content,frame:n.frame,index:n.index},x={...e,boxes:[...e.boxes,c],swimlanes:{...e.swimlanes,[`${a.index}`]:a},previousSwimlaneNumber:i.index,previousFrame:n.frame,maxR:m},u=W(x.swimlanes);u.length>0&&(u[0].y=0);for(let f=1;f<u.length;f++){const e=u[f],t=u[f-1];e.y=t.y+t.height+P.swimlaneGap}return x}function I(e,t){return 0===e&&0===t.sourceFrames.length}function O(e){return void 0!==e.sourceFrames&&null!==e.sourceFrames&&e.sourceFrames.length>0}function C(e,t){if(null!=t)return e.find(e=>e.frame.name===t.name)}function j(e,t,n){if(!(n<0))for(let i=n;i>=0;i--){const n=e[i];if(n.swimlane.index!==t)return n}}function U(e,t){const n=t;if((0,s.F5)(n.frame)||I(n.index,n.frame))return[];const i=C(e.boxes,n.frame);if(void 0===i)throw new Error(`Target box not found for frame ${n.frame.name}`);let a;if(a=n.sourceFrame?C(e.boxes,n.sourceFrame):j(e.boxes,i.swimlane.index,n.index-1),void 0===a)return[];return[{$kind:x,frame:n.frame,index:n.index,sourceBox:a,targetBox:i}]}function N(e,t){const n=t,i={visual:{fill:"none",stroke:"#000"},source:{x:n.sourceBox.x,y:n.sourceBox.y},target:{x:n.targetBox.x,y:n.targetBox.y},sourceBox:n.sourceBox,targetBox:n.targetBox};return{...e,relations:[...e.relations,i]}}(0,o.K2)(K,"extractNamespace"),(0,o.K2)(S,"extractName"),(0,o.K2)(B,"findSwimlaneByNamespace"),(0,o.K2)(F,"findNextAvailableIndex"),(0,o.K2)(R,"calculateSwimlaneProps"),(0,o.K2)($,"calculateEntityVisualProps"),(0,o.K2)(A,"calculateTextProps"),(0,o.K2)(E,"decidePositionFrame"),(0,o.K2)(T,"calculateX"),(0,o.K2)(D,"calculateMaxRight"),(0,o.K2)(W,"sortedSwimlanesArray"),(0,o.K2)(H,"evolveFramePositioned"),(0,o.K2)(I,"isFirstFrame"),(0,o.K2)(O,"hasSourceFrame"),(0,o.K2)(C,"findBoxByFrame"),(0,o.K2)(j,"findBoxByLineIndex"),(0,o.K2)(U,"decidePositionRelation"),(0,o.K2)(N,"evolveRelationPositioned");var V={[d]:E,[c]:U},z={[m]:H,[x]:N};function X(e,t){const n=V[t.$kind];if(null==n)return[];const i=n(e,t);return o.Rm.debug("decided events",i),i}function G(e,t){const n=t.reduce((e,t)=>{const n=z[t.$kind];return null==n?e:n(e,t)},e);return o.Rm.debug("evolve events",{state:e,newState:n,events:t}),n}function L(e,t){return G(e,X(e,t))}(0,o.K2)(X,"decide"),(0,o.K2)(G,"evolve"),(0,o.K2)(L,"dispatch");var Z={getConfig:p,setOptions:u,getOptions:f,clear:g,setAccTitle:r.SV,getAccTitle:r.iN,getAccDescription:r.m7,setAccDescription:r.EI,setDiagramTitle:r.ke,getDiagramTitle:r.ab,setAst:y,getDiagramProps:k,getState:v},Y={parse:(0,o.K2)(async e=>{const t=await(0,s.qg)("eventmodeling",e);o.Rm.debug(t),Z.setAst(t),(0,i.S)(t,Z)},"parse")};var q=(0,r.D7)(),J=q?.eventmodeling;function Q(e,t){return n=>{const i=n.swimlane.y+t.swimlanePadding,a=e.append("g").attr("class","em-box");a.append("rect").attr("x",n.x).attr("y",i).attr("rx","3").attr("width",n.dimension.width).attr("height",n.dimension.height).attr("stroke",n.visual.stroke).attr("fill",n.visual.fill);a.append("foreignObject").attr("x",n.x+t.boxPadding).attr("y",i+10).attr("width",n.dimension.width-2*t.boxPadding).attr("height",n.dimension.height-2*t.boxPadding).append("xhtml:div").style("display","table").style("height","100%").style("width","100%").append("span").style("display","table-cell").style("text-align","center").style("vertical-align","middle").html(n.text)}}function _(e,t){return e>t}function ee(e,t,n,i){return a=>{const r=a.sourceBox.swimlane.y+t.swimlanePadding,s=a.targetBox.swimlane.y+t.swimlanePadding,l=_(r,s),d=a.sourceBox.x+2*a.sourceBox.dimension.width/3,m=a.targetBox.x+a.targetBox.dimension.width/3;let c,x;o.Rm.debug(`rendering relation up=${l} for `,{sourceBox:a.sourceBox,targetBox:a.targetBox}),l?(c=r,x=s+a.targetBox.dimension.height):(c=r+a.sourceBox.dimension.height,x=s);const u=i.emRelationStroke??a.visual.stroke;e.append("path").attr("class","em-relation").attr("fill",a.visual.fill).attr("stroke",u).attr("stroke-width","1").attr("marker-end",`url
1(#${n})`).attr("d",`M${d} ${c} L${m} ${x}`)}}function te(e,t,n,i){return a=>{const r=e.append("g").attr("class","em-swimlane"),o=i.emSwimlaneBackgroundOdd??"rgb(250,250,250)",s=i.emSwimlaneBackgroundStroke??"rgb(240,240,240)";r.append("rect").attr("x",0).attr("y",a.y).attr("rx","3").attr("width",t+n.swimlanePadding).attr("height",a.height).attr("fill",o).attr("stroke",s),r.append("text").attr("font-weight",n.swimlaneTextFontWeight).attr("x",30).attr("y",a.y+30).text(a.label)}}(0,o.K2)(Q,"renderD3Box"),(0,o.K2)(_,"dirUpwards"),(0,o.K2)(ee,"renderD3Relation"),(0,o.K2)(te,"renderD3Swimlane");var ne={parser:Y,db:Z,renderer:{draw:(0,o.K2)(function(e,t,n,i){if(o.Rm.debug("in eventmodeling renderer",e+"\n","id:",t,n),!J)throw new Error("EventModeling config not found");const a=i.db,{themeVariables:s,eventmodeling:d}=(0,r.D7)(),m=(0,l.Ltv)(`[id="${t}"]`),c=a.getDiagramProps(),x=a.getState(),u=`em-arrowhead-${t}`,f=s.emArrowhead??"#000000";x.sortedSwimlanesArray.forEach(te(m,x.maxR,c,s)),x.boxes.forEach(Q(m,c)),x.relations.forEach(ee(m,c,u,s));m.append("defs").append("marker").attr("id",u).attr("markerWidth","10").attr("markerHeight","7").attr("refX","10").attr("refY","3.5").attr("orient","auto").append("polygon").attr("points","0 0, 10 3.5, 0 7").attr("fill",f),(0,r.mj)(void 0,m,d?.padding??30,d?.useMaxWidth)},"draw")},styles:(0,o.K2)(e=>"","getStyles")}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.