Questions tagged [java-16]

Use this tag for questions specific to Java 16, which is version 16 of the Java platform, released on March 16, 2021. In most cases you should also specify the java tag.

This release is the Reference Implementation of version 16 of the Java SE Platform, as specified by JSR 391 in the Java Community Process.

124 questions
0
votes
0 answers

Error trying to use AES encryption in java

I am trying to build a Java program that compresses, then encrypts files using AES encryption. However, I am getting the following error during the encryption process: Exception in thread "main" java.security.NoSuchAlgorithmException: Cannot find…
0
votes
0 answers

URLClassLoader addURL() Java 16 Illegal reflective access

i currently developing a "addon" based system for my minecraft server. Now i have a problem. if i run it on Java 16, it throws a "Illegal Reflection Exception" and the operation will be denied. I try to call the addURL() method from…
0
votes
2 answers

JDK 16 Records, Constructors and Additions Over Time?

I'm interested in using the new JDK 16 records, but when I try and create a new one that has additional arguments, I get an error: public record DrivePacket(Path drivePath, long driveSize) { public DrivePacket(Path drivePath, long driveSize)…
Sarah Szabo
  • 10,345
  • 9
  • 37
  • 60
0
votes
1 answer

JavaFX16: Unsupported JavaFX configuration: classes were loaded from 'unnamed module @...'

I have a Maven multi-module project on IntelliJ that produces 3 jars, 2 of which are executables and the other one is for commmon resources. One of the executable modules has a main class that asks if the user wants to start the program with CLI or…
0
votes
1 answer

What is the purpose of RecordComponent::getDeclaringRecord

RecordComponent has a method getDeclaringRecord. I can't seem to understand what is the purpose of it, especially since it's public. The only way to get a RecordComponent is via calling Record::getRecordComponents, if I do call it like this, I…
Eugene
  • 117,005
  • 15
  • 201
  • 306
0
votes
1 answer

How to repeat a HTTP GET request

I'm building a simple app that checks repeatedly changed made in certain file in a server. I'm using HttpURLConnection instance like so: HttpURLConnection httpURLConnection = (HttpURLConnection) new…
Roy Ash
  • 1,078
  • 1
  • 11
  • 28
0
votes
1 answer

IntelliJ2021.1 IDEA x64(Windows 10) Kotlin REPL Run Error

I started learning Kotlin through Kotlin Bootcamp for Programmers in codelab. In this first section, I created Kotlin project and startd(?) Kotlin REPL(Tools>Kotlin>Kotlin REPL). However, the following error occurred. exception:…
y t
  • 1
  • 1
0
votes
0 answers

Connecting to LDAPS with GSS and Channel Binding

I'm trying to bind to an Active Directory server with GSS on a Windows computer that is logged in as a domain user. Normally, this works fine. But when signing and binding is being enforced (see…
thetechnician94
  • 545
  • 2
  • 21
-1
votes
2 answers

Cannot invoke "Object.getClass()" because "object" is null - Java16

I am trying to setup an Appium project for learning purposes. I have created a basic structure of framework but it is throwing me following error: net.serenitybdd.core.exceptions.StepInitialisationException: Failed to create step library for…
Bilal
  • 558
  • 8
  • 18
-1
votes
1 answer

How to return List from Java 16 Stream.map()?

I am iterating over a list, calling dynamoDBMapper.query() which return a PaginatedQueryList. public List getPerson(final List personIds) { return personIds.stream().map(personId -> dynamoDBMapper.query(Person.class,…
newLearner
  • 637
  • 1
  • 12
  • 20
-1
votes
1 answer

Nashorn JavaScript engine removed from Java 16 - Is there any replacement?

Nashorn JavaScript engine removed from Java 16. I am running Java application (Minecraft server) which using plugin which using Nashorn Engine to run JavaScript snippets. I recently updated my server to Java 16 and now this plugin wont load. Plugin…
Baterka
  • 3,075
  • 5
  • 31
  • 60
-1
votes
1 answer

How to remove --enable-preview in Java 16?

To use records with JDK 15, I used to compile with arguments --enable-preview --release 15 passed to javac on my Ant build. Everything compiled and run fine. When using JDK 16, if I compile with the same arguments, I get error: invalid source…
ARX
  • 1,040
  • 2
  • 14
  • 20
-2
votes
3 answers

Where can I find Java Runtime Environment (JRE) 16 to download and install

I'm developing mod for Minecraft Forge 1.17 which requires JDK16. I have installed that. I'm using Eclipse and the compiler gives a warning that execution environment is JavaSE16 but no JRE16 found. As far as I know there is no JRE16 installed on my…
RInventor7
  • 3
  • 1
  • 4
-2
votes
1 answer

Is there Java Control Panel in java -16?

Hi am new to java and I was using java 15. Then a newer version of java came and it was 16. I downloaded it and installed it in my computer. Then I found that you can update java using java control panel. But I can't found it. Can anyone help me? Is…
user15537709
-2
votes
1 answer

ParallelStream Collecting to Set?

I have a program which would benefit greatly (large data set with a somewhat involved mapping and filtering scheme, but not dependent on exterior variables / synchronization) from using parallelStream(), but must be collected as a set. I'm somewhat…
Sarah Szabo
  • 10,345
  • 9
  • 37
  • 60
1 2 3
8
9