Sidebar-ArchiMate3.js 36 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543
  1. (function()
  2. {
  3. // Adds ArchiMate v3.2 shapes
  4. Sidebar.prototype.addArchimate3Palette = function()
  5. {
  6. this.setCurrentSearchEntryLibrary('archimate3', 'archimate3Generic');
  7. this.addArchimate3GenericPalette();
  8. this.setCurrentSearchEntryLibrary('archimate3', 'archimate3Relationships');
  9. this.addArchimate3RelationshipsPalette();
  10. this.setCurrentSearchEntryLibrary('archimate3', 'archimate3Motivation');
  11. this.addArchimate3MotivationPalette();
  12. this.setCurrentSearchEntryLibrary('archimate3', 'archimate3Strategy');
  13. this.addArchimate3StrategyPalette();
  14. this.setCurrentSearchEntryLibrary('archimate3', 'archimate3Business');
  15. this.addArchimate3BusinessPalette();
  16. this.setCurrentSearchEntryLibrary('archimate3', 'archimate3Application');
  17. this.addArchimate3ApplicationPalette();
  18. this.setCurrentSearchEntryLibrary('archimate3', 'archimate3Technology');
  19. this.addArchimate3TechnologyPalette();
  20. this.setCurrentSearchEntryLibrary('archimate3', 'archimate3Implementation and Migration');
  21. this.addArchimate3ImplementationAndMigrationPalette();
  22. };
  23. Sidebar.prototype.addArchimate3GenericPalette = function()
  24. {
  25. var am = 'html=1;outlineConnect=0;whiteSpace=wrap;fillColor=#EBEBEB;shape=mxgraph.archimate3.';
  26. // Space savers
  27. var sb = this;
  28. var gn = 'mxgraph.archimate3';
  29. var dt = 'archimate generic ';
  30. var w = 1.0;
  31. var h = 1.0;
  32. var fns =
  33. [
  34. this.createVertexTemplateEntry(am + 'application;appType=generic;archiType=square;',
  35. w * 150, h * 75, 'Internal Active Structure Element', 'Internal Active Structure Element', null, null, this.getTagsForStencil(gn, '', dt + 'internal active structure element').join(' ')),
  36. this.createVertexTemplateEntry(am + 'application;appType=collab;archiType=square;',
  37. w * 150, h * 75, 'Collaboration', 'Collaboration', null, null, this.getTagsForStencil(gn, '', dt + 'collaboration').join(' ')),
  38. this.createVertexTemplateEntry(am + 'collaboration;',
  39. w * 60, h * 35, '', 'Collaboration', null, null, this.getTagsForStencil(gn, '', dt + 'collaboration').join(' ')),
  40. this.createVertexTemplateEntry(am + 'application;appType=interface;archiType=square;',
  41. w * 150, h * 75, 'Interface', 'Interface', null, null, this.getTagsForStencil(gn, '', dt + 'interface').join(' ')),
  42. this.createVertexTemplateEntry(am + 'interface;',
  43. w * 70, h * 35, '', 'Interface', null, null, this.getTagsForStencil(gn, '', dt + 'interface').join(' ')),
  44. this.createVertexTemplateEntry(am + 'application;appType=generic;archiType=rounded;',
  45. w * 150, h * 75, 'Internal Behavior Element', 'Internal Behavior Element', null, null, this.getTagsForStencil(gn, '', dt + 'internal behavior element').join(' ')),
  46. this.createVertexTemplateEntry(am + 'application;appType=proc;archiType=rounded;',
  47. w * 150, h * 75, 'Process', 'Process', null, null, this.getTagsForStencil(gn, '', dt + 'process').join(' ')),
  48. this.createVertexTemplateEntry(am + 'process;',
  49. w * 60, h * 35, '', 'Process', null, null, this.getTagsForStencil(gn, '', dt + 'process').join(' ')),
  50. this.createVertexTemplateEntry(am + 'application;appType=func;archiType=rounded;',
  51. w * 150, h * 75, 'Function', 'Function', null, null, this.getTagsForStencil(gn, '', dt + 'function').join(' ')),
  52. this.createVertexTemplateEntry(am + 'function;',
  53. w * 45, h * 45, '', 'Function', null, null, this.getTagsForStencil(gn, '', dt + 'function').join(' ')),
  54. this.createVertexTemplateEntry(am + 'application;appType=interaction;archiType=rounded;',
  55. w * 150, h * 75, 'Interaction', 'Interaction', null, null, this.getTagsForStencil(gn, '', dt + 'interaction').join(' ')),
  56. this.createVertexTemplateEntry(am + 'interaction;',
  57. w * 45, h * 45, '', 'Interaction', null, null, this.getTagsForStencil(gn, '', dt + 'interaction').join(' ')),
  58. this.createVertexTemplateEntry(am + 'application;appType=serv;archiType=rounded',
  59. w * 150, h * 75, 'Service', 'Service', null, null, this.getTagsForStencil(gn, '', dt + 'service').join(' ')),
  60. this.createVertexTemplateEntry(am + 'service;',
  61. w * 60, h * 35, '', 'Service', null, null, this.getTagsForStencil(gn, '', dt + 'service').join(' ')),
  62. this.createVertexTemplateEntry(am + 'application;appType=event;archiType=rounded',
  63. w * 150, h * 75, 'Event', 'Event', null, null, this.getTagsForStencil(gn, '', dt + 'event').join(' ')),
  64. this.createVertexTemplateEntry(am + 'event;',
  65. w * 60, h * 35, '', 'Event', null, null, this.getTagsForStencil(gn, '', dt + 'event').join(' ')),
  66. this.createVertexTemplateEntry(am + 'application;appType=passive;archiType=square',
  67. w * 150, h * 75, 'Passive Structure Element', 'Passive Structure Element', null, null, this.getTagsForStencil(gn, '', dt + 'passive structure element').join(' ')),
  68. this.createVertexTemplateEntry(am + 'passive;',
  69. w * 60, h * 35, '', 'Passive Structure Element', null, null, this.getTagsForStencil(gn, '', dt + 'passive structure element').join(' ')),
  70. this.createVertexTemplateEntry(am + 'application;appType=generic;archiType=oct;',
  71. w * 150, h * 75, 'Motivation Element', 'Motivation Element', null, null, this.getTagsForStencil(gn, '', dt + 'motivation element').join(' ')),
  72. this.createVertexTemplateEntry('html=1;outlineConnect=0;whiteSpace=wrap;shape=mxgraph.archimate3.application;appType=grouping;archiType=square;dashed=1;fillColor=none;',
  73. w * 150, h * 75, 'Grouping', 'Grouping', null, null, this.getTagsForStencil(gn, '', dt + 'grouping').join(' ')),
  74. this.createVertexTemplateEntry('html=1;outlineConnect=0;whiteSpace=wrap;shape=mxgraph.archimate3.grouping;fillColor=none;dashed=1;',
  75. w * 60, h * 35, '', 'Grouping', null, null, this.getTagsForStencil(gn, '', dt + 'grouping').join(' ')),
  76. this.createVertexTemplateEntry('html=1;outlineConnect=0;whiteSpace=wrap;shape=mxgraph.archimate3.application;appType=location;archiType=square;fillColor=#efd1e4;',
  77. w * 150, h * 75, 'Location', 'Location', null, null, this.getTagsForStencil(gn, '', dt + 'location').join(' ')),
  78. this.createVertexTemplateEntry('html=1;outlineConnect=0;whiteSpace=wrap;shape=mxgraph.archimate3.locationIcon;fillColor=#efd1e4;aspect=fixed;',
  79. w * 35, h * 50, '', 'Location', null, null, this.getTagsForStencil(gn, '', dt + 'location').join(' '))
  80. ];
  81. this.addPalette('archimate3Generic', 'Archimate 3.2 / Generic', false, mxUtils.bind(this, function(content)
  82. {
  83. for (var i = 0; i < fns.length; i++)
  84. {
  85. content.appendChild(fns[i](content));
  86. }
  87. }));
  88. };
  89. Sidebar.prototype.addArchimate3ApplicationPalette = function()
  90. {
  91. var am = 'html=1;outlineConnect=0;whiteSpace=wrap;fillColor=#99ffff;shape=mxgraph.archimate3.';
  92. // Space savers
  93. var sb = this;
  94. var gn = 'mxgraph.archimate3';
  95. var dt = 'archimate application layer ';
  96. var w = 1.0;
  97. var h = 1.0;
  98. var fns =
  99. [
  100. this.createVertexTemplateEntry(am + 'application;appType=comp;archiType=square;',
  101. w * 150, h * 75, 'Application Component', 'Application Component', null, null, this.getTagsForStencil(gn, '', dt + 'component').join(' ')),
  102. this.createVertexTemplateEntry(am + 'component;',
  103. w * 48, h * 40, '', 'Component', null, null, this.getTagsForStencil(gn, '', dt + 'component').join(' ')),
  104. this.createVertexTemplateEntry(am + 'application;appType=collab;archiType=square;',
  105. w * 150, h * 75, 'Application Collaboration', 'Application Collaboration', null, null, this.getTagsForStencil(gn, '', dt + 'collaboration').join(' ')),
  106. this.createVertexTemplateEntry(am + 'collaboration;',
  107. w * 60, h * 35, '', 'Collaboration', null, null, this.getTagsForStencil(gn, '', dt + 'collaboration').join(' ')),
  108. this.createVertexTemplateEntry(am + 'application;appType=interface;archiType=square;',
  109. w * 150, h * 75, 'Application Interface', 'Application Interface', null, null, this.getTagsForStencil(gn, '', dt + 'component').join(' ')),
  110. this.createVertexTemplateEntry(am + 'interface;',
  111. w * 70, h * 35, '', 'Interface', null, null, this.getTagsForStencil(gn, '', dt + 'interface').join(' ')),
  112. this.createVertexTemplateEntry(am + 'application;appType=func;archiType=rounded;',
  113. w * 150, h * 75, 'Application Function', 'Application Function', null, null, this.getTagsForStencil(gn, '', dt + 'function').join(' ')),
  114. this.createVertexTemplateEntry(am + 'function;',
  115. w * 60, h * 40, '', 'Function', null, null, this.getTagsForStencil(gn, '', dt + 'function').join(' ')),
  116. this.createVertexTemplateEntry(am + 'application;appType=interaction;archiType=rounded;',
  117. w * 150, h * 75, 'Application Interaction', 'Application Interaction', null, null, this.getTagsForStencil(gn, '', dt + 'interaction').join(' ')),
  118. this.createVertexTemplateEntry(am + 'interaction;',
  119. w * 40, h * 40, '', 'Interaction', null, null, this.getTagsForStencil(gn, '', dt + 'interaction').join(' ')),
  120. this.createVertexTemplateEntry(am + 'application;appType=proc;archiType=rounded;',
  121. w * 150, h * 75, 'Application Process', 'Application Process', null, null, this.getTagsForStencil(gn, '', dt + 'process').join(' ')),
  122. this.createVertexTemplateEntry(am + 'process;',
  123. w * 60, h * 30, '', 'Process', null, null, this.getTagsForStencil(gn, '', dt + 'process').join(' ')),
  124. this.createVertexTemplateEntry(am + 'application;appType=event;archiType=rounded',
  125. w * 150, h * 75, 'Application Event', 'Application Event', null, null, this.getTagsForStencil(gn, '', dt + 'event').join(' ')),
  126. this.createVertexTemplateEntry(am + 'event;',
  127. w * 60, h * 35, '', 'Event', null, null, this.getTagsForStencil(gn, '', dt + 'event').join(' ')),
  128. this.createVertexTemplateEntry(am + 'application;appType=serv;archiType=rounded',
  129. w * 150, h * 75, 'Application Service', 'Application Service', null, null, this.getTagsForStencil(gn, '', dt + 'service').join(' ')),
  130. this.createVertexTemplateEntry(am + 'service;',
  131. w * 60, h * 35, '', 'Service', null, null, this.getTagsForStencil(gn, '', dt + 'service').join(' ')),
  132. this.createVertexTemplateEntry(am + 'application;appType=passive;archiType=square;',
  133. w * 150, h * 75, 'Data Object', 'Data Object', null, null, this.getTagsForStencil(gn, '', dt + 'service').join(' ')),
  134. this.createVertexTemplateEntry(am + 'businessObject;overflow=fill;',
  135. w * 70, h * 40, '<table cellpadding="0" cellspacing="0" style="font-size:1em;width:100%;height:100%;"><tr style="height:20px;"><td align="center"></td></tr><tr><td align="left" valign="top" style="padding:4px;"></td></tr></table>',
  136. 'Data Object', null, null, this.getTagsForStencil(gn, '', dt + 'data object').join(' '))
  137. ];
  138. this.addPalette('archimate3Application', 'Archimate 3.2 / Application', false, mxUtils.bind(this, function(content)
  139. {
  140. for (var i = 0; i < fns.length; i++)
  141. {
  142. content.appendChild(fns[i](content));
  143. }
  144. }));
  145. };
  146. Sidebar.prototype.addArchimate3BusinessPalette = function()
  147. {
  148. var am2 = 'html=1;outlineConnect=0;whiteSpace=wrap;fillColor=#ffff99;shape=mxgraph.archimate3.';
  149. var am3 = 'html=1;outlineConnect=0;whiteSpace=wrap;fillColor=#ffff99;verticalLabelPosition=bottom;verticalAlign=top;align=center;shape=mxgraph.archimate3.';
  150. // Space savers
  151. var sb = this;
  152. var gn = 'mxgraph.archimate3';
  153. var dt = 'archimate business layer ';
  154. var w = 1.0;
  155. var h = 1.0;
  156. var fns =
  157. [
  158. this.createVertexTemplateEntry(am2 + 'application;appType=actor;archiType=square;',
  159. w * 150, h * 75, 'Business Actor', 'Business Actor', null, null, this.getTagsForStencil(gn, '', dt + 'actor').join(' ')),
  160. this.createVertexTemplateEntry(am3 + 'actor;',
  161. w * 26.5, h * 50, '', 'Actor', null, null, this.getTagsForStencil(gn, '', dt + 'actor').join(' ')),
  162. this.createVertexTemplateEntry(am2 + 'application;appType=role;archiType=square;',
  163. w * 150, h * 75, 'Business Role', 'Business Role', null, null, this.getTagsForStencil(gn, '', dt + 'role').join(' ')),
  164. this.createVertexTemplateEntry(am2 + 'role;',
  165. w * 60, h * 35, '', 'Business Role', null, null, this.getTagsForStencil(gn, '', dt + 'role').join(' ')),
  166. this.createVertexTemplateEntry(am2 + 'application;appType=collab;archiType=square;',
  167. w * 150, h * 75, 'Business Collaboration', 'Business Collaboration', null, null, this.getTagsForStencil(gn, '', dt + 'collaboration').join(' ')),
  168. this.createVertexTemplateEntry(am2 + 'collaboration;',
  169. w * 60, h * 35, '', 'Collaboration', null, null, this.getTagsForStencil(gn, '', dt + 'collaboration').join(' ')),
  170. this.createVertexTemplateEntry(am2 + 'application;appType=interface;archiType=square;',
  171. w * 150, h * 75, 'Business Interface', 'Business Interface', null, null, this.getTagsForStencil(gn, '', dt + 'component').join(' ')),
  172. this.createVertexTemplateEntry(am2 + 'interface;',
  173. w * 70, h * 35, '', 'Business Interface', null, null, this.getTagsForStencil(gn, '', dt + 'interface').join(' ')),
  174. this.createVertexTemplateEntry(am2 + 'application;appType=proc;archiType=rounded;',
  175. w * 150, h * 75, 'Business Process', 'Business Process', null, null, this.getTagsForStencil(gn, '', dt + 'process').join(' ')),
  176. this.createVertexTemplateEntry(am2 + 'process;',
  177. w * 60, h * 30, '', 'Business Process', null, null, this.getTagsForStencil(gn, '', dt + 'process').join(' ')),
  178. this.createVertexTemplateEntry(am2 + 'application;appType=func;archiType=rounded;',
  179. w * 150, h * 75, 'Business Function', 'Business Function', null, null, this.getTagsForStencil(gn, '', dt + 'function').join(' ')),
  180. this.createVertexTemplateEntry(am2 + 'function;',
  181. w * 60, h * 40, '', 'Business Function', null, null, this.getTagsForStencil(gn, '', dt + 'function').join(' ')),
  182. this.createVertexTemplateEntry(am2 + 'application;appType=interaction;archiType=rounded;',
  183. w * 150, h * 75, 'Business Interaction', 'Business Interaction', null, null, this.getTagsForStencil(gn, '', dt + 'interaction').join(' ')),
  184. this.createVertexTemplateEntry(am2 + 'interaction;',
  185. w * 40, h * 40, '', 'Business Interaction', null, null, this.getTagsForStencil(gn, '', dt + 'interaction').join(' ')),
  186. this.createVertexTemplateEntry(am2 + 'application;appType=event;archiType=rounded;',
  187. w * 150, h * 75, 'Business Event', 'Business Event', null, null, this.getTagsForStencil(gn, '', dt + 'business event').join(' ')),
  188. this.createVertexTemplateEntry(am2 + 'event;',
  189. w * 60, h * 35, '', 'Business Event', null, null, this.getTagsForStencil(gn, '', dt + 'business event').join(' ')),
  190. this.createVertexTemplateEntry(am2 + 'application;appType=serv;archiType=rounded;',
  191. w * 150, h * 75, 'Business Service', 'Business Service', null, null, this.getTagsForStencil(gn, '', dt + 'service').join(' ')),
  192. this.createVertexTemplateEntry(am2 + 'service;',
  193. w * 60, h * 35, '', 'Business Service', null, null, this.getTagsForStencil(gn, '', dt + 'service').join(' ')),
  194. this.createVertexTemplateEntry(am2 + 'application;appType=passive;archiType=square;',
  195. w * 150, h * 75, 'Business Object', 'Business Object', null, null, this.getTagsForStencil(gn, '', dt + 'service').join(' ')),
  196. this.createVertexTemplateEntry(am2 + 'businessObject;overflow=fill;',
  197. w * 70, h * 40, '<table cellpadding="0" cellspacing="0" style="font-size:1em;width:100%;height:100%;"><tr style="height:20px;"><td align="center"></td></tr><tr><td align="left" valign="top" style="padding:4px;"></td></tr></table>',
  198. 'Business Object', null, null, this.getTagsForStencil(gn, '', dt + 'data object').join(' ')),
  199. this.createVertexTemplateEntry(am2 + 'application;appType=contract;archiType=square;',
  200. w * 150, h * 75, 'Contract', 'Contract', null, null, this.getTagsForStencil(gn, '', dt + 'contract').join(' ')),
  201. this.createVertexTemplateEntry(am2 + 'contract;',
  202. w * 70, h * 40, '', 'Contract', null, null, this.getTagsForStencil(gn, '', dt + 'contract').join(' ')),
  203. this.createVertexTemplateEntry(am2 + 'application;appType=representation;archiType=square;',
  204. w * 150, h * 75, 'Representation', 'Representation', null, null, this.getTagsForStencil(gn, '', dt + 'contract').join(' ')),
  205. this.createVertexTemplateEntry(am2 + 'representation;',
  206. w * 70, h * 40, '', 'Representation', null, null, this.getTagsForStencil(gn, '', dt + 'representation').join(' ')),
  207. this.createVertexTemplateEntry(am2 + 'application;appType=product;archiType=square;',
  208. w * 150, h * 75, 'Product', 'Product', null, null, this.getTagsForStencil(gn, '', dt + 'product').join(' ')),
  209. this.createVertexTemplateEntry(am2 + 'product;',
  210. w * 70, h * 40, '', 'Product', null, null, this.getTagsForStencil(gn, '', dt + 'product').join(' '))
  211. ];
  212. this.addPalette('archimate3Business', 'Archimate 3.2 / Business', false, mxUtils.bind(this, function(content)
  213. {
  214. for (var i = 0; i < fns.length; i++)
  215. {
  216. content.appendChild(fns[i](content));
  217. }
  218. }));
  219. };
  220. Sidebar.prototype.addArchimate3ImplementationAndMigrationPalette = function()
  221. {
  222. var am2 = 'html=1;outlineConnect=0;whiteSpace=wrap;fillColor=#FFE0E0;shape=mxgraph.archimate3.';
  223. var am3 = 'html=1;outlineConnect=0;whiteSpace=wrap;fillColor=#E0FFE0;shape=mxgraph.archimate3.';
  224. // Space savers
  225. var sb = this;
  226. var gn = 'mxgraph.archimate3';
  227. var dt = 'archimate implementation migration element ';
  228. var w = 1.0;
  229. var h = 1.0;
  230. var fns =
  231. [
  232. this.createVertexTemplateEntry(am2 + 'application;appType=workPackage;archiType=rounded;',
  233. w * 150, h * 75, 'Work Package', 'Work Package', null, null, this.getTagsForStencil(gn, '', dt + 'work package').join(' ')),
  234. this.createVertexTemplateEntry(am2 + 'workPackage;strokeWidth=5;',
  235. w * 60, h * 50, '', 'Work Package', null, null, this.getTagsForStencil(gn, '', dt + 'work package').join(' ')),
  236. this.createVertexTemplateEntry(am2 + 'application;appType=deliverable;',
  237. w * 150, h * 75, 'Deliverable', 'Deliverable', null, null, this.getTagsForStencil(gn, '', dt + 'deliverable').join(' ')),
  238. this.createVertexTemplateEntry(am2 + 'deliverable;',
  239. w * 60, h * 35, '', 'Deliverable', null, null, this.getTagsForStencil(gn, '', dt + 'deliverable').join(' ')),
  240. this.createVertexTemplateEntry(am2 + 'application;appType=event;archiType=rounded;',
  241. w * 150, h * 75, 'Implementation Event', 'Implementation Event', null, null, this.getTagsForStencil(gn, '', dt + 'implementation event').join(' ')),
  242. this.createVertexTemplateEntry(am2 + 'event;',
  243. w * 60, h * 35, '', 'Event', null, null, this.getTagsForStencil(gn, '', dt + 'event').join(' ')),
  244. this.createVertexTemplateEntry(am2 + 'application;appType=plateau;',
  245. w * 150, h * 75, 'Plateau', 'Plateau', null, null, this.getTagsForStencil(gn, '', dt + 'plateau').join(' ')),
  246. this.createVertexTemplateEntry(am2 + 'plateau;',
  247. w * 60, h * 40, '', 'Plateau', null, null, this.getTagsForStencil(gn, '', dt + 'plateau').join(' ')),
  248. this.createVertexTemplateEntry(am2 + 'application;appType=gap;',
  249. w * 150, h * 75, 'Gap', 'Gap', null, null, this.getTagsForStencil(gn, '', dt + 'gap').join(' ')),
  250. this.createVertexTemplateEntry(am2 + 'gapIcon;',
  251. w * 55, h * 40, '', 'Gap', null, null, this.getTagsForStencil(gn, '', dt + 'gap').join(' '))
  252. ];
  253. this.addPalette('archimate3Implementation and Migration', 'Archimate 3.2 / Implementation and Migration', false, mxUtils.bind(this, function(content)
  254. {
  255. for (var i = 0; i < fns.length; i++)
  256. {
  257. content.appendChild(fns[i](content));
  258. }
  259. }));
  260. };
  261. Sidebar.prototype.addArchimate3MotivationPalette = function()
  262. {
  263. var am = 'html=1;outlineConnect=0;whiteSpace=wrap;fillColor=#CCCCFF;shape=mxgraph.archimate3.';
  264. // Space savers
  265. var sb = this;
  266. var gn = 'mxgraph.archimate3';
  267. var dt = 'archimate implementation motivation element ';
  268. var w = 1.0;
  269. var h = 1.0;
  270. var fns =
  271. [
  272. this.createVertexTemplateEntry(am + 'application;appType=role;archiType=oct;',
  273. w * 150, h * 75, 'Stakeholder', 'Stakeholder', null, null, this.getTagsForStencil(gn, '', dt + 'stakeholder').join(' ')),
  274. this.createVertexTemplateEntry(am + 'role;',
  275. w * 60, h * 35, '', 'Stakeholder', null, null, this.getTagsForStencil(gn, '', dt + 'stakeholder').join(' ')),
  276. this.createVertexTemplateEntry(am + 'application;appType=driver;archiType=oct;',
  277. w * 150, h * 75, 'Driver', 'Driver', null, null, this.getTagsForStencil(gn, '', dt + 'driver').join(' ')),
  278. this.createVertexTemplateEntry(am + 'driver;',
  279. w * 40, h * 40, '', 'Driver', null, null, this.getTagsForStencil(gn, '', dt + 'driver').join(' ')),
  280. this.createVertexTemplateEntry(am + 'application;appType=assess;archiType=oct;',
  281. w * 150, h * 75, 'Assessment', 'Assessment', null, null, this.getTagsForStencil(gn, '', dt + 'assessment').join(' ')),
  282. this.createVertexTemplateEntry(am + 'assess;',
  283. w * 40, h * 40, '', 'Assessment', null, null, this.getTagsForStencil(gn, '', dt + 'assessment').join(' ')),
  284. this.createVertexTemplateEntry(am + 'application;appType=goal;archiType=oct;',
  285. w * 150, h * 75, 'Goal', 'Goal', null, null, this.getTagsForStencil(gn, '', dt + 'goal').join(' ')),
  286. this.createVertexTemplateEntry(am + 'goal;',
  287. w * 40, h * 40, '', 'Goal', null, null, this.getTagsForStencil(gn, '', dt + 'goal').join(' ')),
  288. this.createVertexTemplateEntry(am + 'application;appType=outcome;archiType=oct;',
  289. w * 150, h * 75, 'Outcome', 'Outcome', null, null, this.getTagsForStencil(gn, '', dt + 'outcome').join(' ')),
  290. this.createVertexTemplateEntry(am + 'outcome;strokeWidth=2;',
  291. w * 60, h * 60, '', 'Outcome', null, null, this.getTagsForStencil(gn, '', dt + 'outcome').join(' ')),
  292. this.createVertexTemplateEntry(am + 'application;appType=principle;archiType=oct;',
  293. w * 150, h * 75, 'Principle', 'Principle', null, null, this.getTagsForStencil(gn, '', dt + 'principle').join(' ')),
  294. this.createVertexTemplateEntry(am + 'principle;strokeWidth=2;',
  295. w * 40, h * 40, '', 'Principle', null, null, this.getTagsForStencil(gn, '', dt + 'principle').join(' ')),
  296. this.createVertexTemplateEntry(am + 'application;appType=requirement;archiType=oct;',
  297. w * 150, h * 75, 'Requirement', 'Requirement', null, null, this.getTagsForStencil(gn, '', dt + 'requirement').join(' ')),
  298. this.createVertexTemplateEntry(am + 'requirement;',
  299. w * 70, h * 35, '', 'Requirement', null, null, this.getTagsForStencil(gn, '', dt + 'requirement').join(' ')),
  300. this.createVertexTemplateEntry(am + 'application;appType=constraint;archiType=oct;',
  301. w * 150, h * 75, 'Constraint', 'Constraint', null, null, this.getTagsForStencil(gn, '', dt + 'constraint').join(' ')),
  302. this.createVertexTemplateEntry(am + 'constraint;',
  303. w * 70, h * 35, '', 'Constraint', null, null, this.getTagsForStencil(gn, '', dt + 'constraint').join(' ')),
  304. this.createVertexTemplateEntry(am + 'application;appType=meaning;archiType=oct;',
  305. w * 150, h * 75, 'Meaning', 'Meaning', null, null, this.getTagsForStencil(gn, '', dt + 'meaning').join(' ')),
  306. this.createVertexTemplateEntry('shape=mxgraph.basic.cloud_callout;html=1;whiteSpace=wrap;fillColor=#CCCCFF;',
  307. w * 70, h * 45, '', 'Meaning', null, null, this.getTagsForStencil(gn, '', dt + 'meaning').join(' ')),
  308. this.createVertexTemplateEntry(am + 'application;appType=amValue;archiType=oct;',
  309. w * 150, h * 75, 'Value', 'Value', null, null, this.getTagsForStencil(gn, '', dt + 'value').join(' ')),
  310. this.createVertexTemplateEntry('shape=ellipse;html=1;whiteSpace=wrap;fillColor=#CCCCFF;',
  311. w * 70, h * 35, '', 'Value', null, null, this.getTagsForStencil(gn, '', dt + 'value').join(' '))
  312. ];
  313. this.addPalette('archimate3Motivation', 'Archimate 3.2 / Motivation', false, mxUtils.bind(this, function(content)
  314. {
  315. for (var i = 0; i < fns.length; i++)
  316. {
  317. content.appendChild(fns[i](content));
  318. }
  319. }));
  320. };
  321. Sidebar.prototype.addArchimate3RelationshipsPalette = function()
  322. {
  323. // Space savers
  324. var sb = this;
  325. var gn = 'mxgraph.archimate3';
  326. var dt = 'archimate relationship ';
  327. var w = 1.0;
  328. var h = 1.0;
  329. var fns =
  330. [
  331. this.createEdgeTemplateEntry('html=1;startArrow=diamondThin;startFill=1;edgeStyle=elbowEdgeStyle;elbow=vertical;startSize=10;endArrow=none;endFill=0;',
  332. w * 160, 0, '', 'Composition', null, this.getTagsForStencil(gn, '', dt + 'composition').join(' ')),
  333. this.createEdgeTemplateEntry('html=1;startArrow=diamondThin;startFill=0;edgeStyle=elbowEdgeStyle;elbow=vertical;startSize=10;endArrow=none;endFill=0;',
  334. w * 160, 0, '', 'Aggregation', null, this.getTagsForStencil(gn, '', dt + 'aggregation').join(' ')),
  335. this.createEdgeTemplateEntry('endArrow=block;html=1;endFill=1;startArrow=oval;startFill=1;edgeStyle=elbowEdgeStyle;elbow=vertical;',
  336. w * 160, 0, '', 'Assignment', null, this.getTagsForStencil(gn, '', dt + 'assignment').join(' ')),
  337. this.createEdgeTemplateEntry('edgeStyle=elbowEdgeStyle;html=1;endArrow=block;elbow=vertical;endFill=0;dashed=1;',
  338. w * 160, 0, '', 'Realization', null, this.getTagsForStencil(gn, '', dt + 'realization').join(' ')),
  339. this.createEdgeTemplateEntry('edgeStyle=elbowEdgeStyle;html=1;endArrow=open;elbow=vertical;endFill=1;',
  340. w * 160, 0, '', 'Serving', null, this.getTagsForStencil(gn, '', dt + 'serving').join(' ')),
  341. this.createEdgeTemplateEntry('edgeStyle=elbowEdgeStyle;html=1;endArrow=none;elbow=vertical;dashed=1;startFill=0;dashPattern=1 4;',
  342. w * 160, 0, '', 'Access', null, this.getTagsForStencil(gn, '', dt + 'access').join(' ')),
  343. this.createEdgeTemplateEntry('edgeStyle=elbowEdgeStyle;html=1;endArrow=open;elbow=vertical;endFill=0;dashed=1;startArrow=open;startFill=0;dashPattern=1 4;',
  344. w * 160, 0, '', 'Access', null, this.getTagsForStencil(gn, '', dt + 'access').join(' ')),
  345. this.createEdgeTemplateEntry('edgeStyle=elbowEdgeStyle;html=1;endArrow=open;elbow=vertical;endFill=0;dashed=1;dashPattern=1 4;',
  346. w * 160, 0, '', 'Access', null, this.getTagsForStencil(gn, '', dt + 'access').join(' ')),
  347. this.addEntry('uml influence', function()
  348. {
  349. var edge = new mxCell('+/-', new mxGeometry(0, 0, 0, 0), 'edgeStyle=elbowEdgeStyle;html=1;endArrow=open;elbow=vertical;endFill=0;dashed=1;dashPattern=6 4;');
  350. edge.geometry.setTerminalPoint(new mxPoint(0, 0), true);
  351. edge.geometry.setTerminalPoint(new mxPoint(160, 0), false);
  352. edge.geometry.relative = true;
  353. edge.geometry.x = 1;
  354. edge.geometry.y = 10;
  355. edge.edge = true;
  356. return sb.createEdgeTemplateFromCells([edge], 160, 0, 'Influence');
  357. }),
  358. this.createEdgeTemplateEntry('edgeStyle=elbowEdgeStyle;html=1;endArrow=none;elbow=vertical;',
  359. w * 160, 0, '', 'Association', null, this.getTagsForStencil(gn, '', dt + 'association').join(' ')),
  360. this.createEdgeTemplateEntry('edgeStyle=elbowEdgeStyle;html=1;endArrow=openAsync;elbow=vertical;rounded=0;endFill=0;',
  361. w * 160, 0, '', 'Association', null, this.getTagsForStencil(gn, '', dt + 'association').join(' ')),
  362. this.createEdgeTemplateEntry('edgeStyle=elbowEdgeStyle;html=1;endArrow=block;dashed=0;elbow=vertical;endFill=1;',
  363. w * 160, 0, '', 'Triggering', null, this.getTagsForStencil(gn, '', dt + 'triggering').join(' ')),
  364. this.createEdgeTemplateEntry('edgeStyle=elbowEdgeStyle;html=1;endArrow=block;dashed=1;elbow=vertical;endFill=1;dashPattern=6 4;',
  365. w * 160, 0, '', 'Flow', null, this.getTagsForStencil(gn, '', dt + 'flow').join(' ')),
  366. this.createEdgeTemplateEntry('endArrow=block;html=1;endFill=0;edgeStyle=elbowEdgeStyle;elbow=vertical;',
  367. w * 160, 0, '', 'Specialization', null, this.getTagsForStencil(gn, '', dt + 'specialization').join(' ')),
  368. this.createVertexTemplateEntry('ellipse;html=1;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;fillColor=strokeColor',
  369. 10, 10, '', 'And Junction', null, this.getTagsForStencil(gn, '', dt + 'junction').join(' ')),
  370. this.createVertexTemplateEntry('ellipse;html=1;verticalLabelPosition=bottom;labelBackgroundColor=#ffffff;verticalAlign=top;fillColor=#ffffff',
  371. 10, 10, '', 'Or Junction', null, this.getTagsForStencil(gn, '', dt + 'junction').join(' '))
  372. ];
  373. this.addPalette('archimate3Relationships', 'Archimate 3.2 / Relationships', false, mxUtils.bind(this, function(content)
  374. {
  375. for (var i = 0; i < fns.length; i++)
  376. {
  377. content.appendChild(fns[i](content));
  378. }
  379. }));
  380. };
  381. Sidebar.prototype.addArchimate3StrategyPalette = function()
  382. {
  383. var am = 'html=1;outlineConnect=0;whiteSpace=wrap;fillColor=#F5DEAA;shape=mxgraph.archimate3.';
  384. // Space savers
  385. var sb = this;
  386. var gn = 'mxgraph.archimate3';
  387. var dt = 'archimate strategy ';
  388. var w = 1.0;
  389. var h = 1.0;
  390. var fns =
  391. [
  392. this.createVertexTemplateEntry(am + 'application;appType=resource;archiType=square;',
  393. w * 150, h * 75, 'Resource', 'Resource', null, null, this.getTagsForStencil(gn, '', dt + 'resource').join(' ')),
  394. this.createVertexTemplateEntry(am + 'resource;',
  395. w * 60, h * 40, '', 'Resource', null, null, this.getTagsForStencil(gn, '', dt + 'resource').join(' ')),
  396. this.createVertexTemplateEntry(am + 'application;appType=capability;archiType=rounded;',
  397. w * 150, h * 75, 'Capability', 'Capability', null, null, this.getTagsForStencil(gn, '', dt + 'capability').join(' ')),
  398. this.createVertexTemplateEntry(am + 'capability;',
  399. w * 40, h * 40, '', 'Capability', null, null, this.getTagsForStencil(gn, '', dt + 'capability').join(' ')),
  400. this.createVertexTemplateEntry(am + 'application;appType=valueStream;archiType=rounded;',
  401. w * 150, h * 75, 'Value Stream', 'Value Stream', null, null, this.getTagsForStencil(gn, '', dt + 'value stream').join(' ')),
  402. this.createVertexTemplateEntry(am + 'valueStream;',
  403. w * 70, h * 35, '', 'Value Stream', null, null, this.getTagsForStencil(gn, '', dt + 'value stream').join(' ')),
  404. this.createVertexTemplateEntry(am + 'application;appType=course;archiType=rounded;',
  405. w * 150, h * 75, 'Course of Action', 'Course of Action', null, null, this.getTagsForStencil(gn, '', dt + 'course action').join(' ')),
  406. this.createVertexTemplateEntry(am + 'course;',
  407. w * 40, h * 40, '', 'Course of Action', null, null, this.getTagsForStencil(gn, '', dt + 'course of action').join(' '))
  408. ];
  409. this.addPalette('archimate3Strategy', 'Archimate 3.2 / Strategy', false, mxUtils.bind(this, function(content)
  410. {
  411. for (var i = 0; i < fns.length; i++)
  412. {
  413. content.appendChild(fns[i](content));
  414. }
  415. }));
  416. };
  417. Sidebar.prototype.addArchimate3TechnologyPalette = function()
  418. {
  419. var am = 'html=1;outlineConnect=0;whiteSpace=wrap;fillColor=#AFFFAF;shape=mxgraph.archimate3.';
  420. // Space savers
  421. var sb = this;
  422. var gn = 'mxgraph.archimate3';
  423. var dt = 'archimate technology ';
  424. var w = 1.0;
  425. var h = 1.0;
  426. var fns =
  427. [
  428. this.createVertexTemplateEntry(am + 'application;appType=node;archiType=square;',
  429. w * 150, h * 75, 'Node', 'Node', null, null, this.getTagsForStencil(gn, '', dt + 'node').join(' ')),
  430. this.createVertexTemplateEntry(am + 'node;',
  431. w * 70, h * 40, '', 'Node', null, null, this.getTagsForStencil(gn, '', dt + 'node').join(' ')),
  432. this.createVertexTemplateEntry(am + 'application;appType=device;',
  433. w * 150, h * 75, 'Device', 'Device', null, null, this.getTagsForStencil(gn, '', dt + 'device').join(' ')),
  434. this.createVertexTemplateEntry(am + 'device;',
  435. w * 70, h * 35, '', 'Device', null, null, this.getTagsForStencil(gn, '', dt + 'device').join(' ')),
  436. this.createVertexTemplateEntry(am + 'application;appType=sysSw;archiType=square;',
  437. w * 150, h * 75, 'System Software', 'System Software', null, null, this.getTagsForStencil(gn, '', dt + 'system software').join(' ')),
  438. this.createVertexTemplateEntry(am + 'sysSw;',
  439. w * 40, h * 40, '', 'System Software', null, null, this.getTagsForStencil(gn, '', dt + 'device').join(' ')),
  440. this.createVertexTemplateEntry(am + 'application;appType=collab;archiType=square;',
  441. w * 150, h * 75, 'Technology Collaboration', 'Technology Collaboration', null, null, this.getTagsForStencil(gn, '', dt + 'collaboration').join(' ')),
  442. this.createVertexTemplateEntry(am + 'collaboration;',
  443. w * 60, h * 35, '', 'Collaboration', null, null, this.getTagsForStencil(gn, '', dt + 'collaboration').join(' ')),
  444. this.createVertexTemplateEntry(am + 'application;appType=interface;archiType=square;',
  445. w * 150, h * 75, 'Technology Interface', 'Technology Interface', null, null, this.getTagsForStencil(gn, '', dt + 'component').join(' ')),
  446. this.createVertexTemplateEntry(am + 'interface;',
  447. w * 70, h * 35, '', 'Interface', null, null, this.getTagsForStencil(gn, '', dt + 'interface').join(' ')),
  448. this.createVertexTemplateEntry(am + 'application;appType=path;archiType=square;',
  449. w * 150, h * 75, 'Path', 'Path', null, null, this.getTagsForStencil(gn, '', dt + 'communication network').join(' ')),
  450. this.createVertexTemplateEntry(am + 'path;strokeWidth=6;',
  451. w * 100, h * 30, '', 'Path', null, null, this.getTagsForStencil(gn, '', dt + 'path').join(' ')),
  452. this.createVertexTemplateEntry(am + 'application;appType=netw;archiType=square;',
  453. w * 150, h * 75, 'Communication Network', 'Communication Network', null, null, this.getTagsForStencil(gn, '', dt + 'communication network').join(' ')),
  454. this.createVertexTemplateEntry(am + 'network;',
  455. w * 65, h * 50, '', 'Communication Network', null, null, this.getTagsForStencil(gn, '', dt + 'communication network').join(' ')),
  456. this.createVertexTemplateEntry(am + 'application;appType=proc;archiType=rounded;',
  457. w * 150, h * 75, 'Technology Process', 'Technology Process', null, null, this.getTagsForStencil(gn, '', dt + 'process').join(' ')),
  458. this.createVertexTemplateEntry(am + 'process;',
  459. w * 70, h * 35, '', 'Process', null, null, this.getTagsForStencil(gn, '', dt + 'process').join(' ')),
  460. this.createVertexTemplateEntry(am + 'application;appType=interaction;archiType=rounded;',
  461. w * 150, h * 75, 'Technology Interaction', 'Technology Interaction', null, null, this.getTagsForStencil(gn, '', dt + 'interaction').join(' ')),
  462. this.createVertexTemplateEntry(am + 'interaction;',
  463. w * 40, h * 40, '', 'Interaction', null, null, this.getTagsForStencil(gn, '', dt + 'interaction').join(' ')),
  464. this.createVertexTemplateEntry(am + 'application;appType=event;archiType=rounded',
  465. w * 150, h * 75, 'Technology Event', 'Technology Event', null, null, this.getTagsForStencil(gn, '', dt + 'event').join(' ')),
  466. this.createVertexTemplateEntry(am + 'event;',
  467. w * 60, h * 35, '', 'Event', null, null, this.getTagsForStencil(gn, '', dt + 'event').join(' ')),
  468. this.createVertexTemplateEntry(am + 'application;appType=serv;archiType=rounded',
  469. w * 150, h * 75, 'Technology Service', 'Technology Service', null, null, this.getTagsForStencil(gn, '', dt + 'service').join(' ')),
  470. this.createVertexTemplateEntry(am + 'service;',
  471. w * 60, h * 35, '', 'Service', null, null, this.getTagsForStencil(gn, '', dt + 'service').join(' ')),
  472. this.createVertexTemplateEntry(am + 'application;appType=artifact;archiType=square;',
  473. w * 150, h * 75, 'Artifact', 'Artifact', null, null, this.getTagsForStencil(gn, '', dt + 'artifact').join(' ')),
  474. this.createVertexTemplateEntry('html=1;outlineConnect=0;whiteSpace=wrap;fillColor=#AFFFAF;shape=note;size=14;',
  475. w * 70, h * 35, '', 'Artifact', null, null, this.getTagsForStencil(gn, '', dt + 'artifact').join(' ')),
  476. this.createVertexTemplateEntry(am + 'application;appType=equipment;archiType=square;',
  477. w * 150, h * 75, 'Equipment', 'Equipment', null, null, this.getTagsForStencil(gn, '', dt + 'artifact').join(' ')),
  478. this.createVertexTemplateEntry(am + 'equipment;',
  479. w * 50, h * 50, '', 'Equipment', null, null, this.getTagsForStencil(gn, '', dt + 'artifact').join(' ')),
  480. this.createVertexTemplateEntry(am + 'application;appType=facility;archiType=square;',
  481. w * 150, h * 75, 'Facility', 'Facility', null, null, this.getTagsForStencil(gn, '', dt + 'facility').join(' ')),
  482. this.createVertexTemplateEntry(am + 'facility;',
  483. w * 60, h * 40, '', 'Facility', null, null, this.getTagsForStencil(gn, '', dt + 'facility').join(' ')),
  484. this.createVertexTemplateEntry(am + 'application;appType=distribution;archiType=square;',
  485. w * 150, h * 75, 'Distribution Network', 'Distribution Network', null, null, this.getTagsForStencil(gn, '', dt + 'distribution network').join(' ')),
  486. this.createVertexTemplateEntry(am + 'distribution;strokeWidth=4;',
  487. w * 70, h * 30, '', 'Distribution Network', null, null, this.getTagsForStencil(gn, '', dt + 'distribution network').join(' ')),
  488. this.createVertexTemplateEntry(am + 'application;appType=material;archiType=square;',
  489. w * 150, h * 75, 'Material', 'Material', null, null, this.getTagsForStencil(gn, '', dt + 'material').join(' ')),
  490. this.createVertexTemplateEntry(am + 'material;',
  491. w * 60, h * 50, '', 'Material', null, null, this.getTagsForStencil(gn, '', dt + 'material').join(' '))
  492. ];
  493. this.addPalette('archimate3Technology', 'Archimate 3.2 / Technology', false, mxUtils.bind(this, function(content)
  494. {
  495. for (var i = 0; i < fns.length; i++)
  496. {
  497. content.appendChild(fns[i](content));
  498. }
  499. }));
  500. };
  501. })();