Automate Updates to the API Client Library
[appc.git] / appc-client / client-kit / pom.xml
index cc21d04..3ff3b78 100644 (file)
         <licenseDir>${project.parent.parent.basedir}</licenseDir>\r
     </properties>\r
 \r
+    <build>\r
+        <plugins>\r
+            <plugin>\r
+                <groupId>org.onap.appc.client</groupId>\r
+                <artifactId>code-generator</artifactId>\r
+                <version>${project.parent.version}</version>\r
+                <dependencies>\r
+                    <dependency>\r
+                        <groupId>org.onap.appc</groupId>\r
+                        <artifactId>appc-provider-model</artifactId>\r
+                        <version>${project.parent.version}</version>\r
+                    </dependency>\r
+                </dependencies>\r
+                <executions>\r
+                    <execution>\r
+                        <id>code-generate-json</id>\r
+                        <goals>\r
+                            <goal>generate-sources</goal>\r
+                        </goals>\r
+                        <configuration>\r
+                            <sourceFileName>META-INF/yang/appc-provider-lcm.yang</sourceFileName>\r
+                            <outputFileName>target/generated-sources/appc-provider-lcm/appc-provider-lcm.json</outputFileName>\r
+                            <templateName>templates/open-api/yang-to-open-api.ftl</templateName>\r
+                            <contextBuilderClassName>org.onap.appc.tools.generator.extensions.YangContextBuilderImpl\r
+                            </contextBuilderClassName>\r
+                            <contextConfigFileName>APPC</contextConfigFileName>\r
+                        </configuration>\r
+                    </execution>\r
+                    <execution>\r
+                        <id>code-generate-java</id>\r
+                        <goals>\r
+                            <goal>generate-sources</goal>\r
+                        </goals>\r
+                        <configuration>\r
+                            <sourceFileName>target/generated-sources/appc-provider-lcm/appc-provider-lcm.json</sourceFileName>\r
+                            <outputFileName>target/generated-sources/appc-provider-lcm/output.txt</outputFileName>\r
+                            <templateName>templates/client-kit/open-api-to-java.ftl</templateName>\r
+                            <contextBuilderClassName>org.onap.appc.tools.generator.extensions.JsonContextBuilderImpl</contextBuilderClassName>\r
+                            <contextConfigFileName>configuration/client-kit.properties</contextConfigFileName>\r
+                        </configuration>\r
+                    </execution>\r
+                </executions>\r
+            </plugin>\r
+        </plugins>\r
+    </build>\r
+\r
     <dependencies>\r
         <dependency>\r
             <groupId>org.onap.appc.client</groupId>\r
@@ -50,5 +96,6 @@
             <version>${yang.parser.impl.version}</version>\r
             <scope>test</scope>\r
         </dependency>\r
+\r
     </dependencies>\r
 </project>\r