File tree Expand file tree Collapse file tree 3 files changed +24
-4
lines changed
cypress/Frank/src/main/configurations/Example1 Expand file tree Collapse file tree 3 files changed +24
-4
lines changed Original file line number Diff line number Diff line change 1
1
<Configuration
2
2
flow : direction =" vertical"
3
3
flow : forwardStyle =" flowchart"
4
- flow : gridSize =" 50"
4
+ flow : gridSize =" 50" xmlns : flow = " urn:frank-flow "
5
5
>
6
6
<Adapter name =" TestFrankFlow" >
7
- <Receiver name =" TestFrankFlow" >
7
+ <Receiver name =" TestFrankFlow" active =" false" flow : x =" 100" flow : y =" 100" >
8
+ <JavaListener name =" TestFrankFlow" flow : x =" 100" flow : y =" 100" />
9
+ </Receiver >
10
+ <Receiver name =" TestFrankFlow" flow : x =" 400" flow : y =" 100" >
8
11
<JavaListener name =" TestFrankFlow" flow : x =" 100" flow : y =" 100" />
9
12
</Receiver >
10
13
<Pipeline >
Original file line number Diff line number Diff line change @@ -17,6 +17,7 @@ export class FlowStructureNode {
17
17
public senders : FlowStructureNode [ ] ;
18
18
public path : string ;
19
19
public isSelfClosing : boolean ;
20
+ public active : boolean ;
20
21
21
22
constructor (
22
23
line : number ,
@@ -40,7 +41,8 @@ export class FlowStructureNode {
40
41
this . path = path ;
41
42
42
43
this . name = this . getName ( ) ;
43
- this . uid = `${ this . type } (${ this . name } )${ this . path ? `@${ this . path } ` : '' } ` ;
44
+ this . active = this . getActive ( ) ;
45
+ this . uid = this . getUid ( ) ;
44
46
this . positions = this . getPositions ( ) ;
45
47
this . senders = [ ] ;
46
48
}
@@ -54,6 +56,19 @@ export class FlowStructureNode {
54
56
return this . type ;
55
57
}
56
58
59
+ private getActive ( ) : boolean {
60
+ const activeIsFalse = this . attributes [ 'active' ] ?. value === 'false' ;
61
+ const activeIsEmpty = this . attributes [ 'active' ] ?. value === '' ;
62
+
63
+ return ! ( activeIsFalse || activeIsEmpty ) ;
64
+ }
65
+
66
+ private getUid ( ) : string {
67
+ return `${ this . type } (${ ! this . active ? `#${ this . name } #` : this . name } )${
68
+ this . path ? `@${ this . path } ` : ''
69
+ } `;
70
+ }
71
+
57
72
private getPositions ( ) : { x : number ; y : number } {
58
73
let x = 0 ;
59
74
let y = 0 ;
Original file line number Diff line number Diff line change @@ -90,7 +90,9 @@ const charBeforeParserIsGreaterThanCharacter = () => {
90
90
} ;
91
91
92
92
parser . on ( 'opentag' , ( tag : TagForOptions < { } > ) => {
93
- const path = unclosedNodes . map ( ( node ) => node . name ) . join ( '>' ) ;
93
+ const path = unclosedNodes
94
+ . map ( ( node ) => ( ! node . active ? `#${ node . name } #` : node . name ) )
95
+ . join ( '>' ) ;
94
96
95
97
const currentNode = new FlowStructureNode (
96
98
tagStartLine ,
You can’t perform that action at this time.
0 commit comments