diff --git a/.github/scripts/BinariesListUpdates.java b/.github/scripts/BinariesListUpdates.java index 5b1b209fa814..6a64515f5ee3 100644 --- a/.github/scripts/BinariesListUpdates.java +++ b/.github/scripts/BinariesListUpdates.java @@ -20,13 +20,13 @@ import java.io.IOException; import java.nio.file.Files; import java.nio.file.Path; -import java.util.List; import java.util.concurrent.Semaphore; +import java.util.concurrent.atomic.LongAdder; import java.util.stream.Stream; -import org.apache.maven.search.api.Record; import org.apache.maven.search.api.SearchRequest; import org.apache.maven.search.backend.smo.SmoSearchBackend; import org.apache.maven.search.backend.smo.SmoSearchBackendFactory; +import org.apache.maven.artifact.versioning.ComparableVersion; import static java.util.FormatProcessor.FMT; import static org.apache.maven.search.api.MAVEN.ARTIFACT_ID; @@ -45,6 +45,10 @@ */ public class BinariesListUpdates { + private static final LongAdder updates = new LongAdder(); + private static final LongAdder checks = new LongAdder(); + private static final LongAdder skips = new LongAdder(); + // java --enable-preview --source 22 --class-path "lib/*" BinariesListUpdates.java /path/to/netbeans/project public static void main(String[] args) throws IOException, InterruptedException { @@ -63,6 +67,8 @@ public static void main(String[] args) throws IOException, InterruptedException } }); } + + System.out.println(STR."checked \{checks.sum()} dependencies, found \{updates.sum()} updates, skipped \{skips.sum()}." ); } private static void checkDependencies(Path path, SmoSearchBackend backend) throws IOException, InterruptedException { @@ -91,15 +97,18 @@ private static void checkDependencies(Path path, SmoSearchBackend backend) throw latest = queryLatestVersion(backend, gid, aid, classifier.split("@")[0]); gac = String.join(":", gid, aid, classifier); } - if (!version.equals(latest)) { + if (latest != null && !version.equals(latest)) { System.out.println(FMT." %-50s\{gac} \{version} -> \{latest}"); + updates.increment(); } } catch (IOException | InterruptedException ex) { throw new RuntimeException(ex); } } else { System.out.println(" skip: '"+l+"'"); + skips.increment(); } + checks.increment(); }); } System.out.println(); @@ -119,8 +128,13 @@ private static String queryLatestVersion(SmoSearchBackend backend, String gid, S private static String queryLatestVersion(SmoSearchBackend backend, SearchRequest request) throws IOException, InterruptedException { requests.acquire(); try { - List result = backend.search(request).getPage(); - return !result.isEmpty() ? result.getFirst().getValue(VERSION) : null; + return backend.search(request).getPage().stream() + .map(r -> r.getValue(VERSION)) + .filter(v -> !v.contains("alpha") && !v.contains("beta")) + .filter(v -> !v.contains("M") && !v.contains("m") && !v.contains("B") && !v.contains("b") && !v.contains("ea")) + .limit(5) + .max((v1, v2) -> new ComparableVersion(v1).compareTo(new ComparableVersion(v2))) + .orElse(null); } finally { requests.release(); } diff --git a/.github/workflows/dependency-checks.yml b/.github/workflows/dependency-checks.yml index 9f0c4d1efffb..034aca8b53c7 100644 --- a/.github/workflows/dependency-checks.yml +++ b/.github/workflows/dependency-checks.yml @@ -39,12 +39,6 @@ jobs: timeout-minutes: 20 steps: - - name: Set up JDK - uses: actions/setup-java@v3 - with: - java-version: '22-ea' - distribution: 'zulu' - - name: Checkout ${{ github.ref }} ( ${{ github.sha }} ) uses: actions/checkout@v4 with: @@ -54,11 +48,11 @@ jobs: - name: Check Dependencies run: | - mvn -q dependency:get -Dartifact=org.apache.maven.indexer:search-backend-smo:7.1.1 mvn -q dependency:copy -Dartifact=org.apache.maven.indexer:search-backend-smo:7.1.1 -DoutputDirectory=./lib mvn -q dependency:copy -Dartifact=org.apache.maven.indexer:search-api:7.1.1 -DoutputDirectory=./lib mvn -q dependency:copy -Dartifact=com.google.code.gson:gson:2.10.1 -DoutputDirectory=./lib + mvn -q dependency:copy -Dartifact=org.apache.maven:maven-artifact:3.9.6 -DoutputDirectory=./lib echo "
" >> $GITHUB_STEP_SUMMARY
-          java --enable-preview --source 22 -cp "lib/*" .github/scripts/BinariesListUpdates.java ./ | tee -a $GITHUB_STEP_SUMMARY
+          $JAVA_HOME_21_X64/bin/java --enable-preview --source 21 -cp "lib/*" .github/scripts/BinariesListUpdates.java ./ | tee -a $GITHUB_STEP_SUMMARY
           echo "
" >> $GITHUB_STEP_SUMMARY rm -Rf lib diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 8e284401e0b9..30f49a083e67 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -109,7 +109,7 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11', '21' ] + java: [ '17', '21', '22-ea' ] fail-fast: false steps: @@ -127,7 +127,7 @@ jobs: show-progress: false - name: Caching dependencies - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ~/.hgexternalcache key: ${{ runner.os }}-${{ hashFiles('*/external/binaries-list', '*/*/external/binaries-list') }} @@ -137,11 +137,11 @@ jobs: run: ant $OPTS -quiet -Dcluster.config=$CLUSTER_CONFIG build-nozip - name: Prepare Artifact - if: ${{ matrix.java == '11' }} + if: ${{ matrix.java == '17' }} run: tar -I 'zstd -9 -T0' -cf /tmp/build.tar.zst --exclude ".git" . - name: Upload Workspace - if: ${{ (matrix.java == '11') && success() }} + if: ${{ (matrix.java == '17') && success() }} uses: actions/upload-artifact@v4 with: name: build @@ -151,11 +151,11 @@ jobs: if-no-files-found: error - name: Create Dev Build - if: ${{ matrix.java == '11' && contains(github.event.pull_request.labels.*.name, 'ci:dev-build') && success() }} + if: ${{ matrix.java == '17' && contains(github.event.pull_request.labels.*.name, 'ci:dev-build') && success() }} run: ant $OPTS -quiet -Dcluster.config=$CLUSTER_CONFIG zip-cluster-config - name: Upload Dev Build - if: ${{ matrix.java == '11' && contains(github.event.pull_request.labels.*.name, 'ci:dev-build') && success() }} + if: ${{ matrix.java == '17' && contains(github.event.pull_request.labels.*.name, 'ci:dev-build') && success() }} uses: actions/upload-artifact@v4 with: name: dev-build @@ -178,13 +178,13 @@ jobs: submodules: false show-progress: false - - name: Set up JDK 11 + - name: Set up JDK 17 uses: actions/setup-java@v4 with: distribution: ${{ env.default_java_distribution }} - java-version: 11 + java-version: 17 - name: Caching dependencies - uses: actions/cache/restore@v3 + uses: actions/cache/restore@v4 with: path: ~/.hgexternalcache key: ${{ runner.os }}-${{ hashFiles('*/external/binaries-list', '*/*/external/binaries-list') }} @@ -201,7 +201,7 @@ jobs: run: ant $OPTS commit-validation -Dnbjavac.class.path=java/libs.javacapi/external/*.jar # secondary jobs - linux-commit-validation: + commit-validation: name: CV on ${{ matrix.os }}/JDK ${{ matrix.java }} needs: base-build runs-on: ${{ matrix.os }} @@ -209,7 +209,7 @@ jobs: strategy: matrix: os: [ ubuntu-latest, macos-latest, windows-latest ] - java: [ 11 ] + java: [ 17 ] include: - os: ubuntu-latest java: 21 @@ -246,14 +246,21 @@ jobs: if: contains(matrix.os, 'macos') && success() run: ant $OPTS -f platform/masterfs.macosx test + - name: Commit Validation tests + run: .github/retry.sh ant $OPTS -Dcluster.config=$CLUSTER_CONFIG commit-validation + + - name: Set up JDK 11 for core.network + uses: actions/setup-java@v4 + if: matrix.java == 17 && success() + with: + java-version: 11 + distribution: ${{ env.default_java_distribution }} + # fails on 17+ - name: platform/core.network - if: matrix.java == 11 && success() + if: matrix.java == 17 && success() run: ant $OPTS -f platform/core.network test - - name: Commit Validation tests - run: ant $OPTS -Dcluster.config=$CLUSTER_CONFIG commit-validation - - name: Create Test Summary uses: test-summary/action@v2 if: failure() @@ -273,7 +280,7 @@ jobs: ANT_OPTS: -Dmetabuild.jsonurl=https://raw.githubusercontent.com/apache/netbeans-jenkins-lib/master/meta/netbeansrelease.json strategy: matrix: - java: [ '11' ] + java: [ '17' ] steps: - name: Set up JDK ${{ matrix.java }} @@ -338,7 +345,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -371,7 +379,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -405,8 +414,9 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] config: [ 'platform', 'release' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -424,7 +434,7 @@ jobs: run: tar --zstd -xf build.tar.zst - name: Restoring Cache - uses: actions/cache/restore@v3 + uses: actions/cache/restore@v4 with: path: ~/.hgexternalcache key: ${{ runner.os }}-${{ hashFiles('*/external/binaries-list', '*/*/external/binaries-list') }} @@ -446,7 +456,7 @@ jobs: # extra round for VSCodeExt which is built with 'release' config - name: Set up node if: ${{ (matrix.config == 'release') && success() }} - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: 18 @@ -464,7 +474,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -661,7 +672,7 @@ jobs: run: ant $OPTS -f ide/libs.freemarker test - name: ide/libs.git - run: ant $OPTS -f ide/libs.git test + run: .github/retry.sh ant $OPTS -f ide/libs.git test - name: ide/libs.graalsdk run: ant $OPTS -f ide/libs.graalsdk test @@ -676,7 +687,7 @@ jobs: run: ant $OPTS -f ide/lsp.client test - name: ide/notifications - run: ant $OPTS -f ide/notifications test + run: .github/retry.sh ant $OPTS -f ide/notifications test - name: ide/o.openidex.util run: ant $OPTS -f ide/o.openidex.util test @@ -812,7 +823,7 @@ jobs: build-tools: - name: Build Tools on Linux/JDK ${{ matrix.java }} (some on 17) + name: Build-Tools on Linux/JDK ${{ matrix.java }} # label triggers: Ant, Gradle, Maven, MX if: ${{ contains(github.event.pull_request.labels.*.name, 'Ant') || contains(github.event.pull_request.labels.*.name, 'Gradle') || contains(github.event.pull_request.labels.*.name, 'Maven') || contains(github.event.pull_request.labels.*.name, 'MX') || contains(github.event.pull_request.labels.*.name, 'ci:all-tests') || github.event_name != 'pull_request' }} needs: base-build @@ -820,7 +831,9 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11', '17', '21' ] + java: [ '17', '21', '22-ea' ] + exclude: + - java: ${{ github.event_name == 'pull_request' && 'nothing' || '21' }} fail-fast: false steps: @@ -907,21 +920,24 @@ jobs: java-version: 17 distribution: ${{ env.default_java_distribution }} - # TODO fix JDK 21 incompatibilites - name: java/java.mx.project - continue-on-error: ${{ github.event_name != 'pull_request' }} + if: ${{ matrix.java == '17' }} run: .github/retry.sh ant $OPTS -f java/java.mx.project test - name: java/gradle.java + if: ${{ matrix.java == '17' }} run: .github/retry.sh ant $OPTS -f java/gradle.java test - name: extide/gradle + if: ${{ matrix.java == '17' }} run: ant $OPTS -f extide/gradle test - name: java/gradle.dependencies + if: ${{ matrix.java == '17' }} run: ant $OPTS -f java/gradle.dependencies test - name: extide/o.apache.tools.ant.module + if: ${{ matrix.java == '17' }} run: ant $OPTS -f extide/o.apache.tools.ant.module test - name: Create Test Summary @@ -940,7 +956,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -986,9 +1003,6 @@ jobs: - name: platform/api.search run: ant $OPTS -f platform/api.search test - - name: platform/api.templates - run: ant $OPTS -f platform/api.templates test - - name: platform/api.visual run: ant $OPTS -f platform/api.visual test @@ -1121,15 +1135,10 @@ jobs: timeout-minutes: 90 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - - name: Set up JDK 11 - uses: actions/setup-java@v4 - with: - java-version: 11 - distribution: ${{ env.default_java_distribution }} - - name: Set up JDK ${{ matrix.java }} uses: actions/setup-java@v4 with: @@ -1233,9 +1242,6 @@ jobs: - name: platform/spi.quicksearch run: ant $OPTS -f platform/spi.quicksearch test - - name: platform/templates - run: ant $OPTS -f platform/templates test - - name: platform/templatesui run: ant $OPTS -f platform/templatesui test @@ -1245,6 +1251,22 @@ jobs: - name: platform/o.n.bootstrap run: ant $OPTS -f platform/o.n.bootstrap test + - name: Set up JDK 11 for platform/templates + uses: actions/setup-java@v4 + with: + java-version: 11 + distribution: ${{ env.default_java_distribution }} + + # TODO tests rely on javax.script.ScriptEngine / js which locks this to JDK 11 + - name: platform/templates + run: ant $OPTS -f platform/templates test + + - name: platform/api.templates + run: ant $OPTS -f platform/api.templates test + + - name: platform/openide.loaders TemplatesMimeTypeTest + run: ant $OPTS -f platform/openide.loaders test -Dtest.config.default.includes=**/TemplatesMimeTypeTest.class -Dtest.config.default.excludes="" + - name: Create Test Summary uses: test-summary/action@v2 if: failure() @@ -1261,7 +1283,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -1327,7 +1350,8 @@ jobs: timeout-minutes: 100 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -1516,6 +1540,7 @@ jobs: strategy: matrix: java: [ '8' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -1568,8 +1593,10 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17', '21' ] config: [ 'batch1', 'batch2' ] + exclude: + - java: ${{ github.event_name == 'pull_request' && 'nothing' || '21' }} fail-fast: false steps: @@ -1619,7 +1646,9 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11', '21' ] + java: [ '17', '21', '22-ea' ] + exclude: + - java: ${{ github.event_name == 'pull_request' && 'nothing' || '21' }} fail-fast: false steps: @@ -1678,6 +1707,7 @@ jobs: strategy: matrix: java: [ '11' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -1702,6 +1732,7 @@ jobs: - name: profiler run: ant $OPTS -f profiler/profiler test-unit + # TODO OQL requires js script engine which locks this to JDK 11 - name: profiler.oql run: ant $OPTS -f profiler/profiler.oql test @@ -1719,7 +1750,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -1741,9 +1773,6 @@ jobs: - name: Extract run: tar --zstd -xf build.tar.zst - - name: webcommon/api.knockout - run: ant $OPTS -f webcommon/api.knockout test - # - name: webcommon/cordova # run: ant $OPTS -f webcommon/cordova test @@ -1841,6 +1870,16 @@ jobs: - name: webcommon/web.inspect run: ant $OPTS -f webcommon/web.inspect test + - name: Set up JDK 11 for webcommon/api.knockout + uses: actions/setup-java@v4 + with: + java-version: 11 + distribution: ${{ env.default_java_distribution }} + + # TODO: requires js script engine + - name: webcommon/api.knockout + run: ant $OPTS -f webcommon/api.knockout test + - name: Create Test Summary uses: test-summary/action@v2 if: failure() @@ -1855,7 +1894,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -1900,6 +1940,7 @@ jobs: strategy: matrix: java: [ '8' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -1955,7 +1996,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -1994,13 +2036,14 @@ jobs: enterprise-test: - name: Enterprise on Linux/JDK ${{ matrix.java }} (some on 8 and 17) + name: Enterprise on Linux/JDK ${{ matrix.java }} (some on 8) needs: base-build runs-on: ubuntu-latest timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -2022,6 +2065,9 @@ jobs: - name: Extract run: tar --zstd -xf build.tar.zst + - name: micronaut + run: .github/retry.sh ant $OPTS -f enterprise/micronaut test + - name: api.web.webmodule run: ant $OPTS -f enterprise/api.web.webmodule test @@ -2232,15 +2278,6 @@ jobs: - name: j2ee.dd.webservice run: ant $OPTS -f enterprise/j2ee.dd.webservice test - - name: Set up JDK 17 for tests that are not compatible with JDK 11 - uses: actions/setup-java@v4 - with: - java-version: 17 - distribution: ${{ env.default_java_distribution }} - - - name: micronaut - run: .github/retry.sh ant $OPTS -f enterprise/micronaut test - - name: Create Test Summary uses: test-summary/action@v2 if: failure() @@ -2255,7 +2292,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -2320,7 +2358,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false services: mysql: @@ -2379,7 +2418,7 @@ jobs: DISPLAY: ":99.0" strategy: matrix: - java: [ '11' ] + java: [ '17' ] os: [ 'windows-latest', 'ubuntu-latest' ] fail-fast: false steps: @@ -2521,7 +2560,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -2626,7 +2666,8 @@ jobs: timeout-minutes: 60 strategy: matrix: - java: [ '11' ] + java: [ '17' ] + fail-fast: false steps: - name: Set up JDK ${{ matrix.java }} @@ -2636,7 +2677,7 @@ jobs: distribution: ${{ env.default_java_distribution }} - name: Set up node - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: 18 @@ -2669,7 +2710,7 @@ jobs: name: Cleanup Workflow Artifacts needs: - base-build - - linux-commit-validation + - commit-validation - paperwork - build-system-test - build-nbms diff --git a/.github/workflows/native-binary-build-lib.profiler.yml b/.github/workflows/native-binary-build-lib.profiler.yml index 3b7ba9223233..e17a41ace275 100644 --- a/.github/workflows/native-binary-build-lib.profiler.yml +++ b/.github/workflows/native-binary-build-lib.profiler.yml @@ -93,7 +93,7 @@ jobs: show-progress: false - name: Caching dependencies - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ~/.hgexternalcache key: profiler-${{ runner.os }}-${{ hashFiles('*/external/binaries-list', '*/*/external/binaries-list') }} diff --git a/README.md b/README.md index 6c4ac6d2a18c..ec0e20700a53 100644 --- a/README.md +++ b/README.md @@ -37,8 +37,8 @@ Apache NetBeans is an open source development environment, tooling platform, and ### Requirements * Git - * Ant 1.9.9 or above - * JDK 11 or above (to build and run NetBeans) + * Ant + * JDK 17 or above (to build and run NetBeans) #### Notes: diff --git a/enterprise/micronaut/src/org/netbeans/modules/micronaut/symbol/MicronautSymbolSearcher.java b/enterprise/micronaut/src/org/netbeans/modules/micronaut/symbol/MicronautSymbolSearcher.java index 9a2fcfb18baf..cab5e57222d5 100644 --- a/enterprise/micronaut/src/org/netbeans/modules/micronaut/symbol/MicronautSymbolSearcher.java +++ b/enterprise/micronaut/src/org/netbeans/modules/micronaut/symbol/MicronautSymbolSearcher.java @@ -71,6 +71,7 @@ public Set getSymbols(Project project, String textForQuery try { FileObject cacheRoot = getCacheRoot(sg.getRootFolder().toURL()); if (cacheRoot != null) { + cacheRoot.refresh(); Enumeration children = cacheRoot.getChildren(true); while (children.hasMoreElements()) { FileObject child = children.nextElement(); diff --git a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/SpringConfigPanelVisual.java b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/SpringConfigPanelVisual.java index 253a1bdcdb05..281063dbf315 100644 --- a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/SpringConfigPanelVisual.java +++ b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/SpringConfigPanelVisual.java @@ -288,17 +288,14 @@ public void run() { springLibs.add(new SpringLibrary(library)); } } - SwingUtilities.invokeLater(new Runnable() { - @Override - public void run() { - cbSpringVersion.setModel(new DefaultComboBoxModel(items.toArray(new String[items.size()]))); - int selectedIndex = cbSpringVersion.getSelectedIndex(); - if (selectedIndex < springLibs.size()) { - springLibrary = springLibs.get(selectedIndex); - libsInitialized = true; - repaint(); - fireChange(); - } + SwingUtilities.invokeLater(() -> { + cbSpringVersion.setModel(new DefaultComboBoxModel(items.toArray(new String[0]))); + int selectedIndex = cbSpringVersion.getSelectedIndex(); + if (selectedIndex < springLibs.size()) { + springLibrary = springLibs.get(selectedIndex); + libsInitialized = true; + repaint(); + fireChange(); } }); LOG.log(Level.FINEST, "Time spent in {0} initLibraries = {1} ms", diff --git a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/SpringWebModuleExtender.java b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/SpringWebModuleExtender.java index c6c9fccc79bd..0b19fe3ea2b5 100644 --- a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/SpringWebModuleExtender.java +++ b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/SpringWebModuleExtender.java @@ -126,6 +126,7 @@ public boolean getIncludeJstl() { return includeJstl; } + @Override public synchronized SpringConfigPanelVisual getComponent() { if (component == null) { component = new SpringConfigPanelVisual(this); @@ -134,6 +135,7 @@ public synchronized SpringConfigPanelVisual getComponent() { return component; } + @Override public boolean isValid() { if (dispatcherName == null || dispatcherName.trim().length() == 0){ controller.setErrorMessage(NbBundle.getMessage(SpringConfigPanelVisual.class, "MSG_DispatcherNameIsEmpty")); // NOI18N @@ -166,18 +168,22 @@ public boolean isValid() { return true; } + @Override public HelpCtx getHelp() { return new HelpCtx(SpringWebModuleExtender.class); } + @Override public final void addChangeListener(ChangeListener l) { changeSupport.addChangeListener(l); } + @Override public final void removeChangeListener(ChangeListener l) { changeSupport.removeChangeListener(l); } + @Override public void stateChanged(ChangeEvent e) { dispatcherName = getComponent().getDispatcherName(); dispatcherMapping = getComponent().getDispatcherMapping(); @@ -238,7 +244,7 @@ private class CreateSpringConfig implements FileSystem.AtomicAction { public static final String DISPATCHER_SERVLET = "org.springframework.web.servlet.DispatcherServlet"; // NOI18N public static final String ENCODING = "UTF-8"; // NOI18N - private final Set filesToOpen = new LinkedHashSet(); + private final Set filesToOpen = new LinkedHashSet<>(); private final WebModule webModule; public CreateSpringConfig(WebModule webModule) { @@ -248,6 +254,7 @@ public CreateSpringConfig(WebModule webModule) { @NbBundle.Messages({ "CreateSpringConfig.msg.invalid.dd=Deployment descriptor cointains errors, Spring framework has to be manually configured there!" }) + @Override public void run() throws IOException { // MODIFY WEB.XML FileObject dd = webModule.getDeploymentDescriptor(); @@ -282,7 +289,7 @@ public void run() throws IOException { } // ADD JSTL LIBRARY IF ENABLED AND SPRING LIBRARY - List libraries = new ArrayList(3); + List libraries = new ArrayList<>(3); Library springLibrary = component.getSpringLibrary(); String version = component.getSpringLibraryVersion(); Library webMVCLibrary = null; @@ -375,18 +382,16 @@ public void run() throws IOException { if (scope != null) { final ConfigFileManager manager = scope.getConfigFileManager(); try { - manager.mutex().writeAccess(new ExceptionAction() { - public Void run() throws IOException { - List files = manager.getConfigFiles(); - files.addAll(newConfigFiles); - List groups = manager.getConfigFileGroups(); - String groupName = NbBundle.getMessage(SpringWebModuleExtender.class, "LBL_DefaultGroup"); - ConfigFileGroup newGroup = ConfigFileGroup.create(groupName, newConfigFiles); - groups.add(newGroup); - manager.putConfigFilesAndGroups(files, groups); - manager.save(); - return null; - } + manager.mutex().writeAccess((ExceptionAction) () -> { + List files = manager.getConfigFiles(); + files.addAll(newConfigFiles); + List groups = manager.getConfigFileGroups(); + String groupName = NbBundle.getMessage(SpringWebModuleExtender.class, "LBL_DefaultGroup"); + ConfigFileGroup newGroup = ConfigFileGroup.create(groupName, newConfigFiles); + groups.add(newGroup); + manager.putConfigFilesAndGroups(files, groups); + manager.save(); + return null; }); } catch (MutexException e) { throw (IOException)e.getException(); @@ -428,7 +433,7 @@ protected boolean addLibrariesToWebModule(List libraries, WebModule web if (groups.length == 0) { return false; } - addLibraryResult = ProjectClassPathModifier.addLibraries(libraries.toArray(new Library[libraries.size()]), groups[0].getRootFolder(), ClassPath.COMPILE); + addLibraryResult = ProjectClassPathModifier.addLibraries(libraries.toArray(new Library[0]), groups[0].getRootFolder(), ClassPath.COMPILE); } catch (IOException e) { LOGGER.log(Level.WARNING, "Libraries required for the Spring MVC project not added", e); // NOI18N } catch (UnsupportedOperationException uoe) { diff --git a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/Bundle.properties b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/Bundle.properties index 94344ac754c7..a210bc001211 100644 --- a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/Bundle.properties +++ b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/Bundle.properties @@ -23,6 +23,4 @@ OpenIDE-Module-Long-Description=Provides support for extending a web project wit Templates/SpringFramework/AbstractController.java=Abstract Controller Templates/SpringFramework/SimpleFormController.java=Simple Form Controller Templates/SpringFramework/index.jsp=View page -spring-webmvc5=Spring Web MVC 5.2.9 -spring-webmvc4=Spring Web MVC 4.3.29 -spring-webmvc3=Spring Web MVC 3.2.18 +spring-webmvc5=Spring Web MVC 5.3.31 diff --git a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/layer.xml b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/layer.xml index 92c9b08e6433..56b2bee5b582 100644 --- a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/layer.xml +++ b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/layer.xml @@ -35,12 +35,6 @@ - - - - - - diff --git a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/spring-webmvc-3.0.xml b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/spring-webmvc-3.0.xml deleted file mode 100644 index 4f1319881ef3..000000000000 --- a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/spring-webmvc-3.0.xml +++ /dev/null @@ -1,44 +0,0 @@ - - - - spring-webmvc3.0 - j2se - org.netbeans.modules.spring.webmvc.resources.Bundle - - classpath - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-webmvc-3.2.18.RELEASE.jar!/ - - - src - - - javadoc - - - - - maven-dependencies - org.springframework:spring-webmvc:3.2.18.RELEASE:jar - - - - diff --git a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/spring-webmvc-4.0.xml b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/spring-webmvc-4.0.xml deleted file mode 100644 index 068e9526f91e..000000000000 --- a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/spring-webmvc-4.0.xml +++ /dev/null @@ -1,43 +0,0 @@ - - - - spring-webmvc4.0 - j2se - org.netbeans.modules.spring.webmvc.resources.Bundle - - classpath - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-webmvc-4.3.29.RELEASE.jar!/ - - - src - - - javadoc - - - - - maven-dependencies - org.springframework:spring-webmvc:4.3.29.RELEASE:jar - - - diff --git a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/spring-webmvc-5.0.xml b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/spring-webmvc-5.0.xml index eebf64b234e0..aa51dbca0081 100644 --- a/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/spring-webmvc-5.0.xml +++ b/enterprise/spring.webmvc/src/org/netbeans/modules/spring/webmvc/resources/spring-webmvc-5.0.xml @@ -25,7 +25,7 @@ org.netbeans.modules.spring.webmvc.resources.Bundle classpath - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-webmvc-5.2.9.RELEASE.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-webmvc-5.3.31.jar!/ src @@ -36,7 +36,7 @@ maven-dependencies - org.springframework:spring-webmvc:5.2.9.RELEASE:jar + org.springframework:spring-webmvc:5.3.31:jar diff --git a/extide/gradle/netbeans-gradle-tooling/build.gradle b/extide/gradle/netbeans-gradle-tooling/build.gradle index 6ed7b10e7357..b6a0cade9db9 100644 --- a/extide/gradle/netbeans-gradle-tooling/build.gradle +++ b/extide/gradle/netbeans-gradle-tooling/build.gradle @@ -23,6 +23,7 @@ mainClassName = 'org.netbeans.modules.gradle.DebugTooling' sourceCompatibility = '1.8' [compileJava, compileTestJava]*.options*.encoding = 'UTF-8' +[compileJava, compileTestJava]*.options*.debug = true repositories { mavenCentral() diff --git a/extide/gradle/netbeans-gradle-tooling/build.xml b/extide/gradle/netbeans-gradle-tooling/build.xml index c9a38495b174..7c994be3b7f3 100644 --- a/extide/gradle/netbeans-gradle-tooling/build.xml +++ b/extide/gradle/netbeans-gradle-tooling/build.xml @@ -42,7 +42,7 @@ - + diff --git a/extide/gradle/src/org/netbeans/modules/gradle/api/execute/GradleDistributionManager.java b/extide/gradle/src/org/netbeans/modules/gradle/api/execute/GradleDistributionManager.java index c90316077493..8075eb7a5a7d 100644 --- a/extide/gradle/src/org/netbeans/modules/gradle/api/execute/GradleDistributionManager.java +++ b/extide/gradle/src/org/netbeans/modules/gradle/api/execute/GradleDistributionManager.java @@ -86,7 +86,7 @@ public final class GradleDistributionManager { private static final Pattern DIST_VERSION_PATTERN = Pattern.compile(".*(gradle-(\\d+\\.\\d+.*))-(bin|all)\\.zip"); //NOI18N private static final Set VERSION_BLACKLIST = new HashSet<>(Arrays.asList("2.3", "2.13")); //NOI18N private static final Map CACHE = new WeakHashMap<>(); - private static final GradleVersion MINIMUM_SUPPORTED_VERSION = GradleVersion.version("2.0"); //NOI18N + private static final GradleVersion MINIMUM_SUPPORTED_VERSION = GradleVersion.version("3.0"); //NOI18N private static final GradleVersion[] JDK_COMPAT = new GradleVersion[]{ GradleVersion.version("4.2.1"), // JDK-9 GradleVersion.version("4.7"), // JDK-10 @@ -103,6 +103,8 @@ public final class GradleDistributionManager { GradleVersion.version("8.5"), // JDK-21 }; + private static final GradleVersion LAST_KNOWN_GRADLE = GradleVersion.version("8.6"); //NOI18N + final File gradleUserHome; private GradleDistributionManager(File gradleUserHome) { @@ -496,10 +498,9 @@ public String getVersion() { */ public boolean isCompatibleWithJava(int jdkMajorVersion) { - GradleVersion lastKnown = JDK_COMPAT[JDK_COMPAT.length - 1]; // Optimistic bias, if the GradleVersion is newer than the last NB // knows, we say it's compatible with any JDK - return lastKnown.compareTo(version.getBaseVersion()) < 0 + return LAST_KNOWN_GRADLE.compareTo(version.getBaseVersion()) < 0 || jdkMajorVersion <= lastSupportedJava(); } diff --git a/extide/gradle/src/org/netbeans/modules/gradle/spi/newproject/TemplateOperation.java b/extide/gradle/src/org/netbeans/modules/gradle/spi/newproject/TemplateOperation.java index 733ea533eb5e..9e2b98e1d81e 100644 --- a/extide/gradle/src/org/netbeans/modules/gradle/spi/newproject/TemplateOperation.java +++ b/extide/gradle/src/org/netbeans/modules/gradle/spi/newproject/TemplateOperation.java @@ -57,6 +57,7 @@ import org.netbeans.modules.gradle.ProjectTrust; import org.netbeans.modules.gradle.api.GradleProjects; import org.netbeans.modules.gradle.api.NbGradleProject.Quality; +import org.netbeans.modules.gradle.spi.GradleSettings; import org.openide.loaders.DataFolder; import org.openide.loaders.DataObject; import org.openide.util.Exceptions; @@ -314,7 +315,11 @@ public Set execute() { args.add(projectName); } - pconn.newBuild().withArguments("--offline").forTasks(args.toArray(new String[0])).run(); //NOI18N + if (GradleSettings.getDefault().isOffline()) { + pconn.newBuild().withArguments("--offline").forTasks(args.toArray(new String[0])).run(); //NOI18N + } else { + pconn.newBuild().forTasks(args.toArray(new String[0])).run(); + } } catch (GradleConnectionException | IllegalStateException ex) { Exceptions.printStackTrace(ex); } @@ -488,7 +493,11 @@ public Set execute() { args.add("--gradle-version"); //NOI18N args.add(version); } - pconn.newBuild().withArguments("--offline").forTasks(args.toArray(new String[0])).run(); //NOI18N + if (GradleSettings.getDefault().isOffline()) { + pconn.newBuild().withArguments("--offline").forTasks(args.toArray(new String[0])).run(); //NOI18N + } else { + pconn.newBuild().forTasks(args.toArray(new String[0])).run(); + } } catch (GradleConnectionException | IllegalStateException ex) { // Well for some reason we were not able to load Gradle. // Ignoring that for now diff --git a/extide/libs.gradle/external/binaries-list b/extide/libs.gradle/external/binaries-list index a66dfd10f60f..cbb0dffff9f6 100644 --- a/extide/libs.gradle/external/binaries-list +++ b/extide/libs.gradle/external/binaries-list @@ -15,4 +15,4 @@ # specific language governing permissions and limitations # under the License. -ADAA3E825C608D2428888126CF4D1DDD5B5203D6 https://repo.gradle.org/artifactory/libs-releases/org/gradle/gradle-tooling-api/8.4/gradle-tooling-api-8.4.jar gradle-tooling-api-8.4.jar +1B1A733327BD5EFE9813DD0590C21865C0EDC954 https://repo.gradle.org/artifactory/libs-releases/org/gradle/gradle-tooling-api/8.6/gradle-tooling-api-8.6.jar gradle-tooling-api-8.6.jar diff --git a/extide/libs.gradle/external/gradle-tooling-api-8.4-license.txt b/extide/libs.gradle/external/gradle-tooling-api-8.6-license.txt similarity index 99% rename from extide/libs.gradle/external/gradle-tooling-api-8.4-license.txt rename to extide/libs.gradle/external/gradle-tooling-api-8.6-license.txt index 297bca2f3d3d..c854552b2608 100644 --- a/extide/libs.gradle/external/gradle-tooling-api-8.4-license.txt +++ b/extide/libs.gradle/external/gradle-tooling-api-8.6-license.txt @@ -1,7 +1,7 @@ Name: Gradle Tooling API Description: Gradle Tooling API -Version: 8.4 -Files: gradle-tooling-api-8.4.jar +Version: 8.6 +Files: gradle-tooling-api-8.6.jar License: Apache-2.0 Origin: Gradle Inc. URL: https://gradle.org/ diff --git a/extide/libs.gradle/external/gradle-tooling-api-8.4-notice.txt b/extide/libs.gradle/external/gradle-tooling-api-8.6-notice.txt similarity index 73% rename from extide/libs.gradle/external/gradle-tooling-api-8.4-notice.txt rename to extide/libs.gradle/external/gradle-tooling-api-8.6-notice.txt index cb6a8aa6879a..ceb605c681af 100644 --- a/extide/libs.gradle/external/gradle-tooling-api-8.4-notice.txt +++ b/extide/libs.gradle/external/gradle-tooling-api-8.6-notice.txt @@ -1,8 +1,8 @@ Gradle Inc.'s Gradle Tooling API -Copyright 2007-2023 Gradle Inc. +Copyright 2007-2024 Gradle Inc. This product includes software developed at Gradle Inc. (https://gradle.org/). This product includes/uses SLF4J (https://www.slf4j.org/) -developed by QOS.ch, 2004-2023 +developed by QOS.ch, 2004-2024 diff --git a/extide/libs.gradle/nbproject/project.properties b/extide/libs.gradle/nbproject/project.properties index 57bf8681b692..feda41f3b074 100644 --- a/extide/libs.gradle/nbproject/project.properties +++ b/extide/libs.gradle/nbproject/project.properties @@ -22,4 +22,4 @@ javac.compilerargs=-Xlint -Xlint:-serial # For more information, please see http://wiki.netbeans.org/SignatureTest sigtest.gen.fail.on.error=false -release.external/gradle-tooling-api-8.4.jar=modules/gradle/gradle-tooling-api.jar +release.external/gradle-tooling-api-8.6.jar=modules/gradle/gradle-tooling-api.jar diff --git a/extide/libs.gradle/nbproject/project.xml b/extide/libs.gradle/nbproject/project.xml index 5539f821a237..6b668eb39f8c 100644 --- a/extide/libs.gradle/nbproject/project.xml +++ b/extide/libs.gradle/nbproject/project.xml @@ -39,7 +39,7 @@ gradle/gradle-tooling-api.jar - external/gradle-tooling-api-8.4.jar + external/gradle-tooling-api-8.6.jar diff --git a/harness/nbjunit/src/org/netbeans/junit/MethodOrder.java b/harness/nbjunit/src/org/netbeans/junit/MethodOrder.java index ae0c9bd6914b..858e1b4b19aa 100644 --- a/harness/nbjunit/src/org/netbeans/junit/MethodOrder.java +++ b/harness/nbjunit/src/org/netbeans/junit/MethodOrder.java @@ -43,6 +43,9 @@ static void initialize() { String orderS = findOrder(); if (!"natural".equals(orderS)) { // NOI18N try { + // TODO: ClassLoader fields can not be accessed via reflection on JDK 12+ + // see jdk.internal.reflect.Reflection#fieldFilterMap + // this won't work Field classesF = ClassLoader.class.getDeclaredField("classes"); // NOI18N classesF.setAccessible(true); @SuppressWarnings("unchecked") @@ -53,6 +56,7 @@ static void initialize() { } } } catch (Exception x) { + System.err.println("WARNING: test method ordering disabled"); x.printStackTrace(); } } diff --git a/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderAZTest.java b/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderAZTest.java index 569a8b19c12a..cf2ce07dd182 100644 --- a/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderAZTest.java +++ b/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderAZTest.java @@ -22,6 +22,7 @@ import junit.framework.TestResult; import junit.framework.TestSuite; import org.junit.Assert; +import org.junit.Ignore; import org.junit.Test; /** Check the a-z behaviour. @@ -33,6 +34,8 @@ public class OrderAZTest { System.setProperty("NbTestCase.order", "a-z"); } + // method order isn't working, see comment in org.netbeans.junit.MethodOrder + @Ignore @Test public void shuffleTest() throws ClassNotFoundException { Class load = Class.forName("org.netbeans.junit.OrderHid"); TestSuite ts = new TestSuite(load); diff --git a/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderTest.java b/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderTest.java index 97d5f0b1dfe8..43d4ee7f704d 100644 --- a/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderTest.java +++ b/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderTest.java @@ -22,6 +22,7 @@ import junit.framework.TestResult; import junit.framework.TestSuite; import org.junit.Assert; +import org.junit.Ignore; import org.junit.Test; /** Check the shuffle behaviour. @@ -32,7 +33,9 @@ public class OrderTest { static { System.setProperty("NbTestCase.order", "1314372086210"); } - + + // method order isn't working, see comment in org.netbeans.junit.MethodOrder + @Ignore @Test public void shuffleTest() throws ClassNotFoundException { Class load = Class.forName("org.netbeans.junit.OrderHid"); TestSuite ts = new TestSuite(load); diff --git a/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderZATest.java b/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderZATest.java index a11bde5204e6..ec88e288ad85 100644 --- a/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderZATest.java +++ b/harness/nbjunit/test/unit/src/org/netbeans/junit/OrderZATest.java @@ -22,6 +22,7 @@ import junit.framework.TestResult; import junit.framework.TestSuite; import org.junit.Assert; +import org.junit.Ignore; import org.junit.Test; /** Check the z-a behaviour. @@ -33,6 +34,8 @@ public class OrderZATest { System.setProperty("NbTestCase.order", "z-a"); } + // method order isn't working, see comment in org.netbeans.junit.MethodOrder + @Ignore @Test public void shuffleTest() throws ClassNotFoundException { Class load = Class.forName("org.netbeans.junit.OrderHid"); TestSuite ts = new TestSuite(load); diff --git a/ide/diff/src/org/netbeans/modules/diff/builtin/visualizer/editable/DiffContentPanel.java b/ide/diff/src/org/netbeans/modules/diff/builtin/visualizer/editable/DiffContentPanel.java index 6bb489e26a78..d693f77f4d68 100644 --- a/ide/diff/src/org/netbeans/modules/diff/builtin/visualizer/editable/DiffContentPanel.java +++ b/ide/diff/src/org/netbeans/modules/diff/builtin/visualizer/editable/DiffContentPanel.java @@ -67,6 +67,8 @@ public DiffContentPanel(EditableDiffView master, boolean isFirst) { add(scrollPane); linesActions = new LineNumbersActionsBar(this, master.isActionsEnabled()); + linesActions.addMouseWheelListener(e -> editorPane.dispatchEvent(e)); // delegate mouse scroll events to editor + actionsScrollPane = new JScrollPane(linesActions); actionsScrollPane.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_NEVER); actionsScrollPane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_NEVER); @@ -149,6 +151,7 @@ public void setCurrentDiff(Difference[] currentDiff) { // revalidate(); } + @Override public Dimension getPreferredSize() { Dimension d = super.getPreferredSize(); Container parent = getParent(); @@ -164,6 +167,7 @@ public DecoratedEditorPane getEditorPane() { return editorPane; } + @Override public AccessibleContext getAccessibleContext() { return editorPane.getAccessibleContext(); } @@ -178,18 +182,21 @@ HighlightsContainer getHighlightsContainer() { return this; } + @Override public HighlightsSequence getHighlights(int start, int end) { return new DiffHighlightsSequence(start, end); } - private final List listeners = new ArrayList(1); + private final List listeners = new ArrayList<>(1); + @Override public void addHighlightsChangeListener(HighlightsChangeListener listener) { synchronized(listeners) { listeners.add(listener); } } + @Override public void removeHighlightsChangeListener(HighlightsChangeListener listener) { synchronized(listeners) { listeners.remove(listener); @@ -229,6 +236,7 @@ public void setCustomEditor(JComponent c) { c.setFocusTraversalPolicyProvider(true); } + @Override public Lookup getLookup() { return Lookups.singleton(getActionMap()); } @@ -261,30 +269,34 @@ public DiffHighlightsSequence(int start, int end) { } private void lookupHilites() { - List list = new ArrayList(); + List list = new ArrayList<>(); DiffViewManager.HighLight[] allHilites = isFirst ? master.getManager().getFirstHighlights() : master.getManager().getSecondHighlights(); for (DiffViewManager.HighLight hilite : allHilites) { if (hilite.getEndOffset() < startOffset) continue; if (hilite.getStartOffset() > endOffset) break; list.add(hilite); } - hilites = list.toArray(new DiffViewManager.HighLight[list.size()]); + hilites = list.toArray(new DiffViewManager.HighLight[0]); } + @Override public boolean moveNext() { if (currentHiliteIndex >= hilites.length - 1) return false; currentHiliteIndex++; return true; } + @Override public int getStartOffset() { return Math.max(hilites[currentHiliteIndex].getStartOffset(), this.startOffset); } + @Override public int getEndOffset() { return Math.min(hilites[currentHiliteIndex].getEndOffset(), this.endOffset); } + @Override public AttributeSet getAttributes() { return hilites[currentHiliteIndex].getAttrs(); } diff --git a/java/gradle.java/src/org/netbeans/modules/gradle/java/newproject/SimpleApplicationProjectWizard.java b/java/gradle.java/src/org/netbeans/modules/gradle/java/newproject/SimpleApplicationProjectWizard.java index 33235fc27cd1..de1889f6504d 100644 --- a/java/gradle.java/src/org/netbeans/modules/gradle/java/newproject/SimpleApplicationProjectWizard.java +++ b/java/gradle.java/src/org/netbeans/modules/gradle/java/newproject/SimpleApplicationProjectWizard.java @@ -66,8 +66,6 @@ static void collectOperationsForType(Map params, TemplateOperati final File root = new File(loc, name); ops.createGradleInit(root, type).basePackage(packageBase).projectName(name).dsl("groovy").add(); // NOI18N - ops.addProjectPreload(root); - ops.addProjectPreload(new File(root, subFolder)); Boolean initWrapper = (Boolean) params.get(PROP_INIT_WRAPPER); if (initWrapper == null || initWrapper) { @@ -76,6 +74,10 @@ static void collectOperationsForType(Map params, TemplateOperati } else { // @TODO delete wrapper added by init? } + + ops.addProjectPreload(root); + ops.addProjectPreload(new File(root, subFolder)); + } } diff --git a/java/java.completion/src/org/netbeans/modules/java/completion/JavaCompletionTask.java b/java/java.completion/src/org/netbeans/modules/java/completion/JavaCompletionTask.java index cb541a6959b1..9a2d8de48307 100644 --- a/java/java.completion/src/org/netbeans/modules/java/completion/JavaCompletionTask.java +++ b/java/java.completion/src/org/netbeans/modules/java/completion/JavaCompletionTask.java @@ -1666,6 +1666,9 @@ private void insideMemberSelect(Env env) throws IOException { env.afterExtends(); } else if (TreeUtilities.CLASS_TREE_KINDS.contains(parent.getKind()) && ((ClassTree) parent).getImplementsClause().contains(fa)) { kinds = EnumSet.of(INTERFACE); + } else if (parent.getKind() == Kind.PACKAGE) { + kinds = EnumSet.noneOf(ElementKind.class); + srcOnly = true; } else if (parent.getKind() == Tree.Kind.IMPORT) { inImport = true; kinds = ((ImportTree) parent).isStatic() ? EnumSet.of(CLASS, ENUM, INTERFACE, ANNOTATION_TYPE, RECORD, FIELD, METHOD, ENUM_CONSTANT, RECORD_COMPONENT) : EnumSet.of(CLASS, ANNOTATION_TYPE, ENUM, INTERFACE, RECORD); diff --git a/java/java.completion/test/unit/data/goldenfiles/org/netbeans/modules/java/completion/JavaCompletionTaskTest/1.8/AutoCompletion_CaseBody_PatternMatchingSwitch.pass b/java/java.completion/test/unit/data/goldenfiles/org/netbeans/modules/java/completion/JavaCompletionTaskTest/1.8/AutoCompletion_CaseBody_PatternMatchingSwitch.pass index 615e4fb668e5..ab6c90ee2a5a 100644 --- a/java/java.completion/test/unit/data/goldenfiles/org/netbeans/modules/java/completion/JavaCompletionTaskTest/1.8/AutoCompletion_CaseBody_PatternMatchingSwitch.pass +++ b/java/java.completion/test/unit/data/goldenfiles/org/netbeans/modules/java/completion/JavaCompletionTaskTest/1.8/AutoCompletion_CaseBody_PatternMatchingSwitch.pass @@ -115,6 +115,7 @@ Process ProcessBuilder ProcessHandle Readable +Record ReflectiveOperationException Runnable Runtime diff --git a/java/java.completion/test/unit/data/goldenfiles/org/netbeans/modules/java/completion/JavaCompletionTaskTest/1.8/AutoCompletion_Guard_PatternMatchingSwitch_1.pass b/java/java.completion/test/unit/data/goldenfiles/org/netbeans/modules/java/completion/JavaCompletionTaskTest/1.8/AutoCompletion_Guard_PatternMatchingSwitch_1.pass index 572d58bebaf1..315c11c6d36d 100644 --- a/java/java.completion/test/unit/data/goldenfiles/org/netbeans/modules/java/completion/JavaCompletionTaskTest/1.8/AutoCompletion_Guard_PatternMatchingSwitch_1.pass +++ b/java/java.completion/test/unit/data/goldenfiles/org/netbeans/modules/java/completion/JavaCompletionTaskTest/1.8/AutoCompletion_Guard_PatternMatchingSwitch_1.pass @@ -96,6 +96,7 @@ Process ProcessBuilder ProcessHandle Readable +Record ReflectiveOperationException Runnable Runtime diff --git a/java/java.freeform/src/org/netbeans/modules/java/freeform/jdkselection/jdk.xml b/java/java.freeform/src/org/netbeans/modules/java/freeform/jdkselection/jdk.xml index af6a3ce376e4..1d6dd548050a 100644 --- a/java/java.freeform/src/org/netbeans/modules/java/freeform/jdkselection/jdk.xml +++ b/java/java.freeform/src/org/netbeans/modules/java/freeform/jdkselection/jdk.xml @@ -161,6 +161,9 @@ + + + diff --git a/java/java.hints.test/src/org/netbeans/modules/java/hints/test/api/HintTest.java b/java/java.hints.test/src/org/netbeans/modules/java/hints/test/api/HintTest.java index 02beebcf0753..7efea72a98fc 100644 --- a/java/java.hints.test/src/org/netbeans/modules/java/hints/test/api/HintTest.java +++ b/java/java.hints.test/src/org/netbeans/modules/java/hints/test/api/HintTest.java @@ -80,13 +80,11 @@ import org.netbeans.modules.java.hints.providers.code.FSWrapper; import org.netbeans.modules.java.hints.providers.code.FSWrapper.ClassWrapper; import org.netbeans.modules.java.hints.providers.spi.HintDescription; -import org.netbeans.modules.java.hints.providers.spi.HintDescription.Worker; import org.netbeans.modules.java.hints.providers.spi.HintDescriptionFactory; import org.netbeans.modules.java.hints.providers.spi.HintMetadata; import org.netbeans.modules.java.hints.providers.spi.HintMetadata.Options; import org.netbeans.modules.java.hints.spiimpl.JavaFixImpl; import org.netbeans.modules.java.hints.spiimpl.JavaFixImpl.Accessor; -import org.netbeans.modules.java.hints.spiimpl.MessageImpl; import org.netbeans.modules.java.hints.spiimpl.SyntheticFix; import org.netbeans.modules.java.hints.spiimpl.batch.BatchUtilities; import org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker; @@ -98,7 +96,6 @@ import org.netbeans.modules.parsing.api.indexing.IndexingManager; import org.netbeans.modules.parsing.impl.indexing.CacheFolder; import org.netbeans.modules.parsing.impl.indexing.MimeTypes; -import org.netbeans.modules.refactoring.spi.RefactoringElementImplementation; import org.netbeans.spi.editor.hints.ErrorDescription; import org.netbeans.spi.editor.hints.Fix; import org.netbeans.spi.editor.hints.Severity; @@ -177,7 +174,7 @@ public class HintTest { private final FileObject cache; private final Preferences testPreferences; private final HintsSettings hintSettings; - private final List checkCompilable = new ArrayList(); + private final List checkCompilable = new ArrayList<>(); private String sourceLevel = "1.5"; private List extraOptions = new ArrayList<>(); private Character caretMarker; @@ -187,7 +184,7 @@ public class HintTest { private ClassPath compileClassPath = ClassPathSupport.createClassPath(new URL[0]); private HintTest() throws Exception { - List layers = new LinkedList(); + List layers = new LinkedList<>(); for (String layer : new String[] {"META-INF/generated-layer.xml"}) { boolean found = false; @@ -222,9 +219,9 @@ private HintTest() throws Exception { Set amt = MimeTypes.getAllMimeTypes(); if (amt == null) { - amt = new HashSet(); + amt = new HashSet<>(); } else { - amt = new HashSet(amt); + amt = new HashSet<>(amt); } amt.add("text/x-java"); MimeTypes.setAllMimeTypes(amt); @@ -381,12 +378,27 @@ private void ensureCompilable(FileObject file) throws IOException, AssertionErro } } + /**Sets a source level for all Java files used in this test. + * + * @param sourceLevel the source level to use while parsing Java files + * @return itself + */ + public HintTest sourceLevel(int sourceLevel) { + assertTrue(sourceLevel >= 8); + return this.sourceLevel(Integer.toString(sourceLevel)); + } + /**Sets a source level for all Java files used in this test. * * @param sourceLevel the source level to use while parsing Java files * @return itself */ public HintTest sourceLevel(String sourceLevel) { + try { + int valid = sourceLevel.startsWith("1.") ? Integer.parseInt(sourceLevel.substring(2)) : Integer.parseInt(sourceLevel); + } catch (NumberFormatException ex) { + throw new IllegalArgumentException(ex); + } this.sourceLevel = sourceLevel; return this; } @@ -459,8 +471,8 @@ public HintOutput run(Class hint, String hintCode) throws Exception { ensureCompilable(file); } - Map> hints = new HashMap>(); - List found = new ArrayList(); + Map> hints = new HashMap<>(); + List found = new ArrayList<>(); for (ClassWrapper w : FSWrapper.listClasses()) { if (hint.getCanonicalName().equals(w.getName().replace('$', '.'))) { @@ -474,8 +486,8 @@ public HintOutput run(Class hint, String hintCode) throws Exception { CodeHintProviderImpl.processClass(w, hints); } - List total = new LinkedList(); - final Set requiresJavaFix = Collections.newSetFromMap(new IdentityHashMap()); + List total = new LinkedList<>(); + final Set requiresJavaFix = Collections.newSetFromMap(new IdentityHashMap<>()); for (final Entry> e : hints.entrySet()) { if (null != hintCode && !e.getKey().id.equals(hintCode)) { @@ -493,20 +505,16 @@ public HintOutput run(Class hint, String hintCode) throws Exception { .setMetadata(e.getKey()) .setAdditionalConstraints(hd.getAdditionalConstraints()) .addOptions(hd.getOptions().toArray(new Options[0])) - .setWorker(new Worker() { - @Override public Collection createErrors(HintContext ctx) { - Collection errors = hd.getWorker().createErrors(ctx); - - if (errors != null) { - for (ErrorDescription ed : errors) { - requiresJavaFix.add(ed); - } - } - - return errors; - } - }) - .produce()); + .setWorker((HintContext ctx) -> { + Collection errors = hd.getWorker().createErrors(ctx); + if (errors != null) { + for (ErrorDescription ed : errors) { + requiresJavaFix.add(ed); + } + } + return errors; + }) + .produce()); } } @@ -514,7 +522,7 @@ public HintOutput run(Class hint, String hintCode) throws Exception { assertNotNull(info); - List result = new ArrayList(); + List result = new ArrayList<>(); Handler h = new Handler() { @Override public void publish(LogRecord record) { @@ -534,10 +542,10 @@ public HintOutput run(Class hint, String hintCode) throws Exception { result.addAll(e.getValue()); } - Collections.sort(result, ERRORS_COMPARATOR); + result.sort(ERRORS_COMPARATOR); - Reference infoRef = new WeakReference(info); - Reference cut = new WeakReference(info.getCompilationUnit()); + Reference infoRef = new WeakReference<>(info); + Reference cut = new WeakReference<>(info.getCompilationUnit()); info = null; @@ -551,7 +559,7 @@ public HintOutput run(Class hint, String hintCode) throws Exception { //must keep the error descriptions (and their Fixes through them) in a field //so that assertGC is able to provide a useful trace of references: - private static Set> DEBUGGING_HELPER = Collections.newSetFromMap(new IdentityHashMap, Boolean>()); + private static Set> DEBUGGING_HELPER = Collections.newSetFromMap(new IdentityHashMap<>()); private CompilationInfo parse(FileObject file) throws DataObjectNotFoundException, IllegalArgumentException, IOException { DataObject od = DataObject.find(file); @@ -576,7 +584,7 @@ private CompilationInfo parse(FileObject file) throws DataObjectNotFoundExceptio } private Map> computeErrors(CompilationInfo info, Iterable hints, AtomicBoolean cancel) { - return new HintsInvoker(hintSettings, caret, cancel).computeHints(info, new TreePath(info.getCompilationUnit()), hints, new LinkedList()); + return new HintsInvoker(hintSettings, caret, cancel).computeHints(info, new TreePath(info.getCompilationUnit()), hints, new LinkedList<>()); } FileObject getSourceRoot() { @@ -596,28 +604,36 @@ private TempPreferences(TempPreferences parent, String name) { newNode = true; } + @Override protected final String getSpi(String key) { return properties().getProperty(key); } + @Override protected final String[] childrenNamesSpi() throws BackingStoreException { return new String[0]; } + @Override protected final String[] keysSpi() throws BackingStoreException { return properties().keySet().toArray(new String[0]); } + @Override protected final void putSpi(String key, String value) { properties().put(key,value); } + @Override protected final void removeSpi(String key) { properties().remove(key); } + @Override protected final void removeNodeSpi() throws BackingStoreException {} + @Override protected void flushSpi() throws BackingStoreException {} + @Override protected void syncSpi() throws BackingStoreException { properties().clear(); } @@ -643,6 +659,7 @@ Properties properties() { return properties; } + @Override protected AbstractPreferences childSpi(String name) { return new TempPreferences(this, name); } @@ -659,22 +676,21 @@ protected AbstractPreferences childSpi(String name) { private class TestSourceForBinaryQuery implements SourceForBinaryQueryImplementation { + @Override public SourceForBinaryQuery.Result findSourceRoots(URL binaryRoot) { FileObject f = URLMapper.findFileObject(binaryRoot); if (buildRoot.equals(f)) { return new SourceForBinaryQuery.Result() { + @Override public FileObject[] getRoots() { return new FileObject[] { sourceRoot, }; } - public void addChangeListener(ChangeListener l) { - } - - public void removeChangeListener(ChangeListener l) { - } + @Override public void addChangeListener(ChangeListener l) {} + @Override public void removeChangeListener(ChangeListener l) {} }; } @@ -687,6 +703,7 @@ public void removeChangeListener(ChangeListener l) { private class TestProxyClassPathProvider implements ClassPathProvider { + @Override public ClassPath findClassPath(FileObject file, String type) { try { if (ClassPath.BOOT == type) { @@ -776,6 +793,7 @@ public DeadlockTask(Phase phase) { this.phase = phase; } + @Override public void run( CompilationController info ) { try { info.toPhase(this.phase); @@ -826,8 +844,8 @@ public HintOutput assertWarnings(String... warnings) { * @throws AssertionError if the given warnings do not match the actual warnings */ public HintOutput assertContainsWarnings(String... warnings) { - Set goldenSet = new HashSet(Arrays.asList(warnings)); - List errorsNames = new LinkedList(); + Set goldenSet = new HashSet<>(Arrays.asList(warnings)); + List errorsNames = new LinkedList<>(); for (ErrorDescription d : errors) { goldenSet.remove(d.toString()); @@ -849,8 +867,8 @@ public HintOutput assertContainsWarnings(String... warnings) { * @throws AssertionError if the given warnings contain the actual warnings */ public HintOutput assertNotContainsWarnings(String... warnings) { - Set goldenSet = new HashSet(Arrays.asList(warnings)); - List errorsNames = new LinkedList(); + Set goldenSet = new HashSet<>(Arrays.asList(warnings)); + List errorsNames = new LinkedList<>(); for (String warning : goldenSet) { if (warning.split(":").length >= 5) { @@ -942,7 +960,7 @@ public AppliedFix applyFix(String fix) throws Exception { assertTrue("Must be computed", warning.getFixes().isComputed()); List fixes = warning.getFixes().getFixes(); - List fixNames = new LinkedList(); + List fixNames = new LinkedList<>(); Fix toApply = null; for (Fix f : fixes) { @@ -989,19 +1007,15 @@ private void doApplyFix(Fix f) throws Exception { private ModificationResult runJavaFix(final JavaFix jf) throws IOException { FileObject file = Accessor.INSTANCE.getFile(jf); JavaSource js = JavaSource.forFileObject(file); - final Map> changes = new HashMap>(); - - ModificationResult mr = js.runModificationTask(new Task() { - public void run(WorkingCopy wc) throws Exception { - if (wc.toPhase(Phase.RESOLVED).compareTo(Phase.RESOLVED) < 0) { - return; - } + final Map> changes = new HashMap<>(); - Map resourceContentChanges = new HashMap(); - Accessor.INSTANCE.process(jf, wc, true, resourceContentChanges, /*Ignored for now:*/new ArrayList()); - BatchUtilities.addResourceContentChanges(resourceContentChanges, changes); - + ModificationResult mr = js.runModificationTask((WorkingCopy wc) -> { + if (wc.toPhase(Phase.RESOLVED).compareTo(Phase.RESOLVED) < 0) { + return; } + Map resourceContentChanges = new HashMap<>(); + Accessor.INSTANCE.process(jf, wc, true, resourceContentChanges, /*Ignored for now:*/new ArrayList<>()); + BatchUtilities.addResourceContentChanges(resourceContentChanges, changes); }); changes.putAll(JavaSourceAccessor.getINSTANCE().getDiffsFromModificationResult(mr)); @@ -1018,7 +1032,7 @@ public void run(WorkingCopy wc) throws Exception { public HintWarning assertFixes(String... expectedFixes) throws Exception { assertTrue("Must be computed", warning.getFixes().isComputed()); - List fixNames = new LinkedList(); + List fixNames = new LinkedList<>(); for (Fix f : warning.getFixes().getFixes()) { if (f instanceof SyntheticFix) continue; @@ -1040,7 +1054,7 @@ public HintWarning assertFixes(String... expectedFixes) throws Exception { public HintWarning assertFixesNotPresent(String... bannedFixes) throws Exception { assertTrue("Must be computed", warning.getFixes().isComputed()); - List fixNames = new LinkedList(); + List fixNames = new LinkedList<>(); for (Fix f : warning.getFixes().getFixes()) { if (f instanceof SyntheticFix) continue; fixNames.add(f.getText()); @@ -1269,11 +1283,8 @@ public String getOutput(String fileName) throws Exception { } } - private static final Comparator ERRORS_COMPARATOR = new Comparator () { - - public int compare (ErrorDescription e1, ErrorDescription e2) { - return e1.getRange ().getBegin ().getOffset () - e2.getRange ().getBegin ().getOffset (); - } + private static final Comparator ERRORS_COMPARATOR = (ErrorDescription e1, ErrorDescription e2) -> { + return e1.getRange().getBegin().getOffset() - e2.getRange().getBegin().getOffset(); }; static { @@ -1369,7 +1380,7 @@ private static String getWorkDirPath() { return realP; } - private static Set usedPaths = new HashSet(); + private static Set usedPaths = new HashSet<>(); private static String abbrevDots(String dotted) { StringBuilder sb = new StringBuilder(); @@ -1417,17 +1428,11 @@ private static String getWorkDirPathFromManager() { private static Properties readProperties() { Properties result = new Properties(); - try { - File propFile = getPreferencesFile(); - FileInputStream is = new FileInputStream(propFile); - try { - result.load(is); - } finally { - is.close(); - } + File propFile = getPreferencesFile(); + try (FileInputStream is = new FileInputStream(propFile)) { + result.load(is); } catch (IOException e) { } - return result; } @@ -1474,11 +1479,10 @@ private static void deleteSubFiles(File file) throws IOException { } } - private static FileObject copyStringToFile (FileObject f, String content) throws Exception { - OutputStream os = f.getOutputStream(); - os.write(content.getBytes(StandardCharsets.UTF_8)); - os.close (); - + private static FileObject copyStringToFile(FileObject f, String content) throws Exception { + try (OutputStream os = f.getOutputStream()) { + os.write(content.getBytes(StandardCharsets.UTF_8)); + } return f; } diff --git a/java/java.hints/test/unit/data/goldenfiles/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptions.java b/java/java.hints/test/unit/data/goldenfiles/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptions.java index bea79d9bae62..807c1c860aef 100644 --- a/java/java.hints/test/unit/data/goldenfiles/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptions.java +++ b/java/java.hints/test/unit/data/goldenfiles/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptions.java @@ -2,15 +2,20 @@ import java.io.FileInputStream; import java.io.IOException; -import java.lang.reflect.Method; +import java.lang.reflect.InvocationTargetException; import java.net.URL; -import java.util.Collections; public class TwoExceptions { + private static class StableMethod { + public Object invoke(Object obj, Object... args) throws IllegalAccessException, IllegalArgumentException, InvocationTargetException {return null;} + } + private static class StableClass { + public StableMethod getDeclaredMethod(String name, Class... types) throws NoSuchMethodException, SecurityException {return null;} + } public void t() { - Class c = Collections.class; + StableClass c = new StableClass(); try { - Method m = c.getDeclaredMethod("foobar"); + StableMethod m = c.getDeclaredMethod("foobar"); m.invoke(null); } /* cmt */ catch (IllegalArgumentException ex) { /* cmt */ diff --git a/java/java.hints/test/unit/data/goldenfiles/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptionsMulti.java b/java/java.hints/test/unit/data/goldenfiles/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptionsMulti.java index 5ae98338b18b..e5e648150539 100644 --- a/java/java.hints/test/unit/data/goldenfiles/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptionsMulti.java +++ b/java/java.hints/test/unit/data/goldenfiles/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptionsMulti.java @@ -2,15 +2,20 @@ import java.io.FileInputStream; import java.io.IOException; -import java.lang.reflect.Method; +import java.lang.reflect.InvocationTargetException; import java.net.URL; -import java.util.Collections; public class TwoExceptions { + private static class StableMethod { + public Object invoke(Object obj, Object... args) throws IllegalAccessException, IllegalArgumentException, InvocationTargetException {return null;} + } + private static class StableClass { + public StableMethod getDeclaredMethod(String name, Class... types) throws NoSuchMethodException, SecurityException {return null;} + } public void t() { - Class c = Collections.class; + StableClass c = new StableClass(); try { - Method m = c.getDeclaredMethod("foobar"); + StableMethod m = c.getDeclaredMethod("foobar"); m.invoke(null); } /* cmt */ catch (IllegalArgumentException | SecurityException ex) { /* cmt */ diff --git a/java/java.hints/test/unit/data/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptions.java b/java/java.hints/test/unit/data/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptions.java index 76199789c9d5..2314244f1aca 100644 --- a/java/java.hints/test/unit/data/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptions.java +++ b/java/java.hints/test/unit/data/org/netbeans/test/java/hints/BroadCatchBlockTest/TwoExceptions.java @@ -2,15 +2,20 @@ import java.io.FileInputStream; import java.io.IOException; -import java.lang.reflect.Method; +import java.lang.reflect.InvocationTargetException; import java.net.URL; -import java.util.Collections; public class TwoExceptions { + private static class StableMethod { + public Object invoke(Object obj, Object... args) throws IllegalAccessException, IllegalArgumentException, InvocationTargetException {return null;} + } + private static class StableClass { + public StableMethod getDeclaredMethod(String name, Class... types) throws NoSuchMethodException, SecurityException {return null;} + } public void t() { - Class c = Collections.class; + StableClass c = new StableClass(); try { - Method m = c.getDeclaredMethod("foobar"); + StableMethod m = c.getDeclaredMethod("foobar"); m.invoke(null); } /* cmt */ catch (RuntimeException ex) { /* cmt */ diff --git a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/ImportsTest.java b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/ImportsTest.java index 3957dc7f5b83..1cd70f8478eb 100644 --- a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/ImportsTest.java +++ b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/ImportsTest.java @@ -63,7 +63,7 @@ public void testUnusedSimpleRemove() throws Exception { public void testRedundantLangImportRemove() throws Exception { assumeTrue(Runtime.version().feature() >= 21); // API dependency HintTest.create() - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .options("--enable-preview") .input( "package test;\n" + diff --git a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/bugs/BroadCatchBlockTest.java b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/bugs/BroadCatchBlockTest.java index 75cce605e1fc..077eac9ce099 100644 --- a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/bugs/BroadCatchBlockTest.java +++ b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/bugs/BroadCatchBlockTest.java @@ -79,10 +79,9 @@ public void testSingleParentException() throws Exception { /** * Checks that generic exception is reported even though * it corresponds to > 1 subclass. It also checks that common - * parents are not reported for neigher 'umbrellas' or normal exceptions. - * + * parents are not reported for neither 'umbrellas' or normal exceptions. */ - private static final String twoSubexceptionsGeneric = "14:27-14:46:verifier:The catch(java.lang.RuntimeException) is too broad, it catches the following exception types: java.lang.IllegalArgumentException and java.lang.SecurityException"; + private static final String twoSubexceptionsGeneric = "19:27-19:46:verifier:The catch(java.lang.RuntimeException) is too broad, it catches the following exception types: java.lang.IllegalArgumentException and java.lang.SecurityException"; public void testTwoSubexceptionsGeneric() throws Exception { final String warnTxt = twoSubexceptionsGeneric; createHintTest("TwoExceptions"). @@ -94,10 +93,10 @@ public void testTwoSubexceptionsGeneric() throws Exception { assertOutput(f(), g()); } - public void testTwoSubexceptionsGeneric7() throws Exception { + public void testTwoSubexceptionsGeneric2() throws Exception { final String warnTxt = twoSubexceptionsGeneric; createHintTest("TwoExceptions"). - sourceLevel("1.7"). + sourceLevel(8). run(BroadCatchBlock.class). assertWarnings(warnTxt). findWarning(warnTxt). @@ -149,7 +148,7 @@ public void testTwoCommonParentFixSeparateCatches() throws Exception { public void testTwoCommonParentFixMultiCatch() throws Exception { createHintTest("TwoExceptionsCommon"). preference(BroadCatchBlock.OPTION_EXCLUDE_COMMON, false). - sourceLevel("1.7"). + sourceLevel(8). run(BroadCatchBlock.class). assertWarnings(warn_twoCommonParents). findWarning(warn_twoCommonParents[0]). diff --git a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertSwitchToRuleSwitchTest.java b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertSwitchToRuleSwitchTest.java index 3323573ea75f..3e763142cc7d 100644 --- a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertSwitchToRuleSwitchTest.java +++ b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertSwitchToRuleSwitchTest.java @@ -60,7 +60,7 @@ public void testSwitch2RuleSwitch() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -91,7 +91,7 @@ public void testLastNotBreak() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -122,7 +122,7 @@ public void testMultipleCases() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -153,7 +153,7 @@ public void testFallThrough() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .assertWarnings(); } @@ -173,7 +173,7 @@ public void testMissingLastBreak() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -204,7 +204,7 @@ public void testDefault() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -244,7 +244,7 @@ public void testVariables1() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -284,7 +284,7 @@ public void testFallThroughDefault1() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .assertWarnings(); } @@ -304,7 +304,7 @@ public void testFallThroughDefault2() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .assertWarnings(); } @@ -326,7 +326,7 @@ public void testTrailingEmptyCase() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -362,7 +362,7 @@ public void testNeedsPreview() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .assertWarnings(); } @@ -381,7 +381,7 @@ public void testBreakInside1() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .assertWarnings(); } @@ -402,7 +402,7 @@ public void testBreakInside2() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("4:9-4:15:verifier:Convert switch to rule switch") .applyFix() @@ -437,7 +437,7 @@ public void testContinueInside1() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .assertWarnings(); } @@ -460,7 +460,7 @@ public void testContinueInside2() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("5:13-5:19:verifier:Convert switch to rule switch") .applyFix() @@ -501,7 +501,7 @@ public void testSwitch2SwitchExpression() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToSwitchExpression()) .applyFix() @@ -536,7 +536,7 @@ public void testSwitch2SwitchExpressionMultiCase() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:8-3:14:verifier:" + Bundle.ERR_ConvertSwitchToSwitchExpression()) .applyFix() @@ -570,7 +570,7 @@ public void testSwitch2SwitchExpressionMultiCase2() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:8-3:14:verifier:" + Bundle.ERR_ConvertSwitchToSwitchExpression()) .applyFix() @@ -601,7 +601,7 @@ public void testSwitch2SwitchExpressionOnlyDefault() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:8-3:14:verifier:" + Bundle.ERR_ConvertSwitchToSwitchExpression()) .applyFix() @@ -636,7 +636,7 @@ public void testSwitch2SwitchExpressionNestedInnerSwitchExpression() throws Exce " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("4:9-4:15:verifier:" + Bundle.ERR_ConvertSwitchToSwitchExpression()) .applyFix() @@ -671,7 +671,7 @@ public void testSwitch2SwitchExpressionReturnValue() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("2:9-2:15:verifier:" + Bundle.ERR_ConvertSwitchToSwitchExpression()) .applyFix() @@ -701,7 +701,7 @@ public void testSwitch2SwitchExpressionTypeCast() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToSwitchExpression()) .applyFix() @@ -731,7 +731,7 @@ public void testSwitch2SwitchExpressionTypeCastReturn() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("2:9-2:15:verifier:" + Bundle.ERR_ConvertSwitchToSwitchExpression()) .applyFix() @@ -764,7 +764,7 @@ public void testSwitch2SwitchExpressionNestedSwitchExpression() throws Exception " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToSwitchExpression()) .applyFix() @@ -806,7 +806,7 @@ public void testSwitch2SwitchExpressionNestedOuterSwitchStatement() throws Excep " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("4:9-4:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -851,7 +851,7 @@ public void testSwitch2SwitchExpressionNestedInnerSwitchStatement() throws Excep " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("6:16-6:22:verifier:" + Bundle.ERR_ConvertSwitchToSwitchExpression()) .applyFix() @@ -893,7 +893,7 @@ public void testSwitchToRuleSwitchFormattingMultiple() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -924,7 +924,7 @@ public void testSwitchToRuleSwitchFormattingSimple() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -959,7 +959,7 @@ public void testSwitchToRuleSwitchBindingPattern() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel("21") + .sourceLevel(21) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -994,7 +994,7 @@ public void testSwitchToRuleSwitchGuardedPattern() throws Exception { " }\n" + " }\n" + "}\n") - .sourceLevel("21") + .sourceLevel(21) .run(ConvertSwitchToRuleSwitch.class) .findWarning("3:9-3:15:verifier:" + Bundle.ERR_ConvertSwitchToRuleSwitch()) .applyFix() @@ -1030,7 +1030,7 @@ public void testSwitchExpressionGuardedPattern() throws Exception { + " }\n" + " }\n" + "}") - .sourceLevel("21") + .sourceLevel(21) .run(ConvertSwitchToRuleSwitch.class) .findWarning("2:8-2:14:verifier:" + Bundle.ERR_ConvertSwitchToSwitchExpression()) .applyFix() diff --git a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertTextBlockToStringTest.java b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertTextBlockToStringTest.java index 8d37b5c6c39f..83667f51d00e 100644 --- a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertTextBlockToStringTest.java +++ b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertTextBlockToStringTest.java @@ -46,7 +46,7 @@ public void newLineAtEnd() throws Exception { + " \"\"\";\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("3:18-3:21:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() @@ -69,7 +69,7 @@ public void simpleTest() throws Exception { + " abc\"\"\";\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("3:18-3:21:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() @@ -98,7 +98,7 @@ public void multipleNewLine() throws Exception { + " \"\"\";\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("3:18-3:21:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() @@ -126,7 +126,7 @@ public void newLineAfter() throws Exception { + " ;\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("3:18-3:21:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() @@ -160,7 +160,7 @@ public void manyLineTextBlock() throws Exception { + " wxyz\"\"\";\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("3:18-3:21:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() @@ -184,7 +184,7 @@ public void twoLineTextBlock() throws Exception { + " def\"\"\";\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("3:18-3:21:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() @@ -209,7 +209,7 @@ public void twoNewLines() throws Exception { + " \"\"\";\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("3:18-3:21:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() @@ -232,7 +232,7 @@ public void slashConvert() throws Exception { + " \\\\\"\"\";\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("3:18-3:21:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() @@ -256,7 +256,7 @@ public void escapeCharTextBlock() throws Exception { + " \"def\"\"\";\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("3:18-3:21:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() @@ -284,7 +284,7 @@ public void escapeCharTextBlock2() throws Exception { + " \"\"\";\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("3:18-3:21:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() @@ -308,7 +308,7 @@ public void textBlockAsParameter1() throws Exception { + " abc\"\"\");\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("4:27-4:30:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() @@ -333,7 +333,7 @@ public void textBlockAsParameter2() throws Exception { + " ghi\"\"\");\n" + " }\n" + "}") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertTextBlockToString.class) .findWarning("2:27-2:30:hint:" + Bundle.ERR_ConvertTextBlockToString()) .applyFix() diff --git a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToNestedRecordPatternTest.java b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToNestedRecordPatternTest.java index 28583a4a57de..566ef10c672f 100644 --- a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToNestedRecordPatternTest.java +++ b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToNestedRecordPatternTest.java @@ -22,6 +22,8 @@ import org.netbeans.modules.java.hints.test.api.HintTest; import javax.lang.model.SourceVersion; +import static org.junit.Assume.assumeTrue; + /** * * @author mjayan @@ -33,9 +35,8 @@ public ConvertToNestedRecordPatternTest(String name) { } public void testSimple() throws Exception { - if (!isRecordClassPresent()) { - return; - } + assumeTrue(isRecordClassPresent()); + assumeTrue(SourceVersion.latest().ordinal() >= 21); HintTest.create() .input("package test;\n" + "record Rect(ColoredPoint upperLeft,ColoredPoint lr) {}\n" @@ -50,8 +51,7 @@ public void testSimple() throws Exception { + " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) - .options("--enable-preview") + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToNestedRecordPattern.class) .findWarning("7:25-7:63:verifier:" + Bundle.ERR_ConvertToNestedRecordPattern()) .applyFix() @@ -71,9 +71,8 @@ public void testSimple() throws Exception { } public void testRecordNameUsed() throws Exception { - if (!isRecordClassPresent()) { - return; - } + assumeTrue(isRecordClassPresent()); + assumeTrue(SourceVersion.latest().ordinal() >= 21); HintTest.create() .input("package test;\n" + "record Rect(ColoredPoint upperLeft,ColoredPoint lr) {}\n" @@ -88,16 +87,14 @@ public void testRecordNameUsed() throws Exception { + " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) - .options("--enable-preview") + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToNestedRecordPattern.class) .assertWarnings(); } public void testNameClash() throws Exception { - if (!isRecordClassPresent()) { - return; - } + assumeTrue(isRecordClassPresent()); + assumeTrue(SourceVersion.latest().ordinal() >= 21); HintTest.create() .input("package test;\n" + "record Rect(ColoredPoint upperLeft,ColoredPoint lr) {}\n" @@ -119,8 +116,7 @@ public void testNameClash() throws Exception { + " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) - .options("--enable-preview") + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToNestedRecordPattern.class) .findWarning("7:25-7:63:verifier:Convert to nested record pattern") .applyFix() @@ -147,9 +143,8 @@ public void testNameClash() throws Exception { } public void testMultipleNested() throws Exception { - if (!isRecordClassPresent()) { - return; - } + assumeTrue(isRecordClassPresent()); + assumeTrue(SourceVersion.latest().ordinal() >= 21); HintTest.create() .input("package test;\n" + "record Rect(ColoredPoint upperLeft) {}\n" @@ -164,8 +159,7 @@ public void testMultipleNested() throws Exception { + " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) - .options("--enable-preview") + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToNestedRecordPattern.class) .findWarning("7:25-7:61:verifier:" + Bundle.ERR_ConvertToNestedRecordPattern()) .applyFix() @@ -185,9 +179,8 @@ public void testMultipleNested() throws Exception { } public void testUserVar() throws Exception { - if (!isRecordClassPresent()) { - return; - } + assumeTrue(isRecordClassPresent()); + assumeTrue(SourceVersion.latest().ordinal() >= 21); HintTest.create() .input("package test;\n" + "record Rect(ColoredPoint upperLeft,ColoredPoint lr,ColoredPoint ur) {}\n" @@ -204,8 +197,7 @@ public void testUserVar() throws Exception { + " }\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) - .options("--enable-preview") + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToNestedRecordPattern.class) .findWarning("7:25-7:112:verifier:" + Bundle.ERR_ConvertToNestedRecordPattern()) .applyFix() diff --git a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToRecordPatternTest.java b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToRecordPatternTest.java index 72cd50c080ce..a4b3a5e6ce99 100644 --- a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToRecordPatternTest.java +++ b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToRecordPatternTest.java @@ -21,6 +21,7 @@ import org.netbeans.junit.NbTestCase; import org.netbeans.modules.java.hints.test.api.HintTest; import javax.lang.model.SourceVersion; +import static org.junit.Assume.assumeTrue; /** * @@ -33,9 +34,8 @@ public ConvertToRecordPatternTest(String name) { } public void testSimple() throws Exception { - if (!isRecordClassPresent()) { - return; - } + assumeTrue(isRecordClassPresent()); + assumeTrue(SourceVersion.latest().ordinal() >= 21); HintTest.create() .input("package test;\n" + "record Person(String name, String place){}\n" @@ -48,8 +48,7 @@ public void testSimple() throws Exception { + " return -1;\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) - .options("--enable-preview") + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToRecordPattern.class) .findWarning("4:8-4:10:verifier:" + Bundle.ERR_ConvertToRecordPattern()) .applyFix() @@ -58,7 +57,7 @@ public void testSimple() throws Exception { + "record Person(String name, String place){}\n" + "public class Test {\n" + " private int test(Object o) {\n" - + " if (o instanceof Person(String name, String place) p) {\n" + + " if (o instanceof Person(String name, String place)) {\n" + " return name.length();\n" + " }\n" + " return -1;\n" @@ -67,9 +66,8 @@ public void testSimple() throws Exception { } public void testDuplicateVarName() throws Exception { - if (!isRecordClassPresent()) { - return; - } + assumeTrue(isRecordClassPresent()); + assumeTrue(SourceVersion.latest().ordinal() >= 21); HintTest.create() .input("package test;\n" + "record Person(String name, int s){}\n" @@ -82,8 +80,7 @@ public void testDuplicateVarName() throws Exception { + " return -1;\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) - .options("--enable-preview") + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToRecordPattern.class) .findWarning("4:8-4:10:verifier:" + Bundle.ERR_ConvertToRecordPattern()) .applyFix() @@ -92,7 +89,7 @@ public void testDuplicateVarName() throws Exception { + "record Person(String name, int s){}\n" + "public class Test {\n" + " private int test(Object s) {\n" - + " if (s instanceof Person(String name, int s1) p) {\n" + + " if (s instanceof Person(String name, int s1)) {\n" + " return name.length();\n" + " }\n" + " return -1;\n" @@ -101,9 +98,8 @@ public void testDuplicateVarName() throws Exception { } public void testUsingUserVar() throws Exception { - if (!isRecordClassPresent()) { - return; - } + assumeTrue(isRecordClassPresent()); + assumeTrue(SourceVersion.latest().ordinal() >= 21); HintTest.create() .input("package test;\n" + "record Person(String name, int s){}\n" @@ -116,8 +112,7 @@ public void testUsingUserVar() throws Exception { + " return -1;\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) - .options("--enable-preview") + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToRecordPattern.class) .findWarning("4:8-4:10:verifier:" + Bundle.ERR_ConvertToRecordPattern()) .applyFix() @@ -126,7 +121,7 @@ public void testUsingUserVar() throws Exception { + "record Person(String name, int s){}\n" + "public class Test {\n" + " private int test(Object s) {\n" - + " if (s instanceof Person(String userName, int s1) p) {\n" + + " if (s instanceof Person(String userName, int s1)) {\n" + " return userName.length();\n" + " }\n" + " return -1;\n" diff --git a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToTextBlockTest.java b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToTextBlockTest.java index 9289ec2ec40b..8b1720ab1219 100644 --- a/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToTextBlockTest.java +++ b/java/java.hints/test/unit/src/org/netbeans/modules/java/hints/jdk/ConvertToTextBlockTest.java @@ -41,7 +41,7 @@ public void testFixWorking() throws Exception { " \"}\");\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToTextBlock.class) .findWarning("3:30-3:37:verifier:" + Bundle.ERR_ConvertToTextBlock()) .applyFix() @@ -75,7 +75,7 @@ public void testNewLineAtEnd() throws Exception { " \"}\\n\");\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToTextBlock.class) .findWarning("3:30-3:37:verifier:" + Bundle.ERR_ConvertToTextBlock()) .applyFix() @@ -110,7 +110,7 @@ public void testNewLinesAtEnd() throws Exception { " \"}\\n\\n\");\n" + " }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToTextBlock.class) .findWarning("3:30-3:37:verifier:" + Bundle.ERR_ConvertToTextBlock()) .applyFix() @@ -144,7 +144,7 @@ public void testOnlyLiterals() throws Exception { " }\n" + " private int c() { return 0; }\n" + "}\n") - .sourceLevel(SourceVersion.latest().name()) + .sourceLevel(SourceVersion.latest().ordinal()) .run(ConvertToTextBlock.class) .assertWarnings(); } diff --git a/java/java.lsp.server/src/org/netbeans/modules/java/lsp/server/protocol/TextDocumentServiceImpl.java b/java/java.lsp.server/src/org/netbeans/modules/java/lsp/server/protocol/TextDocumentServiceImpl.java index be862d3d79ea..dc1967078c2b 100644 --- a/java/java.lsp.server/src/org/netbeans/modules/java/lsp/server/protocol/TextDocumentServiceImpl.java +++ b/java/java.lsp.server/src/org/netbeans/modules/java/lsp/server/protocol/TextDocumentServiceImpl.java @@ -2351,7 +2351,7 @@ public void setColorings(Document doc, Map c long column = 0; int lastLine = 0; long currentLineStart = 0; - long nextLineStart = info.getCompilationUnit().getLineMap().getStartPosition(line + 2); + long nextLineStart = getStartPosition(line + 2); Map ordered = new TreeMap<>((t1, t2) -> t1.offset(null) - t2.offset(null)); ordered.putAll(colorings); for (Entry e : ordered.entrySet()) { @@ -2359,7 +2359,7 @@ public void setColorings(Document doc, Map c while (nextLineStart < currentOffset) { line++; currentLineStart = nextLineStart; - nextLineStart = info.getCompilationUnit().getLineMap().getStartPosition(line + 2); + nextLineStart = getStartPosition(line + 2); column = 0; } Optional tokenType = e.getValue().stream().map(c -> coloring2TokenType[c.ordinal()]).collect(Collectors.maxBy((v1, v2) -> v1.intValue() - v2.intValue())); @@ -2381,6 +2381,14 @@ public void setColorings(Document doc, Map c } } } + + private long getStartPosition(int line) { + try { + return line < 0 ? -1 : info.getCompilationUnit().getLineMap().getStartPosition(line); + } catch (Exception e) { + return info.getText().length(); + } + } }); return true; } diff --git a/java/java.lsp.server/vscode/src/nbcode.ts b/java/java.lsp.server/vscode/src/nbcode.ts index 3344324ef8ce..0450aa5bd126 100644 --- a/java/java.lsp.server/vscode/src/nbcode.ts +++ b/java/java.lsp.server/vscode/src/nbcode.ts @@ -70,8 +70,8 @@ export function launch( ideArgs.push('-J-Dnetbeans.logger.console=true'); } ideArgs.push(`-J-Dnetbeans.extra.dirs=${clusterPath}`) - if (env['netbeans.extra.options']) { - ideArgs.push(...env['netbeans.extra.options'].split(' ')); + if (env['netbeans_extra_options']) { + ideArgs.push(...env['netbeans_extra_options'].split(' ')); } ideArgs.push(...extraArgs); if (env['netbeans_debug'] && extraArgs && extraArgs.find(s => s.includes("--list"))) { diff --git a/java/java.lsp.server/vscode/src/test/runTest.ts b/java/java.lsp.server/vscode/src/test/runTest.ts index cb972cd719f1..97e25bd60915 100644 --- a/java/java.lsp.server/vscode/src/test/runTest.ts +++ b/java/java.lsp.server/vscode/src/test/runTest.ts @@ -52,7 +52,7 @@ async function main() { extensionTestsPath, extensionTestsEnv: { 'ENABLE_CONSOLE_LOG' : 'true', - "netbeans.extra.options" : `-J-Dproject.limitScanRoot=${outRoot} -J-Dnetbeans.logger.console=true` + "netbeans_extra_options" : `-J-Dproject.limitScanRoot=${outRoot} -J-Dnetbeans.logger.console=true` }, launchArgs: [ '--disable-extensions', diff --git a/java/java.mx.project/src/org/netbeans/modules/java/mx/project/suitepy/Parse.java b/java/java.mx.project/src/org/netbeans/modules/java/mx/project/suitepy/Parse.java index 2fb1cc462b3c..dbc623046b82 100644 --- a/java/java.mx.project/src/org/netbeans/modules/java/mx/project/suitepy/Parse.java +++ b/java/java.mx.project/src/org/netbeans/modules/java/mx/project/suitepy/Parse.java @@ -56,30 +56,6 @@ static MxSuite parse(URL u) throws IOException { } private MxSuite parseImpl(URL u) throws IOException { - String full = readText(u); - full = replaceQuotes("\"\"\"", full); - full = replaceQuotes("'''", full); - - StringBuilder sb = new StringBuilder(); - full.lines().forEach((line) -> { - sb.append(jsonify(line)).append("\n"); - }); - String txt = sb.toString(); - - Object value; - try { - final JSONParser p = new JSONParser(); - value = p.parse(txt); - } catch (ParseException ex) { - int endOfPreviousLine = txt.lastIndexOf("\n", ex.getPosition()) + 1; - String err = full.substring(endOfPreviousLine, Math.min(full.length(), endOfPreviousLine + 300)); - throw new IOException("Cannot parse " + u + " ...\n" + err + "\n...", ex); - } - Value suite = new Value(value); - return Meta.create(MxSuite.class).cast(suite); - } - - private String readText(URL u) throws IOException { StringBuilder sb = new StringBuilder(); try (BufferedReader r = new BufferedReader(new InputStreamReader(u.openStream()))) { for (;;) { @@ -87,24 +63,34 @@ private String readText(URL u) throws IOException { if (line == null) { break; } + line = line.replaceAll("(\\s*)#.*", "$1"); sb.append(line).append("\n"); } } - String txt = sb.toString(); - return txt; + String text = jsonify(sb.toString()); + Object value; + try { + final JSONParser p = new JSONParser(); + value = p.parse(text); + } catch (ParseException ex) { + throw new IOException("Cannot parse " + u, ex); + } + Value suite = new Value(value); + return Meta.create(MxSuite.class).cast(suite); } - static String jsonify(String content) { - String text = content.replaceFirst("^suite *= *\\{", "{"); + private static String jsonify(String content) { + String text = content.replaceFirst("\\s*suite *= *\\{", "{"); text = text.replace("True", "true").replace("False", "false"); - text = text.replaceAll("(\\s*)#.*", "$1"); text = text.replaceAll(",\\s*(\\]|\\})", "$1"); + text = replaceQuotes("\"\"\"", text); + text = replaceQuotes("'''", text); text = replaceQuotes("'", text); return text; } - private static String replaceQuotes(String quoteSeq, String text) { - Matcher m = Pattern.compile(quoteSeq + "(.*?)" + quoteSeq, Pattern.DOTALL).matcher(text); + private static String replaceQuotes(String quoteSeq, String imports) { + Matcher m = Pattern.compile(quoteSeq + "(.*?)" + quoteSeq, Pattern.DOTALL).matcher(imports); StringBuffer sb = new StringBuffer(); while (m.find()) { m.appendReplacement(sb, "\""); diff --git a/java/java.mx.project/test/unit/src/org/netbeans/modules/java/mx/project/CoreSuiteTest.java b/java/java.mx.project/test/unit/src/org/netbeans/modules/java/mx/project/CoreSuiteTest.java index a0d212a35a35..2be0bdb1ac50 100644 --- a/java/java.mx.project/test/unit/src/org/netbeans/modules/java/mx/project/CoreSuiteTest.java +++ b/java/java.mx.project/test/unit/src/org/netbeans/modules/java/mx/project/CoreSuiteTest.java @@ -21,6 +21,7 @@ import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import java.lang.reflect.Modifier; +import java.net.URI; import java.net.URL; import java.util.ArrayList; import java.util.Arrays; @@ -39,7 +40,7 @@ public void generateCoreSuite() { public static void main(String... args) throws Exception { // mx version "5.279.0" - URL u = new URL("https://raw.githubusercontent.com/graalvm/mx/dcfad27487a5d13d406febc92976cf3c026e50dd/mx.mx/suite.py"); + URL u = new URI("https://raw.githubusercontent.com/graalvm/mx/dcfad27487a5d13d406febc92976cf3c026e50dd/mx.mx/suite.py").toURL(); assert u != null : "mx suite found"; MxSuite mxSuite = MxSuite.parse(u); diff --git a/java/java.mx.project/test/unit/src/org/netbeans/modules/java/mx/project/SdkSuiteTest.java b/java/java.mx.project/test/unit/src/org/netbeans/modules/java/mx/project/SdkSuiteTest.java index df4bfd254afb..2cb022048acb 100644 --- a/java/java.mx.project/test/unit/src/org/netbeans/modules/java/mx/project/SdkSuiteTest.java +++ b/java/java.mx.project/test/unit/src/org/netbeans/modules/java/mx/project/SdkSuiteTest.java @@ -20,14 +20,21 @@ import java.io.File; import java.net.URL; +import java.util.ArrayList; +import java.util.Arrays; import java.util.HashSet; +import java.util.List; import java.util.Set; import static junit.framework.TestCase.assertEquals; import static junit.framework.TestCase.assertNotNull; import static junit.framework.TestCase.assertTrue; +import org.netbeans.api.java.queries.BinaryForSourceQuery; import org.netbeans.api.java.queries.SourceForBinaryQuery; import org.netbeans.api.project.Project; import org.netbeans.api.project.ProjectManager; +import org.netbeans.api.project.ProjectUtils; +import org.netbeans.api.project.SourceGroup; +import org.netbeans.api.project.Sources; import org.openide.filesystems.FileObject; import org.openide.filesystems.FileUtil; @@ -50,31 +57,27 @@ public void testRootsForAnSdkJar() throws Exception { FileObject fo = FileUtil.toFileObject(sdkSibling); assertNotNull("project directory found", fo); - FileObject graalSdkJar = FileUtil.createData(fo, "mxbuild/dists/jdk1.8/graal-sdk.jar"); - assertNotNull(graalSdkJar); - Project p = ProjectManager.getDefault().findProject(fo); assertNotNull("project found", p); assertEquals("It is suite project: " + p, "SuiteProject", p.getClass().getSimpleName()); + Sources src = ProjectUtils.getSources(p); + List resultRoots = new ArrayList<>(); + for (SourceGroup sourceGroup : src.getSourceGroups("java")) { + BinaryForSourceQuery.Result binaryResult = BinaryForSourceQuery.findBinaryRoots(sourceGroup.getRootFolder().toURL()); + for (URL r : binaryResult.getRoots()) { + SourceForBinaryQuery.Result2 result2 = SourceForBinaryQuery.findSourceRoots2(r); + final FileObject[] rr = result2.getRoots(); + resultRoots.addAll(Arrays.asList(rr)); + } + } - final URL archiveURL = new URL("jar:" + graalSdkJar.toURL() + "!/"); - - SourceForBinaryQuery.Result2 result2 = SourceForBinaryQuery.findSourceRoots2(archiveURL); - final FileObject[] resultRoots = result2.getRoots(); - assertTrue("There should be some roots", resultRoots.length > 0); + assertTrue("There should be some roots", !resultRoots.isEmpty()); Set expected = new HashSet<>(); for (FileObject ch : fo.getFileObject("src").getChildren()) { - if (ch.getNameExt().endsWith(".test")) { - // tests are not in graal-sdk.jar - continue; - } - if (ch.getNameExt().endsWith(".tck")) { - // TCK is not in graal-sdk.jar - continue; - } - if (ch.getNameExt().contains("org.graalvm.launcher")) { - // launcher is not in graal-sdk.jar + String name = ch.getNameExt(); + if (name.equals("org.graalvm.launcher.native") || name.equals("org.graalvm.toolchain.test")) { + // Not a Java code continue; } expected.add(ch); diff --git a/java/libs.springframework/external/binaries-list b/java/libs.springframework/external/binaries-list index 55f5e7f9261a..ae384bba6e05 100644 --- a/java/libs.springframework/external/binaries-list +++ b/java/libs.springframework/external/binaries-list @@ -15,65 +15,24 @@ # specific language governing permissions and limitations # under the License. -BF3BD91214A6D0B4C4DAEEFBE3FCF008D9E3A368 org.springframework:spring-aop:3.2.18.RELEASE -6DA09D3FFFB160DA4DCBFCB37F2C69841DC5880C org.springframework:spring-aspects:3.2.18.RELEASE -4C0BB7E1A69D650145E8E08A3BCC03A8BC3C453E org.springframework:spring-beans:3.2.18.RELEASE -E8DC9E1B55BFB6AD5AD49B358D5CA6E3D4CD7488 org.springframework:spring-context:3.2.18.RELEASE -04350E904118D340AC3BAB577A3CF1CE5E978BB2 org.springframework:spring-context-support:3.2.18.RELEASE -0E2BD9C162280CD79C2EA0F67F174EE5D7B84DDD org.springframework:spring-core:3.2.18.RELEASE -070C1FB9F2111601193E01A8D0C3CCBCA1BF3706 org.springframework:spring-expression:3.2.18.RELEASE -19E9E757AB89ABE73DC537BD23B7E2C7F43BA47C org.springframework:spring-instrument:3.2.18.RELEASE -42242449CF080B4681F3E17F9390CA1389A5823B org.springframework:spring-instrument-tomcat:3.2.18.RELEASE -FF23752B5D75C96FFA6B3EC5055CBC07ED8F0675 org.springframework:spring-jdbc:3.2.18.RELEASE -BD9D212D1501985448BDB42F35C15D87089BAC92 org.springframework:spring-jms:3.2.18.RELEASE -4A771498E04A81D107349CE717251558F8F24931 org.springframework:spring-orm:3.2.18.RELEASE -A1A8B9558B024D44C5CCDBE6523D4504C86AAC7A org.springframework:spring-oxm:3.2.18.RELEASE -BE7D91FE8416A30F53D1039ACEEA08A9AC4AC0DF org.springframework:spring-struts:3.2.18.RELEASE -93351AD841EB73899E2FA8F17F0F55F7346198C9 org.springframework:spring-test:3.2.18.RELEASE -FDD56C7F7AC4EE463BAE12DDCB2EDB0AFCCBDDE6 org.springframework:spring-tx:3.2.18.RELEASE -BC0BDADE0A7A52B8FAE88E1FEBC8479383A2ACAD org.springframework:spring-web:3.2.18.RELEASE -60E5BB3DC9CB83D6CC53628082EC89A57D4832B2 org.springframework:spring-webmvc:3.2.18.RELEASE -3A5C539FC312C386699CD78DA46C579B3C9A191D org.springframework:spring-webmvc-portlet:3.2.18.RELEASE - -27CB46A1F8D108E4383D36891597C70D8B245528 org.springframework:spring-aop:4.3.29.RELEASE -64CFC9F5A92C3446DE797872CB5072FE3C39CF65 org.springframework:spring-aspects:4.3.29.RELEASE -E9643898198ABE38ECD3660ABD217DB2157444ED org.springframework:spring-beans:4.3.29.RELEASE -A156035DB751AC097EBC4A6A0B329000E30F8213 org.springframework:spring-context:4.3.29.RELEASE -3357D1355BC2CD967E0A4D3C8C83F3B2D75FBA5C org.springframework:spring-context-support:4.3.29.RELEASE -363B3A551DB5C20C7872AA143E52CE8933374BA6 org.springframework:spring-core:4.3.29.RELEASE -48C9A0F167899119DC4685590B940442E2B932F4 org.springframework:spring-expression:4.3.29.RELEASE -7D74ED40E1E5C7B49634E9AD11C64701813BFACD org.springframework:spring-instrument:4.3.29.RELEASE -E28297AC3656E6F3FBB7DD699DC52CC7F01246F6 org.springframework:spring-instrument-tomcat:4.3.29.RELEASE -13260B278B849BB1B74BA0C7D5771BD3B1A29F13 org.springframework:spring-jdbc:4.3.29.RELEASE -12F90BA42016E297EF01434E2425537150543D50 org.springframework:spring-jms:4.3.29.RELEASE -DD73936EF2554ABDA9DB4128F80A4489CF0FAA0D org.springframework:spring-messaging:4.3.29.RELEASE -02A662C490E4D53B6C8DF2C74F3946B4D95A1E69 org.springframework:spring-orm:4.3.29.RELEASE -42145BE2D36D4C4FEB8132D66B878142803F8A28 org.springframework:spring-oxm:4.3.29.RELEASE -EA43AFE07BC5908B230CE8CE33AF51C82E6DE878 org.springframework:spring-test:4.3.29.RELEASE -5588F29200B2FA3748F7AD335F625F9744135A08 org.springframework:spring-tx:4.3.29.RELEASE -31BAABE32CE5EDF8B625F47A88FD402947BF9436 org.springframework:spring-web:4.3.29.RELEASE -41EA1DFC591F4378E315179CBD4A35C37C2D513D org.springframework:spring-webmvc:4.3.29.RELEASE -F532F0E38C1DEB2E92B76AF24233EC0E9579EEA8 org.springframework:spring-webmvc-portlet:4.3.29.RELEASE -E5264D0806F8465BACC283B23FE3D48A7743622B org.springframework:spring-websocket:4.3.29.RELEASE - -6AE14B8A11B4A30F22A15C8F97AC4B5D0979A4EF org.springframework:spring-aop:5.2.9.RELEASE -6726B662C862E8BF297C9251E7851FBC9FE01D84 org.springframework:spring-aspects:5.2.9.RELEASE -80E722FFA73A43459F639D36E25AA4E4A08D8D79 org.springframework:spring-beans:5.2.9.RELEASE -4003EF2DB8B5E4B22330FC6D67AAE7AC5D304319 org.springframework:spring-context:5.2.9.RELEASE -A63D4C78080BE31A4BB7B7451137119EB7C9BA0D org.springframework:spring-context-indexer:5.2.9.RELEASE -94038F11339F2A7394AA21B75F8D7B562019667E org.springframework:spring-context-support:5.2.9.RELEASE -400A6FDB45BFA5318AA7D06360F4495B75080BB5 org.springframework:spring-core:5.2.9.RELEASE -C8584DE306BE115EF1715B7ED9D50FB2802867AA org.springframework:spring-expression:5.2.9.RELEASE -7D258AA1A8BCE3501040016D49D244F217517863 org.springframework:spring-instrument:5.2.9.RELEASE -39777C3EEAF3D0957D9FDFFBB75E3FF8A89CAF62 org.springframework:spring-jcl:5.2.9.RELEASE -00877E892E80D3B92F24D70E1E4BDD386B2AA9A2 org.springframework:spring-jdbc:5.2.9.RELEASE -A3E6C6EB1D0D31F5DF62C19D64AEECEB21662F41 org.springframework:spring-jms:5.2.9.RELEASE -649BC39008EC725BA9FDC847AA68DB70ADC5E250 org.springframework:spring-messaging:5.2.9.RELEASE -E21A091F545E8A87ABD721AC5BB2B76431C9C0F2 org.springframework:spring-orm:5.2.9.RELEASE -D136374AB8E8965F7A7D7A516FA573036CE4E933 org.springframework:spring-oxm:5.2.9.RELEASE -CDCD16D9931EE1D9CBA35CA3C465521794C0B98A org.springframework:spring-test:5.2.9.RELEASE -6E7CC2FE50BEBF443F42B91001BD7D4D930AE7A1 org.springframework:spring-tx:5.2.9.RELEASE -4BC4A60B74EA0A92ED09D41C675F8426324B4E56 org.springframework:spring-web:5.2.9.RELEASE -C62F1230A10BDE828161379F16D31ED5051A46FE org.springframework:spring-webflux:5.2.9.RELEASE -BEC8682DF7622707F067F98457EE95A8F276DE80 org.springframework:spring-webmvc:5.2.9.RELEASE -27152843FE9B5F498C890F88C057817794484E60 org.springframework:spring-websocket:5.2.9.RELEASE +3BE929DBDB5F4516919AD09A3D3720D779BB65D9 org.springframework:spring-aop:5.3.31 +9BD8E781E08E1B02A78E867913B96BCCD2BC5798 org.springframework:spring-aspects:5.3.31 +D27258849071B3B268ECC388ECA35BBFCC586448 org.springframework:spring-beans:5.3.31 +A2D6E76507F037AD835E8C2288DFEDF28981999F org.springframework:spring-context:5.3.31 +45F6186340490A5DB5966798375C24835B5152FC org.springframework:spring-context-indexer:5.3.31 +1DCE4C0F8A8382A9107CE6A47E603F4A3EFA3301 org.springframework:spring-context-support:5.3.31 +368E76F732A3C331B970F69CAFEC1525D27B34D3 org.springframework:spring-core:5.3.31 +55637AF1B186D1008890980C2876C5FC83599756 org.springframework:spring-expression:5.3.31 +EA66DC7F38C94F0307DDD23D5A6667D368C004B8 org.springframework:spring-instrument:5.3.31 +E7AB9EE590A195415DD6B898440D776B4C8DB78C org.springframework:spring-jcl:5.3.31 +9124850A2E396A33E5DBD5D1E891E105DAC48633 org.springframework:spring-jdbc:5.3.31 +C0F41C70335786115036CC707B1629A78B7DFB09 org.springframework:spring-jms:5.3.31 +DB3BE10EEDDE60C3F237A4BC625A0C2A98445352 org.springframework:spring-messaging:5.3.31 +CB9B7AC171E680E3EAA2FB69E90A8595F8AA201B org.springframework:spring-orm:5.3.31 +EEC68C6788292F7FB46C02C8CD5AAF4FD241FC88 org.springframework:spring-oxm:5.3.31 +950FF61934D9709AD22FBB176EBCF0E0B80BB5CE org.springframework:spring-test:5.3.31 +143E79385354FC7FFD9773A31BA989931AD9E920 org.springframework:spring-tx:5.3.31 +3BF73C385A1F2F4A0D482149D6A205E854CEC497 org.springframework:spring-web:5.3.31 +D56917F2F1FA8CF6B2CEC4D62EFAE8DC495AA03D org.springframework:spring-webflux:5.3.31 +45754D056EFFE8257A012F6B98ED5454CF1E8960 org.springframework:spring-webmvc:5.3.31 +7AA3AE3FA2DD8A07E61B88A186D8E27F1A6C86D8 org.springframework:spring-websocket:5.3.31 diff --git a/java/libs.springframework/external/spring-framework-3.2.18.RELEASE-license.txt b/java/libs.springframework/external/spring-framework-3.2.18.RELEASE-license.txt deleted file mode 100644 index 2c488c84c3ce..000000000000 --- a/java/libs.springframework/external/spring-framework-3.2.18.RELEASE-license.txt +++ /dev/null @@ -1,287 +0,0 @@ -Name: Spring Framework -Description: Java/J2EE application framework -Version: 3.2.18.RELEASE -Origin: SpringSource -License: Apache-2.0-spring3 -Files: spring-aop-3.2.18.RELEASE.jar spring-aspects-3.2.18.RELEASE.jar spring-beans-3.2.18.RELEASE.jar spring-context-3.2.18.RELEASE.jar spring-context-support-3.2.18.RELEASE.jar spring-core-3.2.18.RELEASE.jar spring-expression-3.2.18.RELEASE.jar spring-instrument-3.2.18.RELEASE.jar spring-instrument-tomcat-3.2.18.RELEASE.jar spring-jdbc-3.2.18.RELEASE.jar spring-jms-3.2.18.RELEASE.jar spring-orm-3.2.18.RELEASE.jar spring-oxm-3.2.18.RELEASE.jar spring-struts-3.2.18.RELEASE.jar spring-test-3.2.18.RELEASE.jar spring-tx-3.2.18.RELEASE.jar spring-web-3.2.18.RELEASE.jar spring-webmvc-3.2.18.RELEASE.jar spring-webmvc-portlet-3.2.18.RELEASE.jar -URL: https://spring.io/projects/spring-framework - - 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. - -======================================================================= - -SPRING FRAMEWORK 3.2.18.RELEASE SUBCOMPONENTS: - -Spring Framework 3.2.18.RELEASE includes a number of subcomponents -with separate copyright notices and license terms. The product that -includes this file does not necessarily use all the open source -subcomponents referred to below. Your use of the source -code for these subcomponents is subject to the terms and -conditions of the following licenses. - - ->>> ASM 4.0 (org.ow2.asm:asm:4.0, org.ow2.asm:asm-commons:4.0): - -Copyright (c) 2000-2011 INRIA, France Telecom -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions -are met: - -1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - -2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - -3. Neither the name of the copyright holders nor the names of its - contributors may be used to endorse or promote products derived from - this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE -LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF -SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN -CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) -ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF -THE POSSIBILITY OF SUCH DAMAGE. - -Copyright (c) 1999-2009, OW2 Consortium - - ->>> CGLIB 3.0 (cglib:cglib:3.0): - -Per the LICENSE file in the CGLIB JAR distribution downloaded from -http://sourceforge.net/projects/cglib/files/cglib3/3.0/cglib-3.0.jar/download, -CGLIB 3.0 is licensed under the Apache License, version 2.0, the text of which -is included above. - - -======================================================================= - -To the extent any open source subcomponents are licensed under the EPL and/or -other similar licenses that require the source code and/or modifications to -source code to be made available (as would be noted above), you may obtain a -copy of the source code corresponding to the binaries for such open source -components and modifications thereto, if any, (the "Source Files"), by -downloading the Source Files from http://www.springsource.org/download, or by -sending a request, with your name and address to: - - Pivotal, Inc., 875 Howard St, - San Francisco, CA 94103 - United States of America - -or email info@gopivotal.com. All such requests should clearly specify: - - OPEN SOURCE FILES REQUEST - Attention General Counsel - -Pivotal shall mail a copy of the Source Files to you on a CD or equivalent -physical medium. This offer to obtain a copy of the Source Files is valid for -three years from the date you acquired this Software product. diff --git a/java/libs.springframework/external/spring-framework-3.2.18.RELEASE-notice.txt b/java/libs.springframework/external/spring-framework-3.2.18.RELEASE-notice.txt deleted file mode 100644 index e16ce3cb04a7..000000000000 --- a/java/libs.springframework/external/spring-framework-3.2.18.RELEASE-notice.txt +++ /dev/null @@ -1,2 +0,0 @@ -Spring Framework 3.2.18.RELEASE -Copyright (c) 2002-2016 Pivotal, Inc. diff --git a/java/libs.springframework/external/spring-framework-4.3.29.RELEASE-license.txt b/java/libs.springframework/external/spring-framework-4.3.29.RELEASE-license.txt deleted file mode 100644 index ed51a3c6eb07..000000000000 --- a/java/libs.springframework/external/spring-framework-4.3.29.RELEASE-license.txt +++ /dev/null @@ -1,297 +0,0 @@ -Name: Spring Framework -Description: Java/J2EE application framework -Version: 4.3.29.RELEASE -Origin: Spring -License: Apache-2.0-spring4 -Files: spring-aop-4.3.29.RELEASE.jar spring-aspects-4.3.29.RELEASE.jar spring-beans-4.3.29.RELEASE.jar spring-context-4.3.29.RELEASE.jar spring-context-support-4.3.29.RELEASE.jar spring-core-4.3.29.RELEASE.jar spring-expression-4.3.29.RELEASE.jar spring-instrument-4.3.29.RELEASE.jar spring-instrument-tomcat-4.3.29.RELEASE.jar spring-jdbc-4.3.29.RELEASE.jar spring-jms-4.3.29.RELEASE.jar spring-messaging-4.3.29.RELEASE.jar spring-orm-4.3.29.RELEASE.jar spring-oxm-4.3.29.RELEASE.jar spring-test-4.3.29.RELEASE.jar spring-tx-4.3.29.RELEASE.jar spring-web-4.3.29.RELEASE.jar spring-webmvc-4.3.29.RELEASE.jar spring-webmvc-portlet-4.3.29.RELEASE.jar spring-websocket-4.3.29.RELEASE.jar -URL: https://spring.io/projects/spring-framework - - Apache License - Version 2.0, January 2004 - https://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 - - https://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. - -======================================================================= - -SPRING FRAMEWORK 4.3.29.RELEASE SUBCOMPONENTS: - -Spring Framework 4.3.29.RELEASE includes a number of subcomponents -with separate copyright notices and license terms. The product that -includes this file does not necessarily use all the open source -subcomponents referred to below. Your use of the source -code for these subcomponents is subject to the terms and -conditions of the following licenses. - - ->>> ASM 6.0 (org.ow2.asm:asm:6.0, org.ow2.asm:asm-commons:6.0): - -Copyright (c) 2000-2011 INRIA, France Telecom -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions -are met: - -1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - -2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - -3. Neither the name of the copyright holders nor the names of its - contributors may be used to endorse or promote products derived from - this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE -LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF -SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN -CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) -ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF -THE POSSIBILITY OF SUCH DAMAGE. - -Copyright (c) 1999-2009, OW2 Consortium - - ->>> CGLIB 3.2.6 (cglib:cglib:3.2.6): - -Per the LICENSE file in the CGLIB JAR distribution downloaded from -https://github.com/cglib/cglib/releases/download/RELEASE_3_2_6/cglib-3.2.6.jar, -CGLIB 3.2.6 is licensed under the Apache License, version 2.0, the text of -which is included above. - - ->>> Objenesis 2.6 (org.objenesis:objenesis:2.6): - -Per the LICENSE file in the Objenesis ZIP distribution downloaded from -http://objenesis.org/download.html, Objenesis 2.6 is licensed under the -Apache License, version 2.0, the text of which is included above. - -Per the NOTICE file in the Objenesis ZIP distribution downloaded from -http://objenesis.org/download.html and corresponding to section 4d of the -Apache License, Version 2.0, in this case for Objenesis: - -Objenesis -Copyright 2006-2017 Joe Walnes, Henri Tremblay, Leonardo Mesquita - - -=============================================================================== - -To the extent any open source components are licensed under the EPL and/or -other similar licenses that require the source code and/or modifications to -source code to be made available (as would be noted above), you may obtain a -copy of the source code corresponding to the binaries for such open source -components and modifications thereto, if any, (the "Source Files"), by -downloading the Source Files from https://spring.io/projects, Pivotal's website -at https://network.pivotal.io/open-source, or by sending a request, with your -name and address to: Pivotal Software, Inc., 875 Howard Street, 5th floor, San -Francisco, CA 94103, Attention: General Counsel. All such requests should -clearly specify: OPEN SOURCE FILES REQUEST, Attention General Counsel. Pivotal -can mail a copy of the Source Files to you on a CD or equivalent physical -medium. - -This offer to obtain a copy of the Source Files is valid for three years from -the date you acquired this Software product. Alternatively, the Source Files -may accompany the Software. diff --git a/java/libs.springframework/external/spring-framework-4.3.29.RELEASE-notice.txt b/java/libs.springframework/external/spring-framework-4.3.29.RELEASE-notice.txt deleted file mode 100644 index ce57456bc092..000000000000 --- a/java/libs.springframework/external/spring-framework-4.3.29.RELEASE-notice.txt +++ /dev/null @@ -1,2 +0,0 @@ -Spring Framework 4.3.29.RELEASE -Copyright (c) 2002-2019 Pivotal, Inc. diff --git a/java/libs.springframework/external/spring-framework-5.2.9.RELEASE-license.txt b/java/libs.springframework/external/spring-framework-5.3.31-license.txt similarity index 93% rename from java/libs.springframework/external/spring-framework-5.2.9.RELEASE-license.txt rename to java/libs.springframework/external/spring-framework-5.3.31-license.txt index da57edaffc0e..bc7cb5454078 100644 --- a/java/libs.springframework/external/spring-framework-5.2.9.RELEASE-license.txt +++ b/java/libs.springframework/external/spring-framework-5.3.31-license.txt @@ -1,9 +1,9 @@ Name: Spring Framework Description: Java/J2EE application framework -Version: 5.2.9.RELEASE +Version: 5.3.31 Origin: Spring License: Apache-2.0-spring5 -Files: spring-instrument-5.2.9.RELEASE.jar spring-context-support-5.2.9.RELEASE.jar spring-context-indexer-5.2.9.RELEASE.jar spring-jms-5.2.9.RELEASE.jar spring-beans-5.2.9.RELEASE.jar spring-webmvc-5.2.9.RELEASE.jar spring-expression-5.2.9.RELEASE.jar spring-context-5.2.9.RELEASE.jar spring-orm-5.2.9.RELEASE.jar spring-core-5.2.9.RELEASE.jar spring-aspects-5.2.9.RELEASE.jar spring-websocket-5.2.9.RELEASE.jar spring-tx-5.2.9.RELEASE.jar spring-jdbc-5.2.9.RELEASE.jar spring-webflux-5.2.9.RELEASE.jar spring-jcl-5.2.9.RELEASE.jar spring-oxm-5.2.9.RELEASE.jar spring-messaging-5.2.9.RELEASE.jar spring-aop-5.2.9.RELEASE.jar spring-web-5.2.9.RELEASE.jar spring-test-5.2.9.RELEASE.jar +Files: spring-instrument-5.3.31.jar spring-context-support-5.3.31.jar spring-context-indexer-5.3.31.jar spring-jms-5.3.31.jar spring-beans-5.3.31.jar spring-webmvc-5.3.31.jar spring-expression-5.3.31.jar spring-context-5.3.31.jar spring-orm-5.3.31.jar spring-core-5.3.31.jar spring-aspects-5.3.31.jar spring-websocket-5.3.31.jar spring-tx-5.3.31.jar spring-jdbc-5.3.31.jar spring-webflux-5.3.31.jar spring-jcl-5.3.31.jar spring-oxm-5.3.31.jar spring-messaging-5.3.31.jar spring-aop-5.3.31.jar spring-web-5.3.31.jar spring-test-5.3.31.jar URL: https://spring.io/projects/spring-framework Apache License @@ -210,9 +210,9 @@ URL: https://spring.io/projects/spring-framework ======================================================================= -SPRING FRAMEWORK 5.2.9.RELEASE SUBCOMPONENTS: +SPRING FRAMEWORK 5.3.31 SUBCOMPONENTS: -Spring Framework 5.2.9.RELEASE includes a number of subcomponents +Spring Framework 5.3.31 includes a number of subcomponents with separate copyright notices and license terms. The product that includes this file does not necessarily use all the open source subcomponents referred to below. Your use of the source @@ -220,7 +220,7 @@ code for these subcomponents is subject to the terms and conditions of the following licenses. ->>> ASM 7.1 (org.ow2.asm:asm:7.1, org.ow2.asm:asm-commons:7.1): +>>> ASM 9.1 (org.ow2.asm:asm:9.1, org.ow2.asm:asm-commons:9.1): Copyright (c) 2000-2011 INRIA, France Telecom All rights reserved. @@ -263,10 +263,10 @@ CGLIB 3.3 is licensed under the Apache License, version 2.0, the text of which is included above. ->>> Objenesis 3.1 (org.objenesis:objenesis:3.1): +>>> Objenesis 3.2 (org.objenesis:objenesis:3.2): Per the LICENSE file in the Objenesis ZIP distribution downloaded from -http://objenesis.org/download.html, Objenesis 3.1 is licensed under the +http://objenesis.org/download.html, Objenesis 3.2 is licensed under the Apache License, version 2.0, the text of which is included above. Per the NOTICE file in the Objenesis ZIP distribution downloaded from diff --git a/java/libs.springframework/external/spring-framework-5.2.9.RELEASE-notice.txt b/java/libs.springframework/external/spring-framework-5.3.31-notice.txt similarity index 55% rename from java/libs.springframework/external/spring-framework-5.2.9.RELEASE-notice.txt rename to java/libs.springframework/external/spring-framework-5.3.31-notice.txt index ebbdfde67b8c..f6a717214c8a 100644 --- a/java/libs.springframework/external/spring-framework-5.2.9.RELEASE-notice.txt +++ b/java/libs.springframework/external/spring-framework-5.3.31-notice.txt @@ -1,2 +1,2 @@ -Spring Framework 5.2.9.RELEASE +Spring Framework 5.3.31 Copyright (c) 2002-2019 Pivotal, Inc. diff --git a/java/libs.springframework/nbproject/project.properties b/java/libs.springframework/nbproject/project.properties index 7a7f64b348c5..44b3f481e81e 100644 --- a/java/libs.springframework/nbproject/project.properties +++ b/java/libs.springframework/nbproject/project.properties @@ -22,130 +22,49 @@ is.autoload=true module.jar.verifylinkageignores=org((\.apache\.commons\.logging\.impl)|(\.springframework)).* -# Spring 3.2.18 -release.external/spring-aop-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-aop-3.2.18.RELEASE.jar -release.external/spring-aspects-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-aspects-3.2.18.RELEASE.jar -release.external/spring-beans-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-beans-3.2.18.RELEASE.jar -release.external/spring-context-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-context-3.2.18.RELEASE.jar -release.external/spring-context-support-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-context-support-3.2.18.RELEASE.jar -release.external/spring-core-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-core-3.2.18.RELEASE.jar -release.external/spring-expression-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-expression-3.2.18.RELEASE.jar -release.external/spring-instrument-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-instrument-3.2.18.RELEASE.jar -release.external/spring-instrument-tomcat-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-instrument-tomcat-3.2.18.RELEASE.jar -release.external/spring-jdbc-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-jdbc-3.2.18.RELEASE.jar -release.external/spring-jms-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-jms-3.2.18.RELEASE.jar -release.external/spring-orm-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-orm-3.2.18.RELEASE.jar -release.external/spring-oxm-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-oxm-3.2.18.RELEASE.jar -release.external/spring-struts-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-struts-3.2.18.RELEASE.jar -release.external/spring-test-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-test-3.2.18.RELEASE.jar -release.external/spring-tx-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-tx-3.2.18.RELEASE.jar -release.external/spring-web-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-web-3.2.18.RELEASE.jar -release.external/spring-webmvc-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-webmvc-3.2.18.RELEASE.jar -release.external/spring-webmvc-portlet-3.2.18.RELEASE.jar=modules/ext/spring-3.0/spring-webmvc-portlet-3.2.18.RELEASE.jar - -# Spring 4.3.25 -release.external/spring-aop-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-aop-4.3.29.RELEASE.jar -release.external/spring-aspects-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-aspects-4.3.29.RELEASE.jar -release.external/spring-beans-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-beans-4.3.29.RELEASE.jar -release.external/spring-context-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-context-4.3.29.RELEASE.jar -release.external/spring-context-support-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-context-support-4.3.29.RELEASE.jar -release.external/spring-core-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-core-4.3.29.RELEASE.jar -release.external/spring-expression-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-expression-4.3.29.RELEASE.jar -release.external/spring-instrument-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-instrument-4.3.29.RELEASE.jar -release.external/spring-instrument-tomcat-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-instrument-tomcat-4.3.29.RELEASE.jar -release.external/spring-jdbc-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-jdbc-4.3.29.RELEASE.jar -release.external/spring-jms-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-jms-4.3.29.RELEASE.jar -release.external/spring-messaging-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-messaging-4.3.29.RELEASE.jar -release.external/spring-orm-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-orm-4.3.29.RELEASE.jar -release.external/spring-oxm-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-oxm-4.3.29.RELEASE.jar -release.external/spring-test-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-test-4.3.29.RELEASE.jar -release.external/spring-tx-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-tx-4.3.29.RELEASE.jar -release.external/spring-web-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-web-4.3.29.RELEASE.jar -release.external/spring-webmvc-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-webmvc-4.3.29.RELEASE.jar -release.external/spring-webmvc-portlet-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-webmvc-portlet-4.3.29.RELEASE.jar -release.external/spring-websocket-4.3.29.RELEASE.jar=modules/ext/spring-4/spring-websocket-4.3.29.RELEASE.jar # Spring 5.2.9 -release.external/spring-aop-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-aop-5.2.9.RELEASE.jar -release.external/spring-aspects-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-aspects-5.2.9.RELEASE.jar -release.external/spring-beans-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-beans-5.2.9.RELEASE.jar -release.external/spring-context-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-context-5.2.9.RELEASE.jar -release.external/spring-context-indexer-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-context-indexer-5.2.9.RELEASE.jar -release.external/spring-context-support-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-context-support-5.2.9.RELEASE.jar -release.external/spring-core-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-core-5.2.9.RELEASE.jar -release.external/spring-expression-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-expression-5.2.9.RELEASE.jar -release.external/spring-instrument-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-instrument-5.2.9.RELEASE.jar -release.external/spring-jcl-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-jcl-5.2.9.RELEASE.jar -release.external/spring-jdbc-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-jdbc-5.2.9.RELEASE.jar -release.external/spring-jms-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-jms-5.2.9.RELEASE.jar -release.external/spring-messaging-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-messaging-5.2.9.RELEASE.jar -release.external/spring-orm-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-orm-5.2.9.RELEASE.jar -release.external/spring-oxm-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-oxm-5.2.9.RELEASE.jar -release.external/spring-test-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-test-5.2.9.RELEASE.jar -release.external/spring-tx-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-tx-5.2.9.RELEASE.jar -release.external/spring-web-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-web-5.2.9.RELEASE.jar -release.external/spring-webflux-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-webflux-5.2.9.RELEASE.jar -release.external/spring-webmvc-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-webmvc-5.2.9.RELEASE.jar -release.external/spring-websocket-5.2.9.RELEASE.jar=modules/ext/spring-5/spring-websocket-5.2.9.RELEASE.jar +release.external/spring-aop-5.3.31.jar=modules/ext/spring-5/spring-aop-5.3.31.jar +release.external/spring-aspects-5.3.31.jar=modules/ext/spring-5/spring-aspects-5.3.31.jar +release.external/spring-beans-5.3.31.jar=modules/ext/spring-5/spring-beans-5.3.31.jar +release.external/spring-context-5.3.31.jar=modules/ext/spring-5/spring-context-5.3.31.jar +release.external/spring-context-indexer-5.3.31.jar=modules/ext/spring-5/spring-context-indexer-5.3.31.jar +release.external/spring-context-support-5.3.31.jar=modules/ext/spring-5/spring-context-support-5.3.31.jar +release.external/spring-core-5.3.31.jar=modules/ext/spring-5/spring-core-5.3.31.jar +release.external/spring-expression-5.3.31.jar=modules/ext/spring-5/spring-expression-5.3.31.jar +release.external/spring-instrument-5.3.31.jar=modules/ext/spring-5/spring-instrument-5.3.31.jar +release.external/spring-jcl-5.3.31.jar=modules/ext/spring-5/spring-jcl-5.3.31.jar +release.external/spring-jdbc-5.3.31.jar=modules/ext/spring-5/spring-jdbc-5.3.31.jar +release.external/spring-jms-5.3.31.jar=modules/ext/spring-5/spring-jms-5.3.31.jar +release.external/spring-messaging-5.3.31.jar=modules/ext/spring-5/spring-messaging-5.3.31.jar +release.external/spring-orm-5.3.31.jar=modules/ext/spring-5/spring-orm-5.3.31.jar +release.external/spring-oxm-5.3.31.jar=modules/ext/spring-5/spring-oxm-5.3.31.jar +release.external/spring-test-5.3.31.jar=modules/ext/spring-5/spring-test-5.3.31.jar +release.external/spring-tx-5.3.31.jar=modules/ext/spring-5/spring-tx-5.3.31.jar +release.external/spring-web-5.3.31.jar=modules/ext/spring-5/spring-web-5.3.31.jar +release.external/spring-webflux-5.3.31.jar=modules/ext/spring-5/spring-webflux-5.3.31.jar +release.external/spring-webmvc-5.3.31.jar=modules/ext/spring-5/spring-webmvc-5.3.31.jar +release.external/spring-websocket-5.3.31.jar=modules/ext/spring-5/spring-websocket-5.3.31.jar jnlp.indirect.jars=\ - modules/ext/spring-3.0/spring-aop-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-aspects-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-beans-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-context-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-context-support-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-core-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-expression-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-instrument-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-instrument-tomcat-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-jdbc-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-jms-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-orm-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-oxm-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-struts-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-test-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-tx-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-web-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-webmvc-3.2.18.RELEASE.jar,\ - modules/ext/spring-3.0/spring-webmvc-portlet-3.2.18.RELEASE.jar,\ - modules/ext/spring-4/spring-aop-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-aspects-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-beans-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-context-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-context-support-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-core-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-expression-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-instrument-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-instrument-tomcat-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-jdbc-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-jms-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-messaging-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-orm-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-oxm-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-test-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-tx-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-web-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-webmvc-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-webmvc-portlet-4.3.29.RELEASE.jar,\ - modules/ext/spring-4/spring-websocket-4.3.29.RELEASE.jar,\ - modules/ext/spring-5/spring-aop-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-aspects-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-beans-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-context-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-context-indexer-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-context-support-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-core-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-expression-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-instrument-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-jcl-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-jdbc-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-jms-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-messaging-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-orm-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-oxm-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-test-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-tx-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-web-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-webflux-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-webmvc-5.2.9.RELEASE.jar,\ - modules/ext/spring-5/spring-websocket-5.2.9.RELEASE.jar + modules/ext/spring-5/spring-aop-5.3.31.jar,\ + modules/ext/spring-5/spring-aspects-5.3.31.jar,\ + modules/ext/spring-5/spring-beans-5.3.31.jar,\ + modules/ext/spring-5/spring-context-5.3.31.jar,\ + modules/ext/spring-5/spring-context-indexer-5.3.31.jar,\ + modules/ext/spring-5/spring-context-support-5.3.31.jar,\ + modules/ext/spring-5/spring-core-5.3.31.jar,\ + modules/ext/spring-5/spring-expression-5.3.31.jar,\ + modules/ext/spring-5/spring-instrument-5.3.31.jar,\ + modules/ext/spring-5/spring-jcl-5.3.31.jar,\ + modules/ext/spring-5/spring-jdbc-5.3.31.jar,\ + modules/ext/spring-5/spring-jms-5.3.31.jar,\ + modules/ext/spring-5/spring-messaging-5.3.31.jar,\ + modules/ext/spring-5/spring-orm-5.3.31.jar,\ + modules/ext/spring-5/spring-oxm-5.3.31.jar,\ + modules/ext/spring-5/spring-test-5.3.31.jar,\ + modules/ext/spring-5/spring-tx-5.3.31.jar,\ + modules/ext/spring-5/spring-web-5.3.31.jar,\ + modules/ext/spring-5/spring-webflux-5.3.31.jar,\ + modules/ext/spring-5/spring-webmvc-5.3.31.jar,\ + modules/ext/spring-5/spring-websocket-5.3.31.jar diff --git a/java/libs.springframework/src/org/netbeans/libs/springframework/Bundle.properties b/java/libs.springframework/src/org/netbeans/libs/springframework/Bundle.properties index e885cc9062d3..3e448bc0a823 100644 --- a/java/libs.springframework/src/org/netbeans/libs/springframework/Bundle.properties +++ b/java/libs.springframework/src/org/netbeans/libs/springframework/Bundle.properties @@ -19,9 +19,7 @@ OpenIDE-Module-Name=Spring Framework Library OpenIDE-Module-Display-Category=Libraries OpenIDE-Module-Short-Description=Bundles the Spring Framework. OpenIDE-Module-Long-Description=\ - The module bundles the Spring Framework http://www.springframework.org/ \ + The module bundles the Spring Framework https://spring.io/ \ and integrates it into NetBeans. -spring-framework300=Spring Framework 3.2.18 -spring-framework400=Spring Framework 4.3.29 -spring-framework500=Spring Framework 5.2.9 +spring-framework500=Spring Framework 5.3.31 diff --git a/java/libs.springframework/src/org/netbeans/libs/springframework/layer.xml b/java/libs.springframework/src/org/netbeans/libs/springframework/layer.xml index 792a36a6f153..360e8a99bd0c 100644 --- a/java/libs.springframework/src/org/netbeans/libs/springframework/layer.xml +++ b/java/libs.springframework/src/org/netbeans/libs/springframework/layer.xml @@ -23,12 +23,6 @@ - - - - - - diff --git a/java/libs.springframework/src/org/netbeans/libs/springframework/spring-framework300.xml b/java/libs.springframework/src/org/netbeans/libs/springframework/spring-framework300.xml deleted file mode 100644 index fd8f4b60a0dd..000000000000 --- a/java/libs.springframework/src/org/netbeans/libs/springframework/spring-framework300.xml +++ /dev/null @@ -1,85 +0,0 @@ - - - - spring-framework300 - j2se - org.netbeans.libs.springframework.Bundle - - classpath - jar:nbinst://org.apache.commons.logging/modules/org-apache-commons-logging.jar!/ - jar:nbinst://org.netbeans.libs.cglib/modules/ext/cglib-2.2.jar!/ - - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-aop-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-aspects-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-beans-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-context-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-context-support-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-core-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-expression-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-instrument-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-instrument-tomcat-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-jdbc-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-jms-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-orm-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-oxm-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-struts-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-test-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-tx-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-web-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-webmvc-3.2.18.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-3.0/spring-webmvc-portlet-3.2.18.RELEASE.jar!/ - - - src - - - javadoc - - - - - maven-dependencies - - org.springframework:spring-aop:3.2.18.RELEASE:jar - org.springframework:spring-aspects:3.2.18.RELEASE:jar - org.springframework:spring-beans:3.2.18.RELEASE:jar - org.springframework:spring-context:3.2.18.RELEASE:jar - org.springframework:spring-context-support:3.2.18.RELEASE:jar - org.springframework:spring-core:3.2.18.RELEASE:jar - org.springframework:spring-expression:3.2.18.RELEASE:jar - org.springframework:spring-framework-bom:3.2.18.RELEASE:pom - org.springframework:spring-instrument:3.2.18.RELEASE:jar - org.springframework:spring-instrument-tomcat:3.2.18.RELEASE:jar - org.springframework:spring-jdbc:3.2.18.RELEASE:jar - org.springframework:spring-jms:3.2.18.RELEASE:jar - org.springframework:spring-orm:3.2.18.RELEASE:jar - org.springframework:spring-oxm:3.2.18.RELEASE:jar - org.springframework:spring-struts:3.2.18.RELEASE:jar - org.springframework:spring-test:3.2.18.RELEASE:jar - org.springframework:spring-tx:3.2.18.RELEASE:jar - org.springframework:spring-web:3.2.18.RELEASE:jar - org.springframework:spring-webmvc:3.2.18.RELEASE:jar - org.springframework:spring-webmvc-portlet:3.2.18.RELEASE:jar - - - - diff --git a/java/libs.springframework/src/org/netbeans/libs/springframework/spring-framework400.xml b/java/libs.springframework/src/org/netbeans/libs/springframework/spring-framework400.xml deleted file mode 100644 index 6d9144410309..000000000000 --- a/java/libs.springframework/src/org/netbeans/libs/springframework/spring-framework400.xml +++ /dev/null @@ -1,87 +0,0 @@ - - - - spring-framework400 - j2se - org.netbeans.libs.springframework.Bundle - - classpath - jar:nbinst://org.apache.commons.logging/modules/org-apache-commons-logging.jar!/ - jar:nbinst://org.netbeans.libs.cglib/modules/ext/cglib-2.2.jar!/ - - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-aop-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-aspects-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-beans-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-context-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-context-support-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-core-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-expression-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-instrument-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-instrument-tomcat-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-jdbc-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-jms-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-messaging-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-orm-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-oxm-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-test-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-tx-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-web-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-webmvc-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-webmvc-portlet-4.3.29.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-4/spring-websocket-4.3.29.RELEASE.jar!/ - - - src - - - javadoc - - - - - maven-dependencies - - org.springframework:spring-aop:4.3.29.RELEASE:jar - org.springframework:spring-aspects:4.3.29.RELEASE:jar - org.springframework:spring-beans:4.3.29.RELEASE:jar - org.springframework:spring-context:4.3.29.RELEASE:jar - org.springframework:spring-context-support:4.3.29.RELEASE:jar - org.springframework:spring-core:4.3.29.RELEASE:jar - org.springframework:spring-expression:4.3.29.RELEASE:jar - org.springframework:spring-framework-bom:4.3.29.RELEASE:pom - org.springframework:spring-instrument:4.3.29.RELEASE:jar - org.springframework:spring-instrument-tomcat:4.3.29.RELEASE:jar - org.springframework:spring-jdbc:4.3.29.RELEASE:jar - org.springframework:spring-jms:4.3.29.RELEASE:jar - org.springframework:spring-messaging:4.3.29.RELEASE:jar - org.springframework:spring-orm:4.3.29.RELEASE:jar - org.springframework:spring-oxm:4.3.29.RELEASE:jar - org.springframework:spring-test:4.3.29.RELEASE:jar - org.springframework:spring-tx:4.3.29.RELEASE:jar - org.springframework:spring-web:4.3.29.RELEASE:jar - org.springframework:spring-webmvc:4.3.29.RELEASE:jar - org.springframework:spring-webmvc-portlet:4.3.29.RELEASE:jar - org.springframework:spring-websocket:4.3.29.RELEASE:jar - - - - diff --git a/java/libs.springframework/src/org/netbeans/libs/springframework/spring-framework500.xml b/java/libs.springframework/src/org/netbeans/libs/springframework/spring-framework500.xml index 8b36204bd1d6..9a031668ccbe 100644 --- a/java/libs.springframework/src/org/netbeans/libs/springframework/spring-framework500.xml +++ b/java/libs.springframework/src/org/netbeans/libs/springframework/spring-framework500.xml @@ -27,27 +27,27 @@ classpath jar:nbinst://org.apache.commons.logging/modules/org-apache-commons-logging.jar!/ jar:nbinst://org.netbeans.libs.cglib/modules/ext/cglib-2.2.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-aop-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-aspects-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-beans-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-context-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-context-indexer-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-context-support-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-core-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-expression-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-instrument-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-jcl-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-jdbc-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-jms-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-messaging-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-orm-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-oxm-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-test-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-tx-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-web-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-webflux-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-webmvc-5.2.9.RELEASE.jar!/ - jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-websocket-5.2.9.RELEASE.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-aop-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-aspects-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-beans-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-context-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-context-indexer-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-context-support-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-core-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-expression-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-instrument-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-jcl-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-jdbc-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-jms-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-messaging-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-orm-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-oxm-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-test-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-tx-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-web-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-webflux-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-webmvc-5.3.31.jar!/ + jar:nbinst://org.netbeans.libs.springframework/modules/ext/spring-5/spring-websocket-5.3.31.jar!/ src @@ -59,28 +59,28 @@ maven-dependencies - org.springframework:spring-aop:5.2.9.RELEASE:jar - org.springframework:spring-aspects:5.2.9.RELEASE:jar - org.springframework:spring-beans:5.2.9.RELEASE:jar - org.springframework:spring-context:5.2.9.RELEASE:jar - org.springframework:spring-context-indexer:5.2.9.RELEASE:jar - org.springframework:spring-context-support:5.2.9.RELEASE:jar - org.springframework:spring-core:5.2.9.RELEASE:jar - org.springframework:spring-expression:5.2.9.RELEASE:jar - org.springframework:spring-framework-bom:5.2.9.RELEASE:pom - org.springframework:spring-instrument:5.2.9.RELEASE:jar - org.springframework:spring-jcl:5.2.9.RELEASE:jar - org.springframework:spring-jdbc:5.2.9.RELEASE:jar - org.springframework:spring-jms:5.2.9.RELEASE:jar - org.springframework:spring-messaging:5.2.9.RELEASE:jar - org.springframework:spring-orm:5.2.9.RELEASE:jar - org.springframework:spring-oxm:5.2.9.RELEASE:jar - org.springframework:spring-test:5.2.9.RELEASE:jar - org.springframework:spring-tx:5.2.9.RELEASE:jar - org.springframework:spring-web:5.2.9.RELEASE:jar - org.springframework:spring-webflux:5.2.9.RELEASE:jar - org.springframework:spring-webmvc:5.2.9.RELEASE:jar - org.springframework:spring-websocket:5.2.9.RELEASE:jar + org.springframework:spring-aop:5.3.31:jar + org.springframework:spring-aspects:5.3.31:jar + org.springframework:spring-beans:5.3.31:jar + org.springframework:spring-context:5.3.31:jar + org.springframework:spring-context-indexer:5.3.31:jar + org.springframework:spring-context-support:5.3.31:jar + org.springframework:spring-core:5.3.31:jar + org.springframework:spring-expression:5.3.31:jar + org.springframework:spring-framework-bom:5.3.31:pom + org.springframework:spring-instrument:5.3.31:jar + org.springframework:spring-jcl:5.3.31:jar + org.springframework:spring-jdbc:5.3.31:jar + org.springframework:spring-jms:5.3.31:jar + org.springframework:spring-messaging:5.3.31:jar + org.springframework:spring-orm:5.3.31:jar + org.springframework:spring-oxm:5.3.31:jar + org.springframework:spring-test:5.3.31:jar + org.springframework:spring-tx:5.3.31:jar + org.springframework:spring-web:5.3.31:jar + org.springframework:spring-webflux:5.3.31:jar + org.springframework:spring-webmvc:5.3.31:jar + org.springframework:spring-websocket:5.3.31:jar diff --git a/java/maven/src/org/netbeans/modules/maven/NbMavenProjectImpl.java b/java/maven/src/org/netbeans/modules/maven/NbMavenProjectImpl.java index 298b3505d1ab..add5d3184815 100644 --- a/java/maven/src/org/netbeans/modules/maven/NbMavenProjectImpl.java +++ b/java/maven/src/org/netbeans/modules/maven/NbMavenProjectImpl.java @@ -313,10 +313,11 @@ public String getHintJavaPlatform() { public @NonNull MavenProject loadMavenProject(MavenEmbedder embedder, List activeProfiles, Properties properties) { ProjectActionContext.Builder b = ProjectActionContext.newBuilder(this). withProfiles(activeProfiles); - for (String pn : properties.stringPropertyNames()) { - b.withProperty(pn, properties.getProperty(pn)); + if (properties != null) { + for (String pn : properties.stringPropertyNames()) { + b.withProperty(pn, properties.getProperty(pn)); + } } - return MavenProjectCache.loadMavenProject(projectFile, b.context(), null); /* diff --git a/java/spring.beans/nbproject/project.properties b/java/spring.beans/nbproject/project.properties index 0eb7832031da..abc32736e74f 100644 --- a/java/spring.beans/nbproject/project.properties +++ b/java/spring.beans/nbproject/project.properties @@ -19,6 +19,7 @@ javac.source=1.8 javac.compilerargs=-Xlint -Xlint:-serial spec.version.base=1.64.0 +#for SpringModelAnnotationsTest requires.nb.javac=true test.config.stableBTD.includes=**/*Test.class @@ -26,4 +27,4 @@ test.config.stableBTD.excludes=\ **/SpringConfigFileModelControllerTest.class # Spring API classes -test.unit.cp.extra=${libs.springframework.dir}/modules/ext/spring-3.0/spring-context-3.2.18.RELEASE.jar +test.unit.cp.extra=${libs.springframework.dir}/modules/ext/spring-5/spring-context-5.3.31.jar diff --git a/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/Bundle.properties b/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/Bundle.properties index bc4a0eb8a5c2..fdf5547454c4 100644 --- a/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/Bundle.properties +++ b/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/Bundle.properties @@ -25,14 +25,11 @@ OpenIDE-Module-Short-Description=Declares NetBeans autoupdate centers. Services/AutoupdateType/distribution-update-provider.instance=NetBeans Distribution Services/AutoupdateType/pluginportal-update-provider.instance=NetBeans Plugin Portal -Services/AutoupdateType/82pluginportal-update-provider.instance=NetBeans 8.2 Plugin Portal #NOI18N URL_Distribution=@@metabuild.DistributionURL@@ #NOI18N URL_PluginPortal=@@metabuild.PluginPortalURL@@ -#NOI18N -URL_82PluginPortal=http://updates.netbeans.org/netbeans/updates/8.2/uc/final/distribution/catalog.xml.gz 3rdparty=Third Party Libraries #NOI18N diff --git a/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/NetBeansClusterCreator.java b/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/NetBeansClusterCreator.java index 7a7949df5131..ae4917e79f92 100644 --- a/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/NetBeansClusterCreator.java +++ b/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/NetBeansClusterCreator.java @@ -45,86 +45,65 @@ @ServiceProvider(service=AutoupdateClusterCreator.class) public final class NetBeansClusterCreator extends AutoupdateClusterCreator { protected @Override File findCluster(String clusterName) { - AtomicReference parent = new AtomicReference(); - File conf = findConf(parent, new ArrayList()); + AtomicReference parent = new AtomicReference<>(); + File conf = findConf(parent, new ArrayList<>()); return conf != null && conf.isFile() && canWrite (conf) ? new File(parent.get(), clusterName) : null; } private static File findConf(AtomicReference parent, List clusters) { String nbdirs = System.getProperty("netbeans.dirs"); if (nbdirs != null) { - StringTokenizer tok = new StringTokenizer(nbdirs, File.pathSeparator); // NOI18N - while (tok.hasMoreElements()) { - File cluster = new File(tok.nextToken()); - clusters.add(cluster); - if (!cluster.exists()) { - continue; - } - - - - if (parent.get() == null) { - parent.set(cluster.getParentFile()); - } - - if (!parent.get().equals(cluster.getParentFile())) { - // we can handle only case when all clusters are in - // the same directory these days - return null; + StringTokenizer tok = new StringTokenizer(nbdirs, File.pathSeparator); // NOI18N + while (tok.hasMoreElements()) { + File cluster = new File(tok.nextToken()); + clusters.add(cluster); + if (!cluster.exists()) { + continue; + } + if (parent.get() == null) { + parent.set(cluster.getParentFile()); + } + if (!parent.get().equals(cluster.getParentFile())) { + // we can handle only case when all clusters are in + // the same directory these days + return null; + } } } - } return new File(new File(parent.get(), "etc"), "netbeans.clusters"); } protected @Override File[] registerCluster(String clusterName, File cluster) throws IOException { - AtomicReference parent = new AtomicReference(); - List clusters = new ArrayList(); + AtomicReference parent = new AtomicReference<>(); + List clusters = new ArrayList<>(); File conf = findConf(parent, clusters); assert conf != null; clusters.add(cluster); Properties p = new Properties(); - InputStream is = new FileInputStream(conf); - try{ + try(InputStream is = new FileInputStream(conf)) { p.load(is); - } finally { - is.close(); } if (!p.containsKey(clusterName)) { - OutputStream os = new FileOutputStream(conf, true); - try { + try (OutputStream os = new FileOutputStream(conf, true)) { os.write('\n'); os.write(clusterName.getBytes()); os.write('\n'); - } finally { - os.close(); } } return clusters.toArray(new File[0]); } public static boolean canWrite (File f) { - // workaround the bug: http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4420020 + // workaround the bug: https://bugs.openjdk.org/browse/JDK-4420020 if (Utilities.isWindows ()) { - FileWriter fw = null; - try { - fw = new FileWriter (f, true); + try (FileWriter fw = new FileWriter(f, true)) { Logger.getLogger(NetBeansClusterCreator.class.getName()).log(Level.FINE, "{0} has write permission", f); + return true; } catch (IOException ioe) { - // just check of write permission Logger.getLogger (NetBeansClusterCreator.class.getName ()).log (Level.FINE, f + " has no write permission", ioe); return false; - } finally { - try { - if (fw != null) { - fw.close (); - } - } catch (IOException ex) { - Logger.getLogger (NetBeansClusterCreator.class.getName ()).log (Level.INFO, ex.getLocalizedMessage (), ex); - } } - return true; } else { return f.canWrite (); } diff --git a/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/NetBeansKeyStoreProvider.java b/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/NetBeansKeyStoreProvider.java index c14e0332e790..c34f760d40d1 100644 --- a/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/NetBeansKeyStoreProvider.java +++ b/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/NetBeansKeyStoreProvider.java @@ -21,7 +21,6 @@ import java.io.File; import java.io.FileInputStream; -import java.io.IOException; import java.io.InputStream; import java.security.KeyStore; import java.util.logging.Level; @@ -39,6 +38,7 @@ public final class NetBeansKeyStoreProvider implements KeyStoreProvider { public static final String KS_FILE_PATH = "core/ide.ks"; private static final String KS_DEFAULT_PASSWORD = "open4all"; + @Override public KeyStore getKeyStore() { return getKeyStore (getKeyStoreFile (), getPassword ()); } @@ -54,28 +54,17 @@ private static File getKeyStoreFile () { * @param password */ private static KeyStore getKeyStore(File file, String password) { - if (file == null) return null; - KeyStore keyStore = null; - InputStream is = null; - - try { - - is = new FileInputStream (file); - - keyStore = KeyStore.getInstance (KeyStore.getDefaultType ()); - keyStore.load (is, password.toCharArray ()); - + if (file == null) { + return null; + } + try (InputStream is = new FileInputStream(file)) { + KeyStore keyStore = KeyStore.getInstance (KeyStore.getDefaultType()); + keyStore.load (is, password.toCharArray()); + return keyStore; } catch (Exception ex) { Logger.getLogger ("global").log (Level.INFO, ex.getMessage (), ex); - } finally { - try { - if (is != null) is.close (); - } catch (IOException ex) { - assert false : ex; - } } - - return keyStore; + return null; } private static String getPassword () { diff --git a/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/mf-layer.xml b/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/mf-layer.xml index bacad2f70e49..5e3480434110 100644 --- a/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/mf-layer.xml +++ b/nb/updatecenters/src/org/netbeans/modules/updatecenters/resources/mf-layer.xml @@ -45,16 +45,6 @@ - - - - - - - - - - diff --git a/nbbuild/jdk.xml b/nbbuild/jdk.xml index b09b36a9d306..c47694ecaedd 100644 --- a/nbbuild/jdk.xml +++ b/nbbuild/jdk.xml @@ -210,10 +210,10 @@ - + - + diff --git a/nbbuild/jms-config/desktop.flags b/nbbuild/jms-config/desktop.flags index 711ccf55a9ac..e10c5f1446bf 100644 --- a/nbbuild/jms-config/desktop.flags +++ b/nbbuild/jms-config/desktop.flags @@ -6,6 +6,8 @@ --add-opens=java.desktop/sun.awt.X11=ALL-UNNAMED --add-opens=java.desktop/javax.swing.plaf.synth=ALL-UNNAMED --add-opens=java.desktop/com.sun.java.swing.plaf.gtk=ALL-UNNAMED +--add-opens=java.desktop/com.sun.java.swing.plaf.windows=ALL-UNNAMED +--add-opens=java.desktop/com.apple.laf=ALL-UNNAMED --add-opens=java.desktop/sun.awt.shell=ALL-UNNAMED --add-opens=java.desktop/sun.awt.im=ALL-UNNAMED --add-exports=java.desktop/sun.awt=ALL-UNNAMED diff --git a/nbbuild/licenses/Apache-2.0-spring5 b/nbbuild/licenses/Apache-2.0-spring5 index b952ca095f16..5da45db0df18 100644 --- a/nbbuild/licenses/Apache-2.0-spring5 +++ b/nbbuild/licenses/Apache-2.0-spring5 @@ -202,9 +202,9 @@ ======================================================================= -SPRING FRAMEWORK 5.2.9.RELEASE SUBCOMPONENTS: +SPRING FRAMEWORK 5.3.31 SUBCOMPONENTS: -Spring Framework 5.2.9.RELEASE includes a number of subcomponents +Spring Framework 5.3.31 includes a number of subcomponents with separate copyright notices and license terms. The product that includes this file does not necessarily use all the open source subcomponents referred to below. Your use of the source @@ -212,7 +212,7 @@ code for these subcomponents is subject to the terms and conditions of the following licenses. ->>> ASM 7.1 (org.ow2.asm:asm:7.1, org.ow2.asm:asm-commons:7.1): +>>> ASM 9.1 (org.ow2.asm:asm:9.1, org.ow2.asm:asm-commons:9.1): Copyright (c) 2000-2011 INRIA, France Telecom All rights reserved. @@ -255,10 +255,10 @@ CGLIB 3.3 is licensed under the Apache License, version 2.0, the text of which is included above. ->>> Objenesis 3.1 (org.objenesis:objenesis:3.1): +>>> Objenesis 3.2 (org.objenesis:objenesis:3.2): Per the LICENSE file in the Objenesis ZIP distribution downloaded from -http://objenesis.org/download.html, Objenesis 3.1 is licensed under the +http://objenesis.org/download.html, Objenesis 3.2 is licensed under the Apache License, version 2.0, the text of which is included above. Per the NOTICE file in the Objenesis ZIP distribution downloaded from diff --git a/nbbuild/nbproject/jdk.xml b/nbbuild/nbproject/jdk.xml index 1e843634b317..5f1a27b85d9e 100644 --- a/nbbuild/nbproject/jdk.xml +++ b/nbbuild/nbproject/jdk.xml @@ -159,10 +159,10 @@ - + - + diff --git a/php/php.editor/src/org/netbeans/modules/php/editor/completion/CompletionContextFinder.java b/php/php.editor/src/org/netbeans/modules/php/editor/completion/CompletionContextFinder.java index 09ea9f24aff1..6e2b4563103a 100644 --- a/php/php.editor/src/org/netbeans/modules/php/editor/completion/CompletionContextFinder.java +++ b/php/php.editor/src/org/netbeans/modules/php/editor/completion/CompletionContextFinder.java @@ -1662,6 +1662,7 @@ private static boolean isInMatchExpression(final int caretOffset, final TokenSeq } static boolean isInAttribute(final int caretOffset, final TokenSequence ts, boolean allowInArgs) { + final int originalOffset = ts.offset(); // e.g. #[MyAttr^ibute] ("^": caret) boolean result = false; int bracketBalance = 0; @@ -1693,7 +1694,7 @@ static boolean isInAttribute(final int caretOffset, final TokenSequence ts, bool break; } } - ts.move(caretOffset); + ts.move(originalOffset); ts.moveNext(); return result; } diff --git a/php/php.editor/src/org/netbeans/modules/php/editor/completion/PHPCodeCompletion.java b/php/php.editor/src/org/netbeans/modules/php/editor/completion/PHPCodeCompletion.java index f9a41fa0c736..fe7c1b11dc5f 100644 --- a/php/php.editor/src/org/netbeans/modules/php/editor/completion/PHPCodeCompletion.java +++ b/php/php.editor/src/org/netbeans/modules/php/editor/completion/PHPCodeCompletion.java @@ -1671,6 +1671,9 @@ private void autoCompleteConstructorParameterName(final PHPCompletionResult comp if (tokenSequence == null) { return; } + if (!tokenSequence.moveNext()) { + return; + } if (CompletionContextFinder.isInAttribute(request.anchor, tokenSequence, true)) { autoCompleteAttributeExpression(completionResult, request); } else { diff --git a/php/php.editor/test/unit/data/testfiles/completion/lib/php80/testParseException/testParseException.php b/php/php.editor/test/unit/data/testfiles/completion/lib/php80/testParseException/testParseException.php new file mode 100644 index 000000000000..6c840599473b --- /dev/null +++ b/php/php.editor/test/unit/data/testfiles/completion/lib/php80/testParseException/testParseException.php @@ -0,0 +1,28 @@ +:8080", selector.select(TO_LOCALHOST).get(0).toString()); assertEquals("One call to my ps", 1, MY_PS.called); } public void testAlwaysProxyForNonLocalhost() { Locale.setDefault(Locale.US); - assertEquals("Connect TO_NB provided by MyPS", "HTTP @ my.webcache:8080", selector.select(TO_NB).get(0).toString()); + assertEquals("Connect TO_NB provided by MyPS", "HTTP @ my.webcache/:8080", selector.select(TO_NB).get(0).toString()); assertEquals("One call to my ps", 1, MY_PS.called); } diff --git a/platform/openide.loaders/nbproject/project.properties b/platform/openide.loaders/nbproject/project.properties index efa4e853b18a..76c4ce2c5edf 100644 --- a/platform/openide.loaders/nbproject/project.properties +++ b/platform/openide.loaders/nbproject/project.properties @@ -22,13 +22,5 @@ javadoc.main.page=org/openide/loaders/doc-files/api.html javadoc.arch=${basedir}/arch.xml javadoc.apichanges=${basedir}/apichanges.xml -test.config.stableBTD.includes=**/*Test.class -test.config.stableBTD.excludes=\ - **/AWTTaskTest.class,\ - **/DataNodeTest.class,\ - **/DefaultDataObjectMissingBinaryTest.class,\ - **/FolderChildrenTest.class,\ - **/LoggingControlTest.class,\ - **/MenuBarTest.class,\ - **/SCFTHandlerTest.class,\ - **/ToolbarConfigurationDeadlockTest.class +# requires js script engine +test.config.default.excludes=**/TemplatesMimeTypeTest.class diff --git a/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777.js b/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777_01.js similarity index 52% rename from webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777.js rename to webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777_01.js index cc2e957847d4..9014bb2b2575 100644 --- a/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777.js +++ b/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777_01.js @@ -1,2 +1 @@ var x= Math. -var x=Math. diff --git a/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777.js.testIssue215777_01.completion b/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777_01.js.testIssue215777_01.completion similarity index 100% rename from webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777.js.testIssue215777_01.completion rename to webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777_01.js.testIssue215777_01.completion diff --git a/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777_02.js b/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777_02.js new file mode 100644 index 000000000000..e4c1f60fb5b3 --- /dev/null +++ b/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777_02.js @@ -0,0 +1 @@ +var x=Math. diff --git a/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777.js.testIssue215777_02.completion b/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777_02.js.testIssue215777_02.completion similarity index 98% rename from webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777.js.testIssue215777_02.completion rename to webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777_02.js.testIssue215777_02.completion index d83304fab8c2..f0f5da242571 100644 --- a/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777.js.testIssue215777_02.completion +++ b/webcommon/javascript2.editor/test/unit/data/testfiles/completion/issue215777_02.js.testIssue215777_02.completion @@ -80,5 +80,4 @@ FIELD SQRT2: Number [PUBLIC, JS Platform FIELD caller: Function [PUBLIC] JS Platform FIELD length: Number [PUBLIC] JS Platform FIELD name: String [PUBLIC] JS Platform -FIELD var: Math [PUBLIC] issue215777.js VARIABLE arguments: Object [PUBLIC] JS Platform diff --git a/webcommon/javascript2.editor/test/unit/src/org/netbeans/modules/javascript2/editor/JsCodeCompletionGeneralTest.java b/webcommon/javascript2.editor/test/unit/src/org/netbeans/modules/javascript2/editor/JsCodeCompletionGeneralTest.java index 23d429f01679..111009235600 100644 --- a/webcommon/javascript2.editor/test/unit/src/org/netbeans/modules/javascript2/editor/JsCodeCompletionGeneralTest.java +++ b/webcommon/javascript2.editor/test/unit/src/org/netbeans/modules/javascript2/editor/JsCodeCompletionGeneralTest.java @@ -61,11 +61,11 @@ public void testIssue215861_02() throws Exception { } public void testIssue215777_01() throws Exception { - checkCompletion("testfiles/completion/issue215777.js", "var x= Math.^", false); + checkCompletion("testfiles/completion/issue215777_01.js", "var x= Math.^", false); } public void testIssue215777_02() throws Exception { - checkCompletion("testfiles/completion/issue215777.js", "var x=Math.^", false); + checkCompletion("testfiles/completion/issue215777_02.js", "var x=Math.^", false); } public void testIssue217100_01() throws Exception {