Category "java"

Search all versions of a file in git log takes long

I noticed that finding all versions of a specific file in git takes a long time when the number of files in the repo is more then a couple of thousand. Any idea

Java - ATM Banking login with 3 times try pin lock

I'm new to java programming. I'm trying to make a banking system log-in that locks the user after entering the wrong pin 3 times. I'm trying to merge 2 pieces o

Apache Commons Configuration: read from classpath/JAR?

Does the Apache Commons Configuration library support reading properties/configuration files from the classpath or JAR? I didn't find an API where it can take a

Drawing multiple objects in Java [duplicate]

I would like to draw multiple objects like ovals, rectangles and lines together. But somehow I can draw only an object. When I try to draw ano

validate input in Thymeleaf

I have this input: Masa: <input type="number" class="form-control form-text" name="masa"/> <div class="text col-sm-12 error" th:if="${wzrost}"

Mutiple iterators in for loop Java not working properly

I am trying to pass a Javascript code to Java, but I've got a problem with the for loop, I have a for with 2 iterators in my Javascript code, and it is working

Calling a method to try and rerun through a block of code

I'm trying to compare the cost of a user's phone usage under plans from three different providers. I can get as far as entering the usage details but once enter

Change username and password for an existing Windows service in Java via Advapi32 (JNA API)

I have been trying to change configuration for an existing Windows Service via the JNA API, specifically via com.sun.jna.platform.win32.Advapi32 class but could

Jave webflux process a String-response with id's

I've a reactive API which receives the following String (image below). I want to process these ID's and perform a search query to my MongoDB and return a Flux w

Consume NAV Soap web service in java

Any Lead for consuming Microsoft dyanmics NAV web service.Client has given us a WSDL file in XML format and we need to consume it in java/spring boot.

"Failed to find cgroup for tid XXX", application crashes with background thread

I'm trying to build a custom launcher for Android, and I'm following this guide to have a clue of what I'm doing. Till the first part everything's ok, it works

java.lang.NoSuchMethodException error in Spring-boot web-application when deploying on tomcat

I am deploying a Spring-boot web-application on 'tomcat 9' and I faced a NoSuchMethodException. I compile and run this code in localhost, successfully; but when

sqlite cannot connect to database error: java.lang.UnsatisfiedLinkError: org.sqlite.core.NativeDB._open_utf8([BI)V

I get the following error: I have this code I have tried several things going before I posted this, I determined that this was the source error it did not conne

Heads up push notification not doing the Pop up function

I am new to Android and I have been trying to show a Heads up action push notification just like whatsapp does. This is my configuration for my notification:

Heads up push notification not doing the Pop up function

I am new to Android and I have been trying to show a Heads up action push notification just like whatsapp does. This is my configuration for my notification:

how to create java project with command?

I'm a beginner, when I create a java project using the command pallate in vscode ctrl-shift-p -> java: Creat java project, only created the lib, src and read

class cannot be cast to the same class Spigot custom API

I recently made a custom api for my spigot plugin to manage the database connection in an easier way. I had to get the plugin and cast it to the class of my API

quarkus + oauth2 + auth0

I'm trying to get auth0 to work with quarkus: resources i've used are: https://github.com/quarkusio/quarkus-quickstarts/tree/main/security-oauth2-quickstart htt

How to convert ArrayList to Pageable object springboot

I was trying to return list as page object to my client side angular Application. But it return all the list not a page. this is my server side controller m

Comparator Error java.lang.IllegalArgumentException [closed]

How can I sort array according to the count of set bits? I'm getting an error whit below code: Arrays.sort(arr, (o1, o2) -> { if (Integ