Category "java"

Property with return value in Java/Kotlin?

This is a pretty basic question, but I haven't been able to find any answer on SO yet. I'm just curious, is there a corresponding way in Java or Kotlin to write

EXCEPTION_ACCESS_VIOLATION Error when using stbi_load

I'm trying to load an image into a ByteBuffer using stbi_load. However, the following error gets thrown up in the console fatal error has been detected by the

Why is Spring @Transactional unreliable with AspectJ?

TLDR: this project reproduces the issue: https://github.com/moreginger/aspectj-no-tx Edit: Above now reproduced without jooq i.e. using plain JDBC. Edit: Spring

Java 17 JDK Install exe won't run

I am trying to download Java 17, but whenever I run the jdk-java17.exe file, nothing happens, this occurs when run as administrator as well. When I debug the ex

Cannot resolve symbol 'CachingSpringLoadBalancerFactory'

I have this code that I would like to migrate to the latest version of 'org.springframework.cloud:spring-cloud-openfeign-core:3.1.1' import feign.Client; import

Convert .apk file to .abb file without Android studio

Please how can I convert .apk to .aab without Android studio I created an Android app using AIDE and I wanted to upload to Google Play Store and then I discover

How to solve Chinese garbled when using javax.servlet.Filter

ContentCachingResponseWrapper wrapper = new ContentCachingResponseWrapper(response); wrapper.setContentType("application/json;charset=UTF-8"); wrapper.setCharac

Check which jar is being used by classes for compilation & execution(runtime)

I've a very big project where thousands of classes are using 100s of third party jars. I need to find out list of jars used by every single class in the project

How to use PDFTemplate of OpenPDF in PDFTable

I want to create a Header of a page which contains a table wit current and total number of pages. As far as I understand OpenPDF, I have to use the PageEventHel

Sobel edge implementation issue

For a class I have to implement the sobel edge detector in java, and do I did. But something isnt right, and after 3 hours trying to figure it out I still haven

Which version of Java do I need for this

I'm trying to use R and the R package rjdbc to connect to an Oracle database. Unfortunately, due to my company's strict IT department, every step of the proces

Creating a Trace Table

I need to write a trace table which is supposed to look like this picture To create the trace table I have to modify the following code with System.out.println

can't run jdk-8u202-windows-x64.exe ... nothing happens ... what do I do?

I'm supposed to install JDK and JRE 8. I tried running file I downloaded from Oracle: jdk-8u202-windows-x64.exe When I try running it, nothing happens, no error

Tuple to Json (with Java & EntityManager)

For a project, i needed to fetch records from a SQL database into a list of objects (using java for backend). The exchange between the backend and the frontend

How to run JUnit5 suite using the @Suite annotation

I'm trying to figure this out for over a year now but I can't run JUnit5 suites unless I use the JUnit4 @RunWith annotation, which brings me some other issues.

On Java 17 WindowBuilder was not able to show the GUI. .wbp-component.xml description for component javax.swing.JFrame

I'm using Eclipse 2021-9 version and already have Window builder installed. this error happens when I click the designer tab. WindowBuilder was not able to sho

File Selector (.txt)

I've been trying to get a code to list all the .txt files which are stored in a directory of a mobile phone. It's my first time with Android Studio, so it's har

How to use a Spring WebClient to parse specific data from an external API?

I'm attempting to use the Spring WebFlux WebClient to retrieve data from the openweathermap API. I've done this using a RestTemplate no problem, but want to und

MySQL - Fetch millions of data in chunk with constantly changing data

Below is the schema of my table A. CREATE TABLE A ( NAME VARCHAR(255), CREATED_AT DATETIME DEFAULT CURRENT_TIMESTAMP, UPDATED_AT DATETIME DEFA

Does the semantics of java volatile guarantee that wrong results will not appear? (Two threads write first and then read)

volatile x=y=0 Thread1 x=1 r1=y Thread2 y=1 r2=x r1 and r2 are local variables Question1: Is the result of r1==r2==0 illegal and does not appear? All stateme