diff --git a/.mvn/wrapper/MavenWrapperDownloader.java b/.mvn/wrapper/MavenWrapperDownloader.java
new file mode 100644
index 0000000..b901097
--- /dev/null
+++ b/.mvn/wrapper/MavenWrapperDownloader.java
@@ -0,0 +1,117 @@
+/*
+ * Copyright 2007-present the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+import java.net.*;
+import java.io.*;
+import java.nio.channels.*;
+import java.util.Properties;
+
+public class MavenWrapperDownloader {
+
+ private static final String WRAPPER_VERSION = "0.5.6";
+ /**
+ * Default URL to download the maven-wrapper.jar from, if no 'downloadUrl' is provided.
+ */
+ private static final String DEFAULT_DOWNLOAD_URL = "https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/"
+ + WRAPPER_VERSION + "/maven-wrapper-" + WRAPPER_VERSION + ".jar";
+
+ /**
+ * Path to the maven-wrapper.properties file, which might contain a downloadUrl property to
+ * use instead of the default one.
+ */
+ private static final String MAVEN_WRAPPER_PROPERTIES_PATH =
+ ".mvn/wrapper/maven-wrapper.properties";
+
+ /**
+ * Path where the maven-wrapper.jar will be saved to.
+ */
+ private static final String MAVEN_WRAPPER_JAR_PATH =
+ ".mvn/wrapper/maven-wrapper.jar";
+
+ /**
+ * Name of the property which should be used to override the default download url for the wrapper.
+ */
+ private static final String PROPERTY_NAME_WRAPPER_URL = "wrapperUrl";
+
+ public static void main(String args[]) {
+ System.out.println("- Downloader started");
+ File baseDirectory = new File(args[0]);
+ System.out.println("- Using base directory: " + baseDirectory.getAbsolutePath());
+
+ // If the maven-wrapper.properties exists, read it and check if it contains a custom
+ // wrapperUrl parameter.
+ File mavenWrapperPropertyFile = new File(baseDirectory, MAVEN_WRAPPER_PROPERTIES_PATH);
+ String url = DEFAULT_DOWNLOAD_URL;
+ if(mavenWrapperPropertyFile.exists()) {
+ FileInputStream mavenWrapperPropertyFileInputStream = null;
+ try {
+ mavenWrapperPropertyFileInputStream = new FileInputStream(mavenWrapperPropertyFile);
+ Properties mavenWrapperProperties = new Properties();
+ mavenWrapperProperties.load(mavenWrapperPropertyFileInputStream);
+ url = mavenWrapperProperties.getProperty(PROPERTY_NAME_WRAPPER_URL, url);
+ } catch (IOException e) {
+ System.out.println("- ERROR loading '" + MAVEN_WRAPPER_PROPERTIES_PATH + "'");
+ } finally {
+ try {
+ if(mavenWrapperPropertyFileInputStream != null) {
+ mavenWrapperPropertyFileInputStream.close();
+ }
+ } catch (IOException e) {
+ // Ignore ...
+ }
+ }
+ }
+ System.out.println("- Downloading from: " + url);
+
+ File outputFile = new File(baseDirectory.getAbsolutePath(), MAVEN_WRAPPER_JAR_PATH);
+ if(!outputFile.getParentFile().exists()) {
+ if(!outputFile.getParentFile().mkdirs()) {
+ System.out.println(
+ "- ERROR creating output directory '" + outputFile.getParentFile().getAbsolutePath() + "'");
+ }
+ }
+ System.out.println("- Downloading to: " + outputFile.getAbsolutePath());
+ try {
+ downloadFileFromURL(url, outputFile);
+ System.out.println("Done");
+ System.exit(0);
+ } catch (Throwable e) {
+ System.out.println("- Error downloading");
+ e.printStackTrace();
+ System.exit(1);
+ }
+ }
+
+ private static void downloadFileFromURL(String urlString, File destination) throws Exception {
+ if (System.getenv("MVNW_USERNAME") != null && System.getenv("MVNW_PASSWORD") != null) {
+ String username = System.getenv("MVNW_USERNAME");
+ char[] password = System.getenv("MVNW_PASSWORD").toCharArray();
+ Authenticator.setDefault(new Authenticator() {
+ @Override
+ protected PasswordAuthentication getPasswordAuthentication() {
+ return new PasswordAuthentication(username, password);
+ }
+ });
+ }
+ URL website = new URL(urlString);
+ ReadableByteChannel rbc;
+ rbc = Channels.newChannel(website.openStream());
+ FileOutputStream fos = new FileOutputStream(destination);
+ fos.getChannel().transferFrom(rbc, 0, Long.MAX_VALUE);
+ fos.close();
+ rbc.close();
+ }
+
+}
diff --git a/.mvn/wrapper/maven-wrapper.properties b/.mvn/wrapper/maven-wrapper.properties
new file mode 100644
index 0000000..346d645
--- /dev/null
+++ b/.mvn/wrapper/maven-wrapper.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.6/apache-maven-3.9.6-bin.zip
+wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
new file mode 100644
index 0000000..533a738
--- /dev/null
+++ b/CONTRIBUTING.md
@@ -0,0 +1,30 @@
+## Getting started
+Here is some information that's good to know when contributing to JavaParser:
+
+- There is some interesting information on the [wiki](https://github.com/javaparser/javaparser/wiki).
+- We work on JavaParser because we like to, not because it earns us money. Please remember that we try to run a professional project in our spare time, on a budget of zero.
+- Be sure to check [the coding guidelines](https://github.com/javaparser/javaparser/wiki/Coding-Guidelines) which are easily used by installing the formatting rules as described there.
+- If you're new and like to casually contribute something, check out the [easy issues](https://github.com/javaparser/javaparser/labels/Easy).
+- If you're new and would like to become a member, start your own project that uses JavaParser.
+We noticed we get the best feedback from those.
+Here are [some fun project ideas](https://github.com/javaparser/javaparser/labels/fun%20project%20idea).
+- If you start working on an issue, please say so with a comment in the issue.
+- If you know how to fix a problem, please fix it and open a pull request instead of opening an issue.
+
+Thanks for helping!
+
+## Contribution Workflow
+
+Our development workflow is based on Pull Request. If you are not familiar with the Pull Requests, we suggest you to checkout the [Github Documentation](https://help.github.com/articles/creating-a-pull-request/) for more information.
+
+1. **Fork** the JavaParser project. If you already have a fork, ensure to fetch the latest commits.
+2. In your forked project, **create a branch** related to the issue you are working on. This is important to ensure that your pull request will not contain unrelated work.
+3. When your work in your branch is done, **push your branch to your forked repository**.
+4. Go back to the [javaparser project site](https://github.com/javaparser/javaparser) and it should have a message offering to **create a pull request**. If it doesn't you can [create one manually](https://github.com/javaparser/javaparser/compare).
+
+### Remember:
+- A pull request should include tests. You can either use BDD or JUnit.
+- Every pull request will automatically be checked by a few tools. Make sure AppVeyor and Travis are green.
+- Pull requests often stay open for at least a few days to give people a chance to review it.
+- A pull request is merged when all comments on it have been resolved.
+- If you create a pull request for an issue, mention the issue in the format #123 to make github link it automatically.
diff --git a/FEATURES.md b/FEATURES.md
new file mode 100644
index 0000000..4755a33
--- /dev/null
+++ b/FEATURES.md
@@ -0,0 +1,309 @@
+
+# Features
+This page describes the changes introduced within each version.
+
+Language-related changes should normally have a validator, used in conjunction with the grammar, as part of the parsing process.
+
+Where a change is not a language-related change _(e.g. JVM and garbage collection changes)_, this is marked as "Not Applicable (NA)".
+
+## JDK 1.0 - January 1996
+Source: https://en.wikipedia.org/wiki/Java_version_history#JDK_1.0
+## JDK 1.1 - February 1997
+Source: https://en.wikipedia.org/wiki/Java_version_history#JDK_1.1
+## JDK 1.2 - December 1998
+Source: https://en.wikipedia.org/wiki/Java_version_history#J2SE_1.2
+## JDK 1.3 - May 2000
+Source: https://en.wikipedia.org/wiki/Java_version_history#J2SE_1.3
+## JDK 1.4 - February 2002
+Source: https://en.wikipedia.org/wiki/Java_version_history#J2SE_1.4
+## JDK 5 - September 2004
+Source: https://en.wikipedia.org/wiki/Java_version_history#J2SE_5.0
+## JDK 6 - December 2006
+Source: https://en.wikipedia.org/wiki/Java_version_history#Java_SE_6
+
+## JDK 7 - July 2011
+Source: https://en.wikipedia.org/wiki/Java_version_history#Java_SE_7
+
+
+## JDK 8 - March 2014
+Source: https://en.wikipedia.org/wiki/Java_version_history#Java_SE_8
+
+- JSR 335, JEP 126: Language-level support for lambda expressions (officially, lambda expressions; unofficially, closures) under Project Lambda and default methods (virtual extension methods) which allow the addition of methods to interfaces without breaking existing implementations. There was an ongoing debate in the Java community on whether to add support for lambda expressions. Sun later declared that lambda expressions would be included in Java and asked for community input to refine the feature. Supporting lambda expressions also enables functional-style operations on streams of elements, such as MapReduce-inspired transformations on collections. Default methods allow an author of an API to add new methods to an interface without breaking the old code using it. Although it was not their primary intent, default methods also allow multiple inheritance of behavior (but not state).
+- JSR 223, JEP 174: Project Nashorn, a JavaScript runtime which allows developers to embed JavaScript code within applications
+- JSR 308, JEP 104: Annotation on Java types, Unsigned integer arithmetic
+- JSR 337, JEP 120: Repeating annotations
+- JSR 310, JEP 150: Date and time API
+- JEP 178: Statically-linked JNI libraries
+- JEP 153: Launch JavaFX applications (direct launching of JavaFX application JARs)
+- JEP 122: Remove the permanent generation
+
+## JDK 9 - September 2017
+Source: https://en.wikipedia.org/wiki/Java_version_history#Java_SE_9
+
+- JSR 376: Modularization of the JDK under Project Jigsaw (Java Platform Module System)
+- JEP 222: JShell: The Java Shell (a Java REPL)
+- JEP 295: Ahead-of-time compilation
+- JEP 268: XML catalogs
+- JEP 266: More concurrency updates. It includes a Java implementation of Reactive Streams, including a new Flow class that included the interfaces previously provided by Reactive Streams
+- JEP 193: Variable handles: define a standard means to invoke the equivalents of various java.util.concurrent.atomic and sun.misc.Unsafe operations
+- JEP 282: jlink: The Java Linker: create a tool that can assemble and optimize a set of modules and their dependencies into a custom run-time image. It effectively allows to produce a fully usable executable including the JVM to run it. JavaDB was removed from JDK
+- JEP 263: HiDPI graphics: automatic scaling and sizing
+- JEP 254: Compact Strings
+- JEP 213: Milling Project Coin
+
+## JDK 10 - March 2018
+Source: https://openjdk.java.net/projects/jdk/10/
+
+Java 10 support [complete on 25/Feb/2018](https://github.com/javaparser/javaparser/blob/master/changelog.md#version-3515)
+
+| JEP | Status | JavaParser Since | Description |
+|:--------------------------------------------:|:----------------:|:---------------------------------------------------------------:|---------------------------------------------------------|
+| [JEP 286](https://openjdk.java.net/jeps/286) | **Release** | **Supported Since: v3.5.15 Released on: 25/Feb/2018** | **Local-Variable Type Inference** |
+| [JEP 296](https://openjdk.java.net/jeps/296) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Consolidate the JDK Forest into a Single Repository~~ |
+| [JEP 304](https://openjdk.java.net/jeps/304) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Garbage-Collector Interface~~ |
+| [JEP 307](https://openjdk.java.net/jeps/307) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Parallel Full GC for G1~~ |
+| [JEP 310](https://openjdk.java.net/jeps/310) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Application Class-Data Sharing~~ |
+| [JEP 312](https://openjdk.java.net/jeps/312) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Thread-Local Handshakes~~ |
+| [JEP 313](https://openjdk.java.net/jeps/313) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Remove the Native-Header Generation Tool (javah)~~ |
+| [JEP 314](https://openjdk.java.net/jeps/314) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Additional Unicode Language-Tag Extensions~~ |
+| [JEP 316](https://openjdk.java.net/jeps/316) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Heap Allocation on Alternative Memory Devices~~ |
+| [JEP 317](https://openjdk.java.net/jeps/317) | ~~Experimental~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Experimental Java-Based JIT Compiler~~ |
+| [JEP 319](https://openjdk.java.net/jeps/319) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Root Certificates~~ |
+| [JEP 322](https://openjdk.java.net/jeps/322) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Time-Based Release Versioning~~ |
+
+## JDK 11 - September 2018
+Source: https://openjdk.java.net/projects/jdk/11/
+
+Java 11 support [complete on 19/Aug/2018](https://github.com/javaparser/javaparser/blob/master/changelog.md#version-3618)
+
+| JEP | Status | JavaParser Since | Description |
+|:--------------------------------------------:|:----------------:|:----------------------------------------------------------------------------------------------------:|------------------------------------------------------------------|
+| [JEP 323](https://openjdk.java.net/jeps/323) | **Release** | **Supported Since: v3.xx.yy Released on: dd/mmm/yyyy** | **Local-Variable Syntax for Lambda Parameters** |
+| [JEP 327](https://openjdk.java.net/jeps/327) | _Release_ | _Discussion Needed [JEP327](#f_11_JEP327)_ | _Unicode 10_ |
+| [JEP 181](https://openjdk.java.net/jeps/181) | _Release_ | _Discussion Needed [JEP181](#f_11_JEP181)_ | _Nest-Based Access Control_ |
+| [JEP 309](https://openjdk.java.net/jeps/309) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Dynamic Class-File Constants~~ |
+| [JEP 315](https://openjdk.java.net/jeps/315) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Improve Aarch64 Intrinsics~~ |
+| [JEP 318](https://openjdk.java.net/jeps/318) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Epsilon: A No-Op Garbage Collector~~ |
+| [JEP 320](https://openjdk.java.net/jeps/320) | ~~_Release_~~ | ~~_Not Applicable - Not a language change (NA) [JEP320](#f_11_JEP320)_~~ | ~~Remove the Java EE and CORBA Modules~~ |
+| [JEP 321](https://openjdk.java.net/jeps/321) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~HTTP Client (Standard)~~ |
+| [JEP 324](https://openjdk.java.net/jeps/324) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Key Agreement with Curve25519 and Curve448~~ |
+| [JEP 328](https://openjdk.java.net/jeps/328) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Flight Recorder~~ |
+| [JEP 329](https://openjdk.java.net/jeps/329) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~ChaCha20 and Poly1305 Cryptographic Algorithms~~ |
+| [JEP 330](https://openjdk.java.net/jeps/330) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Launch Single-File Source-Code Programs~~ |
+| [JEP 331](https://openjdk.java.net/jeps/331) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Low-Overhead Heap Profiling~~ |
+| [JEP 332](https://openjdk.java.net/jeps/332) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Transport Layer Security (TLS) 1.3~~ |
+| [JEP 333](https://openjdk.java.net/jeps/333) | ~~Experimental~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~ZGC: A Scalable Low-Latency Garbage Collector (Experimental)~~ |
+| [JEP 335](https://openjdk.java.net/jeps/335) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Deprecate the Nashorn JavaScript Engine~~ |
+| [JEP 336](https://openjdk.java.net/jeps/336) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Deprecate the Pack200 Tools and API~~ |
+
+##### Footnotes:
+
+- JEP181 - Based on a cursory reading of this JEP, it is unclear if this is a change that affects JavaParser.
+ Comments/discussion on this are welcomed. [↩](#a_11_JEP181)
+- JEP327 - Based on a cursory reading of this JEP, it is unclear if this is a change that affects JavaParser.
+ Comments/discussion on this are welcomed. [↩](#a_11_JEP327)
+- JEP320 - JEP 320 is marked as NA. This is because JavaParser does not make use of classes within these packages,
+ and any users of JavaParser will need to provide the relevant files in order to do parsing/solving
+ (e.g. as source files, a jar, or via reflection). [↩](#a_11_JEP320)
+
+
+## JDK 12 - March 2019
+Source: https://openjdk.java.net/projects/jdk/12/
+
+Parsing support for Java 12 (including preview features) [complete on 03/Feb/2019](https://github.com/javaparser/javaparser/blob/master/changelog.md#version-3110)
+
+Resolution support for Java 12 complete on ??/??/2019
+
+| JEP | Status | JavaParser Since | Description |
+|:--------------------------------------------:|:----------------:|:---------------------------------------------------------------:|-------------------------------------------------------------------|
+| [JEP 325](https://openjdk.java.net/jeps/325) | **_Preview_** | **Supported Since: v3.11.0 Released on: 03/Feb/2019** | Switch Expressions (Preview) |
+| [JEP 189](https://openjdk.java.net/jeps/189) | ~~Experimental~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Shenandoah: A Low-Pause-Time Garbage Collector (Experimental)~~ |
+| [JEP 230](https://openjdk.java.net/jeps/230) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Microbenchmark Suite~~ |
+| [JEP 334](https://openjdk.java.net/jeps/334) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~JVM Constants API~~ |
+| [JEP 340](https://openjdk.java.net/jeps/340) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~One AArch64 Port, Not Two~~ |
+| [JEP 341](https://openjdk.java.net/jeps/341) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Default CDS Archives~~ |
+| [JEP 344](https://openjdk.java.net/jeps/344) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Abortable Mixed Collections for G1~~ |
+| [JEP 346](https://openjdk.java.net/jeps/346) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Promptly Return Unused Committed Memory from G1~~ |
+
+## JDK 13 - September 2018
+Source: https://openjdk.java.net/projects/jdk/13/
+
+No language specification changes in JDK 13 -- thus no "complete" date. Details of preview support is below.
+
+| JEP | Status | JavaParser Since | Description |
+|:--------------------------------------------:|:-------------:|:---------------------------------------------------------------:|---------------------------------------|
+| [JEP 354](https://openjdk.java.net/jeps/354) | **_Preview_** | **Supported Since: v3.11.0 Released on: 03/Feb/2019** | Switch Expressions (Preview) |
+| [JEP 355](https://openjdk.java.net/jeps/355) | **_Preview_** | **Supported Since: v3.14.0 Released on: 05/May/2019** | Text Blocks (Preview) |
+| [JEP 350](https://openjdk.java.net/jeps/350) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Dynamic CDS Archives~~ |
+| [JEP 351](https://openjdk.java.net/jeps/351) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~ZGC: Uncommit Unused Memory~~ |
+| [JEP 353](https://openjdk.java.net/jeps/353) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Reimplement the Legacy Socket API~~ |
+
+
+
+## JDK 14 - March 2020
+Source: https://openjdk.java.net/projects/jdk/14/
+
+Switch support was complete during preview status.
+
+The preview features of records are work-in-progress.
+
+| JEP | Status | JavaParser Since | Description |
+|:--------------------------------------------:|:---------------:|:-----------------------------------------------------------------------------------------------------------------:|---------------------------------------------------------------|
+| [JEP 361](https://openjdk.java.net/jeps/361) | **Release** | **Supported Since: v3.xx.yy Released on: dd/mmm/yyyy** | **Switch Expressions (Standard)** |
+| [JEP 368](https://openjdk.java.net/jeps/368) | **2nd Preview** | **Supported Since: v3.14.0 Released on: 05/May/2019** | **Text Blocks (Second Preview)** |
+| [JEP 305](https://openjdk.java.net/jeps/305) | **_Preview_** | **Supported Since: v3.18.0 Released on: 01/Dec/2020** | **Pattern Matching for `instanceof` (Preview)** |
+| [JEP 359](https://openjdk.java.net/jeps/359) | **_Preview_** | **Partial Support Since: v3.22.0 Released on: 11/May/2021 [JEP343](#f_14_JEP359)** | **Records (Preview)** |
+| [JEP 343](https://openjdk.java.net/jeps/343) | ~~_Incubator_~~ | ~~_Not Applicable (NA)[JEP343](#f_14_JEP343)_~~ | ~~Packaging Tool (Incubator)~~ |
+| [JEP 345](https://openjdk.java.net/jeps/345) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~NUMA-Aware Memory Allocation for G1~~ |
+| [JEP 349](https://openjdk.java.net/jeps/349) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~JFR Event Streaming~~ |
+| [JEP 352](https://openjdk.java.net/jeps/352) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Non-Volatile Mapped Byte Buffers~~ |
+| [JEP 358](https://openjdk.java.net/jeps/358) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Helpful NullPointerExceptions~~ |
+| [JEP 362](https://openjdk.java.net/jeps/362) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Deprecate the Solaris and SPARC Ports~~ |
+| [JEP 363](https://openjdk.java.net/jeps/363) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Remove the Concurrent Mark Sweep (CMS) Garbage Collector~~ |
+| [JEP 364](https://openjdk.java.net/jeps/364) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~ZGC on macOS~~ |
+| [JEP 365](https://openjdk.java.net/jeps/365) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~ZGC on Windows~~ |
+| [JEP 366](https://openjdk.java.net/jeps/366) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Deprecate the ParallelScavenge + SerialOld GC Combination~~ |
+| [JEP 367](https://openjdk.java.net/jeps/367) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Remove the Pack200 Tools and API~~ |
+| [JEP 370](https://openjdk.java.net/jeps/370) | ~~_Release_~~ | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Foreign-Memory Access API (Incubator)~~ |
+
+##### Footnotes:
+
+- JEP343 - JEP 343 is marked as not applicable, as it relates to packaging of apps - e.g. as `.exe`/`.msi`/`.deb`/`.rpm`/`.pkg`/`.dmg`.
+ The JEP describes the layout/structure of the output file, suggesting that _maybe_ in the future the files may be examined, and _potentially_ used similarly to a `.jar` or set of `.class` files.
+ This is not going to be actively pursued (_especially_ since this is still in the incubator stage), though tested PRs are always welcome.
+ [↩](#a_14_JEP343)
+
+
+- JEP359 - The behaviour of records changed between preview/2nd preview/release.
+ Unless otherwise stated, the JavaParser implementation follows the released behaviour.
+ Additionally, note that "partial" support refers to javaparser-core being complete since 3.21.0, and javaparser-symbol-solver-core support is TBC.
+ [↩](#a_14_JEP359)
+
+
+
+## JDK 15 - September 2020
+Source: https://openjdk.java.net/projects/jdk/15/
+
+Note: Unless otherwise stated, the JavaParser implementations of features follows the released behaviour.
+
+| JEP | Status | JavaParser Since | Description |
+|:--------------------------------------------:|:---------------:|:-----------------------------------------------------------------------------------------------------------------:|--------------------------------------------------------|
+| [JEP 378](https://openjdk.java.net/jeps/378) | **_Release_** | **Supported Since: v3.14.0 Released on: 05/May/2019** | **Text Blocks** |
+| [JEP 384](https://openjdk.java.net/jeps/384) | **_Release_** | **Partial Support Since: v3.22.0 Released on: 11/May/2021 [JEP384](#f_15_JEP384)** | **Records (Second Preview)** |
+| [JEP 375](https://openjdk.java.net/jeps/375) | **_Release_** | **Supported Since: v3.18.0 Released on: 01/Dec/2020** | **Pattern Matching for `instanceof` (Second Preview)** |
+| [JEP 360](https://openjdk.java.net/jeps/360) | **_Preview_** | | **Sealed Classes (Preview)** |
+| [JEP 339](https://openjdk.java.net/jeps/339) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Edwards-Curve Digital Signature Algorithm (EdDSA)~~ |
+| [JEP 371](https://openjdk.java.net/jeps/371) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Hidden Classes~~ |
+| [JEP 372](https://openjdk.java.net/jeps/372) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Remove the Nashorn JavaScript Engine~~ |
+| [JEP 373](https://openjdk.java.net/jeps/373) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Reimplement the Legacy DatagramSocket API~~ |
+| [JEP 374](https://openjdk.java.net/jeps/374) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Disable and Deprecate Biased Locking~~ |
+| [JEP 377](https://openjdk.java.net/jeps/377) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~ZGC: A Scalable Low-Latency Garbage Collector~~ |
+| [JEP 379](https://openjdk.java.net/jeps/379) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Shenandoah: A Low-Pause-Time Garbage Collector~~ |
+| [JEP 381](https://openjdk.java.net/jeps/381) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Remove the Solaris and SPARC Ports~~ |
+| [JEP 383](https://openjdk.java.net/jeps/383) | **_Incubator_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Foreign-Memory Access API (Second Incubator)~~ |
+| [JEP 385](https://openjdk.java.net/jeps/385) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Deprecate RMI Activation for Removal~~ |
+
+- JEP384 - The behaviour of records changed between preview/2nd preview/release.
+ Unless otherwise stated, the JavaParser implementation follows the released behaviour.
+ Additionally, note that "partial" support refers to javaparser-core being complete since 3.21.0, and javaparser-symbol-solver-core support is TBC.
+ [↩](#a_15_JEP384)
+
+
+
+## JDK 16 - March 2021
+Source: https://openjdk.java.net/projects/jdk/16/
+
+Note: Unless otherwise stated, the JavaParser implementations of features follows the released behaviour.
+
+| JEP | Status | JavaParser Since | Description |
+|:--------------------------------------------:|:---------------:|:------------------------------------------------------------------------------------------------------------------------------:|---------------------------------------------------|
+| [JEP 395](https://openjdk.java.net/jeps/395) | **_Release_** | **Parser Support Since: v3.22.0 Released on: 11/May/2021, Solving TBC [JEP395](#f_16_JEP395)** | **Records** |
+| [JEP 394](https://openjdk.java.net/jeps/394) | **_Release_** | **Supported Since: v3.18.0 Released on: 01/Dec/2020** | **Pattern Matching for `instanceof`** |
+| [JEP 397](https://openjdk.java.net/jeps/397) | **2nd Preview** | | **Sealed Classes (Second Preview)** |
+| [JEP 338](https://openjdk.java.net/jeps/338) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Vector API (Incubator)~~ |
+| [JEP 347](https://openjdk.java.net/jeps/347) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Enable C++14 Language Features~~ |
+| [JEP 357](https://openjdk.java.net/jeps/357) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Migrate from Mercurial to Git~~ |
+| [JEP 369](https://openjdk.java.net/jeps/369) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Migrate to GitHub~~ |
+| [JEP 376](https://openjdk.java.net/jeps/376) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~ZGC: Concurrent Thread-Stack Processing~~ |
+| [JEP 380](https://openjdk.java.net/jeps/380) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Unix-Domain Socket Channels~~ |
+| [JEP 386](https://openjdk.java.net/jeps/386) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Alpine Linux Port~~ |
+| [JEP 387](https://openjdk.java.net/jeps/387) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Elastic Metaspace~~ |
+| [JEP 388](https://openjdk.java.net/jeps/388) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Windows/AArch64 Port~~ |
+| [JEP 389](https://openjdk.java.net/jeps/389) | **_Incubator_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Foreign Linker API (Incubator)~~ |
+| [JEP 390](https://openjdk.java.net/jeps/390) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Warnings for Value-Based Classes~~ |
+| [JEP 392](https://openjdk.java.net/jeps/392) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Packaging Tool~~ |
+| [JEP 393](https://openjdk.java.net/jeps/393) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Foreign-Memory Access API (Third Incubator)~~ |
+| [JEP 396](https://openjdk.java.net/jeps/396) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | ~~Strongly Encapsulate JDK Internals by Default~~ |
+
+- JEP395 - The behaviour of records changed between preview/2nd preview/release.
+ Unless otherwise stated, the JavaParser implementation follows the released behaviour.
+ Additionally, note that "partial" support refers to javaparser-core being complete since 3.21.0, and javaparser-symbol-solver-core support is TBC.
+ [↩](#a_16_JEP395)
+
+
+## JDK 17 - September 2021
+Source: https://openjdk.java.net/projects/jdk/17/
+
+Note: Unless otherwise stated, the JavaParser implementations of features follows the released behaviour.
+
+| JEP | Status | JavaParser Since | Description |
+|:--------------------------------------------:|:-------------------:|:---------------------------------------------------------------:|------------------------------------------------|
+| [JEP 306](https://openjdk.java.net/jeps/306) | **_Release_** | | Restore Always-Strict Floating-Point Semantics |
+| [JEP 409](https://openjdk.java.net/jeps/409) | **_Release_** | | Sealed Classes |
+| [JEP 406](https://openjdk.java.net/jeps/406) | **_Preview_** | | Pattern Matching for `switch` (Preview) |
+| [JEP 356](https://openjdk.java.net/jeps/356) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Enhanced Pseudo-Random Number Generators |
+| [JEP 382](https://openjdk.java.net/jeps/382) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | New macOS Rendering Pipeline |
+| [JEP 391](https://openjdk.java.net/jeps/391) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | macOS/AArch64 Port |
+| [JEP 398](https://openjdk.java.net/jeps/398) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Deprecate the Applet API for Removal |
+| [JEP 403](https://openjdk.java.net/jeps/403) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Strongly Encapsulate JDK Internals |
+| [JEP 407](https://openjdk.java.net/jeps/407) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Remove RMI Activation |
+| [JEP 410](https://openjdk.java.net/jeps/410) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Remove the Experimental AOT and JIT Compiler |
+| [JEP 411](https://openjdk.java.net/jeps/411) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Deprecate the Security Manager for Removal |
+| [JEP 412](https://openjdk.java.net/jeps/412) | **_Incubator_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Foreign Function & Memory API (Incubator) |
+| [JEP 414](https://openjdk.java.net/jeps/414) | **_2nd Incubator_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Vector API (Second Incubator) |
+| [JEP 415](https://openjdk.java.net/jeps/415) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Context-Specific Deserialization Filters |
+
+
+
+## JDK 18 - March 2022
+Source: https://openjdk.java.net/projects/jdk/18/
+
+Note: Unless otherwise stated, the JavaParser implementations of features follows the released behaviour.
+
+### Schedule
+
+ 2021/12/09 Rampdown Phase One (fork from main line)
+ 2022/01/20 Rampdown Phase Two
+ 2022/02/10 Initial Release Candidate
+ 2022/02/24 Final Release Candidate
+ 2022/03/22 General Availability
+
+
+### Features
+
+| JEP | Status | JavaParser Since | Description |
+|:--------------------------------------------:|:-------------------:|:---------------------------------------------------------------:|--------------------------------------------------|
+| [JEP 413](https://openjdk.java.net/jeps/413) | **_Release_** | | Code Snippets in Java API Documentation |
+| [JEP 420](https://openjdk.java.net/jeps/420) | **_Preview_** | | Pattern Matching for `switch` (Second Preview) |
+| [JEP 400](https://openjdk.java.net/jeps/400) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | UTF-8 by Default |
+| [JEP 408](https://openjdk.java.net/jeps/408) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Simple Web Server |
+| [JEP 416](https://openjdk.java.net/jeps/416) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Reimplement Core Reflection with Method Handles |
+| [JEP 417](https://openjdk.java.net/jeps/417) | **_3rd Incubator_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Vector API (Third Incubator) |
+| [JEP 418](https://openjdk.java.net/jeps/418) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Internet-Address Resolution SPI |
+| [JEP 419](https://openjdk.java.net/jeps/419) | **_2nd Incubator_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Foreign Function & Memory API (Second Incubator) |
+| [JEP 421](https://openjdk.java.net/jeps/421) | **_Release_** | ~~_Not Applicable - Not a language specification change (NA)_~~ | Deprecate Finalization for Removal |
+
+
+
+## JDK 19 - _targeted for September 2022_
+Source: https://openjdk.java.net/projects/jdk/18/
+
+Note: Unless otherwise stated, the JavaParser implementations of features follows the released behaviour.
+
+### Features
+
+ JEPs targeted to JDK 19, so far
+ 422: Linux/RISC-V Port
+
+ Last update: 2022/3/18 16:38 UTC
+
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 0000000..012ddda
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,6 @@
+JavaParser is available either under the terms of the LGPL License or the Apache License. You as the user are entitled to choose the terms under which to adopt JavaParser.
+
+For details about the LGPL License please refer to LICENSE.LGPL. Please note
+that LGPL is just an extension to GPL, located in LICENSE.GPL.
+
+For details about the Apache License please refer to LICENSE.APACHE
diff --git a/LICENSE.APACHE b/LICENSE.APACHE
new file mode 100644
index 0000000..d645695
--- /dev/null
+++ b/LICENSE.APACHE
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/LICENSE.GPL b/LICENSE.GPL
new file mode 100644
index 0000000..fb1a1b0
--- /dev/null
+++ b/LICENSE.GPL
@@ -0,0 +1,674 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 3, 29 June 2007
+
+ Copyright (C) 2007 Free Software Foundation, Inc.
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The GNU General Public License is a free, copyleft license for
+software and other kinds of works.
+
+ The licenses for most software and other practical works are designed
+to take away your freedom to share and change the works. By contrast,
+the GNU General Public License is intended to guarantee your freedom to
+share and change all versions of a program--to make sure it remains free
+software for all its users. We, the Free Software Foundation, use the
+GNU General Public License for most of our software; it applies also to
+any other work released this way by its authors. You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+them if you wish), that you receive source code or can get it if you
+want it, that you can change the software or use pieces of it in new
+free programs, and that you know you can do these things.
+
+ To protect your rights, we need to prevent others from denying you
+these rights or asking you to surrender the rights. Therefore, you have
+certain responsibilities if you distribute copies of the software, or if
+you modify it: responsibilities to respect the freedom of others.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must pass on to the recipients the same
+freedoms that you received. You must make sure that they, too, receive
+or can get the source code. And you must show them these terms so they
+know their rights.
+
+ Developers that use the GNU GPL protect your rights with two steps:
+(1) assert copyright on the software, and (2) offer you this License
+giving you legal permission to copy, distribute and/or modify it.
+
+ For the developers' and authors' protection, the GPL clearly explains
+that there is no warranty for this free software. For both users' and
+authors' sake, the GPL requires that modified versions be marked as
+changed, so that their problems will not be attributed erroneously to
+authors of previous versions.
+
+ Some devices are designed to deny users access to install or run
+modified versions of the software inside them, although the manufacturer
+can do so. This is fundamentally incompatible with the aim of
+protecting users' freedom to change the software. The systematic
+pattern of such abuse occurs in the area of products for individuals to
+use, which is precisely where it is most unacceptable. Therefore, we
+have designed this version of the GPL to prohibit the practice for those
+products. If such problems arise substantially in other domains, we
+stand ready to extend this provision to those domains in future versions
+of the GPL, as needed to protect the freedom of users.
+
+ Finally, every program is threatened constantly by software patents.
+States should not allow patents to restrict development and use of
+software on general-purpose computers, but in those that do, we wish to
+avoid the special danger that patents applied to a free program could
+make it effectively proprietary. To prevent this, the GPL assures that
+patents cannot be used to render the program non-free.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ TERMS AND CONDITIONS
+
+ 0. Definitions.
+
+ "This License" refers to version 3 of the GNU General Public License.
+
+ "Copyright" also means copyright-like laws that apply to other kinds of
+works, such as semiconductor masks.
+
+ "The Program" refers to any copyrightable work licensed under this
+License. Each licensee is addressed as "you". "Licensees" and
+"recipients" may be individuals or organizations.
+
+ To "modify" a work means to copy from or adapt all or part of the work
+in a fashion requiring copyright permission, other than the making of an
+exact copy. The resulting work is called a "modified version" of the
+earlier work or a work "based on" the earlier work.
+
+ A "covered work" means either the unmodified Program or a work based
+on the Program.
+
+ To "propagate" a work means to do anything with it that, without
+permission, would make you directly or secondarily liable for
+infringement under applicable copyright law, except executing it on a
+computer or modifying a private copy. Propagation includes copying,
+distribution (with or without modification), making available to the
+public, and in some countries other activities as well.
+
+ To "convey" a work means any kind of propagation that enables other
+parties to make or receive copies. Mere interaction with a user through
+a computer network, with no transfer of a copy, is not conveying.
+
+ An interactive user interface displays "Appropriate Legal Notices"
+to the extent that it includes a convenient and prominently visible
+feature that (1) displays an appropriate copyright notice, and (2)
+tells the user that there is no warranty for the work (except to the
+extent that warranties are provided), that licensees may convey the
+work under this License, and how to view a copy of this License. If
+the interface presents a list of user commands or options, such as a
+menu, a prominent item in the list meets this criterion.
+
+ 1. Source Code.
+
+ The "source code" for a work means the preferred form of the work
+for making modifications to it. "Object code" means any non-source
+form of a work.
+
+ A "Standard Interface" means an interface that either is an official
+standard defined by a recognized standards body, or, in the case of
+interfaces specified for a particular programming language, one that
+is widely used among developers working in that language.
+
+ The "System Libraries" of an executable work include anything, other
+than the work as a whole, that (a) is included in the normal form of
+packaging a Major Component, but which is not part of that Major
+Component, and (b) serves only to enable use of the work with that
+Major Component, or to implement a Standard Interface for which an
+implementation is available to the public in source code form. A
+"Major Component", in this context, means a major essential component
+(kernel, window system, and so on) of the specific operating system
+(if any) on which the executable work runs, or a compiler used to
+produce the work, or an object code interpreter used to run it.
+
+ The "Corresponding Source" for a work in object code form means all
+the source code needed to generate, install, and (for an executable
+work) run the object code and to modify the work, including scripts to
+control those activities. However, it does not include the work's
+System Libraries, or general-purpose tools or generally available free
+programs which are used unmodified in performing those activities but
+which are not part of the work. For example, Corresponding Source
+includes interface definition files associated with source files for
+the work, and the source code for shared libraries and dynamically
+linked subprograms that the work is specifically designed to require,
+such as by intimate data communication or control flow between those
+subprograms and other parts of the work.
+
+ The Corresponding Source need not include anything that users
+can regenerate automatically from other parts of the Corresponding
+Source.
+
+ The Corresponding Source for a work in source code form is that
+same work.
+
+ 2. Basic Permissions.
+
+ All rights granted under this License are granted for the term of
+copyright on the Program, and are irrevocable provided the stated
+conditions are met. This License explicitly affirms your unlimited
+permission to run the unmodified Program. The output from running a
+covered work is covered by this License only if the output, given its
+content, constitutes a covered work. This License acknowledges your
+rights of fair use or other equivalent, as provided by copyright law.
+
+ You may make, run and propagate covered works that you do not
+convey, without conditions so long as your license otherwise remains
+in force. You may convey covered works to others for the sole purpose
+of having them make modifications exclusively for you, or provide you
+with facilities for running those works, provided that you comply with
+the terms of this License in conveying all material for which you do
+not control copyright. Those thus making or running the covered works
+for you must do so exclusively on your behalf, under your direction
+and control, on terms that prohibit them from making any copies of
+your copyrighted material outside their relationship with you.
+
+ Conveying under any other circumstances is permitted solely under
+the conditions stated below. Sublicensing is not allowed; section 10
+makes it unnecessary.
+
+ 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
+
+ No covered work shall be deemed part of an effective technological
+measure under any applicable law fulfilling obligations under article
+11 of the WIPO copyright treaty adopted on 20 December 1996, or
+similar laws prohibiting or restricting circumvention of such
+measures.
+
+ When you convey a covered work, you waive any legal power to forbid
+circumvention of technological measures to the extent such circumvention
+is effected by exercising rights under this License with respect to
+the covered work, and you disclaim any intention to limit operation or
+modification of the work as a means of enforcing, against the work's
+users, your or third parties' legal rights to forbid circumvention of
+technological measures.
+
+ 4. Conveying Verbatim Copies.
+
+ You may convey verbatim copies of the Program's source code as you
+receive it, in any medium, provided that you conspicuously and
+appropriately publish on each copy an appropriate copyright notice;
+keep intact all notices stating that this License and any
+non-permissive terms added in accord with section 7 apply to the code;
+keep intact all notices of the absence of any warranty; and give all
+recipients a copy of this License along with the Program.
+
+ You may charge any price or no price for each copy that you convey,
+and you may offer support or warranty protection for a fee.
+
+ 5. Conveying Modified Source Versions.
+
+ You may convey a work based on the Program, or the modifications to
+produce it from the Program, in the form of source code under the
+terms of section 4, provided that you also meet all of these conditions:
+
+ a) The work must carry prominent notices stating that you modified
+ it, and giving a relevant date.
+
+ b) The work must carry prominent notices stating that it is
+ released under this License and any conditions added under section
+ 7. This requirement modifies the requirement in section 4 to
+ "keep intact all notices".
+
+ c) You must license the entire work, as a whole, under this
+ License to anyone who comes into possession of a copy. This
+ License will therefore apply, along with any applicable section 7
+ additional terms, to the whole of the work, and all its parts,
+ regardless of how they are packaged. This License gives no
+ permission to license the work in any other way, but it does not
+ invalidate such permission if you have separately received it.
+
+ d) If the work has interactive user interfaces, each must display
+ Appropriate Legal Notices; however, if the Program has interactive
+ interfaces that do not display Appropriate Legal Notices, your
+ work need not make them do so.
+
+ A compilation of a covered work with other separate and independent
+works, which are not by their nature extensions of the covered work,
+and which are not combined with it such as to form a larger program,
+in or on a volume of a storage or distribution medium, is called an
+"aggregate" if the compilation and its resulting copyright are not
+used to limit the access or legal rights of the compilation's users
+beyond what the individual works permit. Inclusion of a covered work
+in an aggregate does not cause this License to apply to the other
+parts of the aggregate.
+
+ 6. Conveying Non-Source Forms.
+
+ You may convey a covered work in object code form under the terms
+of sections 4 and 5, provided that you also convey the
+machine-readable Corresponding Source under the terms of this License,
+in one of these ways:
+
+ a) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by the
+ Corresponding Source fixed on a durable physical medium
+ customarily used for software interchange.
+
+ b) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by a
+ written offer, valid for at least three years and valid for as
+ long as you offer spare parts or customer support for that product
+ model, to give anyone who possesses the object code either (1) a
+ copy of the Corresponding Source for all the software in the
+ product that is covered by this License, on a durable physical
+ medium customarily used for software interchange, for a price no
+ more than your reasonable cost of physically performing this
+ conveying of source, or (2) access to copy the
+ Corresponding Source from a network server at no charge.
+
+ c) Convey individual copies of the object code with a copy of the
+ written offer to provide the Corresponding Source. This
+ alternative is allowed only occasionally and noncommercially, and
+ only if you received the object code with such an offer, in accord
+ with subsection 6b.
+
+ d) Convey the object code by offering access from a designated
+ place (gratis or for a charge), and offer equivalent access to the
+ Corresponding Source in the same way through the same place at no
+ further charge. You need not require recipients to copy the
+ Corresponding Source along with the object code. If the place to
+ copy the object code is a network server, the Corresponding Source
+ may be on a different server (operated by you or a third party)
+ that supports equivalent copying facilities, provided you maintain
+ clear directions next to the object code saying where to find the
+ Corresponding Source. Regardless of what server hosts the
+ Corresponding Source, you remain obligated to ensure that it is
+ available for as long as needed to satisfy these requirements.
+
+ e) Convey the object code using peer-to-peer transmission, provided
+ you inform other peers where the object code and Corresponding
+ Source of the work are being offered to the general public at no
+ charge under subsection 6d.
+
+ A separable portion of the object code, whose source code is excluded
+from the Corresponding Source as a System Library, need not be
+included in conveying the object code work.
+
+ A "User Product" is either (1) a "consumer product", which means any
+tangible personal property which is normally used for personal, family,
+or household purposes, or (2) anything designed or sold for incorporation
+into a dwelling. In determining whether a product is a consumer product,
+doubtful cases shall be resolved in favor of coverage. For a particular
+product received by a particular user, "normally used" refers to a
+typical or common use of that class of product, regardless of the status
+of the particular user or of the way in which the particular user
+actually uses, or expects or is expected to use, the product. A product
+is a consumer product regardless of whether the product has substantial
+commercial, industrial or non-consumer uses, unless such uses represent
+the only significant mode of use of the product.
+
+ "Installation Information" for a User Product means any methods,
+procedures, authorization keys, or other information required to install
+and execute modified versions of a covered work in that User Product from
+a modified version of its Corresponding Source. The information must
+suffice to ensure that the continued functioning of the modified object
+code is in no case prevented or interfered with solely because
+modification has been made.
+
+ If you convey an object code work under this section in, or with, or
+specifically for use in, a User Product, and the conveying occurs as
+part of a transaction in which the right of possession and use of the
+User Product is transferred to the recipient in perpetuity or for a
+fixed term (regardless of how the transaction is characterized), the
+Corresponding Source conveyed under this section must be accompanied
+by the Installation Information. But this requirement does not apply
+if neither you nor any third party retains the ability to install
+modified object code on the User Product (for example, the work has
+been installed in ROM).
+
+ The requirement to provide Installation Information does not include a
+requirement to continue to provide support service, warranty, or updates
+for a work that has been modified or installed by the recipient, or for
+the User Product in which it has been modified or installed. Access to a
+network may be denied when the modification itself materially and
+adversely affects the operation of the network or violates the rules and
+protocols for communication across the network.
+
+ Corresponding Source conveyed, and Installation Information provided,
+in accord with this section must be in a format that is publicly
+documented (and with an implementation available to the public in
+source code form), and must require no special password or key for
+unpacking, reading or copying.
+
+ 7. Additional Terms.
+
+ "Additional permissions" are terms that supplement the terms of this
+License by making exceptions from one or more of its conditions.
+Additional permissions that are applicable to the entire Program shall
+be treated as though they were included in this License, to the extent
+that they are valid under applicable law. If additional permissions
+apply only to part of the Program, that part may be used separately
+under those permissions, but the entire Program remains governed by
+this License without regard to the additional permissions.
+
+ When you convey a copy of a covered work, you may at your option
+remove any additional permissions from that copy, or from any part of
+it. (Additional permissions may be written to require their own
+removal in certain cases when you modify the work.) You may place
+additional permissions on material, added by you to a covered work,
+for which you have or can give appropriate copyright permission.
+
+ Notwithstanding any other provision of this License, for material you
+add to a covered work, you may (if authorized by the copyright holders of
+that material) supplement the terms of this License with terms:
+
+ a) Disclaiming warranty or limiting liability differently from the
+ terms of sections 15 and 16 of this License; or
+
+ b) Requiring preservation of specified reasonable legal notices or
+ author attributions in that material or in the Appropriate Legal
+ Notices displayed by works containing it; or
+
+ c) Prohibiting misrepresentation of the origin of that material, or
+ requiring that modified versions of such material be marked in
+ reasonable ways as different from the original version; or
+
+ d) Limiting the use for publicity purposes of names of licensors or
+ authors of the material; or
+
+ e) Declining to grant rights under trademark law for use of some
+ trade names, trademarks, or service marks; or
+
+ f) Requiring indemnification of licensors and authors of that
+ material by anyone who conveys the material (or modified versions of
+ it) with contractual assumptions of liability to the recipient, for
+ any liability that these contractual assumptions directly impose on
+ those licensors and authors.
+
+ All other non-permissive additional terms are considered "further
+restrictions" within the meaning of section 10. If the Program as you
+received it, or any part of it, contains a notice stating that it is
+governed by this License along with a term that is a further
+restriction, you may remove that term. If a license document contains
+a further restriction but permits relicensing or conveying under this
+License, you may add to a covered work material governed by the terms
+of that license document, provided that the further restriction does
+not survive such relicensing or conveying.
+
+ If you add terms to a covered work in accord with this section, you
+must place, in the relevant source files, a statement of the
+additional terms that apply to those files, or a notice indicating
+where to find the applicable terms.
+
+ Additional terms, permissive or non-permissive, may be stated in the
+form of a separately written license, or stated as exceptions;
+the above requirements apply either way.
+
+ 8. Termination.
+
+ You may not propagate or modify a covered work except as expressly
+provided under this License. Any attempt otherwise to propagate or
+modify it is void, and will automatically terminate your rights under
+this License (including any patent licenses granted under the third
+paragraph of section 11).
+
+ However, if you cease all violation of this License, then your
+license from a particular copyright holder is reinstated (a)
+provisionally, unless and until the copyright holder explicitly and
+finally terminates your license, and (b) permanently, if the copyright
+holder fails to notify you of the violation by some reasonable means
+prior to 60 days after the cessation.
+
+ Moreover, your license from a particular copyright holder is
+reinstated permanently if the copyright holder notifies you of the
+violation by some reasonable means, this is the first time you have
+received notice of violation of this License (for any work) from that
+copyright holder, and you cure the violation prior to 30 days after
+your receipt of the notice.
+
+ Termination of your rights under this section does not terminate the
+licenses of parties who have received copies or rights from you under
+this License. If your rights have been terminated and not permanently
+reinstated, you do not qualify to receive new licenses for the same
+material under section 10.
+
+ 9. Acceptance Not Required for Having Copies.
+
+ You are not required to accept this License in order to receive or
+run a copy of the Program. Ancillary propagation of a covered work
+occurring solely as a consequence of using peer-to-peer transmission
+to receive a copy likewise does not require acceptance. However,
+nothing other than this License grants you permission to propagate or
+modify any covered work. These actions infringe copyright if you do
+not accept this License. Therefore, by modifying or propagating a
+covered work, you indicate your acceptance of this License to do so.
+
+ 10. Automatic Licensing of Downstream Recipients.
+
+ Each time you convey a covered work, the recipient automatically
+receives a license from the original licensors, to run, modify and
+propagate that work, subject to this License. You are not responsible
+for enforcing compliance by third parties with this License.
+
+ An "entity transaction" is a transaction transferring control of an
+organization, or substantially all assets of one, or subdividing an
+organization, or merging organizations. If propagation of a covered
+work results from an entity transaction, each party to that
+transaction who receives a copy of the work also receives whatever
+licenses to the work the party's predecessor in interest had or could
+give under the previous paragraph, plus a right to possession of the
+Corresponding Source of the work from the predecessor in interest, if
+the predecessor has it or can get it with reasonable efforts.
+
+ You may not impose any further restrictions on the exercise of the
+rights granted or affirmed under this License. For example, you may
+not impose a license fee, royalty, or other charge for exercise of
+rights granted under this License, and you may not initiate litigation
+(including a cross-claim or counterclaim in a lawsuit) alleging that
+any patent claim is infringed by making, using, selling, offering for
+sale, or importing the Program or any portion of it.
+
+ 11. Patents.
+
+ A "contributor" is a copyright holder who authorizes use under this
+License of the Program or a work on which the Program is based. The
+work thus licensed is called the contributor's "contributor version".
+
+ A contributor's "essential patent claims" are all patent claims
+owned or controlled by the contributor, whether already acquired or
+hereafter acquired, that would be infringed by some manner, permitted
+by this License, of making, using, or selling its contributor version,
+but do not include claims that would be infringed only as a
+consequence of further modification of the contributor version. For
+purposes of this definition, "control" includes the right to grant
+patent sublicenses in a manner consistent with the requirements of
+this License.
+
+ Each contributor grants you a non-exclusive, worldwide, royalty-free
+patent license under the contributor's essential patent claims, to
+make, use, sell, offer for sale, import and otherwise run, modify and
+propagate the contents of its contributor version.
+
+ In the following three paragraphs, a "patent license" is any express
+agreement or commitment, however denominated, not to enforce a patent
+(such as an express permission to practice a patent or covenant not to
+sue for patent infringement). To "grant" such a patent license to a
+party means to make such an agreement or commitment not to enforce a
+patent against the party.
+
+ If you convey a covered work, knowingly relying on a patent license,
+and the Corresponding Source of the work is not available for anyone
+to copy, free of charge and under the terms of this License, through a
+publicly available network server or other readily accessible means,
+then you must either (1) cause the Corresponding Source to be so
+available, or (2) arrange to deprive yourself of the benefit of the
+patent license for this particular work, or (3) arrange, in a manner
+consistent with the requirements of this License, to extend the patent
+license to downstream recipients. "Knowingly relying" means you have
+actual knowledge that, but for the patent license, your conveying the
+covered work in a country, or your recipient's use of the covered work
+in a country, would infringe one or more identifiable patents in that
+country that you have reason to believe are valid.
+
+ If, pursuant to or in connection with a single transaction or
+arrangement, you convey, or propagate by procuring conveyance of, a
+covered work, and grant a patent license to some of the parties
+receiving the covered work authorizing them to use, propagate, modify
+or convey a specific copy of the covered work, then the patent license
+you grant is automatically extended to all recipients of the covered
+work and works based on it.
+
+ A patent license is "discriminatory" if it does not include within
+the scope of its coverage, prohibits the exercise of, or is
+conditioned on the non-exercise of one or more of the rights that are
+specifically granted under this License. You may not convey a covered
+work if you are a party to an arrangement with a third party that is
+in the business of distributing software, under which you make payment
+to the third party based on the extent of your activity of conveying
+the work, and under which the third party grants, to any of the
+parties who would receive the covered work from you, a discriminatory
+patent license (a) in connection with copies of the covered work
+conveyed by you (or copies made from those copies), or (b) primarily
+for and in connection with specific products or compilations that
+contain the covered work, unless you entered into that arrangement,
+or that patent license was granted, prior to 28 March 2007.
+
+ Nothing in this License shall be construed as excluding or limiting
+any implied license or other defenses to infringement that may
+otherwise be available to you under applicable patent law.
+
+ 12. No Surrender of Others' Freedom.
+
+ If conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot convey a
+covered work so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you may
+not convey it at all. For example, if you agree to terms that obligate you
+to collect a royalty for further conveying from those to whom you convey
+the Program, the only way you could satisfy both those terms and this
+License would be to refrain entirely from conveying the Program.
+
+ 13. Use with the GNU Affero General Public License.
+
+ Notwithstanding any other provision of this License, you have
+permission to link or combine any covered work with a work licensed
+under version 3 of the GNU Affero General Public License into a single
+combined work, and to convey the resulting work. The terms of this
+License will continue to apply to the part which is the covered work,
+but the special requirements of the GNU Affero General Public License,
+section 13, concerning interaction through a network will apply to the
+combination as such.
+
+ 14. Revised Versions of this License.
+
+ The Free Software Foundation may publish revised and/or new versions of
+the GNU General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+ Each version is given a distinguishing version number. If the
+Program specifies that a certain numbered version of the GNU General
+Public License "or any later version" applies to it, you have the
+option of following the terms and conditions either of that numbered
+version or of any later version published by the Free Software
+Foundation. If the Program does not specify a version number of the
+GNU General Public License, you may choose any version ever published
+by the Free Software Foundation.
+
+ If the Program specifies that a proxy can decide which future
+versions of the GNU General Public License can be used, that proxy's
+public statement of acceptance of a version permanently authorizes you
+to choose that version for the Program.
+
+ Later license versions may give you additional or different
+permissions. However, no additional obligations are imposed on any
+author or copyright holder as a result of your choosing to follow a
+later version.
+
+ 15. Disclaimer of Warranty.
+
+ THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
+APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
+HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
+OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
+IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
+ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
+
+ 16. Limitation of Liability.
+
+ IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
+THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
+GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
+USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
+DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
+PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
+EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
+SUCH DAMAGES.
+
+ 17. Interpretation of Sections 15 and 16.
+
+ If the disclaimer of warranty and limitation of liability provided
+above cannot be given local legal effect according to their terms,
+reviewing courts shall apply local law that most closely approximates
+an absolute waiver of all civil liability in connection with the
+Program, unless a warranty or assumption of liability accompanies a
+copy of the Program in return for a fee.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+state the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+ Java 1.5 japa.parser and Abstract Syntax Tree
+ Copyright (C) 2007 J�lio Vilmar Gesser
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see .
+
+Also add information on how to contact you by electronic and paper mail.
+
+ If the program does terminal interaction, make it output a short
+notice like this when it starts in an interactive mode:
+
+ Java 1.5 japa.parser and Abstract Syntax Tree Copyright (C) 2007 J�lio Vilmar Gesser
+ This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, your program's commands
+might be different; for a GUI interface, you would use an "about box".
+
+ You should also get your employer (if you work as a programmer) or school,
+if any, to sign a "copyright disclaimer" for the program, if necessary.
+For more information on this, and how to apply and follow the GNU GPL, see
+.
+
+ The GNU General Public License does not permit incorporating your program
+into proprietary programs. If your program is a subroutine library, you
+may consider it more useful to permit linking proprietary applications with
+the library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License. But first, please read
+.
diff --git a/LICENSE.LGPL b/LICENSE.LGPL
new file mode 100644
index 0000000..b87303c
--- /dev/null
+++ b/LICENSE.LGPL
@@ -0,0 +1,165 @@
+ GNU LESSER GENERAL PUBLIC LICENSE
+ Version 3, 29 June 2007
+
+ Copyright (C) 2007 Free Software Foundation, Inc.
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+
+ This version of the GNU Lesser General Public License incorporates
+the terms and conditions of version 3 of the GNU General Public
+License, supplemented by the additional permissions listed below.
+
+ 0. Additional Definitions.
+
+ As used herein, "this License" refers to version 3 of the GNU Lesser
+General Public License, and the "GNU GPL" refers to version 3 of the GNU
+General Public License.
+
+ "The Library" refers to a covered work governed by this License,
+other than an Application or a Combined Work as defined below.
+
+ An "Application" is any work that makes use of an interface provided
+by the Library, but which is not otherwise based on the Library.
+Defining a subclass of a class defined by the Library is deemed a mode
+of using an interface provided by the Library.
+
+ A "Combined Work" is a work produced by combining or linking an
+Application with the Library. The particular version of the Library
+with which the Combined Work was made is also called the "Linked
+Version".
+
+ The "Minimal Corresponding Source" for a Combined Work means the
+Corresponding Source for the Combined Work, excluding any source code
+for portions of the Combined Work that, considered in isolation, are
+based on the Application, and not on the Linked Version.
+
+ The "Corresponding Application Code" for a Combined Work means the
+object code and/or source code for the Application, including any data
+and utility programs needed for reproducing the Combined Work from the
+Application, but excluding the System Libraries of the Combined Work.
+
+ 1. Exception to Section 3 of the GNU GPL.
+
+ You may convey a covered work under sections 3 and 4 of this License
+without being bound by section 3 of the GNU GPL.
+
+ 2. Conveying Modified Versions.
+
+ If you modify a copy of the Library, and, in your modifications, a
+facility refers to a function or data to be supplied by an Application
+that uses the facility (other than as an argument passed when the
+facility is invoked), then you may convey a copy of the modified
+version:
+
+ a) under this License, provided that you make a good faith effort to
+ ensure that, in the event an Application does not supply the
+ function or data, the facility still operates, and performs
+ whatever part of its purpose remains meaningful, or
+
+ b) under the GNU GPL, with none of the additional permissions of
+ this License applicable to that copy.
+
+ 3. Object Code Incorporating Material from Library Header Files.
+
+ The object code form of an Application may incorporate material from
+a header file that is part of the Library. You may convey such object
+code under terms of your choice, provided that, if the incorporated
+material is not limited to numerical parameters, data structure
+layouts and accessors, or small macros, inline functions and templates
+(ten or fewer lines in length), you do both of the following:
+
+ a) Give prominent notice with each copy of the object code that the
+ Library is used in it and that the Library and its use are
+ covered by this License.
+
+ b) Accompany the object code with a copy of the GNU GPL and this license
+ document.
+
+ 4. Combined Works.
+
+ You may convey a Combined Work under terms of your choice that,
+taken together, effectively do not restrict modification of the
+portions of the Library contained in the Combined Work and reverse
+engineering for debugging such modifications, if you also do each of
+the following:
+
+ a) Give prominent notice with each copy of the Combined Work that
+ the Library is used in it and that the Library and its use are
+ covered by this License.
+
+ b) Accompany the Combined Work with a copy of the GNU GPL and this license
+ document.
+
+ c) For a Combined Work that displays copyright notices during
+ execution, include the copyright notice for the Library among
+ these notices, as well as a reference directing the user to the
+ copies of the GNU GPL and this license document.
+
+ d) Do one of the following:
+
+ 0) Convey the Minimal Corresponding Source under the terms of this
+ License, and the Corresponding Application Code in a form
+ suitable for, and under terms that permit, the user to
+ recombine or relink the Application with a modified version of
+ the Linked Version to produce a modified Combined Work, in the
+ manner specified by section 6 of the GNU GPL for conveying
+ Corresponding Source.
+
+ 1) Use a suitable shared library mechanism for linking with the
+ Library. A suitable mechanism is one that (a) uses at run time
+ a copy of the Library already present on the user's computer
+ system, and (b) will operate properly with a modified version
+ of the Library that is interface-compatible with the Linked
+ Version.
+
+ e) Provide Installation Information, but only if you would otherwise
+ be required to provide such information under section 6 of the
+ GNU GPL, and only to the extent that such information is
+ necessary to install and execute a modified version of the
+ Combined Work produced by recombining or relinking the
+ Application with a modified version of the Linked Version. (If
+ you use option 4d0, the Installation Information must accompany
+ the Minimal Corresponding Source and Corresponding Application
+ Code. If you use option 4d1, you must provide the Installation
+ Information in the manner specified by section 6 of the GNU GPL
+ for conveying Corresponding Source.)
+
+ 5. Combined Libraries.
+
+ You may place library facilities that are a work based on the
+Library side by side in a single library together with other library
+facilities that are not Applications and are not covered by this
+License, and convey such a combined library under terms of your
+choice, if you do both of the following:
+
+ a) Accompany the combined library with a copy of the same work based
+ on the Library, uncombined with any other library facilities,
+ conveyed under the terms of this License.
+
+ b) Give prominent notice with the combined library that part of it
+ is a work based on the Library, and explaining where to find the
+ accompanying uncombined form of the same work.
+
+ 6. Revised Versions of the GNU Lesser General Public License.
+
+ The Free Software Foundation may publish revised and/or new versions
+of the GNU Lesser General Public License from time to time. Such new
+versions will be similar in spirit to the present version, but may
+differ in detail to address new problems or concerns.
+
+ Each version is given a distinguishing version number. If the
+Library as you received it specifies that a certain numbered version
+of the GNU Lesser General Public License "or any later version"
+applies to it, you have the option of following the terms and
+conditions either of that published version or of any later version
+published by the Free Software Foundation. If the Library as you
+received it does not specify a version number of the GNU Lesser
+General Public License, you may choose any version of the GNU Lesser
+General Public License ever published by the Free Software Foundation.
+
+ If the Library as you received it specifies that a proxy can decide
+whether future versions of the GNU Lesser General Public License shall
+apply, that proxy's public statement of acceptance of any version is
+permanent authorization for you to choose that version for the
+Library.
diff --git a/PULL_REQUEST_TEMPLATE.md b/PULL_REQUEST_TEMPLATE.md
new file mode 100644
index 0000000..1548fdd
--- /dev/null
+++ b/PULL_REQUEST_TEMPLATE.md
@@ -0,0 +1 @@
+Fixes #9999.
diff --git a/README.md b/README.md
deleted file mode 100644
index 9ebb840..0000000
--- a/README.md
+++ /dev/null
@@ -1 +0,0 @@
-# template-repository
\ No newline at end of file
diff --git a/appveyor.yml b/appveyor.yml
new file mode 100644
index 0000000..9008921
--- /dev/null
+++ b/appveyor.yml
@@ -0,0 +1,42 @@
+version: '{build}'
+os: Windows Server 2012
+
+environment:
+ appveyor_build_worker_cloud: gce
+
+init:
+ # Setup autocrlf -- by default, appveyor uses autocrlf input
+ # ... This affects tests which expect resource files to have the systems's line separator.
+ - git config --global core.autocrlf true
+
+install:
+ # Download maven
+ - ps: |
+ Add-Type -AssemblyName System.IO.Compression.FileSystem
+ if (!(Test-Path -Path "C:\maven" )) {
+ (new-object System.Net.WebClient).DownloadFile(
+ 'http://www.us.apache.org/dist/maven/maven-3/3.6.3/binaries/apache-maven-3.6.3-bin.zip',
+ 'C:\maven-bin.zip'
+ )
+ [System.IO.Compression.ZipFile]::ExtractToDirectory("C:\maven-bin.zip", "C:\maven")
+ }
+ # Setup environment variables for Maven and Java
+ - cmd: SET JAVA_HOME=C:\Program Files\Java\jdk10
+ - cmd: SET M2_HOME=C:\maven\apache-maven-3.6.3
+ - cmd: SET MAVEN_OPTS=-Xmx1g
+ - cmd: SET JAVA_OPTS=-Xmx1g
+ - cmd: SET PATH=C:\maven\apache-maven-3.6.3\bin;%JAVA_HOME%\bin;%PATH%
+ # Output the git config re: autocrlf to verify the "current" setting
+ - cmd: git config core.autocrlf
+
+# Appveyor is used for testing only -- the build script is not required.
+build_script:
+ - echo ignore this
+
+test_script:
+ - mvn -B clean install --batch-mode
+
+# Use of the cache speeds up future tests, meaning that dependencies do not need to be re-downloaded on every run.
+cache:
+ - C:\maven\
+ - C:\Users\appveyor\.m2
diff --git a/changelog.md b/changelog.md
new file mode 100644
index 0000000..951ede2
--- /dev/null
+++ b/changelog.md
@@ -0,0 +1,2867 @@
+
+Next Release (Version 3.25.11-snapshot)
+--------------------------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/207?closed=1)
+
+### Added
+### Changed
+### Deprecated
+### Removed
+### Fixed
+### Security
+
+
+Version 3.25.10
+---------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/206?closed=1)
+
+### Fixed
+
+* Fix issue 4345 Strange error when trying to find erasure of generic t… (PR [#4362](https://github.com/javaparser/javaparser/pull/4362) by [@jlerbsc](https://github.com/jlerbsc))
+* fix: issue 4358 prevent infinite cycles with static imports (PR [#4359](https://github.com/javaparser/javaparser/pull/4359) by [@kdunee](https://github.com/kdunee))
+* Refactor `ResolvedReferenceType#equals` (PR [#4351](https://github.com/javaparser/javaparser/pull/4351) by [@freya022](https://github.com/freya022))
+* fix: issue 4331 Cannot be 'abstract' and also 'private'. for a private method in an interface (PR [#4332](https://github.com/javaparser/javaparser/pull/4332) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* chore(deps): bump actions/checkout from 4.1.1 to 4.1.2 (PR [#4341](https://github.com/javaparser/javaparser/pull/4341) by [@dependabot[bot]](https://github.com/apps/dependabot))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@kdunee](https://github.com/kdunee)
+* [@freya022](https://github.com/freya022)
+* [@jlerbsc](https://github.com/jlerbsc)
+
+
+
+Version 3.25.9
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/205?closed=1)
+
+### Added
+
+* Fix: issue #3878 resolve MethodReference in ObjectCreationExpr (PR [#4296](https://github.com/javaparser/javaparser/pull/4296) by [@fishautumn](https://github.com/fishautumn))
+
+### Changed
+
+* Switch order of literals to prevent NullPointerException (PR [#4322](https://github.com/javaparser/javaparser/pull/4322) by [@citizenjosh](https://github.com/citizenjosh))
+* Minor refactoring to use the existing getArgumentPosition method (PR [#4306](https://github.com/javaparser/javaparser/pull/4306) by [@jlerbsc](https://github.com/jlerbsc))
+* Optimize find ancestor (PR [#4294](https://github.com/javaparser/javaparser/pull/4294) by [@magicwerk](https://github.com/magicwerk))
+* refac: Removes useless ExpressionHelper utility class and replaces some explicit casts by using the javaparser API (PR [#4291](https://github.com/javaparser/javaparser/pull/4291) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Fixed
+
+* fix: Dead stores should be removed (sonar rule) (PR [#4329](https://github.com/javaparser/javaparser/pull/4329) by [@jlerbsc](https://github.com/jlerbsc))
+* fix: Replace this if-then-else statement by a single return statement (sonar rule) (PR [#4328](https://github.com/javaparser/javaparser/pull/4328) by [@jlerbsc](https://github.com/jlerbsc))
+* fix: issue 2043 getAccessSpecifier should return public for interface methods (PR [#4317](https://github.com/javaparser/javaparser/pull/4317) by [@jlerbsc](https://github.com/jlerbsc))
+* Further improve correction of whitespace during difference application (PR [#4316](https://github.com/javaparser/javaparser/pull/4316) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue #3946 Symbol solver is unable to resolve inherited inner classes (PR [#4314](https://github.com/javaparser/javaparser/pull/4314) by [@jlerbsc](https://github.com/jlerbsc))
+* fix: issue 4311 IllegalStateException when removing all comments with LexicalPreservingPrinter (PR [#4313](https://github.com/javaparser/javaparser/pull/4313) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 3939 SymbolResolver.calculateType(Expression) may fails on first try, then succeed on later tries (PR [#4290](https://github.com/javaparser/javaparser/pull/4290) by [@jlerbsc](https://github.com/jlerbsc))
+* Adds unit test for issue 4284 "ClassCastException when resolving MethodCallExpr inside an enhanced switch statement" (PR [#4285](https://github.com/javaparser/javaparser/pull/4285) by [@jlerbsc](https://github.com/jlerbsc))
+* Change `SwitchStmt` to `SwitchNode` in `SwitchEntryContext` to avoid `ClassCastException` (PR [#4283](https://github.com/javaparser/javaparser/pull/4283) by [@PalashSharma20](https://github.com/PalashSharma20))
+
+### Developer Changes
+
+* chore(deps): bump org.codehaus.mojo:exec-maven-plugin from 3.1.1 to 3.2.0 (PR [#4323](https://github.com/javaparser/javaparser/pull/4323) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update junit5 monorepo to v5.10.2 (PR [#4307](https://github.com/javaparser/javaparser/pull/4307) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update codecov/codecov-action action to v4 (PR [#4304](https://github.com/javaparser/javaparser/pull/4304) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update actions/cache action to v4 (PR [#4293](https://github.com/javaparser/javaparser/pull/4293) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@citizenjosh](https://github.com/citizenjosh)
+* [@magicwerk](https://github.com/magicwerk)
+* [@PalashSharma20](https://github.com/PalashSharma20)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@fishautumn](https://github.com/fishautumn)
+
+
+Version 3.25.8
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/204?closed=1)
+
+### Added
+
+* feat: creates cache statistics and moves Cache interface to javaparser-core (PR [#4278](https://github.com/javaparser/javaparser/pull/4278) by [@jlerbsc](https://github.com/jlerbsc))
+* feat: Add parseArrayInitializerExpr to JavaParser API (PR [#4276](https://github.com/javaparser/javaparser/pull/4276) by [@iMashtak](https://github.com/iMashtak))
+* feat: A visitor looking for a node by its position in an AST (PR [#4258](https://github.com/javaparser/javaparser/pull/4258) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Changed
+
+* fix: Partial removal of the use of instanceof in favour of the use of the API (PR [#4280](https://github.com/javaparser/javaparser/pull/4280) by [@jlerbsc](https://github.com/jlerbsc))
+* [GHA] Run on java 18 (PR [#4252](https://github.com/javaparser/javaparser/pull/4252) by [@hazendaz](https://github.com/hazendaz))
+
+### Fixed
+
+* fix: issue 4240 Calling resolve on catch block parameter throws exception (PR [#4279](https://github.com/javaparser/javaparser/pull/4279) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 4270 Exception when resolving ObjectCreationExpr with nested varargs (PR [#4273](https://github.com/javaparser/javaparser/pull/4273) by [@jlerbsc](https://github.com/jlerbsc))
+* add Java_18 to yieldSupport (PR [#4262](https://github.com/javaparser/javaparser/pull/4262) by [@Kimmmey](https://github.com/Kimmmey))
+* fix: issue #4245 UnsupportedOperationException with LexicalPreservingPrinter when removing a sealed modified (PR [#4253](https://github.com/javaparser/javaparser/pull/4253) by [@jlerbsc](https://github.com/jlerbsc))
+* [ci] Fix change log released version as 3.25.7 (PR [#4251](https://github.com/javaparser/javaparser/pull/4251) by [@hazendaz](https://github.com/hazendaz))
+* Fix: issue 3278 Lazy types cause stack overflow when trying to find the least upper bound type (PR [#4246](https://github.com/javaparser/javaparser/pull/4246) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* chore(deps): bump com.google.guava:guava from 32.1.3-jre to 33.0.0-jre (PR [#4264](https://github.com/javaparser/javaparser/pull/4264) by [@dependabot[bot]](https://github.com/apps/dependabot))
+
+### Uncategorised
+
+* Revert "Refactoring: Move cache features to javaparser-core" (PR [#4274](https://github.com/javaparser/javaparser/pull/4274) by [@jlerbsc](https://github.com/jlerbsc))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@hazendaz](https://github.com/hazendaz)
+* [@iMashtak](https://github.com/iMashtak)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@Kimmmey](https://github.com/Kimmmey)
+
+Version 3.25.7
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/203?closed=1)
+
+### Added
+
+* [GHA] Remove old comment that is no longer valid around jdks and add jdk 17 (PR [#4226](https://github.com/javaparser/javaparser/pull/4226) by [@hazendaz](https://github.com/hazendaz))
+* Fix: issue 3833 No enum constant com.github.javaparser.ParserConfiguration.LanguageLevel.JAVA_18 (PR [#4221](https://github.com/javaparser/javaparser/pull/4221) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Changed
+
+* Refactoring: Move cache features to javaparser-core (PR [#4238](https://github.com/javaparser/javaparser/pull/4238) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: removes reference to coveralls plugin which is not useful because codecov is used to track code coverage (PR [#4235](https://github.com/javaparser/javaparser/pull/4235) by [@jlerbsc](https://github.com/jlerbsc))
+* Uses jakarta.json api, upgrades jakarta.json-api to the latest version & uses new default Eclipse Parsson (PR [#4234](https://github.com/javaparser/javaparser/pull/4234) by [@jlerbsc](https://github.com/jlerbsc))
+* Move mockito to 4.11.0 and handle byte buddy consistently as well as properly define its agent in argLine for surefire (PR [#4228](https://github.com/javaparser/javaparser/pull/4228) by [@hazendaz](https://github.com/hazendaz))
+* Cleanup poms, use jakarta provided (javax namespace), hamcrest follow up, and switch coveralls plugin - Fixes #4111 (PR [#4225](https://github.com/javaparser/javaparser/pull/4225) by [@hazendaz](https://github.com/hazendaz))
+* [pom] Switch from hamcrest-library (deprecated) to hamcrest (PR [#4200](https://github.com/javaparser/javaparser/pull/4200) by [@hazendaz](https://github.com/hazendaz))
+* Putting code in the .orElse that has a side effect that can affect performance (PR [#4199](https://github.com/javaparser/javaparser/pull/4199) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Fixed
+
+* Fix: issue 3650 unreproducible MAVEN_BUILD_TIMESTAMP (PR [#4243](https://github.com/javaparser/javaparser/pull/4243) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 3972 StackOverflowError when resolving type of scope of a MethodCall (PR [#4236](https://github.com/javaparser/javaparser/pull/4236) by [@jlerbsc](https://github.com/jlerbsc))
+* [fix] Jdk 18 enum stub was extended off java 16 post processor not java17 (PR [#4227](https://github.com/javaparser/javaparser/pull/4227) by [@hazendaz](https://github.com/hazendaz))
+* Fix: issue #4047 Symbol Solver mixes name with type (PR [#4206](https://github.com/javaparser/javaparser/pull/4206) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix grammar (PR [#4203](https://github.com/javaparser/javaparser/pull/4203) by [@mernst](https://github.com/mernst))
+* Minor changes : corrupted format, useless cast, javadoc (PR [#4198](https://github.com/javaparser/javaparser/pull/4198) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* chore(deps): update actions/setup-java action to v4 (PR [#4241](https://github.com/javaparser/javaparser/pull/4241) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): bump org.codehaus.mojo:build-helper-maven-plugin from 3.4.0 to 3.5.0 (PR [#4223](https://github.com/javaparser/javaparser/pull/4223) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* Adds sponsor link to help the project live and grow (PR [#4204](https://github.com/javaparser/javaparser/pull/4204) by [@jlerbsc](https://github.com/jlerbsc))
+* chore(deps): bump org.codehaus.mojo:templating-maven-plugin from 1.0.0 to 3.0.0 (PR [#4195](https://github.com/javaparser/javaparser/pull/4195) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update junit5 monorepo to v5.10.1 (PR [#4193](https://github.com/javaparser/javaparser/pull/4193) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### Uncategorised
+
+* Added unit tests for visitors (PR [#4239](https://github.com/javaparser/javaparser/pull/4239) by [@4everTheOne](https://github.com/4everTheOne))
+* Unit tests for class GenericListVisitorAdapter (PR [#4237](https://github.com/javaparser/javaparser/pull/4237) by [@4everTheOne](https://github.com/4everTheOne))
+* Update readme.md (PR [#4222](https://github.com/javaparser/javaparser/pull/4222) by [@jlerbsc](https://github.com/jlerbsc))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@hazendaz](https://github.com/hazendaz)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@mernst](https://github.com/mernst)
+* [@4everTheOne](https://github.com/4everTheOne)
+
+
+Version 3.25.6
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/202?closed=1)
+
+### Changed
+
+* reformat javaconcept take 2 (PR [#4167](https://github.com/javaparser/javaparser/pull/4167) by [@JimmyGan437](https://github.com/JimmyGan437))
+* Using JAXP on XMLPrinter implementation (PR [#4166](https://github.com/javaparser/javaparser/pull/4166) by [@lcbarcellos](https://github.com/lcbarcellos))
+* replace deprecated methond calls to their replacements (PR [#4157](https://github.com/javaparser/javaparser/pull/4157) by [@JimmyGan437](https://github.com/JimmyGan437))
+* feat(#4075): Improve the validation error messages (PR [#4116](https://github.com/javaparser/javaparser/pull/4116) by [@volodya-lombrozo](https://github.com/volodya-lombrozo))
+
+### Fixed
+
+* Fix: issue #2751 new HashSet()" != "new HashSet<>() (PR [#4183](https://github.com/javaparser/javaparser/pull/4183) by [@lcbarcellos](https://github.com/lcbarcellos))
+* Fixes #2625 Add messages to thrown exceptions (PR [#4177](https://github.com/javaparser/javaparser/pull/4177) by [@oannhpham](https://github.com/oannhpham))
+* Fix: issue 4163 Calling MethodDeclaration.getDeclarationAsString leads to MethodDelaration.getComment returning no comment (PR [#4165](https://github.com/javaparser/javaparser/pull/4165) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 3673 isAssignableBy method StackOverflowError (PR [#4156](https://github.com/javaparser/javaparser/pull/4156) by [@jlerbsc](https://github.com/jlerbsc))
+* fix: issue 3184 Unable to get the resolved type of class ResolvedReferenceType from T (PR [#4147](https://github.com/javaparser/javaparser/pull/4147) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue #3269 Test resources containing included interfaces do not compile (PR [#4139](https://github.com/javaparser/javaparser/pull/4139) by [@jlerbsc](https://github.com/jlerbsc))
+* CalculateResolvedType Type error (PR [#4138](https://github.com/javaparser/javaparser/pull/4138) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue #4036 LeastUpperBoundLogic.lub returns null when matches ConditionalExpr (PR [#4137](https://github.com/javaparser/javaparser/pull/4137) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue #2484 SymbolResolver on MethodCallExpr fails if method parameter is of kind Class extends y> (PR [#4136](https://github.com/javaparser/javaparser/pull/4136) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* chore(deps): bump com.google.guava:guava from 32.1.2-jre to 32.1.3-jre (PR [#4154](https://github.com/javaparser/javaparser/pull/4154) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update actions/checkout action to v4 (PR [#4141](https://github.com/javaparser/javaparser/pull/4141) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@lcbarcellos](https://github.com/lcbarcellos)
+* [@volodya-lombrozo](https://github.com/volodya-lombrozo)
+* [@JimmyGan437](https://github.com/JimmyGan437)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@oannhpham](https://github.com/oannhpham)
+
+
+
+Version 3.25.5
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/201?closed=1)
+
+### Added
+
+* fix: issue 4115 ResolvedUnionType should give access to a list of resolved types (PR [#4119](https://github.com/javaparser/javaparser/pull/4119) by [@jlerbsc](https://github.com/jlerbsc))
+* Support getting more annotation default values using reflection (PR [#4103](https://github.com/javaparser/javaparser/pull/4103) by [@freya022](https://github.com/freya022))
+
+### Changed
+
+* Minor refactoring: Simplifies how to group deleted tokens by extracting a method into an independent class (PR [#4134](https://github.com/javaparser/javaparser/pull/4134) by [@jlerbsc](https://github.com/jlerbsc))
+* Replace deprecated command with environment file (PR [#4122](https://github.com/javaparser/javaparser/pull/4122) by [@70825](https://github.com/70825))
+* Fixes missing named constructor in Modifier.java (PR [#4092](https://github.com/javaparser/javaparser/pull/4092) by [@Auties00](https://github.com/Auties00))
+
+### Fixed
+
+* Fix: issue 4133 Top-level class containerType() throws an exception instead of Optional.empty() (PR [#4135](https://github.com/javaparser/javaparser/pull/4135) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: apply multiline strings (PR [#4130](https://github.com/javaparser/javaparser/pull/4130) by [@70825](https://github.com/70825))
+* Fix: issue 3976 Issue resolving implicit generic types (PR [#4128](https://github.com/javaparser/javaparser/pull/4128) by [@jlerbsc](https://github.com/jlerbsc))
+* Add unit test for PR 4091 Fixed missing permits in pretty printer (PR [#4126](https://github.com/javaparser/javaparser/pull/4126) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 4124 UnsupportedOperationException: 'T' is thrown in MethodCallExpr resolve (PR [#4125](https://github.com/javaparser/javaparser/pull/4125) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 4051 Switched upperBounds and lowerBounds on ResolvedTypeP… (PR [#4123](https://github.com/javaparser/javaparser/pull/4123) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix failing test on JDK 17 (PR [#4121](https://github.com/javaparser/javaparser/pull/4121) by [@mahesh-hegde](https://github.com/mahesh-hegde))
+* Fix: issue 3673 isAssignableBy method StackOverflowError (PR [#4118](https://github.com/javaparser/javaparser/pull/4118) by [@jlerbsc](https://github.com/jlerbsc))
+* Orphan comment added when using lexical preservation is not printed (PR [#4114](https://github.com/javaparser/javaparser/pull/4114) by [@jlerbsc](https://github.com/jlerbsc))
+* Fixed missing permits in pretty printer (PR [#4091](https://github.com/javaparser/javaparser/pull/4091) by [@Auties00](https://github.com/Auties00))
+
+### Developer Changes
+
+* chore(deps): update actions/checkout action to v3.6.0 (PR [#4127](https://github.com/javaparser/javaparser/pull/4127) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): bump com.google.guava:guava from 32.1.1-jre to 32.1.2-jre (PR [#4109](https://github.com/javaparser/javaparser/pull/4109) by [@dependabot[bot]](https://github.com/apps/dependabot))
+
+### Uncategorised
+
+* Fix: issue 4104 LPP doesn't handle new switch entries well (PR [#4106](https://github.com/javaparser/javaparser/pull/4106) by [@jlerbsc](https://github.com/jlerbsc))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@freya022](https://github.com/freya022)
+* [@Auties00](https://github.com/Auties00)
+* [@mahesh-hegde](https://github.com/mahesh-hegde)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@70825](https://github.com/70825)
+
+
+Version 3.25.4
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/200?closed=1)
+
+### Changed
+
+* Nested 'if' statements should be simplified (PR [#4085](https://github.com/javaparser/javaparser/pull/4085) by [@jlerbsc](https://github.com/jlerbsc))
+* BDD tests: migarte to JBehave 5 (PR [#4028](https://github.com/javaparser/javaparser/pull/4028) by [@valfirst](https://github.com/valfirst))
+
+### Fixed
+
+* Fix: issue 4077 After building JavaParser (with tests) on MacOS multi… (PR [#4086](https://github.com/javaparser/javaparser/pull/4086) by [@jlerbsc](https://github.com/jlerbsc))
+* fix line separators of selected test files (PR [#4083](https://github.com/javaparser/javaparser/pull/4083) by [@abego](https://github.com/abego))
+* Fix: issue 3978 typesolver can't parse in parallel (PR [#4073](https://github.com/javaparser/javaparser/pull/4073) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix #4056 isDeclaredInInterface() returns true for fields declared inside enumerations contained in an interface (PR [#4057](https://github.com/javaparser/javaparser/pull/4057) by [@Elewyth](https://github.com/Elewyth))
+* Fix: issue 4037 ArrayIndexOutOfBoundsException throws when method param is variadic (PR [#4046](https://github.com/javaparser/javaparser/pull/4046) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 4016 Failed to parse variable with name 'sealed' or 'permits' (PR [#4039](https://github.com/javaparser/javaparser/pull/4039) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* chore(deps): bump guava from 32.1.0-jre to 32.1.1-jre (PR [#4089](https://github.com/javaparser/javaparser/pull/4089) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump guava from 32.0.0-jre to 32.1.0-jre (PR [#4087](https://github.com/javaparser/javaparser/pull/4087) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump checkstyle from 10.12.0 to 10.12.1 (PR [#4084](https://github.com/javaparser/javaparser/pull/4084) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump versions-maven-plugin from 2.15.0 to 2.16.0 (PR [#4055](https://github.com/javaparser/javaparser/pull/4055) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-release-plugin from 3.0.0 to 3.0.1 (PR [#4053](https://github.com/javaparser/javaparser/pull/4053) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump guava from 31.1-jre to 32.0.0-jre (PR [#4042](https://github.com/javaparser/javaparser/pull/4042) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-dependency-plugin from 3.5.0 to 3.6.0 (PR [#4035](https://github.com/javaparser/javaparser/pull/4035) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-checkstyle-plugin from 3.2.2 to 3.3.0 (PR [#4033](https://github.com/javaparser/javaparser/pull/4033) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-scm-plugin from 2.0.0 to 2.0.1 (PR [#4031](https://github.com/javaparser/javaparser/pull/4031) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump codecov/codecov-action from 3.1.3 to 3.1.4 (PR [#4030](https://github.com/javaparser/javaparser/pull/4030) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump build-helper-maven-plugin from 3.3.0 to 3.4.0 (PR [#4026](https://github.com/javaparser/javaparser/pull/4026) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update dependency maven to v3.9.2 (PR [#4024](https://github.com/javaparser/javaparser/pull/4024) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@valfirst](https://github.com/valfirst)
+* [@abego](https://github.com/abego)
+* [@Elewyth](https://github.com/Elewyth)
+* [@jlerbsc](https://github.com/jlerbsc)
+
+
+Version 3.25.3
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/199?closed=1)
+
+
+### Added
+
+* add Java 17 sealed/non-sealed classes (PR [#3997](https://github.com/javaparser/javaparser/pull/3997) by [@kris-scheibe](https://github.com/kris-scheibe))
+
+### Changed
+
+* Minor simplification of the Difference class (PR [#4008](https://github.com/javaparser/javaparser/pull/4008) by [@jlerbsc](https://github.com/jlerbsc))
+* Perf: Remove unnecessary methods and quickly return to the Range.cont… (PR [#3996](https://github.com/javaparser/javaparser/pull/3996) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Fixed
+
+* Fix: issue 1843 Problems with hasAnnotation() and hasDirectlyAnnotati… (PR [#4015](https://github.com/javaparser/javaparser/pull/4015) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: Issue 3995 resolving a method call with a variadic argument of p… (PR [#3998](https://github.com/javaparser/javaparser/pull/3998) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 3983 why FieldDeclaration in an interface calling isStatic… (PR [#3986](https://github.com/javaparser/javaparser/pull/3986) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* chore(deps): bump checkstyle from 10.9.3 to 10.10.0 (PR [#4014](https://github.com/javaparser/javaparser/pull/4014) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update junit5 monorepo to v5.9.3 (PR [#4012](https://github.com/javaparser/javaparser/pull/4012) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): bump jacoco-maven-plugin from 0.8.9 to 0.8.10 (PR [#4011](https://github.com/javaparser/javaparser/pull/4011) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps-dev): bump okhttp from 4.10.0 to 4.11.0 (PR [#4009](https://github.com/javaparser/javaparser/pull/4009) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump codecov/codecov-action from 3.1.2 to 3.1.3 (PR [#4006](https://github.com/javaparser/javaparser/pull/4006) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-checkstyle-plugin from 3.2.1 to 3.2.2 (PR [#4005](https://github.com/javaparser/javaparser/pull/4005) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump actions/checkout from 3.5.1 to 3.5.2 (PR [#3994](https://github.com/javaparser/javaparser/pull/3994) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump actions/checkout from 3.5.0 to 3.5.1 (PR [#3992](https://github.com/javaparser/javaparser/pull/3992) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump codecov/codecov-action from 3.1.1 to 3.1.2 (PR [#3988](https://github.com/javaparser/javaparser/pull/3988) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-deploy-plugin from 3.1.0 to 3.1.1 (PR [#3985](https://github.com/javaparser/javaparser/pull/3985) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump jacoco-maven-plugin from 0.8.8 to 0.8.9 (PR [#3981](https://github.com/javaparser/javaparser/pull/3981) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump checkstyle from 10.9.1 to 10.9.3 (PR [#3980](https://github.com/javaparser/javaparser/pull/3980) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-resources-plugin from 3.3.0 to 3.3.1 (PR [#3979](https://github.com/javaparser/javaparser/pull/3979) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-install-plugin from 3.1.0 to 3.1.1 (PR [#3975](https://github.com/javaparser/javaparser/pull/3975) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-release-plugin from 2.5.3 to 3.0.0 (PR [#3965](https://github.com/javaparser/javaparser/pull/3965) by [@dependabot[bot]](https://github.com/apps/dependabot))
+
+### Uncategorised
+
+* add test for showing interface field shall be static & final (PR [#3984](https://github.com/javaparser/javaparser/pull/3984) by [@XenoAmess](https://github.com/XenoAmess))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@kris-scheibe](https://github.com/kris-scheibe)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@XenoAmess](https://github.com/XenoAmess)
+
+
+Version 3.25.2
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/198?closed=1)
+
+### Changed
+
+* chore(deps): bump maven-scm-plugin from 1.13.0 to 2.0.0 (PR [#3961](https://github.com/javaparser/javaparser/pull/3961) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump checkstyle from 10.8.1 to 10.9.1 (PR [#3958](https://github.com/javaparser/javaparser/pull/3958) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump actions/checkout from 3.3.0 to 3.4.0 (PR [#3954](https://github.com/javaparser/javaparser/pull/3954) by [@dependabot[bot]](https://github.com/apps/dependabot))
+
+### Fixed
+
+* Fix: issue 3947 MANIFEST.MF points to non-existent URL (PR [#3966](https://github.com/javaparser/javaparser/pull/3966) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 3951 ConfilictingGenericTypesException is thrown when an Object type is expected as a parameter and an interface is provided as the actual parameter (PR [#3963](https://github.com/javaparser/javaparser/pull/3963) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 3949 LexicalPreservingPrinter Ignores Changes to LambdaExp… (PR [#3959](https://github.com/javaparser/javaparser/pull/3959) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: Unit test since Return-Type-Substituable is fully implemented on reference type (PR [#3943](https://github.com/javaparser/javaparser/pull/3943) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue on FunctionalInterfaceLogic but waiting for Return-Type-Su… (PR [#3941](https://github.com/javaparser/javaparser/pull/3941) by [@jlerbsc](https://github.com/jlerbsc))
+* Suggested fix: hardcoded specific LambdaExpr case in LexicalDifferenc… (PR [#3938](https://github.com/javaparser/javaparser/pull/3938) by [@blacelle](https://github.com/blacelle))
+* Fix TextBlockLiteralExpr in LexicalDifferenceCalculator (PR [#3937](https://github.com/javaparser/javaparser/pull/3937) by [@blacelle](https://github.com/blacelle))
+* Fix: issue 3919 An array of primitive type cannot be assigned to an array of object (PR [#3933](https://github.com/javaparser/javaparser/pull/3933) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* chore(deps): update actions/checkout action to v3.5.0 (PR [#3953](https://github.com/javaparser/javaparser/pull/3953) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@blacelle](https://github.com/blacelle)
+* [@jlerbsc](https://github.com/jlerbsc)
+
+
+Version 3.25.1
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/197?closed=1)
+
+### API or Behaviour Change
+
+* Fix: Issue 3045 Unexpected exception when solving type inside an Anonymous class (PR [#3896](https://github.com/javaparser/javaparser/pull/3896) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Added
+
+* Improved search for functional interfaces (PR [#3894](https://github.com/javaparser/javaparser/pull/3894) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Changed
+
+* chore(deps): bump maven-compiler-plugin from 3.10.1 to 3.11.0 (PR [#3928](https://github.com/javaparser/javaparser/pull/3928) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump checkstyle from 10.7.0 to 10.8.0 (PR [#3927](https://github.com/javaparser/javaparser/pull/3927) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump versions-maven-plugin from 2.14.2 to 2.15.0 (PR [#3914](https://github.com/javaparser/javaparser/pull/3914) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-javadoc-plugin from 3.4.1 to 3.5.0 (PR [#3906](https://github.com/javaparser/javaparser/pull/3906) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* Refactor: cleanup/refactor code after fixing #3859 (PR [#3886](https://github.com/javaparser/javaparser/pull/3886) by [@abego](https://github.com/abego))
+
+### Fixed
+
+* Fix: issue 3924 Removing ImportDeclaration with Annotated package thr… (PR [#3926](https://github.com/javaparser/javaparser/pull/3926) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 3918 JavaParserTypeDeclarationAdapter resolving wrong Type via Ancestor (PR [#3921](https://github.com/javaparser/javaparser/pull/3921) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 3919 ResolvedType::isAssignableBy(ResolvedType) is wrong f… (PR [#3920](https://github.com/javaparser/javaparser/pull/3920) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 3911 java.lang.UnsupportedOperationException: T[] while resolving generic method with type parameter with arrays like List (PR [#3917](https://github.com/javaparser/javaparser/pull/3917) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: \s escape gives lexical error but should be valid since Java 15 (PR [#3903](https://github.com/javaparser/javaparser/pull/3903) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: Issue 3045 Unexpected exception when solving type inside an Anonymous class (PR [#3896](https://github.com/javaparser/javaparser/pull/3896) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix issue 1883 Finding lambda return type (PR [#3890](https://github.com/javaparser/javaparser/pull/3890) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 1815 ArrayIndexOutOfBoundsException when resolving lambda parameter. This fix is offered by Blackgen (PR [#3888](https://github.com/javaparser/javaparser/pull/3888) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* chore(deps): bump checkstyle from 10.6.0 to 10.7.0 (PR [#3885](https://github.com/javaparser/javaparser/pull/3885) by [@dependabot[bot]](https://github.com/apps/dependabot))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@abego](https://github.com/abego)
+* [@jlerbsc](https://github.com/jlerbsc)
+
+
+Version 3.25.0
+--------------
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/196?closed=1)
+
+### Added
+
+* First part of the implementation of least upper bound logic (PR [#3880](https://github.com/javaparser/javaparser/pull/3880) by [@jlerbsc](https://github.com/jlerbsc))
+* feat: Improved support for calculating the type of an object creation… (PR [#3877](https://github.com/javaparser/javaparser/pull/3877) by [@jlerbsc](https://github.com/jlerbsc))
+* feat: Implement addRecord & getRecordByName for CompilationUnit (PR [#3836](https://github.com/javaparser/javaparser/pull/3836) by [@marcluque](https://github.com/marcluque))
+* Support Jigsaw requires static (PR [#3826](https://github.com/javaparser/javaparser/pull/3826) by [@jlerbsc](https://github.com/jlerbsc))
+* Add toDescriptor to ResolvedMethodDeclaration (PR [#3819](https://github.com/javaparser/javaparser/pull/3819) by [@vanHekthor](https://github.com/vanHekthor))
+* Refactoring context (WIP) (PR [#3792](https://github.com/javaparser/javaparser/pull/3792) by [@jlerbsc](https://github.com/jlerbsc))
+* Refactoring context (WIP) (PR [#3782](https://github.com/javaparser/javaparser/pull/3782) by [@jlerbsc](https://github.com/jlerbsc))
+* Refactoring convert to usage (PR [#3774](https://github.com/javaparser/javaparser/pull/3774) by [@jlerbsc](https://github.com/jlerbsc))
+* Simplified usage of class AssociableToAST (PR [#3063](https://github.com/javaparser/javaparser/pull/3063) by [@4everTheOne](https://github.com/4everTheOne))
+
+### Changed
+
+* Revert import related checkstyle rule from error to warning (PR [#3881](https://github.com/javaparser/javaparser/pull/3881) by [@jlerbsc](https://github.com/jlerbsc))
+* Minor refactoring for example to get all parameter types (PR [#3879](https://github.com/javaparser/javaparser/pull/3879) by [@jlerbsc](https://github.com/jlerbsc))
+* Add header and footer methods in comments instead of using literal st… (PR [#3876](https://github.com/javaparser/javaparser/pull/3876) by [@jlerbsc](https://github.com/jlerbsc))
+* In the context of lexical preservation, the CSM token must be added m… (PR [#3874](https://github.com/javaparser/javaparser/pull/3874) by [@jlerbsc](https://github.com/jlerbsc))
+* Refactoring: remove useless code that is already implemented (PR [#3869](https://github.com/javaparser/javaparser/pull/3869) by [@jlerbsc](https://github.com/jlerbsc))
+* Memory usage improvement when printing a node from the LexicalPreserv… (PR [#3858](https://github.com/javaparser/javaparser/pull/3858) by [@jlerbsc](https://github.com/jlerbsc))
+* chore(deps-dev): bump assertj-core from 3.24.1 to 3.24.2 (PR [#3852](https://github.com/javaparser/javaparser/pull/3852) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-checkstyle-plugin from 3.2.0 to 3.2.1 (PR [#3846](https://github.com/javaparser/javaparser/pull/3846) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-dependency-plugin from 3.4.0 to 3.5.0 (PR [#3845](https://github.com/javaparser/javaparser/pull/3845) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update junit5 monorepo to v5.9.2 (PR [#3840](https://github.com/javaparser/javaparser/pull/3840) by [@renovate[bot]](https://github.com/apps/renovate))
+* Minor refactoring on Difference class (PR [#3839](https://github.com/javaparser/javaparser/pull/3839) by [@jlerbsc](https://github.com/jlerbsc))
+* chore(deps-dev): bump assertj-core from 3.23.1 to 3.24.1 (PR [#3837](https://github.com/javaparser/javaparser/pull/3837) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump actions/checkout from 3.2.0 to 3.3.0 (PR [#3834](https://github.com/javaparser/javaparser/pull/3834) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump checkstyle from 10.5.0 to 10.6.0 (PR [#3829](https://github.com/javaparser/javaparser/pull/3829) by [@dependabot[bot]](https://github.com/apps/dependabot))
+
+### Fixed
+
+* Fix: Method hasScope must return true on NodeWithOptionalScope and No… (PR [#3875](https://github.com/javaparser/javaparser/pull/3875) by [@jlerbsc](https://github.com/jlerbsc))
+* fix #3859 UnsupportedOperationException when trying to resolve a type… (PR [#3873](https://github.com/javaparser/javaparser/pull/3873) by [@abego](https://github.com/abego))
+* Fix: issue 3866 Symbol solver is unable to resolve inner classes of ancestors when they are prefixed with a subclass (PR [#3868](https://github.com/javaparser/javaparser/pull/3868) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: issue 3703 Allow removing empty parentheses after removing all pairs from an annotation (PR [#3865](https://github.com/javaparser/javaparser/pull/3865) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: One must be able to know if any resolved type is a boxed primiti… (PR [#3864](https://github.com/javaparser/javaparser/pull/3864) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: Issue 2374 Comments of added Nodes are ignored in LexicalPreserv… (PR [#3856](https://github.com/javaparser/javaparser/pull/3856) by [@jlerbsc](https://github.com/jlerbsc))
+* Checkstyle for unused import (PR [#3841](https://github.com/javaparser/javaparser/pull/3841) by [@4everTheOne](https://github.com/4everTheOne))
+* Update bnd file (PR [#3783](https://github.com/javaparser/javaparser/pull/3783) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* Update javaparser copyright headers (PR [#3862](https://github.com/javaparser/javaparser/pull/3862) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Uncategorised
+
+* Add test case to verify range calculation on ArrayType (PR [#3828](https://github.com/javaparser/javaparser/pull/3828) by [@jlerbsc](https://github.com/jlerbsc))
+* Add test case to verify that LexicalPreservation supports TextBlock (PR [#3827](https://github.com/javaparser/javaparser/pull/3827) by [@jlerbsc](https://github.com/jlerbsc))
+* Refactoring: Removing useless method convertToUsage in JavaParserFacade (PR [#3780](https://github.com/javaparser/javaparser/pull/3780) by [@jlerbsc](https://github.com/jlerbsc))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@vanHekthor](https://github.com/vanHekthor)
+* [@abego](https://github.com/abego)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@marcluque](https://github.com/marcluque)
+* [@4everTheOne](https://github.com/4everTheOne)
+
+
+Version 3.24.10
+---------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/194?closed=1)
+
+### Added
+
+* Add a method in LexicalPreservingPrinter to know if LPP is available/activated on the specified node (PR [#3823](https://github.com/javaparser/javaparser/pull/3823) by [@jlerbsc](https://github.com/jlerbsc))
+* Handle nested records (PR [#3814](https://github.com/javaparser/javaparser/pull/3814) by [@mernst](https://github.com/mernst))
+* Source printer import ordering strategy (PR [#3807](https://github.com/javaparser/javaparser/pull/3807) by [@4everTheOne](https://github.com/4everTheOne))
+
+### Changed
+
+* chore(deps): bump versions-maven-plugin from 2.14.1 to 2.14.2 (PR [#3817](https://github.com/javaparser/javaparser/pull/3817) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* Enabled import validation (PR [#3812](https://github.com/javaparser/javaparser/pull/3812) by [@4everTheOne](https://github.com/4everTheOne))
+* Part 5 | Import organization (PR [#3805](https://github.com/javaparser/javaparser/pull/3805) by [@4everTheOne](https://github.com/4everTheOne))
+* Part 4 | Import organization (PR [#3804](https://github.com/javaparser/javaparser/pull/3804) by [@4everTheOne](https://github.com/4everTheOne))
+* Part 3 | Import organization (PR [#3803](https://github.com/javaparser/javaparser/pull/3803) by [@4everTheOne](https://github.com/4everTheOne))
+* Part 2 | Import organization (PR [#3802](https://github.com/javaparser/javaparser/pull/3802) by [@4everTheOne](https://github.com/4everTheOne))
+* Part 1 | Import organization (PR [#3801](https://github.com/javaparser/javaparser/pull/3801) by [@4everTheOne](https://github.com/4everTheOne))
+* Checkstyle configuration tweaks (PR [#3799](https://github.com/javaparser/javaparser/pull/3799) by [@4everTheOne](https://github.com/4everTheOne))
+* chore(deps): bump versions-maven-plugin from 2.13.0 to 2.14.1 (PR [#3797](https://github.com/javaparser/javaparser/pull/3797) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump actions/checkout from 3.1.0 to 3.2.0 (PR [#3789](https://github.com/javaparser/javaparser/pull/3789) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump checkstyle from 8.45.1 to 10.5.0 (PR [#3788](https://github.com/javaparser/javaparser/pull/3788) by [@dependabot[bot]](https://github.com/apps/dependabot))
+
+### Fixed
+
+* explicit use asString for performance (PR [#3821](https://github.com/javaparser/javaparser/pull/3821) by [@dencat](https://github.com/dencat))
+* Fix: issue #3818 Wrong range calculation on ArrayType with multiple d… (PR [#3820](https://github.com/javaparser/javaparser/pull/3820) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: Lexical Preserving Fails To Remove Comment (PR [#3810](https://github.com/javaparser/javaparser/pull/3810) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* chore(deps): bump versions-maven-plugin from 2.13.0 to 2.14.0 (PR [#3794](https://github.com/javaparser/javaparser/pull/3794) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* Basic CheckStyle validation (PR [#3781](https://github.com/javaparser/javaparser/pull/3781) by [@4everTheOne](https://github.com/4everTheOne))
+
+### Uncategorised
+
+* Fix: 3412 Remove walkmod again (PR [#3806](https://github.com/javaparser/javaparser/pull/3806) by [@jlerbsc](https://github.com/jlerbsc))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@dencat](https://github.com/dencat)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@mernst](https://github.com/mernst)
+* [@4everTheOne](https://github.com/4everTheOne)
+
+
+Version 3.24.9
+---------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/193?closed=1)
+
+### Highlights
+
+* Remove "executable" bit from code files (PR [#3755](https://github.com/javaparser/javaparser/pull/3755) by [@icmdaf](https://github.com/icmdaf))
+
+### Added
+
+* Created TypeSolverBuilder (PR [#3421](https://github.com/javaparser/javaparser/pull/3421) by [@4everTheOne](https://github.com/4everTheOne))
+
+### Changed
+
+* Changing, in test classes, the initialization of the lexical preserva… (PR [#3779](https://github.com/javaparser/javaparser/pull/3779) by [@jlerbsc](https://github.com/jlerbsc))
+* chore(deps): bump maven-dependency-plugin from 3.3.0 to 3.4.0 (PR [#3770](https://github.com/javaparser/javaparser/pull/3770) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): bump maven-install-plugin from 3.0.1 to 3.1.0 (PR [#3756](https://github.com/javaparser/javaparser/pull/3756) by [@dependabot[bot]](https://github.com/apps/dependabot))
+
+### Fixed
+
+* Fix: #3195 Resolved methods in outer classes not inferred correcly (PR [#3778](https://github.com/javaparser/javaparser/pull/3778) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: #3681 LineComment alwaysing trimming content (PR [#3777](https://github.com/javaparser/javaparser/pull/3777) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: #3773 Replacing nodes causes error in lexical preserving printer… (PR [#3776](https://github.com/javaparser/javaparser/pull/3776) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: #2517 Modifying some nodes with the lexicalPreservation enabled … (PR [#3775](https://github.com/javaparser/javaparser/pull/3775) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: #3725 JavaParserFacade var type in for-each loop cannot be resolved (PR [#3768](https://github.com/javaparser/javaparser/pull/3768) by [@abego](https://github.com/abego))
+* Fix: #3216 LexicalPreservingPrinter add Wrong indentation when removing comments (PR [#3766](https://github.com/javaparser/javaparser/pull/3766) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: #3472 Line comment removal causes IllegalStateException with LexicalPreservingPrinter (PR [#3765](https://github.com/javaparser/javaparser/pull/3765) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: #3441 LexicalPreservingPrinter prints wrong output with line com… (PR [#3764](https://github.com/javaparser/javaparser/pull/3764) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: #2137 ClassOrInterfaceDeclaration addMember using index (PR [#3763](https://github.com/javaparser/javaparser/pull/3763) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: #3761 Lexical preserving corrupts source when adding a modifier in first position (PR [#3762](https://github.com/javaparser/javaparser/pull/3762) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: #3693 Removing modifiers from method declaration results in loss… (PR [#3760](https://github.com/javaparser/javaparser/pull/3760) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: #3750 Lexical preserving corrupts source (PR [#3759](https://github.com/javaparser/javaparser/pull/3759) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix: Fix the indentation generated by the LexicalPreservingPrinter wh… (PR [#3758](https://github.com/javaparser/javaparser/pull/3758) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Security
+
+* Remove "executable" bit from code files (PR [#3755](https://github.com/javaparser/javaparser/pull/3755) by [@icmdaf](https://github.com/icmdaf))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@abego](https://github.com/abego)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@icmdaf](https://github.com/icmdaf)
+* [@4everTheOne](https://github.com/4everTheOne)
+
+
+Version 3.24.8
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/192?closed=1)
+
+### Added
+
+* [Fixes #3099] Added ability to solve type with a list of expected type arguments (PR [#3213](https://github.com/javaparser/javaparser/pull/3213) by [@4everTheOne](https://github.com/4everTheOne))
+* [Suggestion] NonNull generator for parameters (PR [#3127](https://github.com/javaparser/javaparser/pull/3127) by [@4everTheOne](https://github.com/4everTheOne))
+
+### Changed
+
+* Updated workflow to only run one job per PR (PR [#3744](https://github.com/javaparser/javaparser/pull/3744) by [@4everTheOne](https://github.com/4everTheOne))
+* Remove or comment system.out.println statement in unit tests (PR [#3741](https://github.com/javaparser/javaparser/pull/3741) by [@jlerbsc](https://github.com/jlerbsc))
+* Added Optional method in SymbolReference (PR [#3740](https://github.com/javaparser/javaparser/pull/3740) by [@4everTheOne](https://github.com/4everTheOne))
+* Centralized management of symbol solver exceptions to prevent exception type Erasion (PR [#3731](https://github.com/javaparser/javaparser/pull/3731) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Fixed
+
+* Fix issue #1827 Issue resolving a constructor of a class using generics (PR [#3752](https://github.com/javaparser/javaparser/pull/3752) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix issue #3728 ParseProblemException (PR [#3743](https://github.com/javaparser/javaparser/pull/3743) by [@jlerbsc](https://github.com/jlerbsc))
+* Updated Badge for Build and Coverage (PR [#3742](https://github.com/javaparser/javaparser/pull/3742) by [@4everTheOne](https://github.com/4everTheOne))
+* Position (PR [#3734](https://github.com/javaparser/javaparser/pull/3734) by [@ameliagenova](https://github.com/ameliagenova))
+* Fix part of issue #3721 UnsupportedOperationException while trying to modify the type of a variable (PR [#3726](https://github.com/javaparser/javaparser/pull/3726) by [@jlerbsc](https://github.com/jlerbsc))
+* Implemented isReferenceType in `ResolvedTypeDeclaration` and isTypeParameter in `ResolvedTypeParameterDeclaration` (PR [#3206](https://github.com/javaparser/javaparser/pull/3206) by [@4everTheOne](https://github.com/4everTheOne))
+
+### Developer Changes
+
+* chore(deps): bump versions-maven-plugin from 2.12.0 to 2.13.0 (PR [#3727](https://github.com/javaparser/javaparser/pull/3727) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* Fix maven wrapper not found in generator scripts (PR [#3717](https://github.com/javaparser/javaparser/pull/3717) by [@PPazderski](https://github.com/PPazderski))
+* chore(deps): bump actions/checkout from 3.0.2 to 3.1.0 (PR [#3716](https://github.com/javaparser/javaparser/pull/3716) by [@dependabot[bot]](https://github.com/apps/dependabot))
+
+### Uncategorised
+
+* Change issue 1945 test to paramaterized (PR [#3739](https://github.com/javaparser/javaparser/pull/3739) by [@flanbino](https://github.com/flanbino))
+* More unit tests for JavaToken and CodeGenerationUtils (PR [#3736](https://github.com/javaparser/javaparser/pull/3736) by [@ameliagenova](https://github.com/ameliagenova))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@flanbino](https://github.com/flanbino)
+* [@PPazderski](https://github.com/PPazderski)
+* [@ameliagenova](https://github.com/ameliagenova)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@4everTheOne](https://github.com/4everTheOne)
+
+
+
+Version 3.24.7
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/191?closed=1)
+
+### Highlights
+
+* Issue #3415 (PR [#3722](https://github.com/javaparser/javaparser/pull/3722) by [@nelson-ng-96](https://github.com/nelson-ng-96))
+
+### Changed
+
+* Refactoring - use of existing methods (PR [#3697](https://github.com/javaparser/javaparser/pull/3697) by [@jlerbsc](https://github.com/jlerbsc))
+* Refactoring adding convenient methods to know if a DifferenceElement is added, removed or kept (PR [#3695](https://github.com/javaparser/javaparser/pull/3695) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Deprecated
+
+* Issue #3415 (PR [#3722](https://github.com/javaparser/javaparser/pull/3722) by [@nelson-ng-96](https://github.com/nelson-ng-96))
+
+### Fixed
+
+* Fix for ReflectionAnnotationDeclaration getClassName() (PR [#3723](https://github.com/javaparser/javaparser/pull/3723) by [@Blackgen](https://github.com/Blackgen))
+* Fix some yield expressions not recognized (PR [#3714](https://github.com/javaparser/javaparser/pull/3714) by [@PPazderski](https://github.com/PPazderski))
+* Accept final in instanceof pattern (PR [#3713](https://github.com/javaparser/javaparser/pull/3713) by [@PPazderski](https://github.com/PPazderski))
+* [Fix] Avoid test failure due to line separator differences on windows host (PR [#3711](https://github.com/javaparser/javaparser/pull/3711) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix issue #3700 Removing last statement with LexicalPreservingPrinter results in loss of indendation (PR [#3704](https://github.com/javaparser/javaparser/pull/3704) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix issue #3678 Function accepts a configuration but it does not do anything (PR [#3692](https://github.com/javaparser/javaparser/pull/3692) by [@jlerbsc](https://github.com/jlerbsc))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@PPazderski](https://github.com/PPazderski)
+* [@nelson-ng-96](https://github.com/nelson-ng-96)
+* [@Blackgen](https://github.com/Blackgen)
+* [@jlerbsc](https://github.com/jlerbsc)
+
+
+Version 3.24.6
+--------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/190?closed=1)
+
+### API or Behaviour Change
+
+* Issue #3405 thread safety of pre/postprocessors (incl. breaking change to `Processor` with pre/post processor methods). (PR [#3515](https://github.com/javaparser/javaparser/pull/3515) by [@matozoid](https://github.com/matozoid))
+
+### Changed
+
+* chore(deps): bump javassist from 3.29.0-GA to 3.29.1-GA (PR [#3661](https://github.com/javaparser/javaparser/pull/3661) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update junit5 monorepo to v5.9.0 (PR [#3645](https://github.com/javaparser/javaparser/pull/3645) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): bump maven-resources-plugin from 3.2.0 to 3.3.0 (PR [#3644](https://github.com/javaparser/javaparser/pull/3644) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* Flexible symbol resolution for declaration types (PR [#3634](https://github.com/javaparser/javaparser/pull/3634) by [@Col-E](https://github.com/Col-E))
+* Minor refactoring to manage check in range and use hasRange method in class CommentsInserter (PR [#3587](https://github.com/javaparser/javaparser/pull/3587) by [@jlerbsc](https://github.com/jlerbsc))
+* Renaming PACKAGE_PRIVATE to NONE (this refers to the discussion in the issue #2242) (PR [#3573](https://github.com/javaparser/javaparser/pull/3573) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Fixed
+
+* Fix typos (PR [#3675](https://github.com/javaparser/javaparser/pull/3675) by [@mernst](https://github.com/mernst))
+* Fix issue #3614 UnsolvedSymbolException when package declaration contains comment (PR [#3671](https://github.com/javaparser/javaparser/pull/3671) by [@jlerbsc](https://github.com/jlerbsc))
+* chore(deps): update dependency org.apache.maven.plugins:maven-install-plugin to v3.0.0 (PR [#3640](https://github.com/javaparser/javaparser/pull/3640) by [@renovate[bot]](https://github.com/apps/renovate))
+* Fix documentation of `JAVA_17` (PR [#3623](https://github.com/javaparser/javaparser/pull/3623) by [@mernst](https://github.com/mernst))
+* Fix issue 3631 NameExpr.resolve() does not take end of inner block scopes into account (PR [#3613](https://github.com/javaparser/javaparser/pull/3613) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix issue #3588 Modifier is removed when removing an annotation (PR [#3600](https://github.com/javaparser/javaparser/pull/3600) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix lambda generic types that are always resolved to the first type param (PR [#3595](https://github.com/javaparser/javaparser/pull/3595) by [@johannescoetzee](https://github.com/johannescoetzee))
+* Fix issue #3489 SourceRoot.tryToParse() fails if the root path ends with a directory that is not a java identifier (PR [#3551](https://github.com/javaparser/javaparser/pull/3551) by [@jlerbsc](https://github.com/jlerbsc))
+* Default pretty printer should print inner-class receiver parameters on constructors (PR [#3527](https://github.com/javaparser/javaparser/pull/3527) by [@kelloggm](https://github.com/kelloggm))
+* Issue #3405 thread safety of pre/postprocessors (incl. breaking change to `Processor` with pre/post processor methods). (PR [#3515](https://github.com/javaparser/javaparser/pull/3515) by [@matozoid](https://github.com/matozoid))
+
+### Developer Changes
+
+* chore(deps): update dependency org.apache.maven.plugins:maven-install-plugin to v3.0.1 (PR [#3641](https://github.com/javaparser/javaparser/pull/3641) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-deploy-plugin to v3.0.0 (PR [#3639](https://github.com/javaparser/javaparser/pull/3639) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): bump exec-maven-plugin from 3.0.0 to 3.1.0 (PR [#3637](https://github.com/javaparser/javaparser/pull/3637) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update dependency com.squareup.okhttp3:okhttp to v4.10.0 (PR [#3612](https://github.com/javaparser/javaparser/pull/3612) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency biz.aqute.bnd:bnd-maven-plugin to v6.3.1 (PR [#3607](https://github.com/javaparser/javaparser/pull/3607) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-surefire-plugin to v3.0.0-m7 (PR [#3605](https://github.com/javaparser/javaparser/pull/3605) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-inline to v4.6.1 (PR [#3601](https://github.com/javaparser/javaparser/pull/3601) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency biz.aqute.bnd:bnd-maven-plugin to v6.3.0 (PR [#3598](https://github.com/javaparser/javaparser/pull/3598) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.assertj:assertj-core to v3.23.1 (PR [#3596](https://github.com/javaparser/javaparser/pull/3596) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.assertj:assertj-core to v3.23.0 (PR [#3594](https://github.com/javaparser/javaparser/pull/3594) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-scm-plugin to v1.13.0 (PR [#3593](https://github.com/javaparser/javaparser/pull/3593) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-inline to v4.6.0 (PR [#3589](https://github.com/javaparser/javaparser/pull/3589) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.codehaus.mojo:versions-maven-plugin to v2.11.0 (PR [#3585](https://github.com/javaparser/javaparser/pull/3585) by [@renovate[bot]](https://github.com/apps/renovate))
+* fix(deps): update dependency org.javassist:javassist to v3.29.0-ga (PR [#3581](https://github.com/javaparser/javaparser/pull/3581) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.jbehave:jbehave-core to v4.8.3 (PR [#3574](https://github.com/javaparser/javaparser/pull/3574) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): bump codecov/codecov-action from 3.0.0 to 3.1.0 (PR [#3567](https://github.com/javaparser/javaparser/pull/3567) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update actions/checkout action to v3.0.2 (PR [#3565](https://github.com/javaparser/javaparser/pull/3565) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-inline to v4.5.1 (PR [#3564](https://github.com/javaparser/javaparser/pull/3564) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-site-plugin to v3.12.0 (PR [#3561](https://github.com/javaparser/javaparser/pull/3561) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-javadoc-plugin to v3.4.0 (PR [#3560](https://github.com/javaparser/javaparser/pull/3560) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-inline to v4.5.0 (PR [#3557](https://github.com/javaparser/javaparser/pull/3557) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update actions/checkout action to v3.0.1 (PR [#3555](https://github.com/javaparser/javaparser/pull/3555) by [@renovate[bot]](https://github.com/apps/renovate))
+* official Apache Maven wrapper (PR [#3552](https://github.com/javaparser/javaparser/pull/3552) by [@sullis](https://github.com/sullis))
+* chore(deps): update codecov/codecov-action action to v3 (PR [#3545](https://github.com/javaparser/javaparser/pull/3545) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.jacoco:jacoco-maven-plugin to v0.8.8 (PR [#3544](https://github.com/javaparser/javaparser/pull/3544) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-clean-plugin to v3.2.0 (PR [#3542](https://github.com/javaparser/javaparser/pull/3542) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-surefire-plugin to v3.0.0-m6 (PR [#3541](https://github.com/javaparser/javaparser/pull/3541) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### Uncategorised
+
+* Implemented JavaParserTypeVariableDeclaration getAncestors method (PR [#3060](https://github.com/javaparser/javaparser/pull/3060) by [@4everTheOne](https://github.com/4everTheOne))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@sullis](https://github.com/sullis)
+* [@johannescoetzee](https://github.com/johannescoetzee)
+* [@kelloggm](https://github.com/kelloggm)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@mernst](https://github.com/mernst)
+* [@Col-E](https://github.com/Col-E)
+* [@matozoid](https://github.com/matozoid)
+* [@4everTheOne](https://github.com/4everTheOne)
+
+
+Version 3.24.4 - Repeat of 3.24.3
+---------------------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/190?closed=1)
+
+GPG Fingerprint: `253E8E4C6FB28D11748115C1249DEE8E2C07A0A2`
+
+### API or Behaviour Change
+
+* Issue #3405 thread safety of pre/postprocessors (incl. breaking change to `Processor` with pre/post processor methods). (PR [#3515](https://github.com/javaparser/javaparser/pull/3515) by [@matozoid](https://github.com/matozoid))
+
+### Changed
+
+* chore(deps): update junit5 monorepo to v5.9.0 (PR [#3645](https://github.com/javaparser/javaparser/pull/3645) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): bump maven-resources-plugin from 3.2.0 to 3.3.0 (PR [#3644](https://github.com/javaparser/javaparser/pull/3644) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* Flexible symbol resolution for declaration types (PR [#3634](https://github.com/javaparser/javaparser/pull/3634) by [@Col-E](https://github.com/Col-E))
+* Minor refactoring to manage check in range and use hasRange method in class CommentsInserter (PR [#3587](https://github.com/javaparser/javaparser/pull/3587) by [@jlerbsc](https://github.com/jlerbsc))
+* Renaming PACKAGE_PRIVATE to NONE (this refers to the discussion in the issue #2242) (PR [#3573](https://github.com/javaparser/javaparser/pull/3573) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Fixed
+
+* chore(deps): update dependency org.apache.maven.plugins:maven-install-plugin to v3.0.0 (PR [#3640](https://github.com/javaparser/javaparser/pull/3640) by [@renovate[bot]](https://github.com/apps/renovate))
+* Fix documentation of `JAVA_17` (PR [#3623](https://github.com/javaparser/javaparser/pull/3623) by [@mernst](https://github.com/mernst))
+* Fix issue 3631 NameExpr.resolve() does not take end of inner block scopes into account (PR [#3613](https://github.com/javaparser/javaparser/pull/3613) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix issue #3588 Modifier is removed when removing an annotation (PR [#3600](https://github.com/javaparser/javaparser/pull/3600) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix lambda generic types that are always resolved to the first type param (PR [#3595](https://github.com/javaparser/javaparser/pull/3595) by [@johannescoetzee](https://github.com/johannescoetzee))
+* Fix issue #3489 SourceRoot.tryToParse() fails if the root path ends with a directory that is not a java identifier (PR [#3551](https://github.com/javaparser/javaparser/pull/3551) by [@jlerbsc](https://github.com/jlerbsc))
+* Default pretty printer should print inner-class receiver parameters on constructors (PR [#3527](https://github.com/javaparser/javaparser/pull/3527) by [@kelloggm](https://github.com/kelloggm))
+* Issue #3405 thread safety of pre/postprocessors (incl. breaking change to `Processor` with pre/post processor methods). (PR [#3515](https://github.com/javaparser/javaparser/pull/3515) by [@matozoid](https://github.com/matozoid))
+
+### Developer Changes
+
+* chore(deps): update dependency org.apache.maven.plugins:maven-install-plugin to v3.0.1 (PR [#3641](https://github.com/javaparser/javaparser/pull/3641) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-deploy-plugin to v3.0.0 (PR [#3639](https://github.com/javaparser/javaparser/pull/3639) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): bump exec-maven-plugin from 3.0.0 to 3.1.0 (PR [#3637](https://github.com/javaparser/javaparser/pull/3637) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update dependency com.squareup.okhttp3:okhttp to v4.10.0 (PR [#3612](https://github.com/javaparser/javaparser/pull/3612) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency biz.aqute.bnd:bnd-maven-plugin to v6.3.1 (PR [#3607](https://github.com/javaparser/javaparser/pull/3607) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-surefire-plugin to v3.0.0-m7 (PR [#3605](https://github.com/javaparser/javaparser/pull/3605) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-inline to v4.6.1 (PR [#3601](https://github.com/javaparser/javaparser/pull/3601) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency biz.aqute.bnd:bnd-maven-plugin to v6.3.0 (PR [#3598](https://github.com/javaparser/javaparser/pull/3598) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.assertj:assertj-core to v3.23.1 (PR [#3596](https://github.com/javaparser/javaparser/pull/3596) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.assertj:assertj-core to v3.23.0 (PR [#3594](https://github.com/javaparser/javaparser/pull/3594) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-scm-plugin to v1.13.0 (PR [#3593](https://github.com/javaparser/javaparser/pull/3593) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-inline to v4.6.0 (PR [#3589](https://github.com/javaparser/javaparser/pull/3589) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.codehaus.mojo:versions-maven-plugin to v2.11.0 (PR [#3585](https://github.com/javaparser/javaparser/pull/3585) by [@renovate[bot]](https://github.com/apps/renovate))
+* fix(deps): update dependency org.javassist:javassist to v3.29.0-ga (PR [#3581](https://github.com/javaparser/javaparser/pull/3581) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.jbehave:jbehave-core to v4.8.3 (PR [#3574](https://github.com/javaparser/javaparser/pull/3574) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): bump codecov/codecov-action from 3.0.0 to 3.1.0 (PR [#3567](https://github.com/javaparser/javaparser/pull/3567) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update actions/checkout action to v3.0.2 (PR [#3565](https://github.com/javaparser/javaparser/pull/3565) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-inline to v4.5.1 (PR [#3564](https://github.com/javaparser/javaparser/pull/3564) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-site-plugin to v3.12.0 (PR [#3561](https://github.com/javaparser/javaparser/pull/3561) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-javadoc-plugin to v3.4.0 (PR [#3560](https://github.com/javaparser/javaparser/pull/3560) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-inline to v4.5.0 (PR [#3557](https://github.com/javaparser/javaparser/pull/3557) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update actions/checkout action to v3.0.1 (PR [#3555](https://github.com/javaparser/javaparser/pull/3555) by [@renovate[bot]](https://github.com/apps/renovate))
+* official Apache Maven wrapper (PR [#3552](https://github.com/javaparser/javaparser/pull/3552) by [@sullis](https://github.com/sullis))
+* chore(deps): update codecov/codecov-action action to v3 (PR [#3545](https://github.com/javaparser/javaparser/pull/3545) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.jacoco:jacoco-maven-plugin to v0.8.8 (PR [#3544](https://github.com/javaparser/javaparser/pull/3544) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-clean-plugin to v3.2.0 (PR [#3542](https://github.com/javaparser/javaparser/pull/3542) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-surefire-plugin to v3.0.0-m6 (PR [#3541](https://github.com/javaparser/javaparser/pull/3541) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### Uncategorised
+
+* Implemented JavaParserTypeVariableDeclaration getAncestors method (PR [#3060](https://github.com/javaparser/javaparser/pull/3060) by [@4everTheOne](https://github.com/4everTheOne))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@sullis](https://github.com/sullis)
+* [@johannescoetzee](https://github.com/johannescoetzee)
+* [@kelloggm](https://github.com/kelloggm)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@mernst](https://github.com/mernst)
+* [@Col-E](https://github.com/Col-E)
+* [@matozoid](https://github.com/matozoid)
+* [@4everTheOne](https://github.com/4everTheOne)
+
+
+Version 3.24.3
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/190?closed=1)
+
+### API or Behaviour Change
+
+* Issue #3405 thread safety of pre/postprocessors (incl. breaking change to `Processor` with pre/post processor methods). (PR [#3515](https://github.com/javaparser/javaparser/pull/3515) by [@matozoid](https://github.com/matozoid))
+
+### Changed
+
+* Minor refactoring to manage check in range and use hasRange method in class CommentsInserter (PR [#3587](https://github.com/javaparser/javaparser/pull/3587) by [@jlerbsc](https://github.com/jlerbsc))
+* Renaming PACKAGE_PRIVATE to NONE (this refers to the discussion in the issue #2242) (PR [#3573](https://github.com/javaparser/javaparser/pull/3573) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Fixed
+
+* Fix documentation of `JAVA_17` (PR [#3623](https://github.com/javaparser/javaparser/pull/3623) by [@mernst](https://github.com/mernst))
+* Fix issue 3631 NameExpr.resolve() does not take end of inner block scopes into account (PR [#3613](https://github.com/javaparser/javaparser/pull/3613) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix issue #3588 Modifier is removed when removing an annotation (PR [#3600](https://github.com/javaparser/javaparser/pull/3600) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix lambda generic types that are always resolved to the first type param (PR [#3595](https://github.com/javaparser/javaparser/pull/3595) by [@johannescoetzee](https://github.com/johannescoetzee))
+* Fix issue #3489 SourceRoot.tryToParse() fails if the root path ends with a directory that is not a java identifier (PR [#3551](https://github.com/javaparser/javaparser/pull/3551) by [@jlerbsc](https://github.com/jlerbsc))
+* Default pretty printer should print inner-class receiver parameters on constructors (PR [#3527](https://github.com/javaparser/javaparser/pull/3527) by [@kelloggm](https://github.com/kelloggm))
+* Issue #3405 thread safety of pre/postprocessors (incl. breaking change to `Processor` with pre/post processor methods). (PR [#3515](https://github.com/javaparser/javaparser/pull/3515) by [@matozoid](https://github.com/matozoid))
+
+### Developer Changes
+
+* chore(deps): update actions/checkout action to v3.0.1 (PR [#3555](https://github.com/javaparser/javaparser/pull/3555) by [@renovate[bot]](https://github.com/apps/renovate))
+* official Apache Maven wrapper (PR [#3552](https://github.com/javaparser/javaparser/pull/3552) by [@sullis](https://github.com/sullis))
+* chore(deps): update codecov/codecov-action action to v3 (PR [#3545](https://github.com/javaparser/javaparser/pull/3545) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.jacoco:jacoco-maven-plugin to v0.8.8 (PR [#3544](https://github.com/javaparser/javaparser/pull/3544) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-clean-plugin to v3.2.0 (PR [#3542](https://github.com/javaparser/javaparser/pull/3542) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-surefire-plugin to v3.0.0-m6 (PR [#3541](https://github.com/javaparser/javaparser/pull/3541) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@sullis](https://github.com/sullis)
+* [@johannescoetzee](https://github.com/johannescoetzee)
+* [@kelloggm](https://github.com/kelloggm)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@mernst](https://github.com/mernst)
+* [@matozoid](https://github.com/matozoid)
+
+Version 3.24.2
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/188?closed=1)
+
+GPG Fingerprint: `253E8E4C6FB28D11748115C1249DEE8E2C07A0A2`
+
+### Added
+
+* Improve unit test for BlockStmtContextResolutionTest (PR [#3530](https://github.com/javaparser/javaparser/pull/3530) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Changed
+
+* Improve Conditional Operator resolution [JLS 15.25] (PR [#3522](https://github.com/javaparser/javaparser/pull/3522) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Fixed
+
+* Fix issue #3526 Variable or FieldDeclaration is not resolved correctl… (PR [#3529](https://github.com/javaparser/javaparser/pull/3529) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* Bump jbehave-junit-runner from 2.3.0 to 2.3.1 (PR [#3531](https://github.com/javaparser/javaparser/pull/3531) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* Bump actions/cache from 2.1.7 to 3 (PR [#3525](https://github.com/javaparser/javaparser/pull/3525) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* Update JDK 18 and add JDK 19 feature details to FEATURES.md (PR [#3521](https://github.com/javaparser/javaparser/pull/3521) by [@MysterAitch](https://github.com/MysterAitch))
+* Bump maven-dependency-plugin from 3.2.0 to 3.3.0 (PR [#3514](https://github.com/javaparser/javaparser/pull/3514) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update dependency org.apache.maven.plugins:maven-dependency-plugin to v3.3.0 (PR [#3512](https://github.com/javaparser/javaparser/pull/3512) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-compiler-plugin to v3.10.1 (PR [#3511](https://github.com/javaparser/javaparser/pull/3511) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update actions/checkout action (PR [#3508](https://github.com/javaparser/javaparser/pull/3508) by [@renovate[bot]](https://github.com/apps/renovate))
+* Bump bnd-maven-plugin from 6.1.0 to 6.2.0 (PR [#3505](https://github.com/javaparser/javaparser/pull/3505) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update dependency biz.aqute.bnd:bnd-maven-plugin to v6.2.0 (PR [#3503](https://github.com/javaparser/javaparser/pull/3503) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update actions/setup-java action to v3 (PR [#3502](https://github.com/javaparser/javaparser/pull/3502) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@MysterAitch](https://github.com/MysterAitch)
+* [@jlerbsc](https://github.com/jlerbsc)
+
+
+Version 3.24.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/189?closed=1)
+
+### Fixed
+
+* Adding constructor descriptor (PR [#3499](https://github.com/javaparser/javaparser/pull/3499) by [@kanghj](https://github.com/kanghj))
+* Fix issue #3491 Method has a multidimensional arrays argument in jar … (PR [#3493](https://github.com/javaparser/javaparser/pull/3493) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix issue #3218 GetSourceRoots() does not return all source roots (PR [#3485](https://github.com/javaparser/javaparser/pull/3485) by [@jlerbsc](https://github.com/jlerbsc))
+* Bug in ArrayCreationExpr constructors (PR [#3473](https://github.com/javaparser/javaparser/pull/3473) by [@sergekukharev](https://github.com/sergekukharev))
+* Fix issue 3440 Removing a node with LexicalPreservingPrinter causes UnsupportedOperationException (PR [#3449](https://github.com/javaparser/javaparser/pull/3449) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* chore(deps): update dependency org.codehaus.mojo:versions-maven-plugin to v2.10.0 (PR [#3517](https://github.com/javaparser/javaparser/pull/3517) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v4.4.0 (PR [#3510](https://github.com/javaparser/javaparser/pull/3510) by [@renovate[bot]](https://github.com/apps/renovate))
+* fix(deps): update dependency com.google.guava:guava to v31.1-jre (PR [#3507](https://github.com/javaparser/javaparser/pull/3507) by [@renovate[bot]](https://github.com/apps/renovate))
+* Bump guava from 31.0.1-jre to 31.1-jre (PR [#3506](https://github.com/javaparser/javaparser/pull/3506) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update dependency org.apache.maven.plugins:maven-site-plugin to v3.11.0 (PR [#3496](https://github.com/javaparser/javaparser/pull/3496) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-compiler-plugin to v3.10.0 (PR [#3494](https://github.com/javaparser/javaparser/pull/3494) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-javadoc-plugin to v3.3.2 (PR [#3492](https://github.com/javaparser/javaparser/pull/3492) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v4.3.1 (PR [#3481](https://github.com/javaparser/javaparser/pull/3481) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v4.3.0 (PR [#3479](https://github.com/javaparser/javaparser/pull/3479) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.codehaus.mojo:versions-maven-plugin to v2.9.0 (PR [#3477](https://github.com/javaparser/javaparser/pull/3477) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-jar-plugin to v3.2.2 (PR [#3470](https://github.com/javaparser/javaparser/pull/3470) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-compiler-plugin to v3.9.0 (PR [#3469](https://github.com/javaparser/javaparser/pull/3469) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency com.helger.maven:ph-javacc-maven-plugin to v4.1.5 (PR [#3468](https://github.com/javaparser/javaparser/pull/3468) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency com.github.javaparser:javaparser-parent to v3 (PR [#3465](https://github.com/javaparser/javaparser/pull/3465) by [@renovate[bot]](https://github.com/apps/renovate))
+* Partial revert of #3462 (removed GitHub Action) (PR [#3464](https://github.com/javaparser/javaparser/pull/3464) by [@MysterAitch](https://github.com/MysterAitch))
+* Updated release script to be non-interactive, and added option to use a manually-triggered GitHub Action to build a release (PR [#3462](https://github.com/javaparser/javaparser/pull/3462) by [@MysterAitch](https://github.com/MysterAitch))
+* chore(deps): update dependency org.apache.maven.plugins:maven-jar-plugin to v3.2.1 (PR [#3459](https://github.com/javaparser/javaparser/pull/3459) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.codehaus.mojo:build-helper-maven-plugin to v3.3.0 (PR [#3458](https://github.com/javaparser/javaparser/pull/3458) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.assertj:assertj-core to v3.22.0 (PR [#3457](https://github.com/javaparser/javaparser/pull/3457) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-scm-plugin to v1.12.2 (PR [#3456](https://github.com/javaparser/javaparser/pull/3456) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-deploy-plugin to v3.0.0-m2 (PR [#3453](https://github.com/javaparser/javaparser/pull/3453) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### Uncategorised
+
+* Fix the release gha, originally submitted in #3462 (PR [#3463](https://github.com/javaparser/javaparser/pull/3463) by [@MysterAitch](https://github.com/MysterAitch))
+* Update changelog.md to contain 3.24.0 changes, and prepare for 3.24.1 (PR [#3461](https://github.com/javaparser/javaparser/pull/3461) by [@MysterAitch](https://github.com/MysterAitch))
+* Update changelog.md (PR [#3460](https://github.com/javaparser/javaparser/pull/3460) by [@MysterAitch](https://github.com/MysterAitch))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@MysterAitch](https://github.com/MysterAitch)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@kanghj](https://github.com/kanghj)
+* [@sergekukharev](https://github.com/sergekukharev)
+
+
+Version 3.24.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/187?closed=1)
+
+### Added
+
+* Add erasure on parametrized type (PR [#3438](https://github.com/javaparser/javaparser/pull/3438) by [@jlerbsc](https://github.com/jlerbsc))
+* Add test cases for `NoChange` API (PR [#3431](https://github.com/javaparser/javaparser/pull/3431) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Changed
+
+* Minor refactoring on `LexicalreservingPrinter` especially in the class `Difference` (PR [#3424](https://github.com/javaparser/javaparser/pull/3424) by [@jlerbsc](https://github.com/jlerbsc))
+* Update the readme with `@pedrombmachado` 's suggestions (#3357), and also to switch from `mvn` to `mvnw` within some sample instructions (PR [#3420](https://github.com/javaparser/javaparser/pull/3420) by [@MysterAitch](https://github.com/MysterAitch))
+* Reducing deeply nested logic in `MethodResolutionLogic` (work in progress) (PR [#3411](https://github.com/javaparser/javaparser/pull/3411) by [@jlerbsc](https://github.com/jlerbsc))
+* Reducing deeply nested logic in `MethodResolutionLogic` (PR [#3409](https://github.com/javaparser/javaparser/pull/3409) by [@jlerbsc](https://github.com/jlerbsc))
+* Improved `RemoveMethodGenerator` and `ReplaceMethodGenerator` to only override super when needed. (PR [#3248](https://github.com/javaparser/javaparser/pull/3248) by [@4everTheOne](https://github.com/4everTheOne))
+* Reduced complexity for methods in `JavaParserFacade` (PR [#3204](https://github.com/javaparser/javaparser/pull/3204) by [@4everTheOne](https://github.com/4everTheOne))
+
+### Fixed
+
+* Fix issue #3436 `getAncestors()`/`getAllAncestors()` does not work if base class starts with the same name (PR [#3437](https://github.com/javaparser/javaparser/pull/3437) by [@jlerbsc](https://github.com/jlerbsc))
+* Add a missing `hashCode()` method (PR [#3432](https://github.com/javaparser/javaparser/pull/3432) by [@msridhar](https://github.com/msridhar))
+* Call `orElse()` instead of `orElseGet()` (PR [#3430](https://github.com/javaparser/javaparser/pull/3430) by [@msridhar](https://github.com/msridhar))
+* Fix issue #3408 `LexicalPreservationPrinter` fails to add annotation to a class field decalared with fully qualified name (PR [#3429](https://github.com/javaparser/javaparser/pull/3429) by [@jlerbsc](https://github.com/jlerbsc))
+* Issue #3419 - Fixed bug in `Difference.java` (PR [#3428](https://github.com/javaparser/javaparser/pull/3428) by [@4everTheOne](https://github.com/4everTheOne))
+* Issue #3406 `ParseProblemException` when parsing char `\u005cn` (PR [#3407](https://github.com/javaparser/javaparser/pull/3407) by [@apixandru](https://github.com/apixandru))
+* Fix issue #3399 Failed to resolve methods that evaluate as argument (PR [#3401](https://github.com/javaparser/javaparser/pull/3401) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix resoure leak due to `File.walk` (PR [#3398](https://github.com/javaparser/javaparser/pull/3398) by [@lujiefsi](https://github.com/lujiefsi))
+* Fix issue #2259 Type resolution issue when type of formal parameter is Object (PR [#3397](https://github.com/javaparser/javaparser/pull/3397) by [@jlerbsc](https://github.com/jlerbsc))
+* Fixes an issue where `JavaParserTypeSolver` ignores the character encoding configuration. (PR [#3396](https://github.com/javaparser/javaparser/pull/3396) by [@crucoba](https://github.com/crucoba))
+* Issue #3272 resolve lambda exp type (PR [#3273](https://github.com/javaparser/javaparser/pull/3273) by [@si-e](https://github.com/si-e))
+* Issue #3200 `this` exp in anonymous class (PR [#3268](https://github.com/javaparser/javaparser/pull/3268) by [@si-e](https://github.com/si-e))
+
+### Developer Changes
+
+* Partial revert of #3462 (removed GitHub Action) (PR [#3464](https://github.com/javaparser/javaparser/pull/3462) by [@MysterAitch](https://github.com/MysterAitch))
+* Updated release script to be non-interactive, and added option to use a manually-triggered GitHub Action to build a release (PR [#3462](https://github.com/javaparser/javaparser/pull/3462) by [@MysterAitch](https://github.com/MysterAitch))
+* chore(deps): update dependency org.apache.maven.plugins:maven-jar-plugin to v3.2.1 (PR [#3459](https://github.com/javaparser/javaparser/pull/3459) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.codehaus.mojo:build-helper-maven-plugin to v3.3.0 (PR [#3458](https://github.com/javaparser/javaparser/pull/3458) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.assertj:assertj-core to v3.22.0 (PR [#3457](https://github.com/javaparser/javaparser/pull/3457) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-scm-plugin to v1.12.2 (PR [#3456](https://github.com/javaparser/javaparser/pull/3456) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-deploy-plugin to v3.0.0-m2 (PR [#3453](https://github.com/javaparser/javaparser/pull/3453) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-site-plugin to v3.10.0 (PR [#3448](https://github.com/javaparser/javaparser/pull/3448) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v4.2.0 (PR [#3442](https://github.com/javaparser/javaparser/pull/3442) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update junit5 monorepo to v5.8.2 (PR [#3425](https://github.com/javaparser/javaparser/pull/3425) by [@renovate[bot]](https://github.com/apps/renovate))
+* Update / document `codecov.yml` (PR [#3418](https://github.com/javaparser/javaparser/pull/3418) by [@MysterAitch](https://github.com/MysterAitch))
+* chore(deps): update actions/cache action to v2.1.7 (PR [#3417](https://github.com/javaparser/javaparser/pull/3417) by [@renovate[bot]](https://github.com/apps/renovate))
+* Bump bnd-maven-plugin from 6.0.0 to 6.1.0 (PR [#3416](https://github.com/javaparser/javaparser/pull/3416) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update dependency biz.aqute.bnd:bnd-maven-plugin to v6.1.0 (PR [#3414](https://github.com/javaparser/javaparser/pull/3414) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency com.squareup.okhttp3:okhttp to v4.9.3 (PR [#3413](https://github.com/javaparser/javaparser/pull/3413) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update actions/checkout action to v2.4.0 (PR [#3402](https://github.com/javaparser/javaparser/pull/3402) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update actions/checkout action to v2.3.5 (PR [#3395](https://github.com/javaparser/javaparser/pull/3395) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v4 (PR [#3393](https://github.com/javaparser/javaparser/pull/3393) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@crucoba](https://github.com/crucoba)
+* [@msridhar](https://github.com/msridhar)
+* [@MysterAitch](https://github.com/MysterAitch)
+* [@lujiefsi](https://github.com/lujiefsi)
+* [@apixandru](https://github.com/apixandru)
+* [@si-e](https://github.com/si-e)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@4everTheOne](https://github.com/4everTheOne)
+
+
+
+Version 3.23.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/186?closed=1)
+
+### Fixed
+
+* `record` may be used as variable name in Java 16 (PR [#3362](https://github.com/javaparser/javaparser/pull/3362) by [@koppor](github.com/koppor/))
+
+### API or Behaviour Change
+
+* Java 11 is now the most used version (PR [#3301](https://github.com/javaparser/javaparser/pull/3301) by [@matozoid](https://github.com/matozoid))
+
+### Added
+
+* Manage `@Inherited` annotation to prepare the fix on the issue 1843 (PR [#3383](https://github.com/javaparser/javaparser/pull/3383) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Changed
+
+* Configurable caching system for type solvers (PR [#3343](https://github.com/javaparser/javaparser/pull/3343) by [@4everTheOne](https://github.com/4everTheOne))
+* Java 11 is now the most used version (PR [#3301](https://github.com/javaparser/javaparser/pull/3301) by [@matozoid](https://github.com/matozoid))
+
+### Fixed
+
+* Fix issue 3387 LexicalPreservingPrinter adds wrong indentation when adding new comments (PR [#3392](https://github.com/javaparser/javaparser/pull/3392) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix issue 2360 Symbol Solver is missing promotion of byte, char, and short in unary expressions (PR [#3384](https://github.com/javaparser/javaparser/pull/3384) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix "record" as non-type identifier in Java 16 (PR [#3362](https://github.com/javaparser/javaparser/pull/3362) by [@koppor](https://github.com/koppor))
+* Fix issue 3358 LexicalPreservingPrinter error on ArrayType (PR [#3359](https://github.com/javaparser/javaparser/pull/3359) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Developer Changes
+
+* generate changelog for milestones - scripts included to do this by milestone id, milestone title, and a github action to add the output to a draft snapshot release (PR [#3391](https://github.com/javaparser/javaparser/pull/3391) by [@MysterAitch](https://github.com/MysterAitch))
+* Bump bnd-maven-plugin from 5.3.0 to 6.0.0 (PR [#3390](https://github.com/javaparser/javaparser/pull/3390) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update dependency biz.aqute.bnd:bnd-maven-plugin to v6 (PR [#3389](https://github.com/javaparser/javaparser/pull/3389) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency com.squareup.okhttp3:okhttp to v4.9.2 (PR [#3388](https://github.com/javaparser/javaparser/pull/3388) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency com.google.guava:guava to v31.0.1-jre (PR [#3385](https://github.com/javaparser/javaparser/pull/3385) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency com.google.guava:guava to v31 (PR [#3381](https://github.com/javaparser/javaparser/pull/3381) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update junit5 monorepo to v5.8.1 (PR [#3380](https://github.com/javaparser/javaparser/pull/3380) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.assertj:assertj-core to v3.21.0 (PR [#3378](https://github.com/javaparser/javaparser/pull/3378) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-scm-plugin to v1.12.0 (PR [#3376](https://github.com/javaparser/javaparser/pull/3376) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update codecov/codecov-action action to v2.1.0 (PR [#3373](https://github.com/javaparser/javaparser/pull/3373) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update junit5 monorepo to v5.8.0 (PR [#3372](https://github.com/javaparser/javaparser/pull/3372) by [@renovate[bot]](https://github.com/apps/renovate))
+* remove accidentally-added pom release backup files, and added it to gitignore to prevent them being re-added (PR [#3370](https://github.com/javaparser/javaparser/pull/3370) by [@MysterAitch](https://github.com/MysterAitch))
+* chore(deps): update dependency org.apache.maven.plugins:maven-javadoc-plugin to v3.3.1 (PR [#3368](https://github.com/javaparser/javaparser/pull/3368) by [@renovate[bot]](https://github.com/apps/renovate))
+* Reduce mvn verbosity on GitHub actions (and switch to mvnw) (PR [#3363](https://github.com/javaparser/javaparser/pull/3363) by [@koppor](https://github.com/koppor))
+
+### Uncategorised
+
+* Prepare changelog for next version (PR [#3354](https://github.com/javaparser/javaparser/pull/3354) by [@MysterAitch](https://github.com/MysterAitch))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@MysterAitch](https://github.com/MysterAitch)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@koppor](https://github.com/koppor)
+* [@4everTheOne](https://github.com/4everTheOne)
+* [@matozoid](https://github.com/matozoid)
+
+
+Version 3.23.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/185?closed=1)
+
+### Added
+
+* Improving `toString` on CSM classes (PR [#3315](https://github.com/javaparser/javaparser/pull/3315) by [@jlerbsc](https://github.com/jlerbsc))
+* Add test case for issue #2210 Resolution of Method References (PR [#3310](https://github.com/javaparser/javaparser/pull/3310) by [@jlerbsc](https://github.com/jlerbsc))
+* Implemented method reference resolution on expressions (PR [#3307](https://github.com/javaparser/javaparser/pull/3307) by [@maartenc](https://github.com/maartenc))
+* Define if a field is volatile through the ResolvedFieldDeclaration interface - from issue #3240 (PR [#3276](https://github.com/javaparser/javaparser/pull/3276) by [@jlerbsc](https://github.com/jlerbsc))
+* Implemented logic for internalTypes in `JavaParserAnnotationDeclaration` and `JavassistAnnotationDeclaration` (PR [#3215](https://github.com/javaparser/javaparser/pull/3215) by [@4everTheOne](https://github.com/4everTheOne))
+
+### Changed
+
+* Check if ancestor also for super class (PR [#3324](https://github.com/javaparser/javaparser/pull/3324) by [@ReallyLiri](https://github.com/ReallyLiri))
+* Remove useless instanceof usage in Type (PR [#3311](https://github.com/javaparser/javaparser/pull/3311) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix Java 11+ AST postprocessing (PR [#3302](https://github.com/javaparser/javaparser/pull/3302) by [@matozoid](https://github.com/matozoid))
+* Move duplicate code to JavaParserTypeAdapter (PR [#3267](https://github.com/javaparser/javaparser/pull/3267) by [@maartenc](https://github.com/maartenc))
+* Improved performance when resolving types for big source files (PR [#3265](https://github.com/javaparser/javaparser/pull/3265) by [@maartenc](https://github.com/maartenc))
+* Optimizations for Node class (CPU time and Memory usage) (PR [#3233](https://github.com/javaparser/javaparser/pull/3233) by [@4everTheOne](https://github.com/4everTheOne))
+* Fix Javadoc comment * escaping problem. (PR [#3221](https://github.com/javaparser/javaparser/pull/3221) by [@matozoid](https://github.com/matozoid))
+* Remove broken link (PR [#2912](https://github.com/javaparser/javaparser/pull/2912) by [@mernst](https://github.com/mernst))
+
+### Fixed
+
+* Preserving field order when getting the fields declared from a ReferenceType (PR [#3342](https://github.com/javaparser/javaparser/pull/3342) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix String Index out of range in TextBlockLiteralExpr (PR [#3337](https://github.com/javaparser/javaparser/pull/3337) by [@134ARG](https://github.com/134ARG))
+* Fixed prettyprinting new switch-statements (and switch-expressions). (PR [#3335](https://github.com/javaparser/javaparser/pull/3335) by [@kozsik](https://github.com/kozsik))
+* Fix pretty printing of generic records (PR [#3334](https://github.com/javaparser/javaparser/pull/3334) by [@twistedsquare](https://github.com/twistedsquare))
+* Fix issue #3317 Comment in the middle of a multi-line single statement (PR [#3318](https://github.com/javaparser/javaparser/pull/3318) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix issue 3296 LexicalPreservation bug for array brackets (PR [#3316](https://github.com/javaparser/javaparser/pull/3316) by [@jlerbsc](https://github.com/jlerbsc))
+* Fixes Issue #3308 -- stackoverflow when resolving the `FieldAccessExpr` of an `ArrayAccessExpr` (PR [#3312](https://github.com/javaparser/javaparser/pull/3312) by [@MysterAitch](https://github.com/MysterAitch))
+* Fix StackOverflow when resolving ClassOrInterfaceType of nested ObjectCreationExpr (PR [#3279](https://github.com/javaparser/javaparser/pull/3279) by [@maartenc](https://github.com/maartenc))
+* ResolvedMethods from javassist never had exceptions (PR [#3264](https://github.com/javaparser/javaparser/pull/3264) by [@maartenc](https://github.com/maartenc))
+* Issue 3064 conditional nested lambda (PR [#3238](https://github.com/javaparser/javaparser/pull/3238) by [@si-e](https://github.com/si-e))
+* Further optimization in resolving in StatementContext (PR [#3185](https://github.com/javaparser/javaparser/pull/3185) by [@Col-E](https://github.com/Col-E))
+* Improve type resolution for duplicate names (PR [#3012](https://github.com/javaparser/javaparser/pull/3012) by [@thejk](https://github.com/thejk))
+
+### Developer Changes
+
+* chore(deps): update dependency org.mockito:mockito-core to v3.12.4 (PR [#3350](https://github.com/javaparser/javaparser/pull/3350) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v3.12.3 (PR [#3349](https://github.com/javaparser/javaparser/pull/3349) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update codecov/codecov-action action to v2.0.3 (PR [#3348](https://github.com/javaparser/javaparser/pull/3348) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v3.12.2 (PR [#3347](https://github.com/javaparser/javaparser/pull/3347) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v3.12.1 (PR [#3345](https://github.com/javaparser/javaparser/pull/3345) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v3.12.0 (PR [#3344](https://github.com/javaparser/javaparser/pull/3344) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-scm-plugin to v1.11.3 (PR [#3339](https://github.com/javaparser/javaparser/pull/3339) by [@renovate[bot]](https://github.com/apps/renovate))
+* Bump codecov/codecov-action from 1.5.2 to 2.0.2 (PR [#3326](https://github.com/javaparser/javaparser/pull/3326) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* chore(deps): update dependency org.mockito:mockito-core to v3.11.2 (PR [#3305](https://github.com/javaparser/javaparser/pull/3305) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.assertj:assertj-core to v3.20.2 (PR [#3297](https://github.com/javaparser/javaparser/pull/3297) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.assertj:assertj-core to v3.20.0 (PR [#3295](https://github.com/javaparser/javaparser/pull/3295) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-dependency-plugin to v3.2.0 (PR [#3294](https://github.com/javaparser/javaparser/pull/3294) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v3.11.1 (PR [#3293](https://github.com/javaparser/javaparser/pull/3293) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update codecov/codecov-action action to v1.5.2 (PR [#3287](https://github.com/javaparser/javaparser/pull/3287) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v3.11.0 (PR [#3285](https://github.com/javaparser/javaparser/pull/3285) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update actions/cache action to v2.1.6 (PR [#3280](https://github.com/javaparser/javaparser/pull/3280) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-javadoc-plugin to v3.3.0 (PR [#3270](https://github.com/javaparser/javaparser/pull/3270) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update junit5 monorepo to v5.7.2 (PR [#3262](https://github.com/javaparser/javaparser/pull/3262) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.apache.maven.plugins:maven-gpg-plugin to v3 (PR [#3250](https://github.com/javaparser/javaparser/pull/3250) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@maartenc](https://github.com/maartenc)
+* [@kozsik](https://github.com/kozsik)
+* [@ReallyLiri](https://github.com/ReallyLiri)
+* [@mernst](https://github.com/mernst)
+* [@matozoid](https://github.com/matozoid)
+* [@Col-E](https://github.com/Col-E)
+* [@134ARG](https://github.com/134ARG)
+* [@MysterAitch](https://github.com/MysterAitch)
+* [@si-e](https://github.com/si-e)
+* [@thejk](https://github.com/thejk)
+* [@twistedsquare](https://github.com/twistedsquare)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@4everTheOne](https://github.com/4everTheOne)
+
+
+
+Version 3.22.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/184?closed=1)
+
+### Added
+
+* Recover wrong statements no only to ';', but to '}' (not including) as well (PR [#3247](https://github.com/javaparser/javaparser/pull/3247) by [@32kda](https://github.com/32kda))
+
+### Fixed
+
+* update features.md -- fixed release version and date of records support, status of java 16 sealed classes to 2nd preview, and java 17 features (PR [#3263](https://github.com/javaparser/javaparser/pull/3263) by [@MysterAitch](https://github.com/MysterAitch))
+* fixes #3255 -- bugfix grammar case when using `record` to as an identifier (PR [#3256](https://github.com/javaparser/javaparser/pull/3256) by [@MysterAitch](https://github.com/MysterAitch))
+* Fixes issue #3113 -- Arrow missing in Switch Expression + jumbled up in LexicalPreservingPrinter (PR [#3235](https://github.com/javaparser/javaparser/pull/3235) by [@Zoom1111](https://github.com/Zoom1111))
+* Handle possibility of tokens not being available (PR [#3231](https://github.com/javaparser/javaparser/pull/3231) by [@mernst](https://github.com/mernst))
+
+### Developer Changes
+
+* chore(deps): update dependency org.mockito:mockito-core to v3.10.0 (PR [#3259](https://github.com/javaparser/javaparser/pull/3259) by [@renovate[bot]](https://github.com/apps/renovate))
+* Bump codecov/codecov-action from 1 to 1.5.0 (PR [#3258](https://github.com/javaparser/javaparser/pull/3258) by [@dependabot[bot]](https://github.com/apps/dependabot))
+* Bump actions/create-release from 1 to 1.1.4 (PR [#3257](https://github.com/javaparser/javaparser/pull/3257) by [@dependabot[bot]](https://github.com/apps/dependabot))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@32kda](https://github.com/32kda)
+* [@MysterAitch](https://github.com/MysterAitch)
+* [@Zoom1111](https://github.com/Zoom1111)
+* [@mernst](https://github.com/mernst)
+
+
+
+Version 3.22.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/183?closed=1)
+
+
+### API or Behaviour Change
+
+* Implemented isAssignableBy for VoidType - now return `false` instead of throwing `UnsupportedOperationException` (PR [#3197](https://github.com/javaparser/javaparser/pull/3197) by [@4everTheOne](https://github.com/4everTheOne))
+* fixed ellipsis and doublecolon to be categorised as separators not operators (fixes #2897) (PR [#2924](https://github.com/javaparser/javaparser/pull/2924) by [@MysterAitch](https://github.com/MysterAitch))
+
+### Added
+
+* Update parser configuration and validators to include the release of java 16, and java 17 being in development (PR [#3222](https://github.com/javaparser/javaparser/pull/3222) by [@MysterAitch](https://github.com/MysterAitch))
+* Adding convenient methods to find out if a method is a variable/fixed arity method (PR [#3196](https://github.com/javaparser/javaparser/pull/3196) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix issue #3173: Add isAnnotation() and asAnnotation() methods for ResolvedTypeDeclaration (PR [#3187](https://github.com/javaparser/javaparser/pull/3187) by [@deadlocklogic](https://github.com/deadlocklogic))
+* Record support (compilation / parsing only, solving to follow separately) (PR [#3022](https://github.com/javaparser/javaparser/pull/3022) by [@MysterAitch](https://github.com/MysterAitch))
+
+### Changed
+
+* Implemented isAssignableBy for VoidType - now return `false` instead of throwing `UnsupportedOperationException` (PR [#3197](https://github.com/javaparser/javaparser/pull/3197) by [@4everTheOne](https://github.com/4everTheOne))
+* Simplify how to find the package name from AstResolutionUtils (PR [#3193](https://github.com/javaparser/javaparser/pull/3193) by [@jlerbsc](https://github.com/jlerbsc))
+* Type resolution improvment (PR [#3189](https://github.com/javaparser/javaparser/pull/3189) by [@jlerbsc](https://github.com/jlerbsc))
+* Memory optimization for JarTypeSolver (Up to 42% less memory) (PR [#3188](https://github.com/javaparser/javaparser/pull/3188) by [@4everTheOne](https://github.com/4everTheOne))
+* Fixes #3048 (`JavaParserSymbolDeclaration#localVar` returning old declaration) and adds tests for `JavaParserSymbolDeclaration` (PR [#3049](https://github.com/javaparser/javaparser/pull/3049) by [@4everTheOne](https://github.com/4everTheOne))
+
+### Fixed
+
+* Fix issue #3244 OrphanComment in BlockStmt not appearing (PR [#3245](https://github.com/javaparser/javaparser/pull/3245) by [@jlerbsc](https://github.com/jlerbsc))
+* fix Log.error() throwing NullPointerException (PR [#3243](https://github.com/javaparser/javaparser/pull/3243) by [@CD4017BE](https://github.com/CD4017BE))
+* fixed ellipsis and doublecolon to be categorised as separators not operators (fixes #2897) (PR [#2924](https://github.com/javaparser/javaparser/pull/2924) by [@MysterAitch](https://github.com/MysterAitch))
+
+### Developer Changes
+
+* Include and use a Maven wrapper (PR [#3254](https://github.com/javaparser/javaparser/pull/3254) by [@MysterAitch](https://github.com/MysterAitch))
+* chore(deps): update dependency org.javassist:javassist to v3.28.0-ga (PR [#3249](https://github.com/javaparser/javaparser/pull/3249) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.jacoco:jacoco-maven-plugin to v0.8.7 (PR [#3246](https://github.com/javaparser/javaparser/pull/3246) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update actions/cache action to v2.1.5 (PR [#3226](https://github.com/javaparser/javaparser/pull/3226) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update dependency org.mockito:mockito-core to v3.9.0 (PR [#3224](https://github.com/javaparser/javaparser/pull/3224) by [@renovate[bot]](https://github.com/apps/renovate))
+* chore(deps): update actions/setup-java action to v2 (PR [#3220](https://github.com/javaparser/javaparser/pull/3220) by [@renovate[bot]](https://github.com/apps/renovate))
+* Update javaparser copyright headers (PR [#3212](https://github.com/javaparser/javaparser/pull/3212) by [@jlerbsc](https://github.com/jlerbsc))
+* Update readme template so that #3096 becomes permanent (PR [#3210](https://github.com/javaparser/javaparser/pull/3210) by [@MysterAitch](https://github.com/MysterAitch))
+* Improve tests on `getAllAncestors` method (PR [#3209](https://github.com/javaparser/javaparser/pull/3209) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix surefire configuration to allow jacoco to run correctly on JSS tests (PR [#3208](https://github.com/javaparser/javaparser/pull/3208) by [@MysterAitch](https://github.com/MysterAitch))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@MysterAitch](https://github.com/MysterAitch)
+* [@CD4017BE](https://github.com/CD4017BE)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@deadlocklogic](https://github.com/deadlocklogic)
+* [@4everTheOne](https://github.com/4everTheOne)
+
+Version 3.21.2
+------------------
+**v3.21.1 released as 3.21.2 without change**
+
+Version 3.21.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/182?closed=1)
+
+### Added
+
+* Implemented logic for isAssignableBy in JavassistInterfaceDeclaration (PR [#3170](https://github.com/javaparser/javaparser/pull/3170) by [@4everTheOne](https://github.com/4everTheOne))
+* Added additional tests to cover isAssignableBy method in JavassistClassDeclaration (PR [#3169](https://github.com/javaparser/javaparser/pull/3169) by [@4everTheOne](https://github.com/4everTheOne))
+
+### Changed
+
+* Update changelog (PR [#3178](https://github.com/javaparser/javaparser/pull/3178) by [@MysterAitch](https://github.com/MysterAitch))
+* Minor performance improvement on getCanonicalName method call (PR [#3166](https://github.com/javaparser/javaparser/pull/3166) by [@jlerbsc](https://github.com/jlerbsc))
+
+### Fixed
+
+* Fix Issue #1950 Unambigous ambiguity call with generics and lambda's (PR [#3168](https://github.com/javaparser/javaparser/pull/3168) by [@jlerbsc](https://github.com/jlerbsc))
+* Refactor the javassist implementation to delegate to the typesolver instead of using its own classpool (PR [#3167](https://github.com/javaparser/javaparser/pull/3167) by [@maartenc](https://github.com/maartenc))
+* Fixed name resolution in casted lambda expressions (PR [#3165](https://github.com/javaparser/javaparser/pull/3165) by [@maartenc](https://github.com/maartenc))
+* Fix issue #3159 JavaParserSymbolDeclaration is used to represent variables, but #isVariable() always returns false (PR [#3160](https://github.com/javaparser/javaparser/pull/3160) by [@jlerbsc](https://github.com/jlerbsc))
+* Fix wrong author attribution in changelog for #3072 (PR [#3155](https://github.com/javaparser/javaparser/pull/3155) by [@Col-E](https://github.com/Col-E))
+* Fixed #3136 - ThisExpr isn't resolved correctly when it is in the scope of an ObjectCreationExpr (PR [#3137](https://github.com/javaparser/javaparser/pull/3137) by [@deadlocklogic](https://github.com/deadlocklogic))
+* Fix race condition in JavaParserTypeSolver (PR [#3091](https://github.com/javaparser/javaparser/pull/3091) by [@4everTheOne](https://github.com/4everTheOne))
+
+### Developer Changes
+
+* Publish to OSSRH rather than Bintray (PR [#3180](https://github.com/javaparser/javaparser/pull/3180) by [@MysterAitch](https://github.com/MysterAitch))
+* Remove unused JUnit Pioneer dependency (PR [#3179](https://github.com/javaparser/javaparser/pull/3179) by [@MysterAitch](https://github.com/MysterAitch))
+* Verify builds test correctly under JDK16 (PR [#3175](https://github.com/javaparser/javaparser/pull/3175) by [@MysterAitch](https://github.com/MysterAitch))
+* update renovate to include "dependencies" label on PRs (PR [#3174](https://github.com/javaparser/javaparser/pull/3174) by [@MysterAitch](https://github.com/MysterAitch))
+* chore(deps): update dependency com.google.guava:guava to v30.1.1-jre (PR [#3172](https://github.com/javaparser/javaparser/pull/3172) by [@renovate[bot]](https://github.com/apps/renovate))
+
+### :heart: Contributors
+
+Thank You to all contributors who worked on this release!
+
+* [@maartenc](https://github.com/maartenc)
+* [@MysterAitch](https://github.com/MysterAitch)
+* [@jlerbsc](https://github.com/jlerbsc)
+* [@deadlocklogic](https://github.com/deadlocklogic)
+* [@4everTheOne](https://github.com/4everTheOne)
+* [@Col-E](https://github.com/Col-E)
+
+
+
+Version 3.20.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/181?closed=1)
+
+### Added
+* Issue #2991 - Added support for Iterables in CombinedTypeSolver
+ (PR [#3033](https://github.com/javaparser/javaparser/pull/3033), by [@4everTheOne](https://github.com/4everTheOne))
+* Implemented logic for getAllFields in Annotations
+ (PR [#3097](https://github.com/javaparser/javaparser/pull/3097), by [@4everTheOne](https://github.com/4everTheOne))
+### Changed
+* Issue #2717 - Removed "empty" label from break statement and added additional test for BreakStmt
+ (PR [#3109](https://github.com/javaparser/javaparser/pull/3109), by [@4everTheOne](https://github.com/4everTheOne))
+* Issue #2708 - Improvement to the generated code (removal of redundant casts, and additions of `@Override`)
+ (PR [#3124](https://github.com/javaparser/javaparser/pull/3124), by [@4everTheOne](https://github.com/4everTheOne))
+* Performance improvement on ResolvedReferenceTypeDeclaration.isJavaLangObject()
+ (PR [#3125](https://github.com/javaparser/javaparser/pull/3125), by [@jlerbsc](https://github.com/jlerbsc))
+* Optimization to avoid systematically creating a class from javassist when the class has already been created
+ (PR [#3126](https://github.com/javaparser/javaparser/pull/3126), by [@jlerbsc](https://github.com/jlerbsc))
+* Bump jbehave-core from 4.8.1 to 4.8.2
+ (PR [#3043](https://github.com/javaparser/javaparser/pull/3043), by [@dependabot](https://github.com/dependabot))
+* Bump assertj-core from 3.18.1 to 3.19.0
+ (PR [#3047](https://github.com/javaparser/javaparser/pull/3047), by [@dependabot](https://github.com/dependabot))
+* Bump okhttp from 4.9.0 to 4.9.1
+ (PR [#3054](https://github.com/javaparser/javaparser/pull/3054), by [@dependabot](https://github.com/dependabot))
+* Bump actions/cache from v2 to v2.1.4
+ (PR [#3070](https://github.com/javaparser/javaparser/pull/3070), by [@dependabot](https://github.com/dependabot))
+* Bump mockito-core from 3.6.28 to 3.8.0
+ (PR [#3110](https://github.com/javaparser/javaparser/pull/3110), by [@dependabot](https://github.com/dependabot))
+* Bump junit from 4.13.1 to 4.13.2
+ (PR [#3129](https://github.com/javaparser/javaparser/pull/3129), by [@dependabot](https://github.com/dependabot))
+### Fixed
+* Issue #3038 and Issue #3071 - Hanging when certain names are resolved
+ (PR [#3072](https://github.com/javaparser/javaparser/pull/3072), by [@col-e](https://github.com/Col-E))
+* Javadoc fixes
+ (PR [#3082](https://github.com/javaparser/javaparser/pull/3082), by [@mernst](https://github.com/mernst))
+* Update readme with correct Java support versions
+ (PR [#3096](https://github.com/javaparser/javaparser/pull/3096), by [@MaartenGDev](https://github.com/MaartenGDev))
+* Issue #3106 - Wrong descriptor for primitive type long
+ (PR [#3107](https://github.com/javaparser/javaparser/pull/3107), by [@jlerbsc](https://github.com/jlerbsc))
+
+
+Version 3.19.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/180?closed=1)
+
+### Added
+* Adding test case on PrettyPrinter indentation
+ (PR [#2950](https://github.com/javaparser/javaparser/pull/2950), by [@jlerbsc](https://github.com/jlerbsc))
+* Adding interface Printable for printer
+ (PR [#2971](https://github.com/javaparser/javaparser/pull/2971), by [@jlerbsc](https://github.com/jlerbsc))
+* Major update for pretty print, adding interfaces for printer configuration, printer, ... and deprecated old PrettyPrinter API
+ (PR [#2974](https://github.com/javaparser/javaparser/pull/2974), by [@jlerbsc](https://github.com/jlerbsc))
+* Adding method descriptor resolution closes #2059
+ (PR [#2976](https://github.com/javaparser/javaparser/pull/2976), by [@jlerbsc](https://github.com/jlerbsc))
+* Adding management of the poly and standalone expression
+ (PR [#2994](https://github.com/javaparser/javaparser/pull/2994), by [@jlerbsc](https://github.com/jlerbsc))
+* Add test case for issue #1770 UnaryExpr failing to resolve BITWISE_COMPLEMENT operator
+ (PR [#3005](https://github.com/javaparser/javaparser/pull/3005), by [@jlerbsc](https://github.com/jlerbsc))
+* Created additional validators to differentiate between enabling standard and preview features
+ (PR [#3015](https://github.com/javaparser/javaparser/pull/3015), by [@MysterAitch](https://github.com/MysterAitch))
+* Added additional tests to TypeSolvers
+ (PR [#3046](https://github.com/javaparser/javaparser/pull/3046), by [@4everTheOne](https://github.com/4everTheOne))
+* Improved JavaParserTypeVariableDeclaration tests
+ (PR [#3059](https://github.com/javaparser/javaparser/pull/3059), by [@4everTheOne](https://github.com/4everTheOne))
+* Improved coverage for resolved declarations and fixed inconsistencies between them
+ (PR [#3062](https://github.com/javaparser/javaparser/pull/3062), by [@4everTheOne](https://github.com/4everTheOne))
+* Additional GenericVisitorWithDefaults and VoidVisitorWithDefaults tests
+ (PR [#3067](https://github.com/javaparser/javaparser/pull/3067), by [@4everTheOne](https://github.com/4everTheOne))
+* Additional tests for hash code visitors
+ (PR [#3068](https://github.com/javaparser/javaparser/pull/3068), by [@4everTheOne](https://github.com/4everTheOne))
+* Add unit tests to issue #3074 Unable to delete .jar files after parsing and using symbol solver (re: #3074)
+ (PR [#3076](https://github.com/javaparser/javaparser/pull/3076), by [@jlerbsc](https://github.com/jlerbsc))
+### Changed
+* Minor refactoring regarding indentation management
+ (PR [#2969](https://github.com/javaparser/javaparser/pull/2969), by [@jlerbsc](https://github.com/jlerbsc))
+* Minor refactoring regarding indentation management (part2)
+ (PR [#2970](https://github.com/javaparser/javaparser/pull/2970), by [@jlerbsc](https://github.com/jlerbsc))
+* Minor refactoring moving Indentation class to configuration package - preparation for other refactoring on Printer
+ (PR [#2972](https://github.com/javaparser/javaparser/pull/2972), by [@jlerbsc](https://github.com/jlerbsc))
+* Bump guava from 30.0-jre to 30.1-jre
+ (PR [#2977](https://github.com/javaparser/javaparser/pull/2977), by [@dependabot](https://github.com/dependabot))
+* Refactoring: relocation of boxing/unboxing methods
+ (PR [#2983](https://github.com/javaparser/javaparser/pull/2983), by [@jlerbsc](https://github.com/jlerbsc))
+* Improve boxing/unboxing unit tests and remove useless code in isUnbox...
+ (PR [#2984](https://github.com/javaparser/javaparser/pull/2984), by [@jlerbsc](https://github.com/jlerbsc))
+* Bump jbehave-core from 4.7 to 4.8.1
+ (PR [#2989](https://github.com/javaparser/javaparser/pull/2989), by [@dependabot](https://github.com/dependabot))
+* Add JVM memory settings for surefire (seems that forked mode is the default running mode)
+ (PR [#2999](https://github.com/javaparser/javaparser/pull/2999), by [@jlerbsc](https://github.com/jlerbsc))
+* Move unit test Issue2592Test because it's not related to symbol solver
+ (PR [#3000](https://github.com/javaparser/javaparser/pull/3000), by [@jlerbsc](https://github.com/jlerbsc))
+* Manage memory on test suite (clear internal cache to release memory)
+ (PR [#3001](https://github.com/javaparser/javaparser/pull/3001), by [@jlerbsc](https://github.com/jlerbsc))
+* Remove the PhantomNodeLogic that generates memory issues when LexicalPreservingPrinter is used. Phantom node is now an attribut of each node. This is an optimization of the JP memory usage.
+ (PR [#3002](https://github.com/javaparser/javaparser/pull/3002), by [@jlerbsc](https://github.com/jlerbsc))
+* Make the visit order of ModifierVisitor more consistent.
+ (PR [#3011](https://github.com/javaparser/javaparser/pull/3011), by [@mernst](https://github.com/mernst))
+* Link to the specification, not to a random blog.
+ (PR [#3013](https://github.com/javaparser/javaparser/pull/3013), by [@mernst](https://github.com/mernst))
+* Minor refactoring change call to getScope().isPresent() to hasScope()
+ (PR [#3026](https://github.com/javaparser/javaparser/pull/3026), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue #3050 - Minor improvement to thread safety
+ (PR [#3052](https://github.com/javaparser/javaparser/pull/3052), by [@jlerbsc](https://github.com/jlerbsc))
+### Deprecated
+* `PhantomNodeLogic` is now deprecated, with the logic now being handled by the node itself.
+ (PR [#3002](https://github.com/javaparser/javaparser/pull/3002), by [@jlerbsc](https://github.com/jlerbsc))
+### Fixed
+* Fix issue on pretty configuration change
+ (PR [#2979](https://github.com/javaparser/javaparser/pull/2979), by [@jlerbsc](https://github.com/jlerbsc))
+* Fix trivial poly expression lambda, method reference, and parenthesized expressions
+ (PR [#2981](https://github.com/javaparser/javaparser/pull/2981), by [@jlerbsc](https://github.com/jlerbsc))
+* Partially fix the issue #1743 ConditionalExpr resolves to wrong type
+ (PR [#2982](https://github.com/javaparser/javaparser/pull/2982), by [@jlerbsc](https://github.com/jlerbsc))
+* Partially fix issue #1743 ConditionalExpr resolves to wrong type - trying to manage reference condition expression but lub (least upper bound) function is not yet implemented
+ (PR [#3004](https://github.com/javaparser/javaparser/pull/3004), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue #2987 StackOverflow error
+ (PR [#3006](https://github.com/javaparser/javaparser/pull/3006), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue #1774 Ensure the correct type is calculated for all binary expressions and add unary primitive promotion
+ (PR [#3007](https://github.com/javaparser/javaparser/pull/3007), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue #2995 Cannot resolve ClassOrInterfaceType of nested ObjectCreationExpr
+ (PR [#3019](https://github.com/javaparser/javaparser/pull/3019), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue #1634 Missing EOL when add imports if the class not exist imports before
+ (PR [#3020](https://github.com/javaparser/javaparser/pull/3020), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue #3024 methodCallExpr.resolve() StackOverflowError
+ (PR [#3025](https://github.com/javaparser/javaparser/pull/3025), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue #3027 Unable to parse class with generic parameter using JavaParserTypeSolver
+ (PR [#3029](https://github.com/javaparser/javaparser/pull/3029), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue #3030 NoSuchElementException when solving type
+ (PR [#3031](https://github.com/javaparser/javaparser/pull/3031), by [@4everTheOne](https://github.com/4everTheOne))
+* Issue 3028 -- Changed MethodResolutionLogic to deal with multiple candidates with varargs when varargs have not been specified in the call.
+ (PR [#3032](https://github.com/javaparser/javaparser/pull/3032), by [@greggers123](https://github.com/greggers123))
+* Issue #1834 Improving annotation support: Implement ResolvedAnnotationDeclaration#getDefaultValue()
+ (PR [#3055](https://github.com/javaparser/javaparser/pull/3055), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue #3057 Removed redundant definition of method to inherit from super
+ (PR [#3058](https://github.com/javaparser/javaparser/pull/3058), by [@4everTheOne](https://github.com/4everTheOne))
+* Issue #3074 Unable to delete .jar files after parsing
+ (PR [#3075](https://github.com/javaparser/javaparser/pull/3075), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue #3083 Fix choosing the most specific method in case of java.lang.Object argument type
+ (PR [#3084](https://github.com/javaparser/javaparser/pull/3084), by [@jlerbsc](https://github.com/jlerbsc))
+
+
+Version 3.18.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/179?closed=1)
+
+### Added
+* Add a convenient method (hasRange) to the interface NodeWithRange
+ (PR [#2929](https://github.com/javaparser/javaparser/pull/2929), by [@jlerbsc](https://github.com/jlerbsc))
+* Add test case to issue 1017 LambdaExpr left side too permissive
+ (PR [#2946](https://github.com/javaparser/javaparser/pull/2946), by [@jlerbsc](https://github.com/jlerbsc))
+* Added Pattern Matching for instanceof (Java 14 preview, Java 15 second preview, Java 16 targeted release)
+ (PR [#2654](https://github.com/javaparser/javaparser/pull/2654), by [@MysterAitch](https://github.com/MysterAitch))
+* Added java 15 (latest released) and java 16 (bleeding edge) language level options, incl. some validators / post processors / configuration options
+ (PR [#2959](https://github.com/javaparser/javaparser/pull/2959), by [@MysterAitch](https://github.com/MysterAitch))
+### Changed
+* Minor change in PrettyPrinterConfiguration : adding default char in enum IndentType
+ (PR [#2948](https://github.com/javaparser/javaparser/pull/2948), by [@jlerbsc](https://github.com/jlerbsc))
+* Minor refactoring rename interface Printable to Stringable. Something that has a printable form. I.e., it can be converted to a user-facing String
+ (PR [#2949](https://github.com/javaparser/javaparser/pull/2949), by [@jlerbsc](https://github.com/jlerbsc))
+* Adding interface Printable for printer
+ (PR [#2950](https://github.com/javaparser/javaparser/pull/2950), by [@jlerbsc](https://github.com/jlerbsc))
+* Minor refactoring in ResolvedReferenceType and add corresponding tests
+ (PR [#2955](https://github.com/javaparser/javaparser/pull/2955), by [@jlerbsc](https://github.com/jlerbsc))
+* Tweak the property generator to add imports when generating and improve the typecastinggenerator's error message
+ (PR [#2957](https://github.com/javaparser/javaparser/pull/2957), by [@MysterAitch](https://github.com/MysterAitch))
+* Bump mockito-core from 3.6.0 to 3.6.28
+ (PR [#2942](https://github.com/javaparser/javaparser/pull/2942), by dependabot
+### Removed
+* Removed .travis.yml -- per #2919
+ (PR [#2958](https://github.com/javaparser/javaparser/pull/2958), by [@MysterAitch](https://github.com/MysterAitch))
+### Fixed
+* Issue 2909 Improving search for the most relevant declaration of the specified class
+ (PR [#2927](https://github.com/javaparser/javaparser/pull/2927), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2926 NoSuchElementException in PhantomNodeLogic after adding node
+ (PR [#2930](https://github.com/javaparser/javaparser/pull/2930), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2909 try different bottom / up and try with type solver strategies
+ (PR [#2931](https://github.com/javaparser/javaparser/pull/2931), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2936 Triggering observer notifications for the NodeList iterator
+ (PR [#2938](https://github.com/javaparser/javaparser/pull/2938), by [@MysterAitch](https://github.com/MysterAitch))
+* Issue 2065 Problem resolving type of lambda with Math method invocation inside
+ (PR [#2945](https://github.com/javaparser/javaparser/pull/2945), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2740 Issue related to a method call in an anonymous class on a field with a private visibility
+ (PR [#2947](https://github.com/javaparser/javaparser/pull/2947), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2951 Cannot solve function with List argument defined in jar
+ (PR [#2952](https://github.com/javaparser/javaparser/pull/2952), by [@qzchenwl](https://github.com/qzchenwl))
+* Issue 2781 Resolve Stack overflow occurs when the name of the interface implemented by the class is the same as the name of the internal class
+ (PR [#2956](https://github.com/javaparser/javaparser/pull/2956), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2953 UnsolvedSymbolException throw when resolving method in enum class implement in interface by default.
+ (PR [#2954](https://github.com/javaparser/javaparser/pull/2954), by [@qzchenwl](https://github.com/qzchenwl))
+* Fixed MethodCallExprContext generic parameter issue. (NullType must not fail matchTypeParameters)
+ (PR [#2939](https://github.com/javaparser/javaparser/pull/2939), by [@zcbbpo](https://github.com/zcbbpo))
+* Issue 2943 UnsolvedSymbolException thrown on `Stream.()`
+ (PR [#2961](https://github.com/javaparser/javaparser/pull/2961), by [@qzchenwl](https://github.com/qzchenwl))
+* Issue 1945 JavaParser choking on multiple generic method calls on the same line
+ (PR [#2966](https://github.com/javaparser/javaparser/pull/2966), by [@jlerbsc](https://github.com/jlerbsc))
+
+
+Version 3.17.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/178?closed=1)
+### Fixed
+* BEHAVIOUR CHANGE: Fix ArrayType brackets precedence
+ (PR [#2758](https://github.com/javaparser/javaparser/pull/2758), by [@iTakeshi](https://github.com/iTakeshi))
+* BEHAVIOUR CHANGE: Issue 2535 Comments within method missing indentation
+ (PR [#2918](https://github.com/javaparser/javaparser/pull/2918), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2290 Removing the second instance of a cloned statement within a block fails
+ (PR [#2892](https://github.com/javaparser/javaparser/pull/2892), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2393 Apply difference in node text after if condition replacement
+ (PR [#2895](https://github.com/javaparser/javaparser/pull/2895), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2406 Symbol solver fails to solve generic array type
+ (PR [#2896](https://github.com/javaparser/javaparser/pull/2896), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2489 SymbolSolver choosing wrong method after resolving
+ (PR [#2898](https://github.com/javaparser/javaparser/pull/2898), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2062 Type inference issue for method arguments
+ (PR [#2900](https://github.com/javaparser/javaparser/pull/2900), by [@jlerbsc](https://github.com/jlerbsc))
+* Fix LOOKAHEAD for ReferenceType
+ (PR [#2904](https://github.com/javaparser/javaparser/pull/2904), by [@mernst](https://github.com/mernst))
+* Issue 2578 Orphaned Comments exist but not printed on unrelated change to AST
+ (PR [#2916](https://github.com/javaparser/javaparser/pull/2916), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2909 Unexpected result when solving an outer class reference
+ (PR [#2914](https://github.com/javaparser/javaparser/pull/2914), by [@jlerbsc](https://github.com/jlerbsc))
+* Issue 2909 Improving how to resolve inner classes
+ (PR [#2920](https://github.com/javaparser/javaparser/pull/2920), by [@jlerbsc](https://github.com/jlerbsc))
+ (PR [#2921](https://github.com/javaparser/javaparser/pull/2921), by [@jlerbsc](https://github.com/jlerbsc))
+* Ensure spaces between annotations and types for lexical-preserving printing
+ (PR [#2795](https://github.com/javaparser/javaparser/pull/2918), by [@jwaataja](https://github.com/jwaataja))
+
+### Changed
+* Updated dependencies, and dependabot config
+ (PR [#2893](https://github.com/javaparser/javaparser/pull/2893), by [@mysteraitch](https://github.com/mysteraitch))
+ (PR [#2902](https://github.com/javaparser/javaparser/pull/2902), by Dependabot)
+* Issue 2613 Auto update the version in the readme
+ (PR [#2903](https://github.com/javaparser/javaparser/pull/2903), by [@mysteraitch](https://github.com/mysteraitch))
+* Fix jacoco and enable codecov.io action
+ (PR [#2906](https://github.com/javaparser/javaparser/pull/2906), by [@mysteraitch](https://github.com/mysteraitch))
+* Minor refactoring of binary numeric promotion
+ (PR [#2915](https://github.com/javaparser/javaparser/pull/2915), by [@jlerbsc](https://github.com/jlerbsc))
+* Testcases for logical and/or
+ (PR [#2907](https://github.com/javaparser/javaparser/pull/2907), by [@mysteraitch](https://github.com/mysteraitch))
+* Format and document the grammar
+ (PR [#2901](https://github.com/javaparser/javaparser/pull/2901), by [@mysteraitch](https://github.com/mysteraitch))
+ (PR [#2913](https://github.com/javaparser/javaparser/pull/2913), by [@mernst](https://github.com/mernst))
+
+
+Version 3.16.3
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/177?closed=1)
+* ADDED: Created MANY test cases for older issues resolved but not directly linked/closed.
+ (PRs
+ [#2838](https://github.com/javaparser/javaparser/pull/2838),
+ [#2842](https://github.com/javaparser/javaparser/pull/2842),
+ [#2843](https://github.com/javaparser/javaparser/pull/2843),
+ [#2852](https://github.com/javaparser/javaparser/pull/2852),
+ [#2853](https://github.com/javaparser/javaparser/pull/2853),
+ [#2854](https://github.com/javaparser/javaparser/pull/2854),
+ [#2855](https://github.com/javaparser/javaparser/pull/2855),
+ [#2867](https://github.com/javaparser/javaparser/pull/2867),
+ [#2868](https://github.com/javaparser/javaparser/pull/2868),
+ [#2862](https://github.com/javaparser/javaparser/pull/2862),
+ [#2873](https://github.com/javaparser/javaparser/pull/2873),
+ by [@jlerbsc](https://github.com/jlerbsc)
+ )
+* ADDED: Added helper method to `ResolvedPrimitiveType.java` which checks if it is a boolean
+ (PR [#2856](https://github.com/javaparser/javaparser/pull/2856), by [@jlerbsc](https://github.com/jlerbsc))
+* ADDED: Added helper method to `ResolvedPrimitiveType.java` which returns all numeric types
+ (PR [#2858](https://github.com/javaparser/javaparser/pull/2858), by [@jlerbsc](https://github.com/jlerbsc))
+* ADDED/CHANGED: Minor refactoring - formatting code and adding convenient methods to `TypeHelper` and `ResolvedPrimitveType`
+ (PR [#2860](https://github.com/javaparser/javaparser/pull/2860), by [@jlerbsc](https://github.com/jlerbsc))
+* ADDED: Allow the symbol resolver for a `SymbolSolverCollectionStrategy` to be set via the given parser configuration
+ (PR [#2864](https://github.com/javaparser/javaparser/pull/2864), by [@jlerbsc](https://github.com/jlerbsc))
+* FIXED: `MethodResolutionLogic.findMostApplicable` not return correct symbol reference when resolving overloaded method
+ (PR [#2866](https://github.com/javaparser/javaparser/pull/2866), by [@jlerbsc](https://github.com/jlerbsc))
+* FIXED: Updated `AbstractSymbolResolutionTest.java` with better `@BeforeEach`/`@AfterEach`
+ (PR [#2871](https://github.com/javaparser/javaparser/pull/2871), by [@jlerbsc](https://github.com/jlerbsc))
+* FIXED: `TypeResolver` fails on method with args to static imported fields
+ (PR [#2872](https://github.com/javaparser/javaparser/pull/2872), by [@jlerbsc](https://github.com/jlerbsc))
+* FIXED: Fix issue Resolution error for non-generic constructor if generic constructor declared
+ (PR [#2874](https://github.com/javaparser/javaparser/pull/2874), by [@jlerbsc](https://github.com/jlerbsc))
+* FIXED: Fix issue Fails to calculate the type of a generic return type constructed from a Primitive type
+ (PR [#2875](https://github.com/javaparser/javaparser/pull/2875), by [@jlerbsc](https://github.com/jlerbsc))
+* FIXED: Fix issue Can't get qualified signature of a resolved method inside a Constant Enum declaration
+ (PR [#2876](https://github.com/javaparser/javaparser/pull/2876), by [@jlerbsc](https://github.com/jlerbsc))
+* FIXED: Fix issue Constructor resolution error for overloaded variadic constructor
+ (PR [#2877](https://github.com/javaparser/javaparser/pull/2877), by [@jlerbsc](https://github.com/jlerbsc))
+* FIXED: Fix issue Unable to find the constructor declaration when the argument list contains multiple `Optional.empty()` for different `Optional`
+ (PR [#2880](https://github.com/javaparser/javaparser/pull/2880), by [@jlerbsc](https://github.com/jlerbsc))
+* FIXED: Fix issue Solving symbol as value in the case where the scope is a constraint
+ (PR [#2883](https://github.com/javaparser/javaparser/pull/2883), by [@jlerbsc](https://github.com/jlerbsc))
+
+
+Version 3.16.2
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/176?closed=1)
+* FIXED: Enhanced the handling of line separator, introducing an enum `LineSeparator` that can be used.
+ (PR [#2685](https://github.com/javaparser/javaparser/pull/2685), by [@MysterAitch](https://github.com/MysterAitch))
+* FIXED: The generated metamodel classes now have the `@Generated` annotation
+ (PR [#2706](https://github.com/javaparser/javaparser/pull/2706), by [@MysterAitch](https://github.com/MysterAitch))
+* various other bugfixes and enhancements
+
+
+Version 3.16.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/175?closed=1)
+* FIXED: Fixed typo
+ (PR [#2697](https://github.com/javaparser/javaparser/pull/2697), by [@hfreeb](https://github.com/hfreeb))
+
+
+Version 3.16.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/174?closed=1)
+
+There are two breaking changes within this release.
+If you would like assistance with upgrading, get in touch.
+
+* FIXED: Edits to the value of a string value are now correctly handled for use with Lexical Preservation
+ (PR [#2646](https://github.com/javaparser/javaparser/pull/2646), by [@lemoncurry](https://github.com/lemoncurry))
+* FIXED: Edits to the value of other literal values also now handled
+ (PR [#2679](https://github.com/javaparser/javaparser/pull/2679), by [@MysterAitch](https://github.com/MysterAitch))
+* BREAKING CHANGE: Tokens relating to literal values now have the category of `JavaToken.Category.LITERAL` (previously `JavaToken.Category.KEYWORD`)
+ (PR [#2679](https://github.com/javaparser/javaparser/pull/2679), by [@MysterAitch](https://github.com/MysterAitch))
+* FIXED: Add symbol solver support for variadic parameters given zero or more than one argument, and when an array is given
+ (PR [#2675](https://github.com/javaparser/javaparser/pull/2675), by [@hfreeb](https://github.com/hfreeb))
+* CHANGED: Added the keyword `synchronized` to `JavaParserFacade#get`. This is specifically in response to #2668 - JavaParser is not otherwise threadsafe.
+ (PR [#2694](https://github.com/javaparser/javaparser/pull/2694), by [@MysterAitch](https://github.com/MysterAitch))
+* BREAKING CHANGE: The following methods now return `Optional<>` _(as do all classes which implement/extend them)_:
+ `ResolvedClassDeclaration#getSuperClass()`,
+ `ResolvedReferenceType#getTypeDeclaration()`.
+ _Note that Converting to use optional should be as simple as adding `.get()`, given that any cases where returning `Optional.empty()` causes problems would have also previously triggered a `NullPointerException`.
+ You might also use `.orElseThrow()`._
+ (PR [#2693](https://github.com/javaparser/javaparser/pull/2693), by [@MysterAitch](https://github.com/MysterAitch))
+* CHANGED: Added some temporary logic to allow tests to use slightly different expected results based on the version of java used _(e.g. `java.lang.Object.registerNatives()` removed in JDK14)_
+ (PR [#2637](https://github.com/javaparser/javaparser/pull/2637), by [@EFregnan](https://github.com/EFregnan))
+* FIXED: Fix resolving overloaded methods of external types
+ (PR [#2687](https://github.com/javaparser/javaparser/pull/2687), by [@maartenc](https://github.com/maartenc))
+* FIXED: Fix resolving method references on expressions other than ReferenceType::methodname
+ (PR [#2674](https://github.com/javaparser/javaparser/pull/2674), by [@maartenc](https://github.com/maartenc))
+
+
+
+Version 3.15.22
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/173?closed=1)
+* REVERT: Rollback of upgrade to `ph-javacc-maven-plugin` from v4.1.3 to v4.1.2
+ _(this undoes the transitive dependency update `parser-generator-cc` from v1.1.2 to v1.1.1, which appears to have isuse with handling tokens longer than the buffer length)_
+ ([#2646](https://github.com/javaparser/javaparser/pull/2646))
+* ADDED: Support resolving an enum's `valueOf` method
+ ([#2652](https://github.com/javaparser/javaparser/pull/2652))
+* FIXED: Fixed build warning -- bnd-maven-plugin flagging missing id
+ ([#2605](https://github.com/javaparser/javaparser/pull/2605))
+* FIXED: Fixed cases where nodes added after a trailing comment would incorrectly be added to the same line (thus be part of the comment)
+ ([#2646](https://github.com/javaparser/javaparser/pull/2646))
+* FIXED: Fixed resolving overloaded static method references (e.g. `String::valueOf` in a stream map/filter)
+ ([#2662](https://github.com/javaparser/javaparser/pull/2662))
+
+
+Version 3.15.21
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/172?closed=1)
+
+* DEPRECATED: Deprecated and documented `JarTypeSolver#getJarTypeSolver(String)`, with a view to later removal.
+ ([#2598](https://github.com/javaparser/javaparser/pull/2598))
+ ([#2622](https://github.com/javaparser/javaparser/pull/2622))
+* FIXED: Fix issue #2552 : UnsupportedOperationException caused by resolving inner annotation
+ ([#2553](https://github.com/javaparser/javaparser/pull/2553))
+* FIXED: Parents of `NodeList`s now correctly retain their parent when a child is replaced
+ ([#2594](https://github.com/javaparser/javaparser/pull/2594))
+* FIXED: Fix JavaParserClassDeclaration canBeAssignedTo() to not cause a recursion when a node is its own parent (e.g. `java.lang.Object`)
+ ([#2608](https://github.com/javaparser/javaparser/pull/2608))
+* FIXED: Fix replacing an expression preceded by a comment (`LexicalPreservation` would previously throw an `UnsupportedOperation`)
+ ([#2611](https://github.com/javaparser/javaparser/pull/2611))
+* FIXED: The collection strategies now correctly take into account the parser configuration that is passed in via the constructor.
+ ([#2619](https://github.com/javaparser/javaparser/pull/2619))
+
+
+Version 3.15.20
+------------------
+_skipped_
+
+Version 3.15.19
+------------------
+_skipped_
+
+Version 3.15.18
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/170?closed=1)
+
+* CHANGED: Dependencies should now all be up-to-date.
+ ([#2572](https://github.com/javaparser/javaparser/pull/2572) / [#2581](https://github.com/javaparser/javaparser/pull/2581))
+ - Note that the JavaCC update introduced a breaking change that now requires a StreamProvider to be passed a charset if using an InputStream source.
+* FIXED (possible CHANGED/BREAKING):
+ Improvements have been made to method `PositionUtils#nodeContains()` for clarity and precision in behaviour.
+ ([#2502](https://github.com/javaparser/javaparser/pull/2502))
+ - It is believed that there are no changes to behaviour, but if you do see anything please do reach out.
+ - See some additional commentary/thoughts in #2502
+* FIXED: Resolving super methodcalls in anonymous inner classes (fixes #1962)
+ ([#2585](https://github.com/javaparser/javaparser/pull/2585))
+* ADDED: `NodeList#getFirst(): Optional`
+ ([#2502](https://github.com/javaparser/javaparser/pull/2502))
+* ADDED: `NodeList#getLast(): Optional`
+ ([#2502](https://github.com/javaparser/javaparser/pull/2502))
+
+Version 3.15.17
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/169?closed=1)
+
+* CHANGED: Merged symbol solver modules, for java 9 module compatibility
+ ([#2564](https://github.com/javaparser/javaparser/pull/2564))
+* CHANGED: Renamed the pretty printer configuration option `isSpacesBetweenOperators` to `isSpaceAroundOperators`
+ ([#2555](https://github.com/javaparser/javaparser/pull/2555))
+
+Version 3.15.16
+------------------
+_Version skipped_
+
+Version 3.15.15
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/168?closed=1)
+
+* Often requested, finally implemented by [ReallyLiri](https://github.com/ReallyLiri):
+configurable cache sizes for the symbol solver.
+
+Version 3.15.14 (buggy)
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/167?closed=1)
+
+* a suggestion for a new Javadoc parsing API was merged too quickly,
+causing issues parsing Javadoc while parsing Java normally.
+
+Version 3.15.13
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/166?closed=1)
+
+Version 3.15.12
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/165?closed=1)
+
+Version 3.15.11
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/164?closed=1)
+
+Version 3.15.10
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/163?closed=1)
+
+Version 3.15.9
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/161?closed=1)
+
+Version 3.15.8
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/160?closed=1)
+
+Version 3.15.7
+------------------
+* BREAKING: Range.overlapsWith works slightly different now.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/162?closed=1)
+
+Version 3.15.6
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/159?closed=1)
+
+Version 3.15.5
+------------------
+* BREAKING: bugs have been fixed in how SourceRoot configures parsing,
+so behaviour may change (which can be fixed by setting configuration on SourceRoot correctly.)
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/158?closed=1)
+
+Version 3.15.4
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/157?closed=1)
+
+Version 3.15.3
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/156?closed=1)
+
+Version 3.15.2
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/155?closed=1)
+
+Version 3.15.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/154?closed=1)
+
+Version 3.15.0
+------------------
+- The funny "PI" version number messed up the release order in the maven site,
+ so here is a new minor release.
+[issues resolved](https://github.com/javaparser/javaparser/milestone/153?closed=1)
+
+Version 3.14.16
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/152?closed=1)
+
+Version 3.14.159265359
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/151?closed=1)
+
+Version 3.14.14
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/150?closed=1)
+
+Version 3.14.13
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/149?closed=1)
+
+Version 3.14.12
+------------------
+- BREAKING: `NodeWithConstructors` has been merged into `NodeWithMembers`,
+so if you don't have a very specific need to only find nodes that support constructors,
+you can use `NodeWithMembers` instead.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/148?closed=1)
+
+Version 3.14.11
+------------------
+- BREAKING: the pseudo-language levels have been turned into constants with the same name in the same place.
+With a little luck everything will keep compiling.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/147?closed=1)
+
+Version 3.14.10 (buggy!)
+------------------
+- BREAKING: Java 13: `break` no longer has an expression, this was part of a language preview in Java 12
+and has been removed in Java 13.
+- BREAKING: Java 13: `YieldStatement` and the keyword `yield` have been added.
+This means the token numbers have changed, and this affects serialization.
+If you rely on serialized tokens, be sure to deserialize with your current version and serialize with this version.
+- Java 13: `TextBlockLiteralExpr` has been added.
+- This release is broken because no identifier called `yield` can be used.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/146?closed=1)
+
+Version 3.14.9
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/145?closed=1)
+
+Version 3.14.8
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/144?closed=1)
+
+Version 3.14.7
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/143?closed=1)
+
+Version 3.14.6 (oops, failed)
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/142?closed=1)
+
+Version 3.14.5
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/141?closed=1)
+
+Version 3.14.4
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/140?closed=1)
+
+Version 3.14.3
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/139?closed=1)
+
+Version 3.14.2
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/138?closed=1)
+
+Version 3.14.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/137?closed=1)
+
+Version 3.14.0
+------------------
+* BREAKING: `SuperExpr` and `ThisExpr` used to have an `Expression classExpr`.
+this has been tightened to `Name typeName` which is more specific and easier to use.
+Checking if the expression is a `FieldAccessExpr` or `NameExpr` is no longer needed.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/136?closed=1)
+
+Version 3.13.10
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/135?closed=1)
+
+Version 3.13.9
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/134?closed=1)
+
+Version 3.13.8 (failed)
+------------------
+(release failed)
+
+Version 3.13.7
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/133?closed=1)
+
+Version 3.13.6
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/132?closed=1)
+
+Version 3.13.5
+------------------
+* "BREAKING": `ReferenceType.getDirectAncestors()` no longer returns `java.lang.Object` when called on a `ReferenceType` of `java.lang.Object`.
+This remedies infinite recursions in certain edge cases. If you relied on the old behavior, you have to add a `ReferenceType` instance of `java.lang.Object`
+to the List returned by `ReferenceType.getDirectAncestors()` yourself.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/131?closed=1)
+
+Version 3.13.4
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/130?closed=1)
+
+Version 3.13.3
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/129?closed=1)
+
+Version 3.13.2
+------------------
+* Version 3.13.0 and 3.13.1 contain rather bad bugs that have been fixed here.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/128?closed=1)
+
+Version 3.13.1 (buggy!)
+------------------
+* Slightly breaking: most parameters to Log methods now take consumers to avoid evaluating them when not necessary.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/127?closed=1)
+
+Version 3.13.0 (buggy!)
+------------------
+* "BREAKING": The static `JavaParser.parse...` methods have moved to `StaticJavaParser.parse...`!
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/126?closed=1)
+
+Version 3.12.0
+------------------
+* "BREAKING": all deprecated code was removed.
+If you don't know what to do, try version 3.11.0 and read the Javadoc for the deprecated methods.
+It tells you what to use instead.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/124?closed=1)
+
+Version 3.11.0
+------------------
+* BREAKING: `SwitchEntryStmt` is now `SwitchEntry`, because it was never a statement.
+* BREAKING: a case in a switch can now have multiple labels,
+so `SwitchEntry` no longer has an `Expression label`,
+but a `NodeList label`.
+* This completes *parsing* support for Java 12.
+Symbol resolution is still to be done.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/123?closed=1)
+
+Version 3.10.2
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/122?closed=1)
+
+Version 3.10.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/121?closed=1)
+
+Version 3.10.0
+------------------
+* slightly breaking: besides `break;` and `break [label];` there is now `break [expression];` like
+`break 1+2;` or `break "bye!";` . That means that `BreakStmt` no longer has a `label`,
+it has a `value` which is of type `Expression`.
+This is to prepare for Java 12 switch expressions.
+You can find the details in the Javadoc.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/120?closed=1)
+
+Version 3.9.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/119?closed=1)
+
+Version 3.9.0
+------------------
+* MAJOR BREAKAGE: modifiers (like public, static, transient) used to be a special case:
+they were enums stored in an EnumSet.
+This meant they were not true `Node`s, had to be treated in a special way, and missed some information.
+This has now been corrected in [PR 1975](https://github.com/javaparser/javaparser/pull/1975).
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/118?closed=1)
+
+Version 3.8.3
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/117?closed=1)
+
+Version 3.8.2
+------------------
+* slightly breaking: `ObjectCreationExpr` no longer gets a diamond when constructed with the default constructor.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/116?closed=1)
+
+Version 3.8.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/114?closed=1)
+
+Version 3.8.0
+------------------
+* A Unicode preprocessing filter is now available again.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/113?closed=1)
+
+Version 3.7.1
+------------------
+* slightly breaking: the enum constants in JsonToken are now capitalized.
+* slightly breaking: [some obscure methods in the symbol solver changed](https://github.com/javaparser/javaparser/pull/1922)
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/115?closed=1)
+
+Version 3.7.0
+------------------
+* BREAKING: `ForeachStmt` is now correctly capitalized: `ForEachStmt`
+* BREAKING: when using modules, everything that was called `...Statement` is now correctly called `...Directive`
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/112?closed=1)
+
+Version 3.6.27
+------------------
+* The Json serialization now serializes more fields,
+which *should* not impact existing code.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/111?closed=1)
+
+Version 3.6.26
+------------------
+* BREAKING: Node.getData now throws an exception if the data was not set before.
+This can be rewritten by checking with Node.containsData before doing getData.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/110?closed=1)
+
+Version 3.6.25
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/109?closed=1)
+
+Version 3.6.24
+------------------
+* `findAncestor(type, predicate)` is now available
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/108?closed=1)
+
+Version 3.6.23
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/107?closed=1)
+
+Version 3.6.22
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/106?closed=1)
+
+Version 3.6.21
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/105?closed=1)
+
+Version 3.6.20
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/104?closed=1)
+
+Version 3.6.19
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/103?closed=1)
+
+Version 3.6.18
+------------------
+* Parsing Java 11 is now supported.
+* Running on Java 11 is now supported.
+* Building on JDK 11 is NOT yet supported.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/101?closed=1)
+
+Version 3.6.17
+------------------
+* A new artifact was added: javaparser-core-serialization.
+It contains a JSON serializer, and might get more serializers in the future.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/100?closed=1)
+
+Version 3.6.16
+------------------
+* BREAKING: some parts of the module syntax used `Type` where they should have used `Name`.
+This is now fixed, but your code may need to be adapted if you are parsing modules.
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/99?closed=1)
+
+Version 3.6.15
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/98?closed=1)
+
+Version 3.6.14
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/97?closed=1)
+
+Version 3.6.13
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/96?closed=1)
+* JavaParserFacade.getType now can also handle NameExpr referring to types
+while before they were not supported.
+See [issue #1491](https://github.com/javaparser/javaparser/issues/1491#issuecomment-403277963)
+
+Version 3.6.12
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/95?closed=1)
+
+Version 3.6.10 & Version 3.6.11
+------------------
+* A mixup during the release put all the issues in the same milestone:
+
+[issues resolved](https://github.com/javaparser/javaparser/milestone/94?closed=1)
+
+Version 3.6.9
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/93?closed=1)
+
+Version 3.6.8
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/92?closed=1)
+* Intellij Idea project files were deleted from the repository,
+so if you have a clone of the JP source, your local files will be deleted as well.
+Save anything you want to keep.
+
+Version 3.6.7
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/91?closed=1)
+
+Version 3.6.6
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/90?closed=1)
+* You can now configure the parser inside JavaParserTypeSolver.
+
+Version 3.6.5
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/89?closed=1)
+* Be aware of annotations or indents looking slightly different when output!
+
+Version 3.6.4
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/88?closed=1)
+
+Version 3.6.3
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/87?closed=1)
+
+Version 3.6.2
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/86?closed=1)
+
+Version 3.6.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/85?closed=1)
+* BREAKING: `SymbolSolverQuickSetup` has been removed in favor of `ProjectRoot` and `SymbolSolverCollectionStrategy`.
+
+Version 3.6.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/84?closed=1)
+* @daanschipper added `ProjectRoot` which is used for analysing and storing project structure.
+* Upgraded version from 3.5.20 to 3.6.0 because people got tired of seeing 3.5.
+
+Version 3.5.20
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/83?closed=1)
+* Thanks to @daanschipper for the PR :-)
+
+Version 3.5.19
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/82?closed=1)
+
+Version 3.5.18
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/81?closed=1)
+
+Version 3.5.17
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/80?closed=1)
+
+Version 3.5.16
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/79?closed=1)
+
+Version 3.5.15
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/78?closed=1)
+* Java 10 support is complete.
+* BREAKING: Java language level support has changed to make Java 10 support possible.
+[Here's a little article about it](https://matozoid.github.io/2017/04/11/enable-java-9-support.html)
+
+Version 3.5.14
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/77?closed=1)
+* Java 10's `var` can now be parsed and will be turned into a `VarType` node.
+It can not be resolved yet.
+* `NodeList` now has a pretty complete set of `...First` and `...Last` methods.
+Thanks stephenramthun !
+
+Version 3.5.13
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/76?closed=1)
+* The Javadoc parser has received a lot of attention.
+
+Version 3.5.12
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/75?closed=1)
+* Thanks to un0btanium for fixing the readme file!
+
+Version 3.5.11
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/74?closed=1)
+* BREAKING: `AssignExpr.Operator.AND` is now `AssignExpr.Operator.BINARY_AND`.
+* BREAKING: `AssignExpr.Operator.OR` is now `AssignExpr.Operator.BINARY_OR`.
+* `getPrimaryTypeName` and `getPrimaryType` give access to the type that has the same name as the file it came from.
+* Enums will now get their constants aligned vertically if there are more than five.
+* You can now convert between `AssignExpr.Operator` and `AssignExpr.Operator` if you like.
+
+Version 3.5.10
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/73?closed=1)
+* JavaSymbolSolver is now in the same project as JavaParser, meaning they get released together from now on.
+* LexicalPreservingPrinter has had a big speed optimization.
+
+Version 3.5.9
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/72?closed=1)
+* BREAKING: the very confusing constructor `NodeList(Node)` (which sets the parent) was removed.
+* To avoid using the int type for token kinds, use the new `JavaToken.Kind` enum.
+It can convert to and from the int kind.
+
+Version 3.5.8
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/71?closed=1)
+* the module name is now set to com.github.javaparser.core
+
+Version 3.5.7
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/70?closed=1)
+
+Version 3.5.6
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/69?closed=1)
+* `toSomeType()` methods have been added for many types that give more functional access to a subtype.
+* BETA: the below work on Java Symbol Solver is still ongoing.
+
+Version 3.5.5
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/68?closed=1)
+* SourceRoot is now silent by default - look at the Log class if you want to change that.
+* BETA: the below work on Java Symbol Solver is still ongoing.
+
+Version 3.5.4
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/67?closed=1)
+* BETA: the below work on Java Symbol Solver is still ongoing.
+
+Version 3.5.3
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/66?closed=1)
+* Unicode escapes (`\u1234`) are now retained in the AST,
+ but they are now only allowed in comments, string and character literals, and identifiers.
+* BETA: the below work on Java Symbol Solver is still ongoing.
+
+Version 3.5.2
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/65?closed=1)
+* The pretty printer now cleans up Javadoc comments.
+* BETA: the below work on Java Symbol Solver is still ongoing.
+
+Version 3.5.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/64?closed=1)
+* BETA: the below work on Java Symbol Solver is still ongoing.
+
+Version 3.5.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/63?closed=1)
+* A functional visitor API has been added. See [PR 1195](https://github.com/javaparser/javaparser/pull/1195) for now.
+* Build is working again on Windows thanks to Leonardo Herrera.
+* The pretty printer now has an option to order imports, also thanks to Leonardo Herrera.
+* Receiver parameters are now well-supported instead of being a hack. See [issue 1194](https://github.com/javaparser/javaparser/pull/1194) for a description.
+* BETA: the below work on Java Symbol Solver is still ongoing.
+
+Version 3.4.4
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/62?closed=1)
+* BETA: the below work on Java Symbol Solver is still ongoing.
+
+Version 3.4.3
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/61?closed=1)
+* BETA: we're still doing work to integrate parts of [Java Symbol Solver](https://github.com/javaparser/javasymbolsolver) to simplify its API.
+* `VisitorMap` is joined by `VisitorSet` and `VisitorList`,
+for when you want to store `Node`s in collection but don't want its default equals/hascode behaviour
+
+Version 3.4.2
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/60?closed=1)
+* BETA: we're doing work to integrate parts of [Java Symbol Solver](https://github.com/javaparser/javasymbolsolver) to simplify its API.
+* JDK 9 will compile JavaParser now.
+* [An official sample Maven setup](https://github.com/javaparser/javaparser-maven-sample) was added.
+
+Version 3.4.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/59?closed=1)
+* Two visitors were added: `NoCommentEqualsVisitor` and `NoCommentHashCodeVisitor` -
+as the name implies you can use these to compare nodes without considering comments.
+Thanks Ryan Beckett!
+* `isSomeType()` methods have been added for many types that help avoid `instanceof`.
+* `asSomeType()` methods have been added for many types that help avoid casting to that type.
+* `ifSomeType()` methods have been added for many types, giving a nice functional way of doing if-is-type-then-cast-to-type-then-use.
+* The `LexicalPreservingPrinter` had its API changed a little: setup and printing are now separate things,
+so you don't have to drag an instance of `LexicalPreservingPrinter` through your code anymore.
+* `traverseScope` was added to all nodes with a scope, so you can travel through the scope without tripping over (non-)optionality.
+
+
+Version 3.4.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/58?closed=1)
+* BREAKING: We missed a Java 9 feature which is now on board: try with resources can now refer to a resource declared outside of the statement.
+This means that the node type you get for those resources is now `Expression` instead of `VariableDeclarationExpr`.
+For Java 8 and below you can simply cast it to `VariableDeclarationExpr` again.
+See also the Javadoc for `TryStmt`.
+* You can now inspect the AST by exporting it to XML, JSON, YAML, or a Graphviz's dot diagram, thanks to Ryan Beckett!
+* `GenericVisitorWithDefaults` and `VoidVisitorWithDefaults` were added which function like empty visitors,
+but all the visit methods call a default method by default.
+* Annotation support was cleaned up, adding some obscure locations where you can have annotations.
+* `EnumDeclaration` regained its constructor builder methods. They were accidentally lost around 3.2.2.
+* `ArrayType` now has an `origin` field which indicates in which position the array brackets were found.
+
+Version 3.3.5
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/57?closed=1)
+
+Version 3.3.4
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/56?closed=1)
+* `SourceZip` has been added.
+Use it to read source code from jars or zip files.
+Thank you @ryan-beckett !
+* JavaCC was upgraded to 7.0.2
+* A new option for the pretty printer was added.
+You can now wrap-and-column-align parameters of method calls.
+Thank you @tarilabs !
+
+Version 3.3.3
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/55?closed=1)
+* Parsing a partial java file (like an expression or statement) no longer ignores trailing code.
+* New memory saving option: turn off token list.
+
+Version 3.3.2
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/54?closed=1)
+* `VisitorMap` lets you override hashcode/equals for nodes when used as a key for a map.
+
+Version 3.3.1
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/53?closed=1)
+* The token list is now mutable - see methods on `JavaToken`.
+This caused mild breakage - some fields have become `Optional`.
+
+Version 3.3.0
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/52?closed=1)
+* Breaking: `TryStmt::tryBlock` and `EnclosedExpr::inner` were optional for no good reason. Now they are required.
+* You can now ask a `JavaToken` for its category, which is useful for examining the token list or doing syntax highlighting or so.
+* `enum` and `strictfp` can now be used as identifiers on lower Java versions.
+
+Version 3.2.12
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/51?closed=1)
+
+Version 3.2.11
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/50?closed=1)
+* We're up to date with the latest Java 9 module system again.
+
+Version 3.2.10
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/49?closed=1)
+* `Node.replace(old, new)` was added, including property-specific `X.replaceY(newY)` methods
+
+Version 3.2.9
+------------------
+Scrapped due to release problem.
+
+Version 3.2.8
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/48?closed=1)
+* Added `isInnerClass()` that checks if a `ClassOrInterfaceDeclaration` is an inner class (note: this is different from a nested class!)
+* @ryan-beckett contributed a huge [Eclipse setup guide](https://github.com/javaparser/javaparser/wiki/Eclipse-Project-Setup-Guide)
+
+Version 3.2.7
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/47?closed=1)
+* We now recover from some parse errors! [Here is an article](https://matozoid.github.io/2017/06/11/parse-error-recovery.html)
+
+Version 3.2.6
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/46?closed=1)
+* `EmptyMemberDeclaration` is gone!
+It was deprecated for a while because it was in the AST, but doesn't have any meaning in a Java program.
+`EmptyStmt` was also deprecated, but that has been reverted.
+This node *does* have meaning.
+
+Version 3.2.5
+------------------
+[issues resolved](https://github.com/javaparser/javaparser/milestone/45?closed=1)
+* `NodeWithCondition` was added on all nodes containing a condition.
+* Lots of work on improving lexical preservation.
+* If a file was parsed from a file system, you can now get path information etc. from `CompilationUnit`
+* API BREAKING: every node now points to its start and end token.
+Some of the API has started returning `TokenRange` instead of `Range` - you can call `toRange` to get the old object type.
+We may still change the naming of some of this code in the following month.
+
+Version 3.2.4
+------------------
+New style changelog, no more issue numbers, but a link:
+[issues resolved](https://github.com/javaparser/javaparser/milestone/44?closed=1)
+and any notable changes:
+* the new method `Node.removeForced()` by removing it, or removing the first parent that is optional.
+This is different from `Node.remove()`, `remove()` only tries to remove the node from the parent and fails if it can't.
+* `FieldAccessExpr.scope` is now a required property.
+You might find some `get()`s in your code that are no longer necessary.
+* `ReferenceType` no longer has a type parameter, so every `ReferenceType>` can be replaced by `ReferenceType` now.
+
+Version 3.2.3
+------------------
+* 907 906 905 903 911 910 909 908 smaller improvements and fixes
+
+Version 3.2.2
+------------------
+Beta: `TreeStructureVisitor`.
+
+* 770 902 904 901 smaller improvements and fixes
+
+Version 3.2.1
+------------------
+Beta: `TreeStructureVisitor`.
+
+* Maven dependencies were updated to their latest versions
+* 890 the concept of "method signature" now exists in JavaParser
+* 896 891 889 887 882 789 smaller improvements and fixes
+
+Version 3.2.0
+------------------
+The lexical preservation code is stable!
+
+Beta: `TreeStructureVisitor`.
+
+* 885 884 879 878 smaller improvements and fixes
+
+Version 3.1.4
+------------------
+This is the first version to parse Java 9.
+
+Beta: `TreeStructureVisitor`, and `LexicalPreservingPrinter`.
+
+* 872 873 874 787 Remaining Java 9 work.
+
+Version 3.1.3
+------------------
+Beta: `TreeStructureVisitor`, and `LexicalPreservingPrinter`.
+
+A start has been made on source level support. The default level is Java 8.
+It can be set to Java 9 like this for a parser *instance*:
+```java
+private final JavaParser parser = new JavaParser(new ParserConfiguration().setValidator(new Java9Validator()));
+```
+and like this for the static parse methods:
+```java
+QuickJavaParser.getConfiguration().setValidator(new Java9Validator());
+```
+
+* 862 552 "_" is an illegal identifier on source level 9.
+* 869 867 109 855 857 smaller improvements and fixes
+
+Version 3.1.2
+------------------
+Beta: `TreeStructureVisitor`, `ConcreteSyntaxModel`, and `LexicalPreservingPrinter`.
+
+* 594 849 831 a validation framework was introduced to inform about problems in the AST without needing to change the grammar,
+and without requiring parsing code.
+It is open for extension by users.
+* 852 853 826 832 846 839 smaller improvements and fixes
+
+Version 3.1.1
+------------------
+Beta: `TreeStructureVisitor`, `ConcreteSyntaxModel`, and `LexicalPreservingPrinter`.
+
+* 654 124 lexical preservation (printing source code with the same formatting it had when parsing) has been added.
+ Thank you @ftomassetti for a lot of work!
+* 554 800 first (big) step towards Java 9 support: JavaParser can read project Jigsaw module definitions.
+* 795 786 751 extend the TreeVisitor with more traversal options. Thanks @ryan-beckett!
+* 791 `GenericListVisitorAdapter` has been added which collects its results in a list. Thanks @Gottox!
+* 815 798 797 813 clean up Problem text
+* 819 818 817 816 441 809 808 807 fix various absurd annotation related issues.
+* 777 805 802 796 790 792 793 781 784 785 783 782 779 357 799 763 smaller improvements and fixes
+
+Version 3.1.0
+------------------
+Beta: `TreeStructureVisitor` and `ConcreteSyntaxModel`.
+
+* 705 755 Add the concrete syntax model, which will give you information about the exact syntax a certain nodes matches.
+
+* 777 smaller improvements and fixes
+
+Version 3.1.0-beta.2
+------------------
+This version is a beta because `TreeStructureVisitor` is not in its definite state yet.
+
+* 762 761 772 merge `javaparser-metamodel` and `javaparser-generator-utils` into `javaparser-core`.
+* 766 the `ModifierVisitor` is now created by a code generator. Its behaviour has been made logical, and may give different results than before.
+* 755 `ConstructorDeclaration` and `MethodDeclaration` now share a parent: `CallableDeclaration`
+* 687 759 773 769 768 767 765 759 smaller improvements and fixes
+
+Version 3.1.0-beta.1
+------------------
+This version is a beta because there are a lot of new features that may still change.
+
+This version needs a minor version increase because of a backwards compatability issue:
+* 719 `getJavadoc`, `getJavadocComment` and `getComment` could return null. Our promise was to return `Optional`, so that is what they do now.
+
+New:
+* 658 718 736 737 we have created a metamodel.
+It gives information about the structure of the various AST nodes, as if you are introspecting them.
+You can find it in `javaparser-metamodel`, the main class is `JavaParserMetaModel`
+* 353 365 visitors are no longer hand made, they are now generated from the metamodel. This should make them 100% reliable.
+Affected visitors are: `GenericVisitorAdapter`, `EqualsVisitor`, `VoidVisitorAdapter`, `VoidVisitor`, `GenericVisitor`, `HashCodeVisitor`, `CloneVisitor`.
+
+If you want to generate your own visitors, you can use the `VisitorGenerator` class from `javaparser-core-generators`
+
+If you want to reuse the code generation utilities, look at module `javaparser-generator-utils` - there is a very useful `SourceRoot` class in there that takes away a lot of file management troubles.
+* 538 735 `TreeStructureVisitor` has been added, which should be considered beta.
+* 220 733 717 749 745 750 743 748 666 732 746 734 733 smaller improvements and fixes
+
+Version 3.0.1
+------------------
+* 699 433 325 Javadoc can now be parsed
+* 703 696 added NodeWithOptionalScope
+* 702 FieldAccessExpr now implements NodeWithSimpleName, *which means that "field" has been renamed to "name"*
+* 707 706 improve range of array types and levels
+* 709 smaller improvements and fixes
+
+Version 3.0.0
+------------------
+* 695 697 689 680 693 691 682 690 677 679 688 684 683 smaller improvements and fixes
+
+Version 3.0.0-RC.4
+------------------
+* 668 669 TypeDeclarationStmt became LocalClassDeclarationStmt
+* 347 665 every node now has some documentation
+* 660 670 673 four types of import declaration have been merged back into the old ImportDeclaration
+* 659 The pretty printer can now take customized visitors
+* 650 671 672 674 524 smaller improvements and fixes
+
+Version 3.0.0-RC.3
+------------------
+* 639 622 632 657 656 652 653 647 648 645 194 643 630 624 628 627 626 625 623 cleanups, small fixes, and general housekeeping
+
+Version 3.0.0-RC.2
+------------------
+* 593 EmptyImportDeclaration and NonEmptyImportDeclaration have been removed
+* 612 VariableDeclaratorId has been removed. It has been substituted by "SimpleName name"
+* 614 617 the list of tokens has been linearized and simplified
+* 615 support for arrays has once more been changed. See [the issue](https://github.com/javaparser/javaparser/issues/592)
+* 580 453 380 618 580 611 610 424 608 smaller improvements and fixes
+
+Version 3.0.0-RC.1
+------------------
+* 499 601 renames many fields to be more consistent
+* 596 605 602 604 smaller improvements and fixes
+
+Version 3.0.0-alpha.11
+------------------
+* 547 595 Node.range is now using Optional instead of Range.UNKNOWN
+* 584 588 548 585 bug fixes and improvements
+
+Version 3.0.0-alpha.10
+------------------
+* 578 579 577 575 290 570 568 567 562 564 551 bug fixes and improvements
+
+Version 3.0.0-alpha.9
+------------------
+* 403 358 549 Make all names nodes: either SimpleName or Name. This makes every name in the AST visitable. NameExpr is now a wrapper to use SimpleName in an expression.
+* 516 536 use Optional<> for return values.
+* 556 557 558 550 small improvements and fixes.
+* 560 559 make nodes observable.
+
+Version 3.0.0-alpha.8
+------------------
+* 344 529 turn DumpVisitor into an official PrettyPrinter
+* 532 508 427 530 531 513 528 cleanups
+
+Version 3.0.0-alpha.7
+------------------
+* 515 roll back attempt at using Optional
+* 522 504 make NodeList not a Node (restores parent/children behaviour to before alpha.4)
+* 527 526 rename getChildrenNodes to getChildNodes
+* 525 495 520 bug fix
+
+Version 3.0.0-alpha.6
+------------------
+* 503 modified ImportDeclaration hierarchy to have getters for static and "asterisk" again
+* 506 bug fix
+
+Version 3.0.0-alpha.5
+------------------
+* 451 null is no longer allowed in the AST. [See last post in issue](https://github.com/javaparser/javaparser/issues/451)
+* 501 421 420 316 use a special type of list for nodes: NodeList. [See last post in issue](https://github.com/javaparser/javaparser/issues/421)
+
+Version 3.0.0-alpha.4
+------------------
+* 463 471 nodes can now be removed easily
+* 491 import handling changed. Instead of "ImportDeclaration", we now have the four types of import as described in the JLS. [See issue](https://github.com/javaparser/javaparser/pull/491)
+* 452 355 474 494 various improvements
+* 493 492 485 Simplify the JavaParser interface
+
+Version 3.0.0-alpha.3
+------------------
+* 112 237 466 465 461 460 458 457 fundamentally changes how we deal with arrays. [It is explained in the last post here](https://github.com/javaparser/javaparser/issues/237)
+* 472 456 makes the "data" field on every node more structured.
+* 477 468 refactor TypeArguments. You will find that TypeArguments is no longer a type, it is just a list in some nodes.
+* 482 adds the "nodeTypes" packages to the osgi export.
+* 479 476 makes all setters on nodes return this so they become chainable.
+* 473 437 clean up CloneVisitor.
+
+Version 3.0.0-alpha.2
+------------------
+* 157 a new parser frontend, check https://github.com/javaparser/javaparser/pull/447 for explanations
+* 435 more builder methods like 400 and 405
+* 111 440 443 444 445 446 bugs & cleanups
+
+Version 3.0.0-alpha.1
+------------------
+* 400 405 introduce many "builder" style methods for constructing code. Thanks DeepSnowNeeL!
+* 409 remove ASTHelper (methods are now on specific Node subclasses)
+* 414 JavaParser can now be instantiated and reused. InstanceJavaParser removed
+* 418 417 411 408 bugs
+* 367 420 407 402 various cleanups
+
+Version 2.5.1
+-------------
+* 394 OSGi manifest added
+* 391 fix ModifierVisitor NullPointerException bug
+* 385 a few new parse methods
+* 386 fix dumping an empty import (a single ; after the package declaration)
+
+Version 2.5.0
+-------------
+API breaking changes:
+
+* 191: moved TreeVisitor to visitor package
+* 368, 162, 303, 302, 360: use correct type in some places.
+* 371: code is now compiled with Java 8
+* 342, 331: ModifierVisitorAdapter detects and removes broken nodes
+* 328, 270: upgrade JavaCC (use TokenMgrException now)
+Other changes:
+
+* 297: enable access to tokens.
+* 341, 361: node positions are now OO
+* 211, 373: escaping of \n \r for string literals
+* 336, 276, 141: JavaDoc support now works
+* 337, 281: reorganize the stream reading code
+* 343, 309, 332, 57: take advantage of common interfaces
+* 329, 326, 327: deal with platform issues
+* 163, 236, 252, 296, 269, 339, 321, 322, 252, 253, 293, 295: various fixes
+* 310, 311, 313, 301, 294: some code clean-ups
+
+Version 2.4.0
+-------------
+* several fixes in DumpVisitor for bugs due to lazy initialization
+* make TypeDeclaration implements DocumentableNode directly
+* TypedNode interface introduced
+* introduce MultiBoundType
+* refactored IntersectionType and UnionType
+* refactored CatchClause
+* parsing annotations in throws declarations
+* parse orphan semicolons in import statements
+* added PackageDeclaration.getPackageName
+* solved issue with newlines in string literals
+* fixed handling of UnknownType in EqualsVisitor
+* improvements to CommentsParser
+* removing old grammar
+
+Version 2.3.0
+-------------
+* ClassOrInterfaceType implements NamedNode
+* DumpVisitor can now be extended
+* Improved documentation
+* AST: lists are now lazy initialized
+
+Version 2.1.0
+-------------
+* Features
+ * [#75 performance improvement for `PositionUtils.sortByBeginPosition`](https://github.com/javaparser/javaparser/issues/75)
+ * [#64 In getDeclarationAsString parameter names should be optional](https://github.com/javaparser/javaparser/issues/64)
+* Bugfixes
+ * [#79 Fix NPE in `ConstructorDeclaration.getDeclarationAsString`](https://github.com/javaparser/javaparser/pull/79)
+ * [#86 Add missing functions to ModifierVisitorAdapter](https://github.com/javaparser/javaparser/pull/86)
+ * [#82 set LambdaExpr as parent of its child nodes](https://github.com/javaparser/javaparser/issues/82)
+ * [#87 implement `setJavadoc` and `getJavadoc` at various classes](https://github.com/javaparser/javaparser/issues/87)
+ * [#96 Fixed encoding issue in `Javaparser.parse`](https://github.com/javaparser/javaparser/pull/96)
+ * [#85 Casting a lambda expression causes a parsing failure](https://github.com/javaparser/javaparser/issues/85)
+ * [#88 `MethodReferenceExpr` and `TypeExpr` don't set themselves as parents](https://github.com/javaparser/javaparser/issues/88)
+* Internal
+ * [#89 CommentsParser.State contains unused fields](https://github.com/javaparser/javaparser/issues/89)
+ * Switched from drone.io to [Travis](https://travis-ci.org/javaparser/javaparser)
+ * [#105 Enforce compiling the library for a certain Java version](https://github.com/javaparser/javaparser/pull/105)
+
+[Code changes](https://github.com/javaparser/javaparser/compare/javaparser-parent-2.0.0...master)
+
+Version 2.0.0
+-------------
+* support Java 8
+
+Version 1.0.8 (2010-01-17)
+-------------
+* Fixed issues:
+ * Issue 17: A refactor suggestion for AnnotationExpr and its subclasses
+ * Issue 21: Java 5 JavaParser compiled JARs
+ * Issue 22: Please use java.lang.reflect.Modifier constants in japa.parser.ast.body.ModifierSet
+ * Issue 27: Implement the "equal" method
+ * Issue 30: equals and hashCode methods
+
+Version 1.0.7 (2009-04-12)
+-------------
+* Issue 19 fixed:
+* Tests changed to run with junit 4
+
+Version 1.0.6 (2009-01-11)
+-------------
+* Issue 11 fixed: changed method get/setPakage to get/setPackage in the class CompilationUnit
+* Created new visitor adapter to help AST modification: ModifierVisitorAdapter
+* Changed visitor adapters to abstract
+
+Version 1.0.5 (2008-10-26)
+-------------
+* Created simplified constructors in the nodes of the AST (without positional arguments)
+* Created ASTHelper class with some helpful methods (more methods are still needed)
+
+Version 1.0.4 (2008-10-07)
+-------------
+* Moved to javacc 4.1.
+* The java_1_5.jj can be build alone without compilation errors
+
+Version 1.0.3 (2008-09-06)
+-------------
+* Removed SuperMemberAccessExpr class, it was no longer used
+* Removed the methods get/setTypeArgs() from ArrayCreationExpr, this node shouldn't have these methods.
+* Fixed the bug with start/end position of the nodes IntegerLiteralMinValueExpr and LongLiteralMinValueExpr
+* The methods get/setAnnotations() from all BodyDeclaration subclasses were pushed down to BodyDeclaration class
+
+Version 1.0.2 (2008-07-20)
+-------------
+* Issue fixed: Issue 1: Add support for editing AST nodes or create new ones
+
+Version 1.0.1 (2008-07-01)
+-------------
+* Issue fixed: Issue 5: end line and end column equal to begin line and begin column
+
+Version 1.0.0 (2008-06-25)
+-------------
+* Changed version numbering, starting version 1.0.0
+* Javadoc done for packages:
+ * japa.parser
+ * japa.parser.ast
+* Corrected bug when parsing in multithread:
+ * JavaParser.setCacheParser(false) must be called before to use the parser concurrent
+
+2008-06-19
+-------------
+* No code changes, added binary distribution to download page
+
+2008-06-11
+-------------
+* Bug corrected: NPE in VoidVisitorAdapter
+ * http://code.google.com/p/javaparser/issues/detail?id=2
+
+2008-06-09
+-------------
+* Added Adapters for de visitors
+
+2008-05-28
+-------------
+* This project now is published at Google Code:
+ * http://code.google.com/p/javaparser/
+
+2008-05-25
+-------------
+* Added support for comments and javadoc to the tree.
+ * Javadocs are stored directly to members (BodyDeclaration and all deriveds (classes, methods, fields, etc.)), accessible by the method getJavadoc().
+ * All comments are stored in the CompilationUnit, accessible by the method getComments().
+
+2008-04-01
+-------------
+* Changed all nodes public attributes to be private and created getters to access them
+* Changed the methods of the Node getLine e getColumn to getBeginLine and getBeginColumn
+* Added the methods getEndLine and getEndColumn to the Node class (works only in the BlockNode)
+
+2007-12-22
+-------------
+* Corrected ConditionalExpression bug
+
+2007-10-21
+-------------
+* Added LGPL License
+
+2007-10-21
+-------------
+* Bugs corrected:
+ * Created PackageDeclaration member of CompilationUnit to add suport for annotations in the package declaration
+ * Parameterized anonymous constructor invocation
+ * Explicit constructor invotation Type Arguments
+ * ctrl+z ("\u001A") ar end of compilation unit
+
+2007-10-09
+-------------
+* EnumConstantDeclaration annotation support corrected
+* Parssing Java Unicode escape characters suport added
+
+2007-10-03
+-------------
+* Bug corrected: "MotifComboPopup.this.super()" statement was generating parser error
+
+2007-10-01
+-------------
+* Bug corrected: Casting signed primitive values
+```
+ double d = (double) -1;
+ ^
+```
+2007-08-06
+-------------
+* Bug with the single line comments in the final of the unit corrected
+
+2007-07-31
+-------------
+* Fixed the bug with the following expression: `Class c = (int.class);`
+
+2007-06-26
+-------------
+* Bug fixes from Leon Poyyayil work
+ * suport for hex floating point
+ * unicode digits in indentifier
+ * MemberValueArrayInitializer
+
+2007-03-09
+-------------
+* Long and Integer literal MIN_VALUE bug
+
+2007-02-24
+-------------
+* '\0' bug fixed
+
+2007-02-01
+-------------
+* Many bug fixes
+* Added line/column to nodes
diff --git a/codecov.yml b/codecov.yml
new file mode 100644
index 0000000..4755d38
--- /dev/null
+++ b/codecov.yml
@@ -0,0 +1,90 @@
+codecov:
+ require_ci_to_pass: true
+
+
+coverage:
+
+ ## Configure decimal places, rounding, and the colour ranges used:
+ ## https://docs.codecov.com/docs/coverage-configuration
+ precision: 3
+ round: down
+ range: "70...90" # Colour range - 70% coverage (and below) is solid red, 90% coverage (and above) is solid green.
+
+
+ ## These statuses show at the bottom of the PR.
+ ## Split the coverage reporting into sub-projects.
+ ## https://docs.codecov.io/docs/commit-status
+ ## https://docs.codecov.io/docs/codecovyml-reference#coveragestatus
+ status:
+
+ ## Status configuration of the whole project
+ project:
+
+ whole_project: ## Whole project (note no flags specified)
+ target: auto ## Increase overall coverage on each pull request (compared to the previous base commit)
+ threshold: 0.5% ## Flexibility in allowing a minor drop in coverage
+
+ javaparser-core: ## Just JavaParser Core
+ target: auto ## Increase overall coverage on each pull request (compared to the previous base commit)
+ threshold: 0.5% ## Flexibility in allowing a minor drop in coverage
+ ## TBC: Unclear if setting flags AND paths is redundant
+ flags:
+ - javaparser-core
+ paths:
+ - javaparser-core/src/main/java*
+ - javaparser-core-testing/src/test/java*
+ - javaparser-core-testing-bdd/src/test/java*
+
+ javaparser-symbol-solver: ## Just the Symbol Solver
+ target: auto ## Increase overall coverage on each pull request (compared to the previous base commit)
+ threshold: 0.5% ## Flexibility in allowing a minor drop in coverage
+ ## TBC: Unclear if setting flags AND paths is redundant
+ flags:
+ - javaparser-symbol-solver
+ paths:
+ - javaparser-symbol-solver-core/src/main/java*
+ - javaparser-symbol-solver-testing/src/test/java*
+
+ ## Status configuration of ONLY the changed lines
+ patch:
+
+
+
+## Configuration of the comments that get added to PRs
+comment:
+ layout: "reach,diff,flags,files,footer"
+ behavior: default
+ require_changes: false
+ ### Do not comment on the PR until coverage reports for all builds has been received
+ ### Note: 54 = three OSs (mac, windows, ubuntu) x nine java levels (8,9,10,11,12,13,14,15,16) x two modules (jp-core, jss)
+ after_n_builds: 54
+
+
+## Flags defined elsewhere MUST also be defined here (required for GitHub PR checks information)
+flags:
+ javaparser-core:
+ paths:
+ - javaparser-core/src/main/java*
+ - javaparser-core-testing/src/test/java*
+ - javaparser-core-testing-bdd/src/test/java*
+ carryforward: false
+ javaparser-symbol-solver:
+ paths:
+ - javaparser-symbol-solver-core/src/main/java*
+ - javaparser-symbol-solver-testing/src/test/java*
+ carryforward: false
+
+
+# ## New section re: flags
+# ## No individual flags are added to YAML and flag names are automatically ingested from the Uploader
+# ## https://docs.codecov.com/docs/flags
+# flag_management:
+# default_rules:
+# carryforward: false
+
+
+ignore:
+ - "/javaparser-core/src/main/java-templates/**" ## This source is ...
+# - "/javaparser-core/src/main/javacc-support/**" ## This source is generated by JavaCC
+ - "/javaparser-symbol-solver-testing/src/test/test_sourcecode/**" ## This source is used as inputs to test cases
+
diff --git a/debian/README.source b/debian/README.source
new file mode 100644
index 0000000..f23086f
--- /dev/null
+++ b/debian/README.source
@@ -0,0 +1,9 @@
+This package uses a version control system as described in
+http://wiki.debian.org/Java/JavaVcs and the pages linked from there.
+
+It contains the upstream source within the VCS upstream branch.
+Upstream versions are tagged as upstream/.
+
+The original tarball was repackaged, because it was distributed in there
+zip format. Use debian/rules get-orig-source to repeat the repackaging.
+
diff --git a/debian/changelog b/debian/changelog
index bad88e2..38b9a00 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,5 +1,62 @@
-template-repository (1.0-1) unstable; urgency=medium
+javaparser (3.25.10+dfsg-1) unstable; urgency=medium
- * Initial release
+ * Team upload
+ * New upstream version 3.25.10+dfsg
+ * Refreshing patches
+ * Raising Standards version to 4.7.0 (no change)
+ * Repacking with +dfsg suffix
+ * Changing the Maven coordinates of javacc in a patch instead of the
+ d/maven.rules mechanism
+ * Ignoring the jacoco plugin during the build
+ * Set upstream metadata fields: Repository-Browse.
- -- Tsic404 Sat, 28 Jan 2023 13:46:49 +0800
+ -- Pierre Gruet Wed, 24 Apr 2024 22:05:32 +0200
+
+javaparser (3.16.3-2) unstable; urgency=medium
+
+ * Team upload.
+ * Removing repeated @Deprecated annotations in generated sources
+ (Closes: #1011814)
+ * Raising d/watch version to 4
+ * Marking the binary package as Multi-arch: foreign
+ * Trim trailing whitespace.
+ * Use secure copyright file specification URI.
+ * Use secure URI in Homepage field.
+ * Set upstream metadata fields: Bug-Database, Bug-Submit, Repository,
+ Repository-Browse.
+
+ -- Pierre Gruet Wed, 07 Sep 2022 06:59:57 +0200
+
+javaparser (3.16.3-1) unstable; urgency=medium
+
+ * Team upload.
+ * New upstream release (Closes: 901371)
+ - Depend on javacc (>= 6.0)
+ - New dependency on libtemplating-maven-plugin-java
+ * Standards-Version updated to 4.6.1
+ * Switch to debhelper level 13
+ * Removed the -java-doc package
+ * Use salsa.debian.org Vcs-* URLs
+ * Remove the jar files from the upstream tarball
+
+ -- Emmanuel Bourg Mon, 16 May 2022 08:16:36 +0200
+
+javaparser (1.0.11-1) unstable; urgency=medium
+
+ * Team upload.
+ * New upstream release
+ * Build with maven-debian-helper instead of javahelper
+ * Standards-Version updated to 4.0.0
+ * Switch to debhelper level 10
+ * Use secure Vcs-* URLs
+ * Updated the Homepage field
+ * Track and download the new releases from GitHub
+ * Updated the Format URI in debian/copyright
+
+ -- Emmanuel Bourg Mon, 03 Jul 2017 10:40:15 +0200
+
+javaparser (1.0.8-1) unstable; urgency=low
+
+ * Initial release. (Closes: #711109)
+
+ -- Benjamin Mesing Wed, 23 Oct 2013 21:14:08 +0200
diff --git a/debian/compat b/debian/compat
deleted file mode 100644
index b4de394..0000000
--- a/debian/compat
+++ /dev/null
@@ -1 +0,0 @@
-11
diff --git a/debian/control b/debian/control
index cb7c4a0..9a440b5 100644
--- a/debian/control
+++ b/debian/control
@@ -1,15 +1,35 @@
-Source: template-repository
-Section: unknown
+Source: javaparser
+Section: java
Priority: optional
-Maintainer: Tsic404
-Build-Depends: debhelper (>= 11)
-Standards-Version: 4.1.3
-Homepage: https://github.com/deepin-community/template-repository
-#Vcs-Browser: https://salsa.debian.org/debian/deepin-community-template-repository
-#Vcs-Git: https://salsa.debian.org/debian/deepin-community-template-repository.git
+Maintainer: Debian Java Maintainers
+Uploaders: Benjamin Mesing
+Build-Depends:
+ debhelper-compat (= 13),
+ javacc (>= 6.0),
+ libbuild-helper-maven-plugin-java,
+ libexec-maven-plugin-java,
+ libjavacc-maven-plugin-java,
+ libtemplating-maven-plugin-java,
+ maven-debian-helper
+Standards-Version: 4.7.0
+Vcs-Git: https://salsa.debian.org/java-team/javaparser.git
+Vcs-Browser: https://salsa.debian.org/java-team/javaparser
+Homepage: https://javaparser.org
-Package: template-repository
-Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}
-Description:
-
+Package: libjavaparser-java
+Architecture: all
+Depends: ${maven:Depends}, ${misc:Depends}
+Recommends: ${maven:OptionalDepends}
+Multi-Arch: foreign
+Description: Java library for parsing Java 7
+ The library features abstract syntax tree (AST) generation and supports
+ the visitor pattern. The AST records the source code structure, javadoc
+ and comments. It is also possible to change the AST nodes or create new
+ ones to modify the source code.
+ .
+ Main features are:
+ * light weight
+ * good performance
+ * easy to use
+ * AST can be modified
+ * AST can be created from scratc
diff --git a/debian/copyright b/debian/copyright
index f5c805e..a113896 100644
--- a/debian/copyright
+++ b/debian/copyright
@@ -1,22 +1,19 @@
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
-Upstream-Name: template-repository
-Source: https://github.com/deepin-community/template-repository
+Upstream-Name: javaparser
+Upstream-Contact: Júlio Vilmar Gesser
+Source: https://github.com/javaparser/javaparser
+Files-Excluded: *.jar
+ *.aar
Files: *
-Copyright: 2023 Tsic404
-License: GPL-2+
- This package is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2 of the License, or
- (at your option) any later version.
- .
- This package is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
- .
- You should have received a copy of the GNU General Public License
- along with this program. If not, see
- .
- On Debian systems, the complete text of the GNU General
- Public License version 2 can be found in "/usr/share/common-licenses/GPL-2".
+Copyright: 2007, Júlio Vilmar Gesser
+License: LGPL-3+
+
+Files: debian/*
+Copyright: 2013, Benjamin Mesing
+License: LGPL-3+
+
+License: LGPL-3+
+ LGPL license 3.0 or any later version of that license.
+ On Debian GNU/Linux system you can find the complete text of the
+ license in '/usr/share/common-licenses/LGPL-3'
diff --git a/debian/libjavaparser-java.poms b/debian/libjavaparser-java.poms
new file mode 100644
index 0000000..e403133
--- /dev/null
+++ b/debian/libjavaparser-java.poms
@@ -0,0 +1,9 @@
+pom.xml --no-parent
+javaparser-core/pom.xml --has-package-version --java-lib
+javaparser-core-generators/pom.xml --ignore
+javaparser-core-metamodel-generator/pom.xml --ignore
+javaparser-core-serialization/pom.xml --ignore
+javaparser-core-testing/pom.xml --ignore
+javaparser-core-testing-bdd/pom.xml --ignore
+javaparser-symbol-solver-core/pom.xml --ignore
+javaparser-symbol-solver-testing/pom.xml --ignore
diff --git a/debian/maven.ignoreRules b/debian/maven.ignoreRules
new file mode 100644
index 0000000..3fbd462
--- /dev/null
+++ b/debian/maven.ignoreRules
@@ -0,0 +1,6 @@
+
+biz.aQute.bnd bnd-maven-plugin
+org.apache.maven.plugins maven-jar-plugin
+org.apache.maven.plugins maven-source-plugin
+org.codehaus.mojo extra-enforcer-rules
+org.jacoco jacoco-maven-plugin * * * *
diff --git a/debian/maven.rules b/debian/maven.rules
new file mode 100644
index 0000000..d6696a1
--- /dev/null
+++ b/debian/maven.rules
@@ -0,0 +1 @@
+junit junit * s/.*/4.x/ * *
diff --git a/debian/patches/javacc_coordinates.patch b/debian/patches/javacc_coordinates.patch
new file mode 100644
index 0000000..26c0593
--- /dev/null
+++ b/debian/patches/javacc_coordinates.patch
@@ -0,0 +1,35 @@
+Description: providing the Maven coordinates of the Debian-packaged javacc
+ I don't understand why, but the standard debian/maven.rules mechanism does not
+ allow one to recover the good coordinates.
+Author: Pierre Gruet
+Forwarded: not-needed
+Last-Update: 2024-04-24
+
+--- a/javaparser-core/pom.xml
++++ b/javaparser-core/pom.xml
+@@ -31,8 +31,8 @@
+
+
+
+- com.helger.maven
+- ph-javacc-maven-plugin
++ org.codehaus.mojo
++ javacc-maven-plugin
+
+
+ javacc
+--- a/pom.xml
++++ b/pom.xml
+@@ -195,9 +195,9 @@
+
+
+
+- com.helger.maven
+- ph-javacc-maven-plugin
+- 4.1.5
++ org.codehaus.mojo
++ javacc-maven-plugin
++ 2.6
+
+
+ org.apache.maven.plugins
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..aaeb76e
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+javacc_coordinates.patch
diff --git a/debian/upstream/metadata b/debian/upstream/metadata
new file mode 100644
index 0000000..4fefb13
--- /dev/null
+++ b/debian/upstream/metadata
@@ -0,0 +1,5 @@
+---
+Bug-Database: https://github.com/javaparser/javaparser/issues
+Bug-Submit: https://github.com/javaparser/javaparser/issues/new
+Repository: https://github.com/javaparser/javaparser.git
+Repository-Browse: https://github.com/javaparser/javaparser
diff --git a/debian/watch b/debian/watch
new file mode 100644
index 0000000..2d682ae
--- /dev/null
+++ b/debian/watch
@@ -0,0 +1,3 @@
+version=4
+opts="mode=git,repack,repacksuffix=+dfsg,dversionmangle=s/+dfsg//,compression=xz" \
+https://github.com/javaparser/javaparser refs/tags/javaparser(?:-parent)?-([\d\.]+)
diff --git a/dev-files/JavaParser-CheckStyle.xml b/dev-files/JavaParser-CheckStyle.xml
new file mode 100644
index 0000000..534866b
--- /dev/null
+++ b/dev-files/JavaParser-CheckStyle.xml
@@ -0,0 +1,46 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/dev-files/JavaParser-eclipse.xml b/dev-files/JavaParser-eclipse.xml
new file mode 100644
index 0000000..853811c
--- /dev/null
+++ b/dev-files/JavaParser-eclipse.xml
@@ -0,0 +1,295 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dev-files/JavaParser-idea.xml b/dev-files/JavaParser-idea.xml
new file mode 100644
index 0000000..fd90eed
--- /dev/null
+++ b/dev-files/JavaParser-idea.xml
@@ -0,0 +1,38 @@
+
+
+
" +
+ "\n" +
+ "\nFor this reason, any changes made directly to this file will be overwritten the next time generators are run." +
+ "";
+
+ private static final String GENERATED_JAVADOC_COMMENT = "Warning: The content of this class is partially or completely generated - manual edits risk being overwritten.";
+
+ protected NodeMetaModelGenerator(SourceRoot sourceRoot) {
+ super(sourceRoot);
+ }
+
+ public void generate(Class extends Node> nodeClass, ClassOrInterfaceDeclaration metaModelCoid, NodeList initializeNodeMetaModelsStatements, NodeList initializePropertyMetaModelsStatements, NodeList initializeConstructorParametersStatements, SourceRoot sourceRoot) throws NoSuchMethodException {
+ metaModelCoid.setJavadocComment(GENERATED_JAVADOC_COMMENT);
+
+ final AstTypeAnalysis typeAnalysis = new AstTypeAnalysis(nodeClass);
+
+ final String className = MetaModelGenerator.nodeMetaModelName(nodeClass);
+ final String nodeMetaModelFieldName = decapitalize(className);
+ metaModelCoid.getFieldByName(nodeMetaModelFieldName).ifPresent(Node::remove);
+
+ initializeNodeMetaModelsStatements.add(parseStatement(f("nodeMetaModels.add(%s);", nodeMetaModelFieldName)));
+ this.initializeConstructorParametersStatementsGenerator.generate(nodeClass, initializeConstructorParametersStatements);
+
+ final Class> superclass = nodeClass.getSuperclass();
+ final String superNodeMetaModel = MetaModelGenerator.nodeMetaModelName(superclass);
+ final boolean isRootNode = !MetaModelGenerator.isNode(superclass);
+
+ final FieldDeclaration nodeField = metaModelCoid.addField(className, nodeMetaModelFieldName, PUBLIC, STATIC, FINAL);
+ annotateGenerated(nodeField);
+ nodeField.getVariable(0).setInitializer(
+ parseExpression(
+ f("new %s(%s)",
+ className,
+ optionalOf(decapitalize(superNodeMetaModel), !isRootNode))
+ )
+ );
+
+
+ // The node-specific metamodel file
+ final CompilationUnit classMetaModelJavaFile = new CompilationUnit(MetaModelGenerator.METAMODEL_PACKAGE);
+ classMetaModelJavaFile.setBlockComment(COPYRIGHT_NOTICE_JP_CORE);
+ classMetaModelJavaFile.addImport(Optional.class);
+ classMetaModelJavaFile.addImport(nodeClass);
+
+ //
+ final ClassOrInterfaceDeclaration nodeMetaModelClass = classMetaModelJavaFile.addClass(className, PUBLIC);
+ annotateGenerated(nodeMetaModelClass);
+ nodeMetaModelClass.setJavadocComment(GENERATED_CLASS_COMMENT);
+
+ if (isRootNode) {
+ nodeMetaModelClass.addExtendedType(MetaModelGenerator.BASE_NODE_META_MODEL);
+ } else {
+ nodeMetaModelClass.addExtendedType(superNodeMetaModel);
+ }
+
+ // Constructors
+ final ConstructorDeclaration classMMConstructor = nodeMetaModelClass
+ .addConstructor()
+ .addParameter(
+ f("Optional<%s>", MetaModelGenerator.BASE_NODE_META_MODEL),
+ f("super%s", MetaModelGenerator.BASE_NODE_META_MODEL)
+ );
+ classMMConstructor
+ .getBody()
+ .addStatement(
+ parseExplicitConstructorInvocationStmt(f("super(super%s, %s.class, \"%s\", \"%s\", %s, %s);",
+ MetaModelGenerator.BASE_NODE_META_MODEL,
+ nodeClass.getSimpleName(),
+ nodeClass.getSimpleName(),
+ nodeClass.getPackage().getName(),
+ typeAnalysis.isAbstract,
+ typeAnalysis.isSelfType
+ ))
+ );
+ annotateGenerated(classMMConstructor);
+
+ // ?Abstract protected constructor?
+ if (typeAnalysis.isAbstract) {
+ classMetaModelJavaFile.addImport(Node.class);
+ BodyDeclaration> bodyDeclaration = parseBodyDeclaration(f(
+ "protected %s(Optional<%s> superNodeMetaModel, Class extends Node> type, String name, String packageName, boolean isAbstract, boolean hasWildcard) {" +
+ "super(superNodeMetaModel, type, name, packageName, isAbstract, hasWildcard);" +
+ " }",
+ className,
+ MetaModelGenerator.BASE_NODE_META_MODEL
+ ));
+ annotateGenerated(bodyDeclaration);
+ nodeMetaModelClass.addMember(bodyDeclaration);
+ }
+
+ // Fields, sorted by name.
+ final List fields = new ArrayList<>(Arrays.asList(nodeClass.getDeclaredFields()));
+ fields.sort(Comparator.comparing(Field::getName));
+ for (Field field : fields) {
+ if (this.fieldShouldBeIgnored(field)) {
+ continue;
+ }
+
+ this.initializePropertyMetaModelsStatementsGenerator.generate(field, nodeMetaModelClass, nodeMetaModelFieldName, initializePropertyMetaModelsStatements);
+ }
+
+ // Methods, sorted by name.
+ final List methods = new ArrayList<>(Arrays.asList(nodeClass.getMethods()));
+ methods.sort(Comparator.comparing(Method::getName));
+ for (Method method : methods) {
+ if (method.isAnnotationPresent(DerivedProperty.class)) {
+ this.initializePropertyMetaModelsStatementsGenerator.generateDerivedProperty(method, nodeMetaModelClass, nodeMetaModelFieldName, initializePropertyMetaModelsStatements);
+ }
+ }
+
+
+ this.moveStaticInitializeToTheEndOfTheClassBecauseWeNeedTheFieldsToInitializeFirst(metaModelCoid);
+
+ // Add the file to the source root, enabling it to be saved later.
+ sourceRoot.add(MetaModelGenerator.METAMODEL_PACKAGE, className + ".java", classMetaModelJavaFile);
+ }
+
+ private void moveStaticInitializeToTheEndOfTheClassBecauseWeNeedTheFieldsToInitializeFirst(ClassOrInterfaceDeclaration metaModelCoid) {
+ for (BodyDeclaration> m : metaModelCoid.getMembers()) {
+ if (m instanceof InitializerDeclaration) {
+ m.remove();
+ metaModelCoid.addMember(m);
+ return;
+ }
+ }
+ }
+
+ private boolean fieldShouldBeIgnored(Field reflectionField) {
+ return java.lang.reflect.Modifier.isStatic(reflectionField.getModifiers()) ||
+ reflectionField.isAnnotationPresent(InternalProperty.class);
+ }
+}
diff --git a/javaparser-core-serialization/pom.xml b/javaparser-core-serialization/pom.xml
new file mode 100644
index 0000000..6f64d24
--- /dev/null
+++ b/javaparser-core-serialization/pom.xml
@@ -0,0 +1,71 @@
+
+
+ javaparser-parent
+ com.github.javaparser
+ 3.25.10
+
+ 4.0.0
+
+ javaparser-core-serialization
+ Serializers for the JavaParser AST.
+
+
+
+ GNU Lesser General Public License
+ http://www.gnu.org/licenses/lgpl-3.0.html
+ repo
+
+
+ Apache License, Version 2.0
+ http://www.apache.org/licenses/LICENSE-2.0.txt
+ repo
+ A business-friendly OSS license
+
+
+
+
+ 1.8
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-jar-plugin
+
+
+
+ com.github.javaparser.core.serialization
+
+
+
+
+
+
+
+
+
+
+ org.junit.jupiter
+ junit-jupiter-engine
+
+
+ com.github.javaparser
+ javaparser-core
+ ${project.version}
+
+
+ jakarta.json
+ jakarta.json-api
+ 2.1.3
+
+
+
+ org.eclipse.parsson
+ parsson
+ 1.1.5
+ test
+
+
+
+
diff --git a/javaparser-core-serialization/src/main/java/com/github/javaparser/serialization/JavaParserJsonDeserializer.java b/javaparser-core-serialization/src/main/java/com/github/javaparser/serialization/JavaParserJsonDeserializer.java
new file mode 100644
index 0000000..f2192ad
--- /dev/null
+++ b/javaparser-core-serialization/src/main/java/com/github/javaparser/serialization/JavaParserJsonDeserializer.java
@@ -0,0 +1,208 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+package com.github.javaparser.serialization;
+
+import com.github.javaparser.*;
+import com.github.javaparser.ast.CompilationUnit;
+import com.github.javaparser.ast.Node;
+import com.github.javaparser.ast.NodeList;
+import com.github.javaparser.ast.comments.Comment;
+import com.github.javaparser.metamodel.BaseNodeMetaModel;
+import com.github.javaparser.metamodel.PropertyMetaModel;
+import com.github.javaparser.utils.Log;
+
+import jakarta.json.JsonArray;
+import jakarta.json.JsonObject;
+import jakarta.json.JsonReader;
+import jakarta.json.JsonValue;
+
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Optional;
+
+import static com.github.javaparser.ast.NodeList.toNodeList;
+import static com.github.javaparser.metamodel.JavaParserMetaModel.getNodeMetaModel;
+import static com.github.javaparser.serialization.JavaParserJsonSerializer.*;
+
+/**
+ * Deserializes the JSON file that was built by {@link JavaParserJsonSerializer}.
+ */
+public class JavaParserJsonDeserializer {
+ /**
+ * Deserializes json, contained by JsonReader, into AST node.
+ * The root node and all its child nodes will be deserialized.
+ * @param reader json-p reader (object-level reader, see their docs)
+ * @return the root level deserialized node
+ */
+ public Node deserializeObject(JsonReader reader) {
+ Log.info("Deserializing JSON to Node.");
+ JsonObject jsonObject = reader.readObject();
+ return deserializeObject(jsonObject);
+ }
+
+ /**
+ * Recursive depth-first deserializing method that creates a Node instance from JsonObject.
+ *
+ * @param nodeJson json object at current level containg values as properties
+ * @return deserialized node including all children.
+ * @implNote the Node instance will be constructed by the properties defined in the meta model.
+ * Non meta properties will be set after Node is instantiated.
+ * @implNote comment is included in the propertyKey meta model, but not set when constructing the Node instance.
+ * That is, comment is not included in the constructor propertyKey list, and therefore needs to be set
+ * after constructing the node.
+ * See {@link com.github.javaparser.metamodel.BaseNodeMetaModel#construct(Map)} how the node is contructed
+ */
+ private Node deserializeObject(JsonObject nodeJson) {
+ try {
+ String serializedNodeType = nodeJson.getString(JsonNode.CLASS.propertyKey);
+ BaseNodeMetaModel nodeMetaModel = getNodeMetaModel(Class.forName(serializedNodeType))
+ .orElseThrow(() -> new IllegalStateException("Trying to deserialize an unknown node type: " + serializedNodeType));
+ Map parameters = new HashMap<>();
+ Map deferredJsonValues = new HashMap<>();
+
+ for (String name : nodeJson.keySet()) {
+ if (name.equals(JsonNode.CLASS.propertyKey)) {
+ continue;
+ }
+
+ Optional optionalPropertyMetaModel = nodeMetaModel.getAllPropertyMetaModels().stream()
+ .filter(mm -> mm.getName().equals(name))
+ .findFirst();
+ if (!optionalPropertyMetaModel.isPresent()) {
+ deferredJsonValues.put(name, nodeJson.get(name));
+ continue;
+ }
+
+ PropertyMetaModel propertyMetaModel = optionalPropertyMetaModel.get();
+ if (propertyMetaModel.isNodeList()) {
+ JsonArray nodeListJson = nodeJson.getJsonArray(name);
+ parameters.put(name, deserializeNodeList(nodeListJson));
+ } else if (propertyMetaModel.isNode()) {
+ parameters.put(name, deserializeObject(nodeJson.getJsonObject(name)));
+ } else {
+ Class> type = propertyMetaModel.getType();
+ if (type == String.class) {
+ parameters.put(name, nodeJson.getString(name));
+ } else if (type == boolean.class) {
+ parameters.put(name, Boolean.parseBoolean(nodeJson.getString(name)));
+ } else if (Enum.class.isAssignableFrom(type)) {
+ parameters.put(name, Enum.valueOf((Class extends Enum>) type, nodeJson.getString(name)));
+ } else {
+ throw new IllegalStateException("Don't know how to convert: " + type);
+ }
+ }
+ }
+
+ Node node = nodeMetaModel.construct(parameters);
+ // COMMENT is in the propertyKey meta model, but not required as constructor parameter.
+ // Set it after construction
+ if (parameters.containsKey(JsonNode.COMMENT.propertyKey)) {
+ node.setComment((Comment)parameters.get(JsonNode.COMMENT.propertyKey));
+ }
+
+ for (String name : deferredJsonValues.keySet()) {
+ if (!readNonMetaProperties(name, deferredJsonValues.get(name), node)) {
+ throw new IllegalStateException("Unknown propertyKey: " + nodeMetaModel.getQualifiedClassName() + "." + name);
+ }
+ }
+ setSymbolResolverIfCompilationUnit(node);
+
+ return node;
+ } catch (ClassNotFoundException e) {
+ throw new RuntimeException(e);
+ }
+ }
+
+ private NodeList> deserializeNodeList(JsonArray nodeListJson) {
+ return nodeListJson.stream().map(nodeJson -> deserializeObject((JsonObject) nodeJson)).collect(toNodeList());
+ }
+
+ /**
+ * Reads properties from json not included in meta model (i.e., RANGE and TOKEN_RANGE).
+ * When read, it sets the deserialized value to the node instance.
+ * @param name propertyKey name for json value
+ * @param jsonValue json value that needs to be deserialized for this propertyKey
+ * @param node instance to which the deserialized value will be set to
+ * @return true if propertyKey is read from json and set to Node instance
+ */
+ protected boolean readNonMetaProperties(String name, JsonValue jsonValue, Node node) {
+ return readRange(name, jsonValue, node)
+ || readTokenRange(name, jsonValue, node);
+ }
+
+ protected boolean readRange(String name, JsonValue jsonValue, Node node) {
+ if (name.equals(JsonNode.RANGE.propertyKey)) {
+ JsonObject jsonObject = (JsonObject)jsonValue;
+ Position begin = new Position(
+ jsonObject.getInt(JsonRange.BEGIN_LINE.propertyKey),
+ jsonObject.getInt(JsonRange.BEGIN_COLUMN.propertyKey)
+ );
+ Position end = new Position(
+ jsonObject.getInt(JsonRange.END_LINE.propertyKey),
+ jsonObject.getInt(JsonRange.END_COLUMN.propertyKey)
+ );
+ node.setRange(new Range(begin, end));
+ return true;
+ }
+ return false;
+ }
+
+ protected boolean readTokenRange(String name, JsonValue jsonValue, Node node) {
+ if (name.equals(JsonNode.TOKEN_RANGE.propertyKey)) {
+ JsonObject jsonObject = (JsonObject)jsonValue;
+ JavaToken begin = readToken(
+ JsonTokenRange.BEGIN_TOKEN.propertyKey, jsonObject
+ );
+ JavaToken end = readToken(
+ JsonTokenRange.END_TOKEN.propertyKey, jsonObject
+ );
+ node.setTokenRange(new TokenRange(begin, end));
+ return true;
+ }
+ return false;
+ }
+
+ protected JavaToken readToken(String name, JsonObject jsonObject) {
+ JsonObject tokenJson = jsonObject.getJsonObject(name);
+ return new JavaToken(
+ tokenJson.getInt(JsonToken.KIND.propertyKey),
+ tokenJson.getString(JsonToken.TEXT.propertyKey)
+ );
+ }
+
+ /**
+ * This method sets symbol resolver to Node if it is an instance of CompilationUnit
+ * and a SymbolResolver is configured in the static configuration. This is necessary to be able to resolve symbols
+ * within the cu after deserialization. Normally, when parsing java with JavaParser, the symbol resolver is injected
+ * to the cu as a data element with key SYMBOL_RESOLVER_KEY.
+ * @param node instance to which symbol resolver will be set to when instance of a Compilation Unit
+ * @see com.github.javaparser.ast.Node#SYMBOL_RESOLVER_KEY
+ * @see com.github.javaparser.ParserConfiguration#ParserConfiguration()
+ */
+ private void setSymbolResolverIfCompilationUnit(Node node) {
+ if (node instanceof CompilationUnit && StaticJavaParser.getConfiguration().getSymbolResolver().isPresent()) {
+ CompilationUnit cu = (CompilationUnit)node;
+ cu.setData(Node.SYMBOL_RESOLVER_KEY, StaticJavaParser.getConfiguration().getSymbolResolver().get());
+ }
+ }
+
+
+}
diff --git a/javaparser-core-serialization/src/main/java/com/github/javaparser/serialization/JavaParserJsonSerializer.java b/javaparser-core-serialization/src/main/java/com/github/javaparser/serialization/JavaParserJsonSerializer.java
new file mode 100644
index 0000000..d468069
--- /dev/null
+++ b/javaparser-core-serialization/src/main/java/com/github/javaparser/serialization/JavaParserJsonSerializer.java
@@ -0,0 +1,203 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+package com.github.javaparser.serialization;
+
+import com.github.javaparser.JavaToken;
+import com.github.javaparser.Range;
+import com.github.javaparser.TokenRange;
+import com.github.javaparser.ast.Node;
+import com.github.javaparser.ast.NodeList;
+import com.github.javaparser.metamodel.BaseNodeMetaModel;
+import com.github.javaparser.metamodel.JavaParserMetaModel;
+import com.github.javaparser.metamodel.PropertyMetaModel;
+import com.github.javaparser.utils.Log;
+
+import jakarta.json.stream.JsonGenerator;
+
+import static com.github.javaparser.utils.Utils.decapitalize;
+import static java.util.Objects.requireNonNull;
+
+/**
+ * Serializes an AST or a partial AST to JSON.
+ */
+public class JavaParserJsonSerializer {
+
+ /**
+ * Serializes node and all its children into json. Any node siblings will be ignored.
+ *
+ * @param node the node that will be the root level json object
+ * @param generator the json-p generator for writing the json
+ * @see json-p
+ */
+ public void serialize(Node node, JsonGenerator generator) {
+ requireNonNull(node);
+ Log.info("Serializing Node to JSON.");
+ try {
+ serialize(null, node, generator);
+ } finally {
+ generator.close();
+ }
+ }
+
+ /**
+ * Recursive depth-first method that serializes nodes into json
+ *
+ * @param nodeName nullable String. If null, it is the root object, otherwise it is the property key for the object
+ * @param node the current node to be serialized
+ * @param generator the json-p generator for writing the json
+ */
+
+ private void serialize(String nodeName, Node node, JsonGenerator generator) {
+ requireNonNull(node);
+ BaseNodeMetaModel nodeMetaModel = JavaParserMetaModel.getNodeMetaModel(node.getClass()).orElseThrow(() -> new IllegalStateException("Unknown Node: " + node.getClass()));
+
+ if (nodeName == null) {
+ generator.writeStartObject();
+ } else {
+ generator.writeStartObject(nodeName);
+ }
+ generator.write(JsonNode.CLASS.propertyKey, node.getClass().getName());
+ this.writeNonMetaProperties(node, generator);
+ for (PropertyMetaModel propertyMetaModel : nodeMetaModel.getAllPropertyMetaModels()) {
+ String name = propertyMetaModel.getName();
+ Object value = propertyMetaModel.getValue(node);
+ if (value != null) {
+ if (propertyMetaModel.isNodeList()) {
+ NodeList list = (NodeList) value;
+ generator.writeStartArray(name);
+ for (Node n : list) {
+ serialize(null, n, generator);
+ }
+ generator.writeEnd();
+ } else if (propertyMetaModel.isNode()) {
+ serialize(name, (Node) value, generator);
+ } else {
+ generator.write(name, value.toString());
+ }
+ }
+ }
+ generator.writeEnd();
+ }
+
+ /***
+ * This method writes json for properties not included in meta model (i.e., RANGE and TOKEN_RANGE).
+ * This method could be overriden so that - for example - tokens are not written to json to save space
+ *
+ * @see com.github.javaparser.metamodel.BaseNodeMetaModel#getAllPropertyMetaModels()
+ */
+
+ protected void writeNonMetaProperties(Node node, JsonGenerator generator) {
+ this.writeRange(node, generator);
+ this.writeTokens(node, generator);
+ }
+
+ protected void writeRange(Node node, JsonGenerator generator) {
+ if (node.hasRange()) {
+ Range range = node.getRange().get();
+ generator.writeStartObject(JsonNode.RANGE.propertyKey);
+ generator.write(JsonRange.BEGIN_LINE.propertyKey, range.begin.line);
+ generator.write(JsonRange.BEGIN_COLUMN.propertyKey, range.begin.column);
+ generator.write(JsonRange.END_LINE.propertyKey, range.end.line);
+ generator.write(JsonRange.END_COLUMN.propertyKey, range.end.column);
+ generator.writeEnd();
+ }
+ }
+
+ protected void writeTokens(Node node, JsonGenerator generator) {
+ if (node.getTokenRange().isPresent()) {
+ TokenRange tokenRange = node.getTokenRange().get();
+ generator.writeStartObject(JsonNode.TOKEN_RANGE.propertyKey);
+ writeToken(JsonTokenRange.BEGIN_TOKEN.propertyKey, tokenRange.getBegin(), generator);
+ writeToken(JsonTokenRange.END_TOKEN.propertyKey, tokenRange.getEnd(), generator);
+ generator.writeEnd();
+ }
+ }
+
+ protected void writeToken(String name, JavaToken token, JsonGenerator generator) {
+ generator.writeStartObject(name);
+ generator.write(JsonToken.KIND.propertyKey, token.getKind());
+ generator.write(JsonToken.TEXT.propertyKey, token.getText());
+ generator.writeEnd();
+ }
+
+ /**
+ * excludes properties from meta model (except comment)
+ **/
+ public enum JsonNode {
+ RANGE("range"),
+ TOKEN_RANGE("tokenRange"),
+ COMMENT(decapitalize(JavaParserMetaModel.commentMetaModel.getTypeName())),
+ CLASS("!");
+ final String propertyKey;
+
+ JsonNode(String p) {
+ this.propertyKey = p;
+ }
+
+ public String toString() {
+ return this.propertyKey;
+ }
+ }
+
+ public enum JsonRange {
+ BEGIN_LINE("beginLine"),
+ BEGIN_COLUMN("beginColumn"),
+ END_LINE("endLine"),
+ END_COLUMN("endColumn");
+ final String propertyKey;
+
+ JsonRange(String p) {
+ this.propertyKey = p;
+ }
+
+ public String toString() {
+ return this.propertyKey;
+ }
+ }
+
+ public enum JsonTokenRange {
+ BEGIN_TOKEN("beginToken"),
+ END_TOKEN("endToken");
+ final String propertyKey;
+
+ JsonTokenRange(String p) {
+ this.propertyKey = p;
+ }
+
+ public String toString() {
+ return this.propertyKey;
+ }
+ }
+
+ public enum JsonToken {
+ TEXT("text"),
+ KIND("kind");
+ final String propertyKey;
+
+ JsonToken(String p) {
+ this.propertyKey = p;
+ }
+
+ public String toString() {
+ return this.propertyKey;
+ }
+ }
+}
diff --git a/javaparser-core-serialization/src/test/java/com/github/javaparser/serialization/JavaParserJsonDeserializerTest.java b/javaparser-core-serialization/src/test/java/com/github/javaparser/serialization/JavaParserJsonDeserializerTest.java
new file mode 100644
index 0000000..bef9fb4
--- /dev/null
+++ b/javaparser-core-serialization/src/test/java/com/github/javaparser/serialization/JavaParserJsonDeserializerTest.java
@@ -0,0 +1,235 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+package com.github.javaparser.serialization;
+
+import com.github.javaparser.ParserConfiguration;
+import com.github.javaparser.Range;
+import com.github.javaparser.StaticJavaParser;
+import com.github.javaparser.TokenRange;
+import com.github.javaparser.ast.CompilationUnit;
+import com.github.javaparser.ast.Node;
+import com.github.javaparser.ast.body.ClassOrInterfaceDeclaration;
+import com.github.javaparser.ast.body.MethodDeclaration;
+import com.github.javaparser.ast.comments.Comment;
+import com.github.javaparser.ast.expr.Expression;
+import com.github.javaparser.ast.type.Type;
+import com.github.javaparser.javadoc.Javadoc;
+import com.github.javaparser.javadoc.JavadocBlockTag;
+import com.github.javaparser.resolution.SymbolResolver;
+import com.github.javaparser.resolution.declarations.ResolvedReferenceTypeDeclaration;
+import com.github.javaparser.resolution.types.ResolvedType;
+import com.github.javaparser.utils.LineSeparator;
+
+import jakarta.json.Json;
+
+import org.junit.jupiter.api.AfterAll;
+import org.junit.jupiter.api.Test;
+
+import java.io.StringReader;
+
+import static com.github.javaparser.StaticJavaParser.*;
+import static com.github.javaparser.serialization.JavaParserJsonSerializerTest.serialize;
+import static com.github.javaparser.utils.Utils.normalizeEolInTextBlock;
+import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.assertTrue;
+
+class JavaParserJsonDeserializerTest {
+ private final JavaParserJsonDeserializer deserializer = new JavaParserJsonDeserializer();
+
+ @Test
+ void simpleTest() {
+ CompilationUnit cu = parse("public class X{} class Z{}");
+ String serialized = serialize(cu, false);
+
+ Node deserialized = deserializer.deserializeObject(Json.createReader(new StringReader(serialized)));
+
+ assertEqualsStringIgnoringEol("public class X {\n}\n\nclass Z {\n}\n", deserialized.toString());
+ assertEquals(cu.hashCode(), deserialized.hashCode());
+ }
+
+ @Test
+ void testRawType() {
+ Type type = parseType("Blub");
+ String serialized = serialize(type, false);
+
+ Node deserialized = deserializer.deserializeObject(Json.createReader(new StringReader(serialized)));
+
+ assertEqualsStringIgnoringEol("Blub", deserialized.toString());
+ assertEquals(type.hashCode(), deserialized.hashCode());
+ }
+
+ @Test
+ void testDiamondType() {
+ Type type = parseType("Blub<>");
+ String serialized = serialize(type, false);
+
+ Node deserialized = deserializer.deserializeObject(Json.createReader(new StringReader(serialized)));
+
+ assertEqualsStringIgnoringEol("Blub<>", deserialized.toString());
+ assertEquals(type.hashCode(), deserialized.hashCode());
+ }
+
+ @Test
+ void testGenerics() {
+ Type type = parseType("Blub");
+ String serialized = serialize(type, false);
+
+ Node deserialized = deserializer.deserializeObject(Json.createReader(new StringReader(serialized)));
+
+ assertEqualsStringIgnoringEol("Blub", deserialized.toString());
+ assertEquals(type.hashCode(), deserialized.hashCode());
+ }
+
+ @Test
+ void testOperator() {
+ Expression expr = parseExpression("1+1");
+ String serialized = serialize(expr, false);
+
+ Node deserialized = deserializer.deserializeObject(Json.createReader(new StringReader(serialized)));
+
+ assertEqualsStringIgnoringEol("1 + 1", deserialized.toString());
+ assertEquals(expr.hashCode(), deserialized.hashCode());
+ }
+
+ @Test
+ void testPrimitiveType() {
+ Type type = parseType("int");
+ String serialized = serialize(type, false);
+
+ Node deserialized = deserializer.deserializeObject(Json.createReader(new StringReader(serialized)));
+
+ assertEqualsStringIgnoringEol("int", deserialized.toString());
+ assertEquals(type.hashCode(), deserialized.hashCode());
+ }
+
+ @Test
+ void testComment() {
+ CompilationUnit cu = parse("/* block comment */\npublic class X{ \n // line comment\npublic void test() {}\n}");
+ String serialized = serialize(cu, false);
+
+ CompilationUnit deserialized = (CompilationUnit) deserializer.deserializeObject(Json.createReader(new StringReader(serialized)));
+ ClassOrInterfaceDeclaration classXDeclaration = deserialized.getClassByName("X").get();
+ assertTrue(classXDeclaration.getComment().isPresent());
+
+ Comment comment = classXDeclaration.getComment().get();
+ assertEquals("com.github.javaparser.ast.comments.BlockComment", comment.getClass().getName());
+ assertEquals(" block comment ", comment.getContent());
+
+ MethodDeclaration methodDeclaration = classXDeclaration.getMethods().get(0);
+ assertTrue(methodDeclaration.getComment().isPresent());
+ assertEquals("com.github.javaparser.ast.comments.LineComment", methodDeclaration.getComment().get().getClass().getName());
+ assertEquals(" line comment", methodDeclaration.getComment().get().getContent());
+ }
+
+ @Test
+ void testJavaDocComment() {
+ CompilationUnit cu = parse("public class X{ " +
+ " /**\n" +
+ " * Woke text.\n" +
+ " * @param a blub\n" +
+ " * @return true \n" +
+ " */" +
+ " public boolean test(int a) { return true; }\n" +
+ "}");
+ String serialized = serialize(cu, false);
+
+ CompilationUnit deserialized = (CompilationUnit) deserializer.deserializeObject(Json.createReader(new StringReader(serialized)));
+ ClassOrInterfaceDeclaration classDeclaration = deserialized.getClassByName("X").get();
+ MethodDeclaration methodDeclaration = classDeclaration.getMethods().get(0);
+ assertTrue(methodDeclaration.getJavadoc().isPresent());
+ Javadoc javadoc = methodDeclaration.getJavadoc().get();
+
+ JavadocBlockTag paramBlockTag = javadoc.getBlockTags().get(0);
+ assertEquals("param", paramBlockTag.getTagName());
+ assertEquals("blub", paramBlockTag.getContent().toText());
+
+ JavadocBlockTag returnBlockTag = javadoc.getBlockTags().get(1);
+ assertEquals("return", returnBlockTag.getTagName());
+ assertEquals("true", returnBlockTag.getContent().toText());
+ }
+
+ @Test
+ void testNonMetaProperties() {
+ CompilationUnit cu = parse("public class X{} class Z{}");
+ String serialized = serialize(cu, false);
+
+ CompilationUnit deserialized = (CompilationUnit) deserializer.deserializeObject(Json.createReader(new StringReader(serialized)));
+
+ assertTrue(deserialized.hasRange());
+ Range range = deserialized.getRange().get();
+ assertEquals(1, range.begin.line);
+ assertEquals(1, range.begin.line);
+ assertEquals(26, range.end.column);
+
+ assertTrue(deserialized.getTokenRange().isPresent());
+ TokenRange tokenRange = deserialized.getTokenRange().get();
+ assertEquals("public", tokenRange.getBegin().getText());
+ assertEquals("", tokenRange.getEnd().getText());
+ }
+
+ @Test
+ void testAttachingSymbolResolver() {
+ SymbolResolver stubResolver = new SymbolResolver() {
+ @Override
+ public T resolveDeclaration(Node node, Class resultClass) {
+ return null;
+ }
+
+ @Override
+ public T toResolvedType(Type javaparserType, Class resultClass) {
+ return null;
+ }
+
+ @Override
+ public ResolvedType calculateType(Expression expression) {
+ return null;
+ }
+
+ @Override
+ public ResolvedReferenceTypeDeclaration toTypeDeclaration(Node node) {
+ return null;
+ }
+ };
+ StaticJavaParser.getConfiguration().setSymbolResolver(stubResolver);
+ CompilationUnit cu = parse("public class X{} class Z{}");
+ String serialized = serialize(cu, false);
+
+ CompilationUnit deserialized = (CompilationUnit) deserializer.deserializeObject(Json.createReader(new StringReader(serialized)));
+ assertTrue(deserialized.containsData(Node.SYMBOL_RESOLVER_KEY));
+ assertEquals(stubResolver, deserialized.getData(Node.SYMBOL_RESOLVER_KEY));
+ }
+
+ @AfterAll
+ static void clearConfiguration() {
+ StaticJavaParser.setConfiguration(new ParserConfiguration());
+ }
+
+ /**
+ * Assert that "actual" equals "expected", and that any EOL characters in "actual" are correct for the platform.
+ */
+ private static void assertEqualsStringIgnoringEol(String expected, String actual) {
+ assertEquals(
+ normalizeEolInTextBlock(expected, LineSeparator.ARBITRARY),
+ normalizeEolInTextBlock(actual, LineSeparator.ARBITRARY)
+ );
+ }
+
+}
diff --git a/javaparser-core-serialization/src/test/java/com/github/javaparser/serialization/JavaParserJsonSerializerTest.java b/javaparser-core-serialization/src/test/java/com/github/javaparser/serialization/JavaParserJsonSerializerTest.java
new file mode 100644
index 0000000..d56b093
--- /dev/null
+++ b/javaparser-core-serialization/src/test/java/com/github/javaparser/serialization/JavaParserJsonSerializerTest.java
@@ -0,0 +1,62 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+package com.github.javaparser.serialization;
+
+import com.github.javaparser.ast.CompilationUnit;
+import com.github.javaparser.ast.Node;
+
+import jakarta.json.Json;
+import jakarta.json.stream.JsonGenerator;
+import jakarta.json.stream.JsonGeneratorFactory;
+
+import org.junit.jupiter.api.Test;
+
+import java.io.StringWriter;
+import java.util.HashMap;
+import java.util.Map;
+
+import static com.github.javaparser.StaticJavaParser.parse;
+import static org.junit.jupiter.api.Assertions.assertEquals;
+
+class JavaParserJsonSerializerTest {
+ @Test
+ void test() {
+ CompilationUnit cu = parse("class X{java.util.Y y;}");
+
+ String serialized = serialize(cu, false);
+
+ assertEquals("{\"!\":\"com.github.javaparser.ast.CompilationUnit\",\"range\":{\"beginLine\":1,\"beginColumn\":1,\"endLine\":1,\"endColumn\":23},\"tokenRange\":{\"beginToken\":{\"kind\":19,\"text\":\"class\"},\"endToken\":{\"kind\":0,\"text\":\"\"}},\"imports\":[],\"types\":[{\"!\":\"com.github.javaparser.ast.body.ClassOrInterfaceDeclaration\",\"range\":{\"beginLine\":1,\"beginColumn\":1,\"endLine\":1,\"endColumn\":23},\"tokenRange\":{\"beginToken\":{\"kind\":19,\"text\":\"class\"},\"endToken\":{\"kind\":103,\"text\":\"}\"}},\"extendedTypes\":[],\"implementedTypes\":[],\"isInterface\":\"false\",\"permittedTypes\":[],\"typeParameters\":[],\"members\":[{\"!\":\"com.github.javaparser.ast.body.FieldDeclaration\",\"range\":{\"beginLine\":1,\"beginColumn\":9,\"endLine\":1,\"endColumn\":22},\"tokenRange\":{\"beginToken\":{\"kind\":97,\"text\":\"java\"},\"endToken\":{\"kind\":106,\"text\":\";\"}},\"modifiers\":[],\"variables\":[{\"!\":\"com.github.javaparser.ast.body.VariableDeclarator\",\"range\":{\"beginLine\":1,\"beginColumn\":21,\"endLine\":1,\"endColumn\":21},\"tokenRange\":{\"beginToken\":{\"kind\":97,\"text\":\"y\"},\"endToken\":{\"kind\":97,\"text\":\"y\"}},\"name\":{\"!\":\"com.github.javaparser.ast.expr.SimpleName\",\"range\":{\"beginLine\":1,\"beginColumn\":21,\"endLine\":1,\"endColumn\":21},\"tokenRange\":{\"beginToken\":{\"kind\":97,\"text\":\"y\"},\"endToken\":{\"kind\":97,\"text\":\"y\"}},\"identifier\":\"y\"},\"type\":{\"!\":\"com.github.javaparser.ast.type.ClassOrInterfaceType\",\"range\":{\"beginLine\":1,\"beginColumn\":9,\"endLine\":1,\"endColumn\":19},\"tokenRange\":{\"beginToken\":{\"kind\":97,\"text\":\"java\"},\"endToken\":{\"kind\":97,\"text\":\"Y\"}},\"name\":{\"!\":\"com.github.javaparser.ast.expr.SimpleName\",\"range\":{\"beginLine\":1,\"beginColumn\":19,\"endLine\":1,\"endColumn\":19},\"tokenRange\":{\"beginToken\":{\"kind\":97,\"text\":\"Y\"},\"endToken\":{\"kind\":97,\"text\":\"Y\"}},\"identifier\":\"Y\"},\"scope\":{\"!\":\"com.github.javaparser.ast.type.ClassOrInterfaceType\",\"range\":{\"beginLine\":1,\"beginColumn\":9,\"endLine\":1,\"endColumn\":17},\"tokenRange\":{\"beginToken\":{\"kind\":97,\"text\":\"java\"},\"endToken\":{\"kind\":97,\"text\":\"util\"}},\"name\":{\"!\":\"com.github.javaparser.ast.expr.SimpleName\",\"range\":{\"beginLine\":1,\"beginColumn\":14,\"endLine\":1,\"endColumn\":17},\"tokenRange\":{\"beginToken\":{\"kind\":97,\"text\":\"util\"},\"endToken\":{\"kind\":97,\"text\":\"util\"}},\"identifier\":\"util\"},\"scope\":{\"!\":\"com.github.javaparser.ast.type.ClassOrInterfaceType\",\"range\":{\"beginLine\":1,\"beginColumn\":9,\"endLine\":1,\"endColumn\":12},\"tokenRange\":{\"beginToken\":{\"kind\":97,\"text\":\"java\"},\"endToken\":{\"kind\":97,\"text\":\"java\"}},\"name\":{\"!\":\"com.github.javaparser.ast.expr.SimpleName\",\"range\":{\"beginLine\":1,\"beginColumn\":9,\"endLine\":1,\"endColumn\":12},\"tokenRange\":{\"beginToken\":{\"kind\":97,\"text\":\"java\"},\"endToken\":{\"kind\":97,\"text\":\"java\"}},\"identifier\":\"java\"},\"annotations\":[]},\"annotations\":[]},\"annotations\":[]}}],\"annotations\":[]}],\"modifiers\":[],\"name\":{\"!\":\"com.github.javaparser.ast.expr.SimpleName\",\"range\":{\"beginLine\":1,\"beginColumn\":7,\"endLine\":1,\"endColumn\":7},\"tokenRange\":{\"beginToken\":{\"kind\":97,\"text\":\"X\"},\"endToken\":{\"kind\":97,\"text\":\"X\"}},\"identifier\":\"X\"},\"annotations\":[]}]}", serialized);
+ }
+
+ static String serialize(Node node, boolean prettyPrint) {
+ Map config = new HashMap<>();
+ if (prettyPrint) {
+ config.put(JsonGenerator.PRETTY_PRINTING, null);
+ }
+ JsonGeneratorFactory generatorFactory = Json.createGeneratorFactory(config);
+ JavaParserJsonSerializer serializer = new JavaParserJsonSerializer();
+ StringWriter jsonWriter = new StringWriter();
+ try (JsonGenerator generator = generatorFactory.createGenerator(jsonWriter)) {
+ serializer.serialize(node, generator);
+ }
+ return jsonWriter.toString();
+ }
+}
diff --git a/javaparser-core-testing-bdd/pom.xml b/javaparser-core-testing-bdd/pom.xml
new file mode 100644
index 0000000..7cae9d4
--- /dev/null
+++ b/javaparser-core-testing-bdd/pom.xml
@@ -0,0 +1,132 @@
+
+
+ javaparser-parent
+ com.github.javaparser
+ 3.25.10
+
+ 4.0.0
+
+ javaparser-core-testing-bdd
+ The BDD test suite for javaparser-core
+
+
+
+ GNU Lesser General Public License
+ http://www.gnu.org/licenses/lgpl-3.0.html
+ repo
+
+
+ Apache License, Version 2.0
+ http://www.apache.org/licenses/LICENSE-2.0.txt
+ repo
+ A business-friendly OSS license
+
+
+
+
+
+
+ org.jacoco
+ jacoco-maven-plugin
+
+
+ jacoco-initialize
+
+ prepare-agent
+
+
+
+ jacoco-report
+ test
+
+ report
+
+
+
+
+
+ maven-resources-plugin
+
+
+ copy-javaparser-core-classes
+ test-compile
+
+ copy-resources
+
+
+ UTF-8
+ ${basedir}/target/classes
+
+
+ ../javaparser-core/target/classes
+ false
+
+
+
+
+
+ copy-javaparser-core-generated-sources
+ test-compile
+
+ copy-resources
+
+
+ UTF-8
+ ${basedir}/target/generated-sources/
+
+
+ ../javaparser-core/target/generated-sources
+ false
+
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-deploy-plugin
+
+
+ true
+
+
+
+ org.apache.maven.plugins
+ maven-surefire-plugin
+
+ plain
+ true
+
+
+
+
+
+
+ com.github.javaparser
+ javaparser-core
+ ${project.version}
+ test
+
+
+ org.junit.jupiter
+ junit-jupiter-engine
+
+
+ org.junit.vintage
+ junit-vintage-engine
+
+
+ org.jbehave
+ jbehave-core
+ 5.2.0
+ test
+
+
+ org.hamcrest
+ hamcrest
+ test
+
+
+
+
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/BasicJBehaveTest.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/BasicJBehaveTest.java
new file mode 100644
index 0000000..df29a5d
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/BasicJBehaveTest.java
@@ -0,0 +1,65 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser;
+
+
+import org.jbehave.core.configuration.Configuration;
+import org.jbehave.core.configuration.MostUsefulConfiguration;
+import org.jbehave.core.failures.FailingUponPendingStep;
+import org.jbehave.core.io.LoadFromClasspath;
+import org.jbehave.core.io.StoryFinder;
+import org.jbehave.core.junit.JUnit4StoryRunner;
+import org.jbehave.core.junit.JUnitStories;
+import org.jbehave.core.reporters.Format;
+import org.jbehave.core.reporters.StoryReporterBuilder;
+
+import java.util.List;
+
+import static org.jbehave.core.io.CodeLocations.codeLocationFromClass;
+
+abstract class BasicJBehaveTest extends JUnitStories {
+
+ private final String storiesPath;
+
+ BasicJBehaveTest(String storiesPath) {
+ this.storiesPath = storiesPath;
+ JUnit4StoryRunner.recommendedControls(configuredEmbedder());
+ }
+
+ @Override
+ public final Configuration configuration() {
+ return new MostUsefulConfiguration()
+ // where to find the stories
+ .useStoryLoader(new LoadFromClasspath(this.getClass()))
+ // Fails if Steps are not implemented
+ .usePendingStepStrategy(new FailingUponPendingStep())
+ // CONSOLE and HTML reporting
+ .useStoryReporterBuilder(new StoryReporterBuilder().withDefaultFormats()
+ .withFormats(Format.CONSOLE, Format.HTML));
+ }
+
+ @Override
+ public final List storyPaths() {
+ return new StoryFinder().findPaths(codeLocationFromClass(this.getClass()), storiesPath, "");
+ }
+
+}
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/CommentParsingTest.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/CommentParsingTest.java
new file mode 100644
index 0000000..b421b59
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/CommentParsingTest.java
@@ -0,0 +1,42 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser;
+
+import com.github.javaparser.steps.CommentParsingSteps;
+import org.jbehave.core.junit.JUnit4StoryRunner;
+import org.jbehave.core.steps.InjectableStepsFactory;
+import org.jbehave.core.steps.InstanceStepsFactory;
+import org.junit.runner.RunWith;
+
+@RunWith(JUnit4StoryRunner.class)
+public class CommentParsingTest extends BasicJBehaveTest {
+
+ @Override
+ public InjectableStepsFactory stepsFactory() {
+ return new InstanceStepsFactory(configuration(), new CommentParsingSteps());
+ }
+
+ public CommentParsingTest() {
+ super("**/comment*.story");
+ }
+}
+
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/ComparingTest.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/ComparingTest.java
new file mode 100644
index 0000000..7072ab7
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/ComparingTest.java
@@ -0,0 +1,51 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser;
+
+import com.github.javaparser.steps.ComparingSteps;
+import com.github.javaparser.steps.SharedSteps;
+import org.jbehave.core.junit.JUnit4StoryRunner;
+import org.jbehave.core.steps.InjectableStepsFactory;
+import org.jbehave.core.steps.InstanceStepsFactory;
+import org.junit.runner.RunWith;
+
+import java.util.HashMap;
+import java.util.Map;
+
+@RunWith(JUnit4StoryRunner.class)
+public class ComparingTest extends BasicJBehaveTest {
+
+ @Override
+ public InjectableStepsFactory stepsFactory() {
+ Map state = new HashMap<>();
+
+ return new InstanceStepsFactory(configuration(),
+ new SharedSteps(state),
+ new ComparingSteps());
+ }
+
+ public ComparingTest() {
+ super("**/comparing*.story");
+ }
+}
+
+
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/ManipulationTest.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/ManipulationTest.java
new file mode 100644
index 0000000..559ae9b
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/ManipulationTest.java
@@ -0,0 +1,49 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser;
+
+import com.github.javaparser.steps.ManipulationSteps;
+import com.github.javaparser.steps.SharedSteps;
+import org.jbehave.core.junit.JUnit4StoryRunner;
+import org.jbehave.core.steps.InjectableStepsFactory;
+import org.jbehave.core.steps.InstanceStepsFactory;
+import org.junit.runner.RunWith;
+
+import java.util.HashMap;
+import java.util.Map;
+
+@RunWith(JUnit4StoryRunner.class)
+public class ManipulationTest extends BasicJBehaveTest {
+
+ @Override
+ public InjectableStepsFactory stepsFactory() {
+ Map state = new HashMap<>();
+
+ return new InstanceStepsFactory(configuration(),
+ new SharedSteps(state),
+ new ManipulationSteps(state));
+ }
+
+ public ManipulationTest() {
+ super("**/manipulation*.story");
+ }
+}
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/ParsingTest.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/ParsingTest.java
new file mode 100644
index 0000000..3e73bad
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/ParsingTest.java
@@ -0,0 +1,51 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser;
+
+import com.github.javaparser.steps.ParsingSteps;
+import com.github.javaparser.steps.SharedSteps;
+import org.jbehave.core.junit.JUnit4StoryRunner;
+import org.jbehave.core.steps.InjectableStepsFactory;
+import org.jbehave.core.steps.InstanceStepsFactory;
+import org.junit.runner.RunWith;
+
+import java.util.HashMap;
+import java.util.Map;
+
+@RunWith(JUnit4StoryRunner.class)
+public class ParsingTest extends BasicJBehaveTest {
+
+ @Override
+ public InjectableStepsFactory stepsFactory() {
+ Map state = new HashMap<>();
+
+ return new InstanceStepsFactory(configuration(),
+ new SharedSteps(state),
+ new ParsingSteps(state));
+ }
+
+ public ParsingTest() {
+ super("**/parsing*.story");
+ }
+}
+
+
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/PositionRangeTest.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/PositionRangeTest.java
new file mode 100644
index 0000000..615794b
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/PositionRangeTest.java
@@ -0,0 +1,51 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser;
+
+import com.github.javaparser.steps.PositionRangeSteps;
+import com.github.javaparser.steps.SharedSteps;
+import org.jbehave.core.junit.JUnit4StoryRunner;
+import org.jbehave.core.steps.InjectableStepsFactory;
+import org.jbehave.core.steps.InstanceStepsFactory;
+import org.junit.runner.RunWith;
+
+import java.util.HashMap;
+import java.util.Map;
+
+@RunWith(JUnit4StoryRunner.class)
+public class PositionRangeTest extends BasicJBehaveTest {
+
+ @Override
+ public InjectableStepsFactory stepsFactory() {
+ Map state = new HashMap<>();
+
+ return new InstanceStepsFactory(configuration(),
+ new SharedSteps(state),
+ new PositionRangeSteps());
+ }
+
+ public PositionRangeTest() {
+ super("**/position_range*.story");
+ }
+}
+
+
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/PrettyPrintingTest.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/PrettyPrintingTest.java
new file mode 100644
index 0000000..cf98815
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/PrettyPrintingTest.java
@@ -0,0 +1,42 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser;
+
+import com.github.javaparser.steps.PrettyPrintingSteps;
+import org.jbehave.core.junit.JUnit4StoryRunner;
+import org.jbehave.core.steps.InjectableStepsFactory;
+import org.jbehave.core.steps.InstanceStepsFactory;
+import org.junit.runner.RunWith;
+
+@RunWith(JUnit4StoryRunner.class)
+public class PrettyPrintingTest extends BasicJBehaveTest {
+
+ @Override
+ public InjectableStepsFactory stepsFactory() {
+ return new InstanceStepsFactory(configuration(), new PrettyPrintingSteps());
+ }
+
+ public PrettyPrintingTest() {
+ super("**/pretty_printing*.story");
+ }
+}
+
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/TestUtils.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/TestUtils.java
new file mode 100644
index 0000000..10c9e97
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/TestUtils.java
@@ -0,0 +1,37 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser;
+
+import java.io.InputStream;
+
+public class TestUtils {
+
+ public static InputStream getSampleStream(String sampleName) {
+ InputStream is = TestUtils.class.getClassLoader().getResourceAsStream("com/github/javaparser/samples/"
+ + sampleName + ".java");
+ if (is == null) {
+ throw new RuntimeException("Example not found, check your test. Sample name: " + sampleName);
+ }
+ return is;
+ }
+
+}
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/VisitorTest.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/VisitorTest.java
new file mode 100644
index 0000000..5ef26e1
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/VisitorTest.java
@@ -0,0 +1,51 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser;
+
+import com.github.javaparser.steps.SharedSteps;
+import com.github.javaparser.steps.VisitorSteps;
+import org.jbehave.core.junit.JUnit4StoryRunner;
+import org.jbehave.core.steps.InjectableStepsFactory;
+import org.jbehave.core.steps.InstanceStepsFactory;
+import org.junit.runner.RunWith;
+
+import java.util.HashMap;
+import java.util.Map;
+
+@RunWith(JUnit4StoryRunner.class)
+public class VisitorTest extends BasicJBehaveTest {
+
+ @Override
+ public InjectableStepsFactory stepsFactory() {
+ Map state = new HashMap<>();
+ return new InstanceStepsFactory(configuration(),
+ new SharedSteps(state),
+ new VisitorSteps(state));
+ }
+
+ public VisitorTest() {
+ super("**/visitor*.story");
+ }
+}
+
+
+
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/CommentParsingSteps.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/CommentParsingSteps.java
new file mode 100644
index 0000000..d61864d
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/CommentParsingSteps.java
@@ -0,0 +1,432 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser.steps;
+
+import com.github.javaparser.*;
+import com.github.javaparser.ast.CompilationUnit;
+import com.github.javaparser.ast.body.*;
+import com.github.javaparser.ast.comments.*;
+import com.github.javaparser.ast.expr.Expression;
+import com.github.javaparser.ast.expr.IntegerLiteralExpr;
+import com.github.javaparser.ast.stmt.BlockStmt;
+import com.github.javaparser.ast.stmt.ExpressionStmt;
+import com.github.javaparser.ast.type.PrimitiveType;
+import com.github.javaparser.printer.PrettyPrinter;
+import com.github.javaparser.printer.Printer;
+import com.github.javaparser.printer.configuration.PrettyPrinterConfiguration;
+import org.jbehave.core.annotations.Alias;
+import org.jbehave.core.annotations.Given;
+import org.jbehave.core.annotations.Then;
+import org.jbehave.core.annotations.When;
+import org.jbehave.core.model.ExamplesTable;
+import org.jbehave.core.steps.Parameters;
+
+import java.nio.charset.Charset;
+import java.util.Iterator;
+import java.util.Set;
+
+import static com.github.javaparser.ParseStart.COMPILATION_UNIT;
+import static com.github.javaparser.Providers.provider;
+import static com.github.javaparser.Range.range;
+import static com.github.javaparser.steps.SharedSteps.getMemberByTypeAndPosition;
+import static org.hamcrest.CoreMatchers.instanceOf;
+import static org.hamcrest.CoreMatchers.is;
+import static org.hamcrest.MatcherAssert.assertThat;
+import static org.hamcrest.text.IsEqualCompressingWhiteSpace.equalToCompressingWhiteSpace;
+import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.fail;
+
+public class CommentParsingSteps {
+
+ private CompilationUnit compilationUnit;
+ private CommentsCollection commentsCollection;
+ private String sourceUnderTest;
+ private ParserConfiguration configuration = new ParserConfiguration();
+ private Printer prettyPrinter = new PrettyPrinter(new PrettyPrinterConfiguration());
+
+ @Given("the class:$classSrc")
+ public void givenTheClass(String classSrc) {
+ this.sourceUnderTest = classSrc.trim();
+ }
+
+ @When("read sample \"$sampleName\" using encoding \"$encoding\"")
+ public void givenTheClassWithEncoding(String sampleName, String encoding) {
+ sourceUnderTest = null;
+ ParseResult parseResult = new JavaParser(new ParserConfiguration()).parse(
+ COMPILATION_UNIT,
+ provider(
+ TestUtils.getSampleStream(sampleName),
+ Charset.forName(encoding)));
+ commentsCollection = parseResult.getCommentsCollection().orElse(new CommentsCollection());
+ }
+
+ @When("the class is parsed by the comment parser")
+ public void whenTheClassIsParsedByTheCommentParser() {
+ ParseResult parseResult = new JavaParser(new ParserConfiguration()).parse(COMPILATION_UNIT, provider(sourceUnderTest));
+ commentsCollection = parseResult.getCommentsCollection().orElse(new CommentsCollection());
+ }
+
+ @When("the do not consider annotations as node start for code attribution is $value on the Java parser")
+ public void whenTheDoNotConsiderAnnotationsAsNodeStartForCodeAttributionIsTrueOnTheJavaParser(boolean value) {
+ configuration.setIgnoreAnnotationsWhenAttributingComments(value);
+ }
+
+ @When("the do not assign comments preceding empty lines is $value on the Java parser")
+ public void whenTheDoNotAssignCommentsPrecedingEmptyLinesIsTrueOnTheJavaParser(boolean value) {
+ configuration.setDoNotAssignCommentsPrecedingEmptyLines(value);
+ }
+
+ @When("the class is parsed by the Java parser")
+ public void whenTheClassIsParsedByTheJavaParser() {
+ ParseResult result = new JavaParser(configuration).parse(COMPILATION_UNIT, provider(sourceUnderTest));
+ compilationUnit = result.getResult().get();
+ }
+
+ @Then("the Java parser cannot parse it because of an error")
+ public void javaParserCannotParseBecauseOfLexicalErrors() {
+ ParseResult result = new JavaParser(configuration).parse(COMPILATION_UNIT, provider(sourceUnderTest));
+ if (result.isSuccessful()) {
+ fail("Lexical error expected");
+ }
+ }
+
+ @Then("the total number of comments is $expectedCount")
+ public void thenTheTotalNumberOfCommentsIs(int expectedCount) {
+ assertThat(commentsCollection.size(), is(expectedCount));
+ }
+
+ private T getCommentAt(Set set, int index) {
+ Iterator iterator = set.iterator();
+ T comment = null;
+ while (index >= 0) {
+ comment = iterator.next();
+ index--;
+ }
+ return comment;
+ }
+
+ @Then("line comment $position is \"$expectedContent\"")
+ public void thenLineCommentIs(int position, String expectedContent) {
+ LineComment lineCommentUnderTest = getCommentAt(commentsCollection.getLineComments(), position - 1);
+
+ assertThat(lineCommentUnderTest.getContent(), is(expectedContent));
+ }
+
+ @Then("block comment $position is \"$expectedContent\"")
+ public void thenBlockCommentIs(int position, String expectedContent) {
+ BlockComment lineCommentUnderTest = getCommentAt(commentsCollection.getBlockComments(), position - 1);
+
+ assertThat(lineCommentUnderTest.getContent(), is(equalToCompressingWhiteSpace(expectedContent)));
+ }
+
+ @Then("Javadoc comment $position is \"$expectedContent\"")
+ public void thenJavadocCommentIs(int position, String expectedContent) {
+ JavadocComment commentUnderTest = getCommentAt(commentsCollection.getJavadocComments(), position - 1);
+
+ assertThat(commentUnderTest.getContent(), is(equalToCompressingWhiteSpace(expectedContent)));
+ }
+
+ @Then("the line comments have the following positions: $table")
+ public void thenTheLineCommentsHaveTheFollowingPositions(ExamplesTable examplesTable) {
+ int index = 0;
+ for (Parameters exampleRow : examplesTable.getRowsAsParameters()) {
+ Comment expectedLineComment = toComment(exampleRow, new LineComment());
+ Comment lineCommentUnderTest = getCommentAt(commentsCollection.getLineComments(), index);
+
+ Range underTestRange = lineCommentUnderTest.getRange().get();
+ Range expectedRange = expectedLineComment.getRange().get();
+
+ assertThat(underTestRange.begin.line, is(expectedRange.begin.line));
+ assertThat(underTestRange.begin.column, is(expectedRange.begin.column));
+ assertThat(underTestRange.end.line, is(expectedRange.end.line));
+ assertThat(underTestRange.end.column, is(expectedRange.end.column));
+ index++;
+ }
+ }
+
+ @Then("the block comments have the following positions: $table")
+ public void thenTheBlockCommentsHaveTheFollowingPositions(ExamplesTable examplesTable) {
+ int index = 0;
+ for (Parameters exampleRow : examplesTable.getRowsAsParameters()) {
+ Comment expectedLineComment = toComment(exampleRow, new BlockComment());
+ Comment lineCommentUnderTest = getCommentAt(commentsCollection.getBlockComments(), index);
+
+ Range underTestRange = lineCommentUnderTest.getRange().get();
+ Range expectedRange = expectedLineComment.getRange().get();
+
+ assertThat(underTestRange.begin.line, is(expectedRange.begin.line));
+ assertThat(underTestRange.begin.column, is(expectedRange.begin.column));
+ assertThat(underTestRange.end.line, is(expectedRange.end.line));
+ assertThat(underTestRange.end.column, is(expectedRange.end.column));
+ index++;
+ }
+ }
+
+ @Then("the Javadoc comments have the following positions: $table")
+ public void thenTheJavadocCommentsHaveTheFollowingPositions(ExamplesTable examplesTable) {
+ int index = 0;
+ for (Parameters exampleRow : examplesTable.getRowsAsParameters()) {
+ Comment expectedLineComment = toComment(exampleRow, new BlockComment());
+ Comment lineCommentUnderTest = getCommentAt(commentsCollection.getJavadocComments(), index);
+
+ Range underTestRange = lineCommentUnderTest.getRange().get();
+ Range expectedRange = expectedLineComment.getRange().get();
+
+ assertThat(underTestRange.begin.line, is(expectedRange.begin.line));
+ assertThat(underTestRange.begin.column, is(expectedRange.begin.column));
+ assertThat(underTestRange.end.line, is(expectedRange.end.line));
+ assertThat(underTestRange.end.column, is(expectedRange.end.column));
+ index++;
+ }
+ }
+
+ @Then("it is printed as:$src")
+ public void isPrintedAs(String src) {
+ assertThat(prettyPrinter.print(compilationUnit).trim(), is(src.trim()));
+ }
+
+ @Then("the compilation unit is not commented")
+ public void thenTheCompilationUnitIsNotCommented() {
+ assertEquals(false, compilationUnit.getComment().isPresent());
+ }
+
+ @Then("the compilation is commented \"$expectedContent\"")
+ public void thenTheCompilationIsCommentedCompilationUnitComment(String expectedContent) {
+ assertThat(compilationUnit.getComment().get().getContent(), is(expectedContent));
+ }
+
+ @Then("the compilation unit has $expectedCount contained comments")
+ public void thenTheCompilationUnitHasContainedComments(int expectedCount) {
+ assertThat(compilationUnit.getComments().size(), is(expectedCount));
+ }
+
+ @Then("the compilation unit has $expectedCount orphan comments")
+ public void thenTheCompilationUnitHasExpectedCountOrphanComments(int expectedCount) {
+ assertThat(compilationUnit.getOrphanComments().size(), is(expectedCount));
+ }
+
+ @Then("the compilation unit orphan comment $position is \"$expectedContent\"")
+ public void thenTheCompilationUnitOrphanCommentIs(int position, String expectedContent) {
+ Comment commentUnderTest = compilationUnit.getOrphanComments().get(position - 1);
+ assertThat(commentUnderTest.getContent(), is(equalToCompressingWhiteSpace(expectedContent)));
+ }
+
+ @Then("comment $commentPosition in compilation unit is not an orphan")
+ public void thenCommentInCompilationUnitIsNotAnOrphan(int commentPosition) {
+ Comment commentUnderTest = compilationUnit.getAllContainedComments().get(commentPosition - 1);
+ assertThat(commentUnderTest.isOrphan(), is(false));
+ }
+
+ @Then("comment $commentPosition in compilation unit is an orphan")
+ public void thenCommentInCompilationUnitIsAnOrphan(int commentPosition) {
+ Comment commentUnderTest = compilationUnit.getAllContainedComments().get(commentPosition - 1);
+ assertThat(commentUnderTest.isOrphan(), is(true));
+ }
+
+ @Then("comment $commentPosition in compilation unit is \"$expectedContent\"")
+ public void thenCommentInCompilationUnitIs(int position, String expectedContent) {
+ Comment commentUnderTest = compilationUnit.getAllContainedComments().get(position - 1);
+ assertThat(commentUnderTest.getContent(), is(equalToCompressingWhiteSpace(expectedContent)));
+ }
+
+ @Then("class $position is not commented")
+ public void thenClassIsNotCommented(int position) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(position - 1);
+ assertEquals(false, classUnderTest.getComment().isPresent());
+ }
+
+ @Then("class $position is commented \"$expectedContent\"")
+ public void thenClassIsCommented(int position, String expectedContent) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(position - 1);
+ assertThat(classUnderTest.getComment().get().getContent(), is(expectedContent));
+ }
+
+ @Then("class $position has $expectedCount total contained comments")
+ public void thenClassHasTotalContainedComments(int position, int expectedCount) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(position - 1);
+ assertThat(classUnderTest.getAllContainedComments().size(), is(expectedCount));
+ }
+
+ @Then("class $position has $expectedCount orphan comment")
+ @Alias("class $position has $expectedCount orphan comments")
+ public void thenClassHasOrphanComments(int position, int expectedCount) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(position - 1);
+ assertThat(classUnderTest.getOrphanComments().size(), is(expectedCount));
+ }
+
+ @Then("class $classPosition orphan comment $commentPosition is \"$expectedContent\"")
+ public void thenClassOrphanCommentIs(int classPosition, int commentPosition, String expectedContent) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ Comment commentUnderTest = classUnderTest.getOrphanComments().get(commentPosition - 1);
+ assertThat(commentUnderTest.getContent(), is(equalToCompressingWhiteSpace(expectedContent)));
+ }
+
+ @Then("method $methodPosition in class $classPosition is commented \"$expectedContent\"")
+ public void thenMethodInClassIsCommented(int methodPosition, int classPosition, String expectedContent) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ MethodDeclaration methodUnderTest = getMemberByTypeAndPosition(classUnderTest, methodPosition - 1,
+ MethodDeclaration.class);
+ assertThat(methodUnderTest.getComment().get().getContent(), equalToCompressingWhiteSpace(expectedContent));
+ }
+
+ @Then("method $methodPosition in class $classPosition has $expectedCount total contained comments")
+ public void thenMethodInClassHasTotalContainedComments(int methodPosition, int classPosition, int expectedCount) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ MethodDeclaration methodUnderTest = getMemberByTypeAndPosition(classUnderTest, methodPosition - 1,
+ MethodDeclaration.class);
+ assertThat(methodUnderTest.getAllContainedComments().size(), is(expectedCount));
+ }
+
+ @Then("comment $commentPosition in method $methodPosition in class $classPosition is \"$expectedContent\"")
+ public void thenCommentInMethodInClassIs(int commentPosition, int methodPosition, int classPosition, String expectedContent) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ MethodDeclaration methodUnderTest = getMemberByTypeAndPosition(classUnderTest, methodPosition - 1,
+ MethodDeclaration.class);
+ Comment commentUnderTest = methodUnderTest.getAllContainedComments().get(commentPosition - 1);
+ assertThat(commentUnderTest.getContent(), is(equalToCompressingWhiteSpace(expectedContent)));
+ }
+
+ @Then("method $methodPosition in class $classPosition has $expectedCount orphan comments")
+ public void thenMethodInClassHasOrphanComments(int methodPosition, int classPosition, int expectedCount) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ MethodDeclaration methodUnderTest = getMemberByTypeAndPosition(classUnderTest, methodPosition - 1,
+ MethodDeclaration.class);
+ assertThat(methodUnderTest.getOrphanComments().size(), is(expectedCount));
+ }
+
+ @Then("block statement in method $methodPosition in class $classPosition has $expectedCount total contained comments")
+ public void thenBlockStatementInMethodInClassHasTotalContainedComments(int methodPosition, int classPosition, int expectedCount) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ MethodDeclaration methodUnderTest = getMemberByTypeAndPosition(classUnderTest, methodPosition - 1,
+ MethodDeclaration.class);
+ BlockStmt blockStmtUnderTest = methodUnderTest.getBody().orElse(null);
+ assertThat(blockStmtUnderTest.getAllContainedComments().size(), is(expectedCount));
+ }
+
+ @Then("block statement in method $methodPosition in class $classPosition has $expectedCount orphan comments")
+ public void thenBlockStatementInMethodInClassHasOrphanComments(int methodPosition, int classPosition, int expectedCount) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ MethodDeclaration methodUnderTest = getMemberByTypeAndPosition(classUnderTest, methodPosition - 1,
+ MethodDeclaration.class);
+ BlockStmt blockStmtUnderTest = methodUnderTest.getBody().orElse(null);
+ assertThat(blockStmtUnderTest.getOrphanComments().size(), is(expectedCount));
+ }
+
+ @Then("block statement in method $methodPosition in class $classPosition orphan comment $commentPosition is \"$expectedContent\"")
+ public void thenBlockStatementInMethodInClassIs(int methodPosition, int classPosition, int commentPosition, String expectedContent) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ MethodDeclaration methodUnderTest = getMemberByTypeAndPosition(classUnderTest, methodPosition - 1,
+ MethodDeclaration.class);
+ BlockStmt blockStmtUnderTest = methodUnderTest.getBody().orElse(null);
+ Comment commentUnderTest = blockStmtUnderTest.getOrphanComments().get(commentPosition - 1);
+ assertThat(commentUnderTest.getContent(), is(equalToCompressingWhiteSpace(expectedContent)));
+ }
+
+ @Then("type of method $methodPosition in class $classPosition is commented \"$expectedContent\"")
+ public void thenTypeOfMethodInClassIsCommented(int methodPosition, int classPosition, String expectedContent) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ MethodDeclaration methodUnderTest = getMemberByTypeAndPosition(classUnderTest, methodPosition - 1,
+ MethodDeclaration.class);
+ Comment commentUnderTest = methodUnderTest.getType().getComment().get();
+ assertThat(commentUnderTest.getContent(), is(equalToCompressingWhiteSpace(expectedContent)));
+ }
+
+ @Then("field $fieldPosition in class $classPosition contains $expectedCount comments")
+ public void thenFieldInClassContainsComments(int fieldPosition, int classPosition, int expectedCount) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ FieldDeclaration fieldUnderTest = getMemberByTypeAndPosition(classUnderTest, fieldPosition - 1,
+ FieldDeclaration.class);
+ assertThat(fieldUnderTest.getAllContainedComments().size(), is(expectedCount));
+ }
+
+ @Then("field $fieldPosition in class $classPosition is not commented")
+ public void thenFieldInClassIsNotCommented(int fieldPosition, int classPosition) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ FieldDeclaration fieldUnderTest = getMemberByTypeAndPosition(classUnderTest, fieldPosition - 1,
+ FieldDeclaration.class);
+ assertEquals(false, fieldUnderTest.getComment().isPresent());
+ }
+
+ @Then("field $fieldPosition in class $classPosition is commented \"$expectedContent\"")
+ public void thenFieldInClassIsCommented(int fieldPosition, int classPosition, String expectedContent) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ FieldDeclaration fieldUnderTest = getMemberByTypeAndPosition(classUnderTest, fieldPosition - 1,
+ FieldDeclaration.class);
+ Comment commentUnderTest = fieldUnderTest.getComment().get();
+ assertThat(commentUnderTest.getContent(), is(equalToCompressingWhiteSpace(expectedContent)));
+ }
+
+ @Then("variable $variablePosition value of field $fieldPosition in class $classPosition is commented \"$expectedContent\"")
+ public void thenVariableValueOfFieldInClassIsCommented(int variablePosition, int fieldPosition, int classPosition, String expectedContent) {
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ FieldDeclaration fieldUnderTest = getMemberByTypeAndPosition(classUnderTest, fieldPosition - 1,
+ FieldDeclaration.class);
+ VariableDeclarator variableUnderTest = fieldUnderTest.getVariable(variablePosition - 1);
+ Expression valueUnderTest = variableUnderTest.getInitializer().orElse(null);
+ Comment commentUnderTest = valueUnderTest.getComment().get();
+ assertThat(commentUnderTest.getContent(), is(expectedContent));
+ }
+
+ @Then("comment $commentPosition in compilation unit parent is ClassOrInterfaceDeclaration")
+ public void thenCommentInCompilationUnitParentIsClassOrInterfaceDeclaration(int commentPosition) {
+ Comment commentUnderTest = compilationUnit.getAllContainedComments().get(commentPosition - 1);
+ assertThat(commentUnderTest.getParentNode().get(), instanceOf(ClassOrInterfaceDeclaration.class));
+ }
+
+ @Then("comment $commentPosition in compilation unit commented node is ClassOrInterfaceDeclaration")
+ public void thenCommentInCompilationUnitCommentedNodeIsClassOrInterfaceDeclaration(int commentPosition) {
+ Comment commentUnderTest = compilationUnit.getAllContainedComments().get(commentPosition - 1);
+ assertThat(commentUnderTest.getCommentedNode().get(), instanceOf(ClassOrInterfaceDeclaration.class));
+ }
+
+ @Then("comment $commentPosition in compilation unit commented node is FieldDeclaration")
+ public void thenCommentInCompilationUnitCommentedNodeIsFieldDeclaration(int commentPosition) {
+ Comment commentUnderTest = compilationUnit.getAllContainedComments().get(commentPosition - 1);
+ assertThat(commentUnderTest.getCommentedNode().get(), instanceOf(FieldDeclaration.class));
+ }
+
+ @Then("comment $commentPosition in compilation unit commented node is IntegerLiteralExpr")
+ public void thenCommentInCompilationUnitCommentedNodeIsIntegerLiteralExpr(int commentPosition) {
+ Comment commentUnderTest = compilationUnit.getAllContainedComments().get(commentPosition - 1);
+ assertThat(commentUnderTest.getCommentedNode().get(), instanceOf(IntegerLiteralExpr.class));
+ }
+
+ @Then("comment $commentPosition in compilation unit commented node is ExpressionStmt")
+ public void thenCommentInCompilationUnitCommentedNodeIsIntegerExpressionStmt(int commentPosition) {
+ Comment commentUnderTest = compilationUnit.getAllContainedComments().get(commentPosition - 1);
+ assertThat(commentUnderTest.getCommentedNode().get(), instanceOf(ExpressionStmt.class));
+ }
+
+ @Then("comment $commentPosition in compilation unit commented node is PrimitiveType")
+ public void thenCommentInCompilationUnitCommentedNodeIsIntegerPrimitiveType(int commentPosition) {
+ Comment commentUnderTest = compilationUnit.getAllContainedComments().get(commentPosition - 1);
+ assertThat(commentUnderTest.getCommentedNode().get(), instanceOf(PrimitiveType.class));
+ }
+
+ private Comment toComment(Parameters row, Comment comment) {
+ comment.setRange(range(Integer.parseInt(row.values().get("beginLine")),
+ Integer.parseInt(row.values().get("beginColumn")),
+ Integer.parseInt(row.values().get("endLine")),
+ Integer.parseInt(row.values().get("endColumn"))));
+ return comment;
+ }
+}
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ComparingSteps.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ComparingSteps.java
new file mode 100644
index 0000000..9a09e92
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ComparingSteps.java
@@ -0,0 +1,61 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser.steps;
+
+import com.github.javaparser.ast.CompilationUnit;
+import org.jbehave.core.annotations.Given;
+import org.jbehave.core.annotations.Then;
+
+import static com.github.javaparser.StaticJavaParser.parse;
+import static org.hamcrest.CoreMatchers.equalTo;
+import static org.hamcrest.CoreMatchers.is;
+import static org.hamcrest.MatcherAssert.assertThat;
+
+public class ComparingSteps {
+
+ private CompilationUnit first;
+ private CompilationUnit second;
+
+ /*
+ * Given steps
+ */
+
+ @Given("the first class:$classSrc")
+ public void givenTheFirstClass(String classSrc) {
+ this.first = parse(classSrc.trim());
+ }
+
+ @Given("the second class:$classSrc")
+ public void givenTheSecondClass(String classSrc) {
+ this.second = parse(classSrc.trim());
+ }
+
+ /*
+ * Then steps
+ */
+
+ @Then("they are equals")
+ public void thenTheyAreEquals() {
+ assertThat(first, is(equalTo(second)));
+ }
+
+}
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ExistenceOfParentNodeVerifier.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ExistenceOfParentNodeVerifier.java
new file mode 100644
index 0000000..69b6089
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ExistenceOfParentNodeVerifier.java
@@ -0,0 +1,551 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser.steps;
+
+import com.github.javaparser.HasParentNode;
+import com.github.javaparser.ast.ArrayCreationLevel;
+import com.github.javaparser.ast.CompilationUnit;
+import com.github.javaparser.ast.NodeList;
+import com.github.javaparser.ast.PackageDeclaration;
+import com.github.javaparser.ast.body.*;
+import com.github.javaparser.ast.comments.BlockComment;
+import com.github.javaparser.ast.comments.JavadocComment;
+import com.github.javaparser.ast.comments.LineComment;
+import com.github.javaparser.ast.expr.*;
+import com.github.javaparser.ast.stmt.*;
+import com.github.javaparser.ast.type.*;
+import com.github.javaparser.ast.visitor.VoidVisitorAdapter;
+
+import static org.hamcrest.MatcherAssert.assertThat;
+import static org.hamcrest.Matchers.notNullValue;
+import static org.hamcrest.core.Is.is;
+
+/**
+ * The ExistenceOfParentNodeVerifier verifies that each node of the compilation unit has a parent set.
+ */
+class ExistenceOfParentNodeVerifier {
+
+ public void verify(CompilationUnit compilationUnit) throws AssertionError {
+ new Verifier().visit(compilationUnit, null);
+ }
+
+ private static class Verifier extends VoidVisitorAdapter {
+ private static void assertParentIsSet(HasParentNode> n) {
+ assertThat(n + " has no parent set!", n.getParentNode().orElse(null), is(notNullValue()));
+ }
+
+ @Override
+ public void visit(AnnotationDeclaration n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(AnnotationMemberDeclaration n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ArrayAccessExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ArrayCreationExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ArrayInitializerExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(AssertStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(AssignExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(BinaryExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(BlockComment n, Void arg) {
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(BlockStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(BooleanLiteralExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(BreakStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(CastExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(CatchClause n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(CharLiteralExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ClassExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ClassOrInterfaceDeclaration n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ClassOrInterfaceType n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(CompilationUnit n, Void arg) {
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ConditionalExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ConstructorDeclaration n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ContinueStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(DoStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(DoubleLiteralExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(EmptyStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(EnclosedExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(EnumConstantDeclaration n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(EnumDeclaration n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ExplicitConstructorInvocationStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ExpressionStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(FieldAccessExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(FieldDeclaration n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ForEachStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ForStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(IfStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(InitializerDeclaration n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(InstanceOfExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(IntegerLiteralExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(JavadocComment n, Void arg) {
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(LabeledStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(LineComment n, Void arg) {
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(LambdaExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(LongLiteralExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(MarkerAnnotationExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(MemberValuePair n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(MethodCallExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(MethodDeclaration n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(MethodReferenceExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(NameExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(NormalAnnotationExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(NullLiteralExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ObjectCreationExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(PackageDeclaration n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(Parameter n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(PrimitiveType n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(Name n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(SimpleName n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ArrayType n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ArrayCreationLevel n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(IntersectionType n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(UnionType n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ReturnStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(SingleMemberAnnotationExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(StringLiteralExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(SuperExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(SwitchEntry n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(SwitchStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(SynchronizedStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ThisExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(ThrowStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(TryStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(LocalClassDeclarationStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(LocalRecordDeclarationStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(TypeExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(NodeList n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(TypeParameter n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(UnaryExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(UnknownType n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(VariableDeclarationExpr n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(VariableDeclarator n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(VoidType n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(WhileStmt n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+
+ @Override
+ public void visit(WildcardType n, Void arg) {
+ assertParentIsSet(n);
+ super.visit(n, arg);
+ }
+ }
+
+}
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ManipulationSteps.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ManipulationSteps.java
new file mode 100644
index 0000000..a8c10f0
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ManipulationSteps.java
@@ -0,0 +1,285 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser.steps;
+
+import com.github.javaparser.ast.CompilationUnit;
+import com.github.javaparser.ast.Modifier;
+import com.github.javaparser.ast.NodeList;
+import com.github.javaparser.ast.PackageDeclaration;
+import com.github.javaparser.ast.body.ClassOrInterfaceDeclaration;
+import com.github.javaparser.ast.body.MethodDeclaration;
+import com.github.javaparser.ast.body.Parameter;
+import com.github.javaparser.ast.body.TypeDeclaration;
+import com.github.javaparser.ast.expr.*;
+import com.github.javaparser.ast.stmt.BlockStmt;
+import com.github.javaparser.ast.stmt.Statement;
+import com.github.javaparser.ast.stmt.TryStmt;
+import com.github.javaparser.ast.type.VoidType;
+import com.github.javaparser.ast.visitor.VoidVisitorAdapter;
+import org.jbehave.core.annotations.Alias;
+import org.jbehave.core.annotations.Given;
+import org.jbehave.core.annotations.Then;
+import org.jbehave.core.annotations.When;
+
+import java.util.Map;
+
+import static com.github.javaparser.StaticJavaParser.*;
+import static com.github.javaparser.ast.Modifier.Keyword.PUBLIC;
+import static com.github.javaparser.ast.Modifier.createModifierList;
+import static com.github.javaparser.ast.Modifier.staticModifier;
+import static com.github.javaparser.ast.NodeList.nodeList;
+import static com.github.javaparser.ast.type.PrimitiveType.intType;
+import static com.github.javaparser.steps.SharedSteps.getMethodByPositionAndClassPosition;
+import static org.hamcrest.CoreMatchers.is;
+import static org.hamcrest.MatcherAssert.assertThat;
+import static org.junit.jupiter.api.Assertions.assertNotEquals;
+
+public class ManipulationSteps {
+
+ /* Fields used to maintain step state within this step class */
+ private BlockStmt blockStmt;
+ private Statement statement;
+ private TryStmt tryStmt;
+ private NodeList variableDeclarationExprList;
+ private ChangeMethodNameToUpperCaseVisitor changeMethodNameToUpperCaseVisitor;
+ private AddNewIntParameterCalledValueVisitor addNewIntParameterCalledValueVisitor;
+
+ /* Map that maintains shares state across step classes. If manipulating the objects in the map you must update the state */
+ private Map state;
+
+ public ManipulationSteps(Map state) {
+ this.state = state;
+ }
+
+ @Given("a BlockStmt")
+ public void givenABlockStatement() {
+ blockStmt = new BlockStmt();
+ }
+
+ @Given("a Statement")
+ public void givenAStatement() {
+ statement = null;
+ }
+
+ @Given("a TryStmt")
+ public void givenATryStmt() {
+ tryStmt = new TryStmt();
+ }
+
+ @Given("a List of VariableDeclarations")
+ public void givenAListOfVariableDeclarations() {
+ variableDeclarationExprList = new NodeList<>();
+ variableDeclarationExprList.add(new VariableDeclarationExpr());
+ variableDeclarationExprList.add(new VariableDeclarationExpr());
+ }
+
+ @Given("a ChangeNameToUpperCaseVisitor")
+ public void givenAChangeNameToUpperCaseVisitor() {
+ changeMethodNameToUpperCaseVisitor = new ChangeMethodNameToUpperCaseVisitor();
+ }
+
+ @Given("a AddNewIntParameterCalledValueVisitor")
+ public void givenAAddNewParameterCalledValueVisitor() {
+ addNewIntParameterCalledValueVisitor = new AddNewIntParameterCalledValueVisitor();
+ }
+
+ @When("is the String \"$value\" is parsed by the JavaParser using parseBlock")
+ public void whenIsTheStringIsParsedByTheJavaParser(String value) {
+ blockStmt = parseBlock(value);
+ }
+
+ @When("is the String \"$value\" is parsed by the JavaParser using parseStatement")
+ public void whenIsTheStringIsParsedByTheJavaParserUsingParseStatement(String value) {
+ statement = parseStatement(value);
+ }
+
+ @When("the List of VariableDeclarations are set as the resources on TryStmt")
+ public void whenTheListOfVariableDeclarationsAreSetAsTheResourcesOnTryStmt() {
+ tryStmt.setResources(variableDeclarationExprList);
+ }
+
+ @When("empty list is set as the resources on TryStmt")
+ public void whenNullIsSetAsTheResourcesOnTryStmt() {
+ tryStmt.setResources(new NodeList<>());
+ }
+
+ @When("the package declaration is set to \"$packageName\"")
+ public void whenThePackageDeclarationIsSetTo(String packageName) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ compilationUnit.setPackageDeclaration(new PackageDeclaration(parseName(packageName)));
+ state.put("cu1", compilationUnit);
+ }
+
+ @When("a public class called \"$className\" is added to the CompilationUnit")
+ public void whenAClassCalledIsAddedToTheCompilationUnit(String className) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ TypeDeclaration> type = new ClassOrInterfaceDeclaration(createModifierList(PUBLIC), false, "CreateClass");
+ compilationUnit.setTypes(nodeList(type));
+ state.put("cu1", compilationUnit);
+ }
+
+ @When("a public static method called \"$methodName\" returning void is added to class $position in the compilation unit")
+ public void whenAStaticMethodCalledReturningIsAddedToClassInTheCompilationUnit(String methodName, int position) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ TypeDeclaration> type = compilationUnit.getType(position - 1);
+ NodeList modifiers = createModifierList(PUBLIC);
+ MethodDeclaration method = new MethodDeclaration(modifiers, new VoidType(), methodName);
+ modifiers.add(staticModifier());
+ method.setModifiers(modifiers);
+ type.addMember(method);
+ state.put("cu1", compilationUnit);
+ }
+
+ @When("$typeName varargs called \"$parameterName\" are added to method $methodPosition in class $classPosition")
+ public void whenVarargsCalledAreAddedToMethodInClass(String typeName, String parameterName, int methodPosition, int classPosition) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ getMethodByPositionAndClassPosition(compilationUnit, methodPosition, classPosition)
+ .addAndGetParameter(typeName, parameterName)
+ .setVarArgs(true);
+ }
+
+ @When("a BlockStmt is added to method $methodPosition in class $classPosition")
+ public void whenABlockStmtIsAddedToMethodInClass(int methodPosition, int classPosition) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ MethodDeclaration method = getMethodByPositionAndClassPosition(compilationUnit, methodPosition, classPosition);
+ method.setBody(new BlockStmt());
+ }
+
+ @When("$className.$fieldName.$methodName(\"$stringValue\"); is added to the body of method $methodPosition in class $classPosition")
+ public void whenHelloWorldIsAddedToTheBodyOfMethodInClass(String className, String fieldName, String methodName, String stringValue,
+ int methodPosition, int classPosition) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ MethodDeclaration method = getMethodByPositionAndClassPosition(compilationUnit, methodPosition, classPosition);
+ NameExpr clazz = new NameExpr(className);
+ FieldAccessExpr field = new FieldAccessExpr(clazz, fieldName);
+ MethodCallExpr call = new MethodCallExpr(field, methodName);
+ call.addArgument(new StringLiteralExpr(stringValue));
+ method.getBody().get().addStatement(call);
+ }
+
+ @When("method $methodPosition in class $classPosition has it's name converted to uppercase")
+ public void whenMethodInClassHasItsNameConvertedToUppercase(int methodPosition, int classPosition) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ MethodDeclaration method = getMethodByPositionAndClassPosition(compilationUnit, methodPosition, classPosition);
+ method.setName(method.getNameAsString().toUpperCase());
+ }
+
+ @When("method $methodPosition in class $classPosition has an int parameter called \"$paramName\" added")
+ public void whenMethodInClassHasAnIntArgumentCalledAdded(int methodPosition, int classPosition, String paramName) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ MethodDeclaration method = getMethodByPositionAndClassPosition(compilationUnit, methodPosition, classPosition);
+ method.addParameter(intType(), paramName);
+ }
+
+ @When("the compilation unit is cloned")
+ public void whenTheCompilationUnitIsCloned() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ state.put("cu1", compilationUnit.clone());
+ }
+
+ @When("the ChangeNameToUpperCaseVisitor visits to compilation unit")
+ public void whenTheVisitorVisitsToCompilationUnit() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ changeMethodNameToUpperCaseVisitor.visit(compilationUnit, null);
+ state.put("cu1", compilationUnit);
+ }
+
+ @When("the AddNewIntParameterCalledValueVisitor visits to compilation unit")
+ public void whenTheAddNewParameterCalledValueVisitorVisitsToCompilationUnit() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ addNewIntParameterCalledValueVisitor.visit(compilationUnit, null);
+ state.put("cu1", compilationUnit);
+ }
+
+ @Then("is not equal to null")
+ public void thenIsNotEqualToNull() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ assertNotEquals(compilationUnit, null);
+ }
+
+ @Then("is not equal to $value")
+ public void thenIsNotEqualTo(String value) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ assertNotEquals(compilationUnit, value);
+ }
+
+ @Then("Statement $position in BlockStmt toString is \"$expectedContent\"")
+ public void thenTheBlockStmtContentIs(int position, String expectedContent) {
+ Statement statementUnderTest = blockStmt.getStatement(position - 1);
+ assertThat(statementUnderTest.toString(), is(expectedContent));
+ }
+
+ @Then("Statement toString is \"$expectedContent\"")
+ public void thenStatementToStringIsxXy(String expectedContent) {
+ assertThat(statement.toString(), is(expectedContent));
+ }
+
+ @Then("all the VariableDeclarations parent is the TryStmt")
+ public void thenAllTheVariableDeclarationsParentIsTheTryStmt() {
+ variableDeclarationExprList.forEach(expr -> assertThat(expr.getParentNode().get(), is(tryStmt)));
+ }
+
+ @Then("the TryStmt has no child nodes")
+ public void thenTheTryStmtHasNotChildNodes() {
+ assertThat(tryStmt.getChildNodes().size(), is(0));
+ }
+
+ @Then("method $methodPosition in class $classPosition has the name \"$expectedName\"")
+ public void thenMethodInClassHasTheName(int methodPosition, int classPosition, String expectedName) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ MethodDeclaration method = getMethodByPositionAndClassPosition(compilationUnit, methodPosition, classPosition);
+ assertThat(method.getNameAsString(), is(expectedName));
+ }
+
+ @Then("method $methodPosition in class $classPosition has $expectedCount parameters")
+ @Alias("method $methodPosition in class $classPosition has $expectedCount parameter")
+ public void thenMethodInClassHasArguments(int methodPosition, int classPosition, int expectedCount) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ MethodDeclaration method = getMethodByPositionAndClassPosition(compilationUnit, methodPosition, classPosition);
+
+ assertThat(method.getParameters().size(), is(expectedCount));
+ }
+
+ @Then("method $methodPosition in class $classPosition parameter $parameterPosition is type int called \"$expectedName\"")
+ public void thenMethodInClassParameterIsTypeIntCalled(int methodPosition, int classPosition, int parameterPosition, String expectedName) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ MethodDeclaration method = getMethodByPositionAndClassPosition(compilationUnit, methodPosition, classPosition);
+ Parameter parameter = method.getParameter(parameterPosition - 1);
+ assertThat(parameter.getType(), is(intType()));
+ assertThat(parameter.getNameAsString(), is(expectedName));
+ }
+
+ private static class ChangeMethodNameToUpperCaseVisitor extends VoidVisitorAdapter {
+ @Override
+ public void visit(MethodDeclaration n, Void arg) {
+ n.setName(n.getNameAsString().toUpperCase());
+ }
+ }
+
+ private static class AddNewIntParameterCalledValueVisitor extends VoidVisitorAdapter {
+ @Override
+ public void visit(MethodDeclaration n, Void arg) {
+ n.addParameter(intType(), "value");
+ }
+ }
+}
+
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ParsingSteps.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ParsingSteps.java
new file mode 100644
index 0000000..38c059b
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/ParsingSteps.java
@@ -0,0 +1,344 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser.steps;
+
+import com.github.javaparser.JavaParser;
+import com.github.javaparser.ParseResult;
+import com.github.javaparser.ast.CompilationUnit;
+import com.github.javaparser.ast.Node;
+import com.github.javaparser.ast.PackageDeclaration;
+import com.github.javaparser.ast.body.*;
+import com.github.javaparser.ast.expr.*;
+import com.github.javaparser.ast.stmt.BlockStmt;
+import com.github.javaparser.ast.stmt.ExpressionStmt;
+import com.github.javaparser.ast.stmt.ReturnStmt;
+import com.github.javaparser.ast.stmt.Statement;
+import org.jbehave.core.annotations.Given;
+import org.jbehave.core.annotations.Then;
+import org.jbehave.core.annotations.When;
+
+import java.util.List;
+import java.util.Map;
+
+import static com.github.javaparser.ParseStart.COMPILATION_UNIT;
+import static com.github.javaparser.Providers.provider;
+import static com.github.javaparser.steps.SharedSteps.getMemberByTypeAndPosition;
+import static com.github.javaparser.steps.SharedSteps.getMethodByPositionAndClassPosition;
+import static java.lang.String.format;
+import static org.hamcrest.MatcherAssert.assertThat;
+import static org.hamcrest.core.Is.is;
+import static org.hamcrest.core.IsNull.notNullValue;
+import static org.junit.jupiter.api.Assertions.*;
+
+public class ParsingSteps {
+
+ private Map state;
+
+ public ParsingSteps(Map state) {
+ this.state = state;
+ }
+
+ private String sourceUnderTest;
+
+ /*
+ * Given steps
+ */
+
+ @Given("the class:$classSrc")
+ public void givenTheClass(String classSrc) {
+ this.sourceUnderTest = classSrc.trim();
+ }
+
+
+ /*
+ * When steps
+ */
+
+ @When("I take the ArrayCreationExpr")
+ public void iTakeTheArrayCreationExpr() {
+ setSelectedNodeFromCompilationUnit(ArrayCreationExpr.class);
+ }
+
+ @When("I take the PackageDeclaration")
+ public void iTakeThePackageDeclaration() {
+ setSelectedNodeFromCompilationUnit(PackageDeclaration.class);
+ }
+
+ @When("I take the ObjectCreationExpr")
+ public void iTakeTheObjectCreationExpr() throws ClassNotFoundException {
+ setSelectedNodeFromCompilationUnit(ObjectCreationExpr.class);
+ }
+
+ /*
+ * Then steps
+ */
+
+ @Then("constructor $constructorPosition in class $classPosition declaration as a String is \"$expectedString\"")
+ public void thenTheConstructorDeclarationAsAStringIs(int constructorPosition, int classPosition, String expectedString) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ ClassOrInterfaceDeclaration clazz = (ClassOrInterfaceDeclaration) compilationUnit.getType(classPosition - 1);
+ ConstructorDeclaration constructor = (ConstructorDeclaration) clazz.getMember(constructorPosition - 1);
+ assertThat(constructor.getDeclarationAsString(), is(expectedString));
+ }
+
+ @Then("constructor $constructorPosition in class $classPosition declaration short form as a String is \"$expectedString\"")
+ public void thenConstructorInClassDeclarationShortFormAsAStringIs(int constructorPosition, int classPosition, String expectedString) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ ClassOrInterfaceDeclaration clazz = (ClassOrInterfaceDeclaration) compilationUnit.getType(classPosition - 1);
+ ConstructorDeclaration constructor = (ConstructorDeclaration) clazz.getMember(constructorPosition - 1);
+ assertThat(constructor.getDeclarationAsString(false, false), is(expectedString));
+ }
+
+ @Then("method $methodPosition in class $classPosition declaration as a String is \"$expectedString\"")
+ public void thenMethod1InClass1DeclarationAsAStringIs(int methodPosition, int classPosition, String expectedString) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ ClassOrInterfaceDeclaration clazz = (ClassOrInterfaceDeclaration) compilationUnit.getType(classPosition - 1);
+ MethodDeclaration method = (MethodDeclaration) clazz.getMember(methodPosition - 1);
+ assertThat(method.getDeclarationAsString(), is(expectedString));
+ }
+
+ @Then("method $methodPosition in class $classPosition declaration as a String short form is \"$expectedString\"")
+ public void thenMethodInClassDeclarationAsAStringShortFormIs(int methodPosition, int classPosition, String expectedString) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ ClassOrInterfaceDeclaration clazz = (ClassOrInterfaceDeclaration) compilationUnit.getType(classPosition - 1);
+ MethodDeclaration method = (MethodDeclaration) clazz.getMember(methodPosition - 1);
+ assertThat(method.getDeclarationAsString(false, false), is(expectedString));
+ }
+
+ @Then("field $fieldPosition in class $classPosition contains annotation $annotationPosition value is \"$expectedValue\"")
+ public void thenFieldInClassContainsAnnotationValueIs(int fieldPosition, int classPosition, int annotationPosition, String expectedValue) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+
+ TypeDeclaration> classUnderTest = compilationUnit.getType(classPosition - 1);
+ FieldDeclaration fieldUnderTest = getMemberByTypeAndPosition(classUnderTest, fieldPosition - 1,
+ FieldDeclaration.class);
+ AnnotationExpr annotationUnderTest = fieldUnderTest.getAnnotation(annotationPosition - 1);
+ assertThat(annotationUnderTest.getChildNodes().get(1).toString(), is(expectedValue));
+ }
+
+ @Then("lambda in statement $statementPosition in method $methodPosition in class $classPosition is called $expectedName")
+ public void thenLambdaInClassIsCalled(int statementPosition, int methodPosition, int classPosition, String expectedName) {
+ Statement statement = getStatementInMethodInClass(statementPosition, methodPosition, classPosition);
+ VariableDeclarationExpr expression = (VariableDeclarationExpr) ((ExpressionStmt) statement).getExpression();
+ VariableDeclarator variableDeclarator = expression.getVariable(0);
+ assertThat(variableDeclarator.getNameAsString(), is(expectedName));
+ }
+
+ @Then("lambda in statement $statementPosition in method $methodPosition in class $classPosition body is \"$expectedBody\"")
+ public void thenLambdaInStatementInMethodInClassBody(int statementPosition, int methodPosition, int classPosition,
+ String expectedBody) {
+ LambdaExpr lambdaExpr = getLambdaExprInStatementInMethodInClass(statementPosition, methodPosition, classPosition);
+ assertThat(lambdaExpr.getBody().toString(), is(expectedBody));
+ }
+
+ @Then("lambda in method call in statement $statementPosition in method $methodPosition in class $classPosition body is \"$expectedBody\"")
+ public void thenLambdaInMethodCallInStatementInMethodInClassBody(int statementPosition, int methodPosition, int classPosition,
+ String expectedBody) {
+ ExpressionStmt statement = getStatementInMethodInClass(statementPosition, methodPosition, classPosition).asExpressionStmt();
+ VariableDeclarationExpr variableDeclarationExpr = statement.getExpression().asVariableDeclarationExpr();
+ VariableDeclarator variableDeclarator = variableDeclarationExpr.getVariable(0);
+ MethodCallExpr methodCallExpr = (MethodCallExpr) variableDeclarator.getInitializer().orElse(null);
+ CastExpr castExpr = methodCallExpr.getArgument(0).asCastExpr();
+ LambdaExpr lambdaExpr = castExpr.getExpression().asLambdaExpr();
+ assertThat(lambdaExpr.getBody().toString(), is(expectedBody));
+ }
+
+ @Then("lambda in statement $statementPosition in method $methodPosition in class $classPosition block statement is null")
+ public void thenLambdaInStatementInMethodInClassBlockStatementIsNull(int statementPosition, int methodPosition, int classPosition) {
+ LambdaExpr lambdaExpr = getLambdaExprInStatementInMethodInClass(statementPosition, methodPosition, classPosition);
+ BlockStmt blockStmt = lambdaExpr.getBody().asBlockStmt();
+ assertEquals(true, blockStmt.getStatements().isEmpty());
+ }
+
+ @Then("lambda in statement $statementPosition in method $methodPosition in class $classPosition has parameters with non-null type")
+ public void thenLambdaInStatementInMethodInClassHasParametersWithNonNullType(int statementPosition, int methodPosition, int classPosition) {
+ LambdaExpr lambdaExpr = getLambdaExprInStatementInMethodInClass(statementPosition, methodPosition, classPosition);
+ for (Parameter parameter : lambdaExpr.getParameters()) {
+ assertThat(parameter.getType(), is(notNullValue()));
+ }
+ }
+
+ @Then("lambda in statement $statementPosition in method $methodPosition in class $classPosition block statement is \"$expectedBody\"")
+ public void thenLambdaInStatementInMethodInClassBlockStatement(int statementPosition, int methodPosition, int classPosition,
+ String expectedBody) {
+ LambdaExpr lambdaExpr = getLambdaExprInStatementInMethodInClass(statementPosition, methodPosition, classPosition);
+ BlockStmt blockStmt = lambdaExpr.getBody().asBlockStmt();
+ Statement lambdaStmt = blockStmt.getStatement(0);
+ assertThat(lambdaStmt.toString(), is(expectedBody));
+ }
+
+ @Then("lambda in statement $statementPosition in method $methodPosition in class $classPosition is parent of contained body")
+ public void thenLambdaInStatementInMethodInClassIsParentOfContainedBody(int statementPosition, int methodPosition, int classPosition) {
+ LambdaExpr lambdaExpr = getLambdaExprInStatementInMethodInClass(statementPosition, methodPosition, classPosition);
+ Statement body = lambdaExpr.getBody();
+ assertThat(body.getParentNode().get(), is(lambdaExpr));
+ }
+
+ @Then("lambda in statement $statementPosition in method $methodPosition in class $classPosition is parent of contained parameter")
+ public void thenLambdaInStatementInMethodInClassIsParentOfContainedParameter(int statementPosition, int methodPosition, int classPosition) {
+ LambdaExpr lambdaExpr = getLambdaExprInStatementInMethodInClass(statementPosition, methodPosition, classPosition);
+ Parameter parameter = lambdaExpr.getParameter(0);
+ assertThat(parameter.getParentNode().get(), is(lambdaExpr));
+ }
+
+ @Then("method reference in statement $statementPosition in method $methodPosition in class $classPosition scope is $expectedName")
+ public void thenMethodReferenceInStatementInMethodInClassIsScope(int statementPosition, int methodPosition,
+ int classPosition, String expectedName) {
+ ExpressionStmt statementUnderTest = getStatementInMethodInClass(statementPosition, methodPosition, classPosition).asExpressionStmt();
+ assertEquals(1, statementUnderTest.findAll(MethodReferenceExpr.class).size());
+ MethodReferenceExpr methodReferenceUnderTest = statementUnderTest.findFirst(MethodReferenceExpr.class).get();
+ assertThat(methodReferenceUnderTest.getScope().toString(), is(expectedName));
+ }
+
+ @Then("method reference in statement $statementPosition in method $methodPosition in class $classPosition identifier is $expectedName")
+ public void thenMethodReferenceInStatementInMethodInClassIdentifierIsCompareByAge(int statementPosition, int methodPosition,
+ int classPosition, String expectedName) {
+ Statement statementUnderTest = getStatementInMethodInClass(statementPosition, methodPosition, classPosition);
+ assertEquals(1, statementUnderTest.findAll(MethodReferenceExpr.class).size());
+ MethodReferenceExpr methodReferenceUnderTest = statementUnderTest.findFirst(MethodReferenceExpr.class).get();
+ assertThat(methodReferenceUnderTest.getIdentifier(), is(expectedName));
+ }
+
+ @Then("method $methodPosition class $classPosition is a default method")
+ public void thenMethodClassIsADefaultMethod(int methodPosition, int classPosition) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ MethodDeclaration methodUnderTest = getMethodByPositionAndClassPosition(compilationUnit,
+ methodPosition, classPosition);
+ assertThat(methodUnderTest.isDefault(), is(true));
+ }
+
+ @Then("method $methodPosition class $classPosition is not a default method")
+ public void thenMethodClassIsNotADefaultMethod(int methodPosition, int classPosition) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ MethodDeclaration methodUnderTest = getMethodByPositionAndClassPosition(compilationUnit,
+ methodPosition, classPosition);
+ assertThat(methodUnderTest.isDefault(), is(false));
+ }
+
+ private Statement getStatementInMethodInClass(int statementPosition, int methodPosition, int classPosition) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ MethodDeclaration method = getMethodByPositionAndClassPosition(compilationUnit, methodPosition, classPosition);
+ return method.getBody().get().getStatement(statementPosition - 1);
+ }
+
+ private LambdaExpr getLambdaExprInStatementInMethodInClass(int statementPosition, int methodPosition, int classPosition) {
+ Statement statement = getStatementInMethodInClass(statementPosition, methodPosition, classPosition);
+ VariableDeclarationExpr expression = ((ExpressionStmt) statement).getExpression().asVariableDeclarationExpr();
+ VariableDeclarator variableDeclarator = expression.getVariable(0);
+ return (LambdaExpr) variableDeclarator.getInitializer().orElse(null);
+ }
+
+ @Then("all nodes refer to their parent")
+ public void allNodesReferToTheirParent() {
+ assertAllNodesOfTheCompilationUnitHaveTheirParentSet("cu1");
+ }
+
+ @Then("all nodes of the second compilation unit refer to their parent")
+ public void thenAllNodesOfTheSecondCompilationUnitReferToTheirParent() {
+ assertAllNodesOfTheCompilationUnitHaveTheirParentSet("cu2");
+ }
+
+ private void assertAllNodesOfTheCompilationUnitHaveTheirParentSet(String stateKey) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get(stateKey);
+ ExistenceOfParentNodeVerifier parentVerifier = new ExistenceOfParentNodeVerifier();
+ parentVerifier.verify(compilationUnit);
+ }
+
+ @Then("ThenExpr in the conditional expression of the statement $statementPosition in method $methodPosition in class $classPosition is LambdaExpr")
+ public void thenLambdaInConditionalExpressionInMethodInClassIsParentOfContainedParameter(int statementPosition, int methodPosition, int classPosition) {
+ ReturnStmt returnStmt = getStatementInMethodInClass(statementPosition, methodPosition, classPosition).asReturnStmt();
+ ConditionalExpr conditionalExpr = (ConditionalExpr) returnStmt.getExpression().orElse(null);
+ assertThat(conditionalExpr.getElseExpr().getClass().getName(), is(LambdaExpr.class.getName()));
+ }
+
+ @Then("the begin line is $line")
+ public void thenTheBeginLineIs(int line) {
+ Node node = (Node) state.get("selectedNode");
+ assertEquals(line, node.getBegin().get().line);
+ }
+
+ @Then("the begin column is $column")
+ public void thenTheBeginColumnIs(int column) {
+ Node node = (Node) state.get("selectedNode");
+ assertEquals(column, node.getBegin().get().column);
+ }
+
+ @Then("the end line is $line")
+ public void thenTheEndLineIs(int line) {
+ Node node = (Node) state.get("selectedNode");
+ assertEquals(line, node.getEnd().get().line);
+ }
+
+ @Then("the end column is $column")
+ public void thenTheEndColumnIs(int column) {
+ Node node = (Node) state.get("selectedNode");
+ assertEquals(column, node.getEnd().get().column);
+ }
+
+ @Then("no errors are reported")
+ public void thenNoErrorsAreReported() {
+ // this is present just for readability in the scenario specification
+ // if the code is not parsed then exceptions are thrown before reaching this step
+ }
+
+ @Then("the package name is $package")
+ public void thenThePackageNameIs(String expected) {
+ PackageDeclaration node = (PackageDeclaration) state.get("selectedNode");
+ assertEquals(expected, node.getNameAsString());
+ assertEquals(expected, node.getName().toString());
+ }
+
+ @Then("the type's diamond operator flag should be $expectedValue")
+ public void thenTheUsesDiamondOperatorShouldBeBooleanAsString(boolean expectedValue) {
+ ObjectCreationExpr expr = (ObjectCreationExpr) state.get("selectedNode");
+ assertEquals(expectedValue, expr.getType().isUsingDiamondOperator());
+ }
+
+ @Then("the Java parser cannot parse it because of an error")
+ public void javaParserCannotParseBecauseOfLexicalErrors() {
+ ParseResult result = new JavaParser().parse(COMPILATION_UNIT, provider(sourceUnderTest));
+ if (result.isSuccessful()) {
+ fail("Lexical error expected");
+ }
+ }
+
+ @Then("the assignExpr produced doesn't have a null target")
+ public void thenTheAssignExprProducedDoesntHaveANullTarget() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ ClassOrInterfaceDeclaration classDeclaration = compilationUnit.getType(0).asClassOrInterfaceDeclaration();
+ ConstructorDeclaration ctor = classDeclaration.getMember(1).asConstructorDeclaration();
+ ExpressionStmt assignStmt = ctor.getBody().getStatement(0).asExpressionStmt();
+ AssignExpr assignExpr = assignStmt.getExpression().asAssignExpr();
+ assertNotNull(assignExpr.getTarget());
+ assertEquals(NameExpr.class, assignExpr.getTarget().getClass());
+ assertEquals(assignExpr.getTarget().asNameExpr().getNameAsString(), "mString");
+ }
+
+ private void setSelectedNodeFromCompilationUnit(Class extends Node> nodeType) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ List extends Node> nodes = compilationUnit.findAll(nodeType);
+ if (nodes.size() != 1) {
+ throw new RuntimeException(format("Exactly one %s expected", nodeType.getSimpleName()));
+ }
+ state.put("selectedNode", nodes.get(0));
+ }
+}
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/PositionRangeSteps.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/PositionRangeSteps.java
new file mode 100644
index 0000000..9ca8969
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/PositionRangeSteps.java
@@ -0,0 +1,128 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser.steps;
+
+import com.github.javaparser.Position;
+import com.github.javaparser.Range;
+import org.jbehave.core.annotations.BeforeScenario;
+import org.jbehave.core.annotations.Given;
+import org.jbehave.core.annotations.Then;
+import org.jbehave.core.annotations.When;
+
+import static com.github.javaparser.Range.range;
+import static org.junit.jupiter.api.Assertions.assertFalse;
+import static org.junit.jupiter.api.Assertions.assertTrue;
+
+public class PositionRangeSteps {
+
+ private Position position;
+ private Position secondPosition;
+ private Range range;
+ private Range secondRange;
+
+ @BeforeScenario
+ public void reset() {
+ position = null;
+ secondPosition = null;
+ range = null;
+ secondRange = null;
+ }
+ /*
+ * Given steps
+ */
+
+ @Given("the position $line, $column")
+ public void givenThePosition(int line, int column) {
+ this.position = new Position(line, column);
+ }
+
+ @Given("the range $line1, $column1 - $line2, $column2")
+ public void givenTheRange(int line1, int column1, int line2, int column2) {
+ this.range = range(line1, column1, line2, column2);
+ }
+
+ /*
+ * When steps
+ */
+
+ @When("I compare to position $line, $column")
+ public void iCompareToPosition(int line, int column) {
+ secondPosition = new Position(line, column);
+ }
+
+ @When("I compare to range $line1, $column1 - $line2, $column2")
+ public void whenICompareToRange(int line1, int column1, int line2, int column2) {
+ this.secondRange = range(line1, column1, line2, column2);
+ }
+
+ /*
+ * Then steps
+ */
+
+ @Then("the positions are equal")
+ public void thenThePositionsAreEqual() {
+ assertTrue(position.equals(secondPosition));
+ }
+
+ @Then("it is after the {first|} position")
+ public void thenItIsAfterTheFirstPosition() {
+ if (secondPosition != null) {
+ assertTrue(secondPosition.isAfter(position));
+ } else {
+ assertTrue(secondRange.isAfter(position));
+ }
+ }
+
+ @Then("it is before the {first|} position")
+ public void thenItIsBeforeTheFirstPosition() {
+ if (secondPosition != null) {
+ assertTrue(secondPosition.isBefore(position));
+ } else {
+ assertTrue(secondRange.isBefore(position));
+ }
+ }
+
+ @Then("the positions are not equal")
+ public void thenThePositionsAreNotEqual() {
+ assertFalse(position.equals(secondPosition));
+ }
+
+ @Then("it is not after the {first|} position")
+ public void thenItIsNotAfterTheFirstPosition() {
+ assertFalse(secondPosition.isAfter(position));
+ }
+
+ @Then("it is not before the {first|} position")
+ public void thenItIsNotBeforeTheFirstPosition() {
+ assertFalse(secondPosition.isBefore(position));
+ }
+
+ @Then("the ranges are equal")
+ public void theRangesAreEqual() {
+ assertTrue(range.equals(secondRange));
+ }
+
+ @Then("it is contained in the first range")
+ public void itIsContainedInTheFirstRange() {
+ assertTrue(range.contains(secondRange));
+ }
+}
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/PrettyPrintingSteps.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/PrettyPrintingSteps.java
new file mode 100644
index 0000000..8a536b7
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/PrettyPrintingSteps.java
@@ -0,0 +1,112 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser.steps;
+
+import com.github.javaparser.ast.CompilationUnit;
+import com.github.javaparser.ast.Node;
+import com.github.javaparser.ast.visitor.ModifierVisitor;
+import org.jbehave.core.annotations.Given;
+import org.jbehave.core.annotations.Then;
+import org.jbehave.core.annotations.When;
+
+import java.io.File;
+import java.io.FileReader;
+import java.io.IOException;
+import java.net.URISyntaxException;
+import java.net.URL;
+
+import static com.github.javaparser.StaticJavaParser.*;
+import static com.github.javaparser.utils.Utils.readerToString;
+import static org.junit.jupiter.api.Assertions.assertEquals;
+
+public class PrettyPrintingSteps {
+
+ private Node resultNode;
+ private String sourceUnderTest;
+
+ @Given("the {class|compilation unit|expression|block|statement|import|annotation|body|class body|interface body}:$classSrc")
+ public void givenTheClass(String classSrc) {
+ this.sourceUnderTest = classSrc.trim();
+ }
+
+ @Given("the {class|compilation unit|expression|block|statement|import|annotation|body|class body|interface body} in the file \"$classFile\"")
+ public void givenTheClassInTheFile(String classFile) throws URISyntaxException, IOException {
+ URL url = getClass().getResource("../samples/" + classFile);
+ sourceUnderTest = readerToString(new FileReader(new File(url.toURI()))).trim();
+ }
+
+ @When("the {class|compilation unit} is parsed by the Java parser")
+ public void whenTheClassIsParsedByTheJavaParser() {
+ resultNode = parse(sourceUnderTest);
+ }
+
+ @When("the expression is parsed by the Java parser")
+ public void whenTheExpressionIsParsedByTheJavaParser() {
+ resultNode = parseExpression(sourceUnderTest);
+ }
+
+ @When("the block is parsed by the Java parser")
+ public void whenTheBlockIsParsedByTheJavaParser() {
+ resultNode = parseBlock(sourceUnderTest);
+ }
+
+ @When("the statement is parsed by the Java parser")
+ public void whenTheStatementIsParsedByTheJavaParser() {
+ resultNode = parseStatement(sourceUnderTest);
+ }
+
+ @When("the import is parsed by the Java parser")
+ public void whenTheImportIsParsedByTheJavaParser() {
+ resultNode = parseImport(sourceUnderTest);
+ }
+
+ @When("the annotation is parsed by the Java parser")
+ public void whenTheAnnotationIsParsedByTheJavaParser() {
+ resultNode = parseAnnotation(sourceUnderTest);
+ }
+
+ @When("the annotation body declaration is parsed by the Java parser")
+ public void whenTheBodyDeclarationIsParsedByTheJavaParser() {
+ resultNode = parseAnnotationBodyDeclaration(sourceUnderTest);
+ }
+
+ @When("the class body declaration is parsed by the Java parser")
+ public void whenTheClassBodyDeclarationIsParsedByTheJavaParser() {
+ resultNode = parseBodyDeclaration(sourceUnderTest);
+ }
+
+ @When("the interface body declaration is parsed by the Java parser")
+ public void whenTheInterfaceBodyDeclarationIsParsedByTheJavaParser() {
+ resultNode = parseBodyDeclaration(sourceUnderTest);
+ }
+
+ @When("the class is visited by an empty ModifierVisitorAdapter")
+ public void whenTheClassIsVisitedByAnEmptyModifierVisitorAdapter() {
+ (new ModifierVisitor() {
+ }).visit((CompilationUnit) resultNode, null);
+ }
+
+ @Then("it is printed as:$src")
+ public void isPrintedAs(String src) {
+ assertEquals(src.trim(), resultNode.toString().trim());
+ }
+}
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/SharedSteps.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/SharedSteps.java
new file mode 100644
index 0000000..73ae736
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/SharedSteps.java
@@ -0,0 +1,163 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser.steps;
+
+import com.github.javaparser.ast.CompilationUnit;
+import com.github.javaparser.ast.body.BodyDeclaration;
+import com.github.javaparser.ast.body.MethodDeclaration;
+import com.github.javaparser.ast.body.TypeDeclaration;
+import org.hamcrest.CoreMatchers;
+import org.jbehave.core.annotations.Given;
+import org.jbehave.core.annotations.Then;
+import org.jbehave.core.annotations.When;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.URISyntaxException;
+import java.net.URL;
+import java.util.Map;
+
+import static com.github.javaparser.StaticJavaParser.parse;
+import static org.hamcrest.MatcherAssert.assertThat;
+import static org.hamcrest.core.Is.is;
+import static org.hamcrest.core.IsEqual.equalTo;
+import static org.hamcrest.core.IsNot.not;
+import static org.hamcrest.text.IsEqualCompressingWhiteSpace.equalToCompressingWhiteSpace;
+
+public class SharedSteps {
+
+ /* Map that maintains shares state across step classes. If manipulating the objects in the map you must update the state */
+ private Map state;
+
+ public SharedSteps(Map state) {
+ this.state = state;
+ }
+
+ /*
+ * Given steps
+ */
+
+ @Given("a CompilationUnit")
+ public void givenACompilationUnit() {
+ state.put("cu1", new CompilationUnit());
+ }
+
+ @Given("a second CompilationUnit")
+ public void givenASecondCompilationUnit() {
+ state.put("cu2", new CompilationUnit());
+ }
+
+ /*
+ * When steps
+ */
+
+ @When("the following source is parsed:$classSrc")
+ public void whenTheFollowingSourceIsParsed(String classSrc) {
+ state.put("cu1", parse(classSrc.trim()));
+ }
+
+ @When("the following source is parsed (trimming space):$classSrc")
+ public void whenTheFollowingSourceIsParsedTrimmingSpace(String classSrc) {
+ state.put("cu1", parse(classSrc.trim()));
+ }
+
+ @When("the following sources is parsed by the second CompilationUnit:$classSrc")
+ public void whenTheFollowingSourcesIsParsedBytTheSecondCompilationUnit(String classSrc) {
+ state.put("cu2", parse(classSrc.trim()));
+ }
+
+ @When("file \"$fileName\" is parsed")
+ public void whenTheJavaFileIsParsed(String fileName) throws IOException, URISyntaxException {
+ URL url = getClass().getResource("../samples/" + fileName);
+ CompilationUnit compilationUnit = parse(new File(url.toURI()));
+ state.put("cu1", compilationUnit);
+ }
+
+ @Then("the CompilationUnit is equal to the second CompilationUnit")
+ public void thenTheCompilationUnitIsEqualToTheSecondCompilationUnit() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ CompilationUnit compilationUnit2 = (CompilationUnit) state.get("cu2");
+
+ assertThat(compilationUnit, is(equalTo(compilationUnit2)));
+ }
+
+ @Then("the CompilationUnit has the same hashcode to the second CompilationUnit")
+ public void thenTheCompilationUnitHasTheSameHashcodeToTheSecondCompilationUnit() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ CompilationUnit compilationUnit2 = (CompilationUnit) state.get("cu2");
+
+ assertThat(compilationUnit.hashCode(), is(equalTo(compilationUnit2.hashCode())));
+ }
+
+ @Then("the CompilationUnit is not equal to the second CompilationUnit")
+ public void thenTheCompilationUnitIsNotEqualToTheSecondCompilationUnit() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ CompilationUnit compilationUnit2 = (CompilationUnit) state.get("cu2");
+
+ assertThat(compilationUnit, not(equalTo(compilationUnit2)));
+ }
+
+ @Then("the CompilationUnit has a different hashcode to the second CompilationUnit")
+ public void thenTheCompilationUnitHasADifferentHashcodeToTheSecondCompilationUnit() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ CompilationUnit compilationUnit2 = (CompilationUnit) state.get("cu2");
+
+ assertThat(compilationUnit.hashCode(), not(equalTo(compilationUnit2.hashCode())));
+ }
+
+ @Then("the expected source should be:$classSrc")
+ public void thenTheExpectedSourcesShouldBe(String classSrc) {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ assertThat(compilationUnit.toString(), CoreMatchers.is(equalToCompressingWhiteSpace(classSrc)));
+ }
+
+ public static > T getMemberByTypeAndPosition(TypeDeclaration> typeDeclaration, int position, Class typeClass) {
+ int typeCount = 0;
+ for (BodyDeclaration> declaration : typeDeclaration.getMembers()) {
+ if (declaration.getClass().equals(typeClass)) {
+ if (typeCount == position) {
+ return (T) declaration;
+ }
+ typeCount++;
+ }
+ }
+ throw new IllegalArgumentException("No member " + typeClass + " at position: " + position);
+ }
+
+ public static MethodDeclaration getMethodByPositionAndClassPosition(CompilationUnit compilationUnit,
+ int methodPosition, int classPosition) {
+ TypeDeclaration> type = compilationUnit.getType(classPosition - 1);
+
+ int memberCount = 0;
+ int methodCount = 0;
+ for (BodyDeclaration> bodyDeclaration : type.getMembers()) {
+ if (bodyDeclaration instanceof MethodDeclaration) {
+ if (methodCount == methodPosition - 1) {
+ return (MethodDeclaration) type.getMember(memberCount);
+ }
+ methodCount++;
+ }
+ memberCount++;
+ }
+ throw new IllegalArgumentException("Method not found at position " + methodPosition + "in class " + classPosition);
+ }
+}
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/VisitorSteps.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/VisitorSteps.java
new file mode 100644
index 0000000..5894711
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/steps/VisitorSteps.java
@@ -0,0 +1,171 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser.steps;
+
+import com.github.javaparser.ast.CompilationUnit;
+import com.github.javaparser.ast.body.Parameter;
+import com.github.javaparser.ast.body.VariableDeclarator;
+import com.github.javaparser.ast.visitor.CloneVisitor;
+import com.github.javaparser.ast.visitor.GenericListVisitorAdapter;
+import com.github.javaparser.ast.visitor.GenericVisitorAdapter;
+import com.github.javaparser.ast.visitor.VoidVisitorAdapter;
+import com.github.javaparser.visitors.PositionTestVisitor;
+import org.jbehave.core.annotations.Given;
+import org.jbehave.core.annotations.Then;
+import org.jbehave.core.annotations.When;
+
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
+import java.util.concurrent.atomic.AtomicReference;
+
+import static org.hamcrest.CoreMatchers.is;
+import static org.hamcrest.MatcherAssert.assertThat;
+
+public class VisitorSteps {
+
+ /* Fields used to maintain step state within this step class */
+ private VoidVisitorAdapter> toUpperCaseVariableNameVisitor;
+ private VoidVisitorAdapter> collectVariableNameVisitor;
+ private PositionTestVisitor positionTestVisitor;
+ private GenericVisitorAdapter nameReturningVisitor;
+ private GenericListVisitorAdapter allNameReturningVisitor;
+ private AtomicReference collectedVariableName;
+ private String returnedVariableName;
+ private List returnedVariableNames;
+
+ /* Map that maintains shares state across step classes. If manipulating the objects in the map you must update the state */
+ private Map state;
+
+ public VisitorSteps(Map state) {
+ this.state = state;
+ }
+
+ @Given("a VoidVisitorAdapter with a visit method that changes variable names to uppercase")
+ public void givenAVoidVisitorAdapterWithAVisitMethodThatChangesVariableNamesToUppercase() {
+ toUpperCaseVariableNameVisitor = new VoidVisitorAdapter>() {
+ @Override
+ public void visit(VariableDeclarator n, AtomicReference arg) {
+ n.setName(n.getNameAsString().toUpperCase());
+ }
+ };
+ }
+
+ @Given("a VoidVisitorAdapter with a visit method and collects the variable names")
+ public void givenAVoidVisitorAdapterWithAVisitMethodThatCollectsTheVariableName() {
+ collectVariableNameVisitor = new VoidVisitorAdapter>() {
+ @Override
+ public void visit(VariableDeclarator n, AtomicReference arg) {
+ arg.set(arg.get() + n.getName() + ";");
+ }
+
+ @Override
+ public void visit(Parameter n, AtomicReference arg) {
+ arg.set(arg.get() + n.getName() + ";");
+ }
+ };
+ }
+
+ @Given("a GenericVisitorAdapter with a visit method that returns variable names")
+ public void givenAGenericVisitorAdapterWithAVisitMethodThatReturnsVariableNames() {
+ nameReturningVisitor = new GenericVisitorAdapter() {
+ @Override
+ public String visit(VariableDeclarator n, Void arg) {
+ return n.getNameAsString();
+ }
+ };
+ }
+
+ @Given("a GenericListVisitorAdapter with a visit method that returns all variable names")
+ public void givenAGenericListVisitorAdapterWithAVisitMethodThatReturnsAllVariableNames() {
+ allNameReturningVisitor = new GenericListVisitorAdapter() {
+ @Override
+ public List visit(VariableDeclarator n, Void arg) {
+ return Collections.singletonList(n.getNameAsString());
+ }
+ };
+ }
+
+ @Given("a VoidVisitorAdapter with a visit method that asserts sensible line positions")
+ public void givenAVoidVisitorAdapterWithAVisitMethodThatAssertsSensibleLinePositions() {
+ positionTestVisitor = new PositionTestVisitor();
+ }
+
+ @When("the CompilationUnit is cloned to the second CompilationUnit")
+ public void whenTheSecondCompilationUnitIsCloned() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ CompilationUnit compilationUnit2 = (CompilationUnit) compilationUnit.accept(new CloneVisitor(), null);
+ state.put("cu2", compilationUnit2);
+ }
+
+ @When("the CompilationUnit is visited by the to uppercase visitor")
+ public void whenTheCompilationUnitIsVisitedByTheVistor() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ toUpperCaseVariableNameVisitor.visit(compilationUnit, null);
+ state.put("cu1", compilationUnit);
+ }
+
+ @When("the CompilationUnit is visited by the variable name collector visitor")
+ public void whenTheCompilationUnitIsVisitedByTheVariableNameCollectorVisitor() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ collectedVariableName = new AtomicReference<>("");
+ collectVariableNameVisitor.visit(compilationUnit, collectedVariableName);
+ }
+
+ @When("the CompilationUnit is visited by the visitor that returns variable names")
+ public void whenTheCompilationUnitIsVisitedByTheVisitorThatReturnsVariableNames() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ returnedVariableName = nameReturningVisitor.visit(compilationUnit, null);
+ }
+
+ @When("the CompilationUnit is visited by the visitor that returns all variable names")
+ public void whenTheCompilationUnitIsVisitedByTheVisitorThatReturnsAllVariableNames() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ returnedVariableNames = allNameReturningVisitor.visit(compilationUnit, null);
+ }
+
+ @When("the CompilationUnit is visited by the PositionTestVisitor")
+ public void whenTheCompilationUnitIsVisitedByThePositionTestVisitor() {
+ CompilationUnit compilationUnit = (CompilationUnit) state.get("cu1");
+ compilationUnit.accept(positionTestVisitor, null);
+ }
+
+ @Then("the collected variable name is \"$nameUnderTest\"")
+ public void thenTheCollectedVariableNameIs(String nameUnderTest) {
+ assertThat(collectedVariableName.get(), is(nameUnderTest));
+ }
+
+ @Then("the return variable name is \"$nameUnderTest\"")
+ public void thenTheReturnVariableNameIs(String nameUnderTest) {
+ assertThat(returnedVariableName, is(nameUnderTest));
+ }
+
+ @Then("the first return variable name is \"$nameUnderTest\"")
+ public void thenTheFirstReturnVariableNameIs(String nameUnderTest) {
+ assertThat(returnedVariableNames.get(0), is(nameUnderTest));
+ }
+
+ @Then("the total number of nodes visited is $expectedCount")
+ public void thenTheTotalNumberOfNodesVisitedIs(int expectedCount) {
+ assertThat(positionTestVisitor.getNumberOfNodesVisited(), is(expectedCount));
+ }
+}
diff --git a/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/visitors/PositionTestVisitor.java b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/visitors/PositionTestVisitor.java
new file mode 100644
index 0000000..f365905
--- /dev/null
+++ b/javaparser-core-testing-bdd/src/test/java/com/github/javaparser/visitors/PositionTestVisitor.java
@@ -0,0 +1,562 @@
+/*
+ * Copyright (C) 2007-2010 Júlio Vilmar Gesser.
+ * Copyright (C) 2011, 2013-2024 The JavaParser Team.
+ *
+ * This file is part of JavaParser.
+ *
+ * JavaParser can be used either under the terms of
+ * a) the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * b) the terms of the Apache License
+ *
+ * You should have received a copy of both licenses in LICENCE.LGPL and
+ * LICENCE.APACHE. Please refer to those files for details.
+ *
+ * JavaParser is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ */
+
+package com.github.javaparser.visitors;
+
+import com.github.javaparser.Position;
+import com.github.javaparser.ast.ArrayCreationLevel;
+import com.github.javaparser.ast.CompilationUnit;
+import com.github.javaparser.ast.Node;
+import com.github.javaparser.ast.PackageDeclaration;
+import com.github.javaparser.ast.body.*;
+import com.github.javaparser.ast.comments.BlockComment;
+import com.github.javaparser.ast.comments.JavadocComment;
+import com.github.javaparser.ast.comments.LineComment;
+import com.github.javaparser.ast.expr.*;
+import com.github.javaparser.ast.stmt.*;
+import com.github.javaparser.ast.type.*;
+import com.github.javaparser.ast.visitor.VoidVisitorAdapter;
+
+import static org.hamcrest.MatcherAssert.assertThat;
+import static org.hamcrest.Matchers.greaterThanOrEqualTo;
+import static org.hamcrest.Matchers.lessThanOrEqualTo;
+import static org.hamcrest.core.Is.is;
+
+public class PositionTestVisitor extends VoidVisitorAdapter