You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| _--custom-resolver_ : use an external resolver for the resolution of the model elements | `bamm aspect AspectModel.ttl validate --custom-resolver myresolver.sh`
| _--output, -o_ : the output will be saved to the given file | `bamm aspect AspectModel.ttl prettyprint -o c:\Results\PrettyPrinted.ttl`
44
+
| _--output, -o_ : the output will be saved to the given file | `bamm aspect AspectModel.ttl prettyprint -o c:\Results\PrettyPrinted.ttl`
44
45
.2+| aspect <model> migrate | Migrate Aspect Model to the latest BAMM version | `bamm aspect AspectModel.ttl migrate AspectModel.ttl`
45
-
| _--output, -o_ : the output will be saved to the given file | `bamm aspect AspectModel.ttl migrate AspectModel.ttl -o c:\Results\MigratedModel.ttl`
46
-
.4+| aspect <model> to html | Generate HTML documentation for an Aspect Model | `bamm aspect AspectModel.ttl to html`
47
-
| _--output, -o_ : the output will be saved to the given file | `bamm aspect AspectModel.ttl to html -o c:\Model.html`
48
-
| _--css, -c_ : CSS file with custom styles to be included in the generated HTML documentation | `bamm aspect AspectModel.ttl to html -c c:\styles.css`
49
-
| _--language, -l_ : The language from the model for which the HTML should be generated (default: en) | `bamm aspect AspectModel.ttl to html -l de`
50
-
.3+| aspect <model> to png | Generate PNG diagram for Aspect Model | `bamm aspect AspectModel.ttl to png`
51
-
| _--output, -o_ : output file path (default: stdout); as PNG is a binary format, it is strongly recommended to output the result to a file by using the -o option or the console redirection operator '>')|
46
+
| _--output, -o_ : the output will be saved to the given file | `bamm aspect AspectModel.ttl migrate AspectModel.ttl -o c:\Results\MigratedModel.ttl`
47
+
.5+| aspect <model> to html | Generate HTML documentation for an Aspect Model | `bamm aspect AspectModel.ttl to html`
48
+
| _--output, -o_ : the output will be saved to the given file | `bamm aspect AspectModel.ttl to html -o c:\Model.html`
49
+
| _--css, -c_ : CSS file with custom styles to be included in the generated HTML documentation | `bamm aspect AspectModel.ttl to html -c c:\styles.css`
50
+
| _--language, -l_ : The language from the model for which the HTML should be generated (default: en) | `bamm aspect AspectModel.ttl to html -l de`
51
+
| _--custom-resolver_ : use an external resolver for the resolution of the model elements | `bamm aspect AspectModel.ttl to html --custom-resolver myresolver.bat`
52
+
.4+| aspect <model> to png | Generate PNG diagram for Aspect Model | `bamm aspect AspectModel.ttl to png`
53
+
| _--output, -o_ : output file path (default: stdout); as PNG is a binary format, it is strongly recommended to output the result to a file by using the -o option or the console redirection operator '>')|
52
54
| _--language, -l_ : the language from the model for which the diagram should be generated (default: en)|
53
-
.3+| aspect <model> to svg | Generate SVG diagram for Aspect Model | `bamm aspect AspectModel.ttl to svg`
55
+
| _--custom-resolver_ : use an external resolver for the resolution of the model elements | `bamm aspect AspectModel.ttl to png --custom-resolver resolver.jar`
56
+
.4+| aspect <model> to svg | Generate SVG diagram for Aspect Model | `bamm aspect AspectModel.ttl to svg`
54
57
| _--output, -o_ : the output will be saved to the given file |
55
58
| _--language, -l_ : the language from the model for which the diagram should be generated (default: en)|
56
-
.3+| aspect <model> to dot | Generate https://graphviz.org/doc/info/lang.html[DOT] diagram for Aspect Model | `bamm aspect AspectModel.ttl to dot`
59
+
| _--custom-resolver_ : use an external resolver for the resolution of the model elements | `bamm aspect AspectModel.ttl to svg --custom-resolver "java -jar resolver.jar"`
60
+
.4+| aspect <model> to dot | Generate https://graphviz.org/doc/info/lang.html[DOT] diagram for Aspect Model | `bamm aspect AspectModel.ttl to dot`
| _--template-library-file, -tlf_ : the path and name of the https://velocity.apache.org/[Velocity] template file containing the macro library|
64
69
| _--execute-library-macros, -elm_ : Execute the macros provided in the https://velocity.apache.org/[Velocity] macro library|
65
70
| _--static, -s_ : generate Java domain classes for a Static Meta Model|
66
-
.12+| aspect <model> to openapi | Generate https://spec.openapis.org/oas/v3.0.3[OpenAPI] specification for an Aspect Model | `bamm aspect AspectModel.ttl to openapi -j`
71
+
| _--custom-resolver_ : use an external resolver for the resolution of the model elements |
72
+
.13+| aspect <model> to openapi | Generate https://spec.openapis.org/oas/v3.0.3[OpenAPI] specification for an Aspect Model | `bamm aspect AspectModel.ttl to openapi -j`
| _--api-base-url, -b_ : the base url for the Aspect API used in the https://spec.openapis.org/oas/v3.0.3[OpenAPI] specification| `bamm aspect AspectModel.ttl to openapi -j -b \http://mysite.de`
69
75
| _--json, -j_ : generate a JSON specification for an Aspect Model (default format is YAML)|
@@ -75,15 +81,29 @@ The available options and their meaning can also be seen in the help text of the
75
81
| _--paging-cursor-based, -pc_ : in case there is more than one paging possibility, it has to be cursor based paging|
76
82
| _--paging-offset-based, -po_ : in case there is more than one paging possibility, it has to be offset based paging|
77
83
| _--paging-time-based, -pt_ : in case there is more than one paging possibility, it has to be time based paging|
78
-
.2+| aspect <model> to json | Generate OpenAPI JSON specification for an Aspect Model | `bamm aspect AspectModel.ttl to json`
84
+
| _--custom-resolver_ : use an external resolver for the resolution of the model elements |
85
+
.3+| aspect <model> to json | Generate OpenAPI JSON specification for an Aspect Model | `bamm aspect AspectModel.ttl to json`
| _--format, -f_ : output file format (xml or aasx, default: xml)|
94
+
| _--custom-resolver_ : use an external resolver for the resolution of the model elements |
85
95
|===
86
96
97
+
=== Custom model resolver
98
+
99
+
To allow the users to provide their own custom implementations of a model resolver, `--custom-resolver` command-line switch can be used.
100
+
The value of the switch can be any command which is directly executable by the underlying operating system (such as a batch script on Windows or a shell script on Linux/Unix).
101
+
When a model element needs to be resolved, this command is executed with the URN of the element to resolve passed as the last parameter.
102
+
The command can provide other parameters as well, the element URN will be added automatically as the last one by bamm-cli.
103
+
The resolved model definition is expected to be output to the stdout in Turtle format.
104
+
From there, it is read by the bamm-cli and passed on to the internal processing pipeline.
105
+
In this way the extension can be flexibly done in any programming language/script language, including complex logic if necessary.
106
+
87
107
== Using the CLI to create a JSON OpenAPI Specification
88
108
89
109
Every specification is based on one Aspect, which needs a separately defined server URL where the given aspect will be.
0 commit comments