2 ============LICENSE_START=======================================================
3 Copyright (C) 2018 Ericsson. All rights reserved.
4 Modifications Copyright (C) 2020,2022 Nordix Foundation.
5 ================================================================================
6 Licensed under the Apache License, Version 2.0 (the "License");
7 you may not use this file except in compliance with the License.
8 You may obtain a copy of the License at
10 http://www.apache.org/licenses/LICENSE-2.0
12 Unless required by applicable law or agreed to in writing, software
13 distributed under the License is distributed on an "AS IS" BASIS,
14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 See the License for the specific language governing permissions and
16 limitations under the License.
18 SPDX-License-Identifier: Apache-2.0
19 ============LICENSE_END=========================================================
22 xmlns="http://maven.apache.org/POM/4.0.0"
23 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
24 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
25 <modelVersion>4.0.0</modelVersion>
27 <groupId>org.onap.policy.apex-pdp.examples</groupId>
28 <artifactId>examples</artifactId>
29 <version>3.1.3-SNAPSHOT</version>
32 <artifactId>examples-myfirstpolicy</artifactId>
33 <name>${project.artifactId}</name>
34 <description>Specific code for the Apex MyFirstPolicy Example</description>
37 <policymodel1m.name>MyFirstPolicyModelMvel_0.0.1</policymodel1m.name>
38 <policymodel1j.name>MyFirstPolicyModelJavascript_0.0.1</policymodel1j.name>
39 <policymodel2.name>MyFirstPolicyModel_0.0.1</policymodel2.name>
40 <policymodel3.name>MyFirstPolicyModelSFL_0.0.1</policymodel3.name>
41 <policymodel4.name>MyFirstPolicyModelAvro_0.0.1</policymodel4.name>
46 <groupId>org.onap.policy.apex-pdp.model</groupId>
47 <artifactId>model</artifactId>
48 <version>${project.version}</version>
51 <groupId>org.onap.policy.apex-pdp.core</groupId>
52 <artifactId>core</artifactId>
53 <version>${project.version}</version>
57 <groupId>org.onap.policy.apex-pdp.auth</groupId>
58 <artifactId>cli-editor</artifactId>
59 <version>${project.version}</version>
62 <groupId>org.onap.policy.apex-pdp.plugins.plugins-executor</groupId>
63 <artifactId>plugins-executor-mvel</artifactId>
64 <version>${project.version}</version>
68 <groupId>org.onap.policy.apex-pdp.plugins.plugins-executor</groupId>
69 <artifactId>plugins-executor-javascript</artifactId>
70 <version>${project.version}</version>
78 <groupId>org.codehaus.mojo</groupId>
79 <artifactId>exec-maven-plugin</artifactId>
81 <!-- Generate the APEX Policy JSON files from the APEX CLI command -->
83 <id>generate-policy1m</id>
84 <phase>compile</phase>
89 <mainClass>org.onap.policy.apex.auth.clieditor.ApexCommandLineEditorMain</mainClass>
90 <classpathScope>compile</classpathScope>
93 --command-file=${project.basedir}/src/main/resources/examples/models/MyFirstPolicy/1/${policymodel1m.name}.apex
96 --output-model-file=${project.build.directory}/classes/examples/models/MyFirstPolicy/1/${policymodel1m.name}.json
99 --log-file=${project.build.directory}/${policymodel1m.name}_policygeneration.log
101 <argument>--working-dir=${project.basedir}</argument>
106 <id>generate-policy1j</id>
107 <phase>compile</phase>
112 <mainClass>org.onap.policy.apex.auth.clieditor.ApexCommandLineEditorMain</mainClass>
113 <classpathScope>compile</classpathScope>
116 --command-file=${project.basedir}/src/main/resources/examples/models/MyFirstPolicy/1/${policymodel1j.name}.apex
119 --output-model-file=${project.build.directory}/classes/examples/models/MyFirstPolicy/1/${policymodel1j.name}.json
122 --log-file=${project.build.directory}/${policymodel1j.name}_policygeneration.log
124 <argument>--working-dir=${project.basedir}</argument>
129 <id>generate-policy2</id>
130 <phase>compile</phase>
135 <mainClass>org.onap.policy.apex.auth.clieditor.ApexCommandLineEditorMain</mainClass>
136 <classpathScope>compile</classpathScope>
139 --command-file=${project.basedir}/src/main/resources/examples/models/MyFirstPolicy/2/${policymodel2.name}.apex
142 --output-model-file=${project.build.directory}/classes/examples/models/MyFirstPolicy/2/${policymodel2.name}.json
145 --log-file=${project.build.directory}/${policymodel2.name}_policygeneration.log
147 <argument>--working-dir=${project.basedir}</argument>
152 <id>generate-policy3</id>
153 <phase>compile</phase>
158 <mainClass>org.onap.policy.apex.auth.clieditor.ApexCommandLineEditorMain</mainClass>
159 <classpathScope>compile</classpathScope>
162 --command-file=${project.basedir}/src/main/resources/examples/models/MyFirstPolicy/3/${policymodel3.name}.apex
165 --output-model-file=${project.build.directory}/classes/examples/models/MyFirstPolicy/3/${policymodel3.name}.json
168 --log-file=${project.build.directory}/${policymodel3.name}_policygeneration.log
170 <argument>--working-dir=${project.basedir}</argument>
175 <id>generate-policy4</id>
176 <phase>compile</phase>
181 <mainClass>org.onap.policy.apex.auth.clieditor.ApexCommandLineEditorMain</mainClass>
182 <classpathScope>compile</classpathScope>
185 --command-file=${project.basedir}/src/main/resources/examples/models/MyFirstPolicy/4/${policymodel4.name}.apex
188 --output-model-file=${project.build.directory}/classes/examples/models/MyFirstPolicy/4/${policymodel4.name}.json
191 --log-file=${project.build.directory}/${policymodel4.name}_policygeneration.log
193 <argument>--working-dir=${project.basedir}</argument>