diff --git a/extensions/java16/pom.xml b/integrationtest/java16/pom.xml similarity index 88% rename from extensions/java16/pom.xml rename to integrationtest/java16/pom.xml index 814be0bb..0e86bce7 100644 --- a/extensions/java16/pom.xml +++ b/integrationtest/java16/pom.xml @@ -7,7 +7,7 @@ io.toolisticon.aptk - extension-parent + integrationtest-parent 0.24.1-148_records-SNAPSHOT @@ -16,12 +16,6 @@ - - - io.toolisticon.aptk - aptk-tools-java9 - - io.toolisticon.aptk aptk-tools @@ -57,7 +51,6 @@ io.toolisticon.aptk:aptk-tools:* - io.toolisticon.aptk:aptk-tools-java9:* *:*:*:*:test:* *:*:*:*:provided:* @@ -84,6 +77,14 @@ + + org.apache.maven.plugins + maven-deploy-plugin + + true + + + diff --git a/extensions/java16/src/test/java/io/toolisticon/aptk/tools/wrapper/Java16Tests.java b/integrationtest/java16/src/test/java/io/toolisticon/aptk/tools/wrapper/Java16Tests.java similarity index 100% rename from extensions/java16/src/test/java/io/toolisticon/aptk/tools/wrapper/Java16Tests.java rename to integrationtest/java16/src/test/java/io/toolisticon/aptk/tools/wrapper/Java16Tests.java diff --git a/extensions/java9/pom.xml b/integrationtest/java9/pom.xml similarity index 89% rename from extensions/java9/pom.xml rename to integrationtest/java9/pom.xml index 17b2be14..761d794e 100644 --- a/extensions/java9/pom.xml +++ b/integrationtest/java9/pom.xml @@ -7,7 +7,7 @@ io.toolisticon.aptk - extension-parent + integrationtest-parent 0.24.1-148_records-SNAPSHOT @@ -77,6 +77,13 @@ + + org.apache.maven.plugins + maven-deploy-plugin + + true + + diff --git a/extensions/java9/src/test/java/io/toolisticon/aptk/wrapper/ModuleElementWrapperTest.java b/integrationtest/java9/src/test/java/io/toolisticon/aptk/wrapper/ModuleElementWrapperTest.java similarity index 100% rename from extensions/java9/src/test/java/io/toolisticon/aptk/wrapper/ModuleElementWrapperTest.java rename to integrationtest/java9/src/test/java/io/toolisticon/aptk/wrapper/ModuleElementWrapperTest.java diff --git a/extensions/pom.xml b/integrationtest/pom.xml similarity index 91% rename from extensions/pom.xml rename to integrationtest/pom.xml index 9bafa412..2a587340 100644 --- a/extensions/pom.xml +++ b/integrationtest/pom.xml @@ -1,7 +1,7 @@ 4.0.0 - extension-parent + integrationtest-parent pom @@ -10,7 +10,7 @@ 0.24.1-148_records-SNAPSHOT - extension-parent + integrationtest-parent diff --git a/pom.xml b/pom.xml index 5d5f6272..01f9b5d0 100644 --- a/pom.xml +++ b/pom.xml @@ -18,7 +18,7 @@ tools example templating - extensions + integrationtest annotationwrapper diff --git a/tools/src/main/java/io/toolisticon/aptk/tools/wrapper/RecordComponentElementWrapper.java b/tools/src/main/java/io/toolisticon/aptk/tools/wrapper/RecordComponentElementWrapper.java index a08bd743..c41db307 100644 --- a/tools/src/main/java/io/toolisticon/aptk/tools/wrapper/RecordComponentElementWrapper.java +++ b/tools/src/main/java/io/toolisticon/aptk/tools/wrapper/RecordComponentElementWrapper.java @@ -31,6 +31,11 @@ public ExecutableElementWrapper getAccessor() { return ExecutableElementWrapper.wrap(this.invokeParameterlessMethodOfElement("getAccessor", null)); } + /** + * Re-wraps an ElementWrapper to a RecordComponentElementWrapper. + * @param element the wrapper to re-wrap + * @return The RecordComponentElementWrapper or null if the passed ElementWrapper doesn't wrap a RecordComponentElement + */ public static RecordComponentElementWrapper toRecordComponentElement(ElementWrapper element) { if (element == null) { return null; @@ -38,6 +43,12 @@ public static RecordComponentElementWrapper toRecordComponentElement(ElementWrap return RecordComponentElementWrapper.wrap(element.unwrap()); } + /** + * Wraps an element with the RecordComponentElementWrapper. + * + * @param element the element to wrap + * @return the wrapped element, or null if passed element isn't an RecordComponentElement + */ public static RecordComponentElementWrapper wrap(Element element) { if (element == null || !"RECORD_COMPONENT".equals(element.getKind().name())) { return null;