addinshapescript - Helmut-Ortmann/EnterpriseArchitect_hoTools GitHub Wiki
You need something you can't express with EA ShapeScript language. Add-Ins give you the power to almost visualize everything. The things you have to consider:
- First Add-In for ShapeScript needs some time
- Diagram rendering performance may be decreased
-
Specify what you want to visualize
print("#ADDIN:AddInSimple, GetParentProperty, TAG=TEST#");
-
Define a Stereotype, see e.g. Domain specific Profiles, by Thomas Kilian
-
Write your ShapeScript, see e.g. Shape Script made easy, by Thomas Kilian
-
Develop your Add-In (usually, add a public function to an existing one)
public string GetParentProperty(EA.Repository repository, string eaGuid, object theParams) {..}
-
Install Add-In (you can test it in DEBUG mode first)
-
Test, improve and give feedback
hoTools contains two C# Visual Studio 2017 projects which show:
- How to construct an Addin, see AddInSimple
- How to deploy an Addin using a WIX Installation Project, see, AddInSimpleSetup
- Two Example Shape Script methods:
- public string GetValueForShape(EA.Repository repository, string eaGuid, object theParams)
- public string GetParentProperty(EA.Repository repository, string eaGuid, object theParams)
The Shape Script print method GetParentProperty outputs the specified information of a parent Element. GetParentProperty supports the following theParams values (see implementation):
- ALIAS
- COMPLEXITY
- ISSUE=<IssueName> (visualize Reporter)
- KEYWORDS
- LANGUAGE
- NAME
- PHASE
- RESOURCE=<ResourceName> (Visualize Role)
- RISK=<RiskName> (visualize weight)
- RUNSTATE
- STATUS
- STEREOTYPE
- TAG=<TagName>
- TEST=<TestName> (visualize test result)
- TYPE
- VERSION
If you understand how to implement & deploy an Add-In, then it's just a few lines of code. The example should give you the know-how to do it or to find someone who will make it for you.
To install Add-Ins the user needs local administration rights. You may look to Non-admin installation of Add-Ins to find a way around.
Be aware: Excessive use of Add-In to print in Shape Scripts may decrease diagram rendering performance.
I've found, bought, and appreciated the following books
- Fifty Enterprise Architect tricks, by Peter Doomen
- Scripting Enterprise Architect, by Thomas Kilian
- Inside Enterprise Architect, by Thomas Kilian
- Shape Script made easy, by Thomas Kilian
- Domain Specific Profiles
- EA Forum entry to show the principles
- AddInSimple: C# Example Addin with Shape Script extension
- AddinSimpleSetup: C#/WIX Example Installation Project for AddinSimple
- Tip&Tricks
- SPARX Tricks and Traps Add-In Deployment
- EA Installation Inspector V2, by Adrian
- Non-admin installation of Add-Ins
- Tutorial: C# Add-In in 10 minutes, by Geert Bellekens
- Implementation