<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<parent>
		<groupId>hu.icellmobilsoft.coffee</groupId>
		<artifactId>coffee-dto</artifactId>
		<version>2.2.0</version>
	</parent>

	<artifactId>coffee-dto-gen</artifactId>

	<dependencies>
		<dependency>
			<groupId>hu.icellmobilsoft.coffee</groupId>
			<artifactId>coffee-dto-xsd</artifactId>
		</dependency>
		<dependency>
			<groupId>hu.icellmobilsoft.coffee</groupId>
			<artifactId>coffee-dto-base</artifactId>
		</dependency>

		<dependency>
			<groupId>org.eclipse.microprofile.openapi</groupId>
			<artifactId>microprofile-openapi-api</artifactId>
			<version>3.0</version>
		</dependency>

		<!--Test dependecies -->
		<dependency>
			<groupId>org.junit.jupiter</groupId>
			<artifactId>junit-jupiter</artifactId>
			<version>5.9.1</version>
			<scope>test</scope>
		</dependency>
	</dependencies>

	<build>
		<plugins>
			<plugin>
<!-- eredeti plugin: ez nem tudja a jaxb3 vagy 4-et
				<groupId>org.jvnet.jaxb2.maven2</groupId>
				<artifactId>maven-jaxb2-plugin</artifactId>
				<version>0.15.1</version>
-->
<!-- forkolt es releaselt plugin a felsobol kiindulva jaxb4-re -->
<!-- https://github.com/phax/maven-jaxb2-plugin/tree/v016 -->
				<groupId>com.helger.maven</groupId>
				<artifactId>jaxb40-maven-plugin</artifactId>
				<version>0.16.0</version>

				<executions>
					<execution>
						<id>coffee-super</id>
						<goals>
							<goal>generate</goal>
						</goals>
						<configuration>
							<strict>false</strict>
							<!-- https://github.com/highsource/maven-jaxb2-plugin/wiki/Catalogs-in-Strict-Mode -->
							<catalog>src/main/resources/xsd/hu/icellmobilsoft/coffee/dto/super.catalog.xml</catalog>
							<schemaIncludes>
								<include>xsd/hu/icellmobilsoft/coffee/dto/super.xsd</include>
							</schemaIncludes>
							<bindingIncludes>
								<include>xsd/hu/icellmobilsoft/coffee/dto/bindings.xjb</include>
							</bindingIncludes>
							<generateDirectory>${project.build.directory}/generated-sources/src/main/java</generateDirectory>
						</configuration>
					</execution>
				</executions>
				<configuration>
					<verbose>true</verbose>
					<schemaDirectory>src/main/resources</schemaDirectory>
					<args>
						<arguments>-openapify</arguments>
						<arguments>-Xfluent-api</arguments>
					</args>
					<plugins>
						<plugin>
							<groupId>hu.icellmobilsoft.jaxb</groupId>
							<artifactId>openapi-jaxb-plugin</artifactId>
							<version>2.0.0</version>
						</plugin>
						<plugin>
							<groupId>net.java.dev.jaxb2-commons</groupId>
							<artifactId>jaxb-fluent-api</artifactId>
							<version>2.1.8</version>
						</plugin>
					</plugins>
				</configuration>
			</plugin>
		</plugins>
	</build>
</project>
