1,916,707 questions
1
vote
1
answer
34
views
How to implement a stacked notification layout using RecyclerView in Android?
I want to implement a notification-style list using a single RecyclerView in Android.
The layout includes:
Grouped (stacked) notifications: multiple items combined into one group
Normal ...
0
votes
0
answers
60
views
Java Socket does not honor timeout
Tried following code with a wrong serverAddress:
final int CONNECT_TIMEOUT = 5000; // 5000 ms = 5 seconds
final int SO_TIMEOUT = 5000;
try (Socket socket = new Socket()) {
socket.setSoTimeout(...
0
votes
0
answers
39
views
The import org.springframework.boot.autoconfigure.jdbc cannot be resolved
so I've been following this tutorial to build a small website: https://medium.com/@alexandre.therrien3/java-spring-tutorial-the-only-tutorial-you-will-need-to-get-started-vs-code-13413e661db5
I used ...
2
votes
1
answer
69
views
Missing fields during serialization after upgrading Jackson 2 to Jackson 3
I migrated from spring boot 3 to spring boot 4 and I have an issue with the JSON created by Jackson.
The response is like this:
public class MyResponse {
private List<MyData> data;
...
Best practices
0
votes
4
replies
81
views
Cron Expression to choose any one day
Is there a Cron expression to run on either 2 or 3 days of the month, e.g.
run once on either 11th, 12th or 13th
4
votes
3
answers
108
views
Reference Types: Variable Not Initialized Error Confusion
My instructor gave us this question for homework:
11. Select the TRUE statement.
a) This code will not compile.The error will be:
local variable c may not have been initialized
b) ...
Best practices
0
votes
5
replies
110
views
Notifying programmer to use another function: Alternatives to @Deprecated?
Suppose I have these classes:
class Tool {
String method1() {
return "ok";
}
}
class RareSpecialTool extends Tool {
/**
* @...
Advice
0
votes
2
replies
86
views
Telegram Group Chat Creation Automated
I am using a Telegram bot in a Spring Boot application and I want to automate messaging for my system users.
Is it possible to:
Automatically create a group chat for each user using a Telegram bot
...
1
vote
1
answer
91
views
Spring boot application moving from JAVA 17 to JAVA 25 gives Exception java.lang.NoClassDefFoundError: sun/security/action/GetPropertyAction
I had a Java application in JDK17 which uses the IIOP corba protocol for JMS message connection listener and processing those further.
Now upgrade the JDK17 to JDK25 , with that i am getting below ...
0
votes
1
answer
54
views
Visual Studio Code unable to create java gradle projects
I'm trying to fix this problem from some days now, I have 'gradle for java' and 'extension pack for java' extensions installed, but when I try to create a new gradle java project, it tryies to create ...
-3
votes
1
answer
60
views
Odd type casting error with com.fasterxml.jackson(.databind) v3 when deserializing a class deriving from `java.util.Properties` [duplicate]
I am having an issue while trying to upgrade my application from using Jackson v2 to Jackson v3:
My application has a class that contains a reference to an object of type NodeProperties, a class which ...
-3
votes
0
answers
72
views
Mysterious AccessibleJTable registered as TableModelListener
I have a JTable in a JFrame that uses an AbstractTableModel extension, all built with NetBeans 28. When the table loads I find through debug that the model has one listener. Later when I try to delete ...
0
votes
1
answer
60
views
How to get concrete Controller type using Guava
I am using Google Guava to switch the content pane in my JavaFX app.
@Subscribe
public void handleChangeViewDataModel(ChangeViewEventDataModel event) {
try {
FXMLLoader loader = new ...
0
votes
0
answers
51
views
How to avoid "Continuous access evaluation resulted in challenge with result: InteractionRequired and code: TokenCreatedWithOutdatedPolicies"
I have a user which has been granted to use MS Graph API.
I wrote a code in Java which is using the MicrosoftGraphClient and makes simple lookup to find an user by email. The code is runing fine just ...
Advice
0
votes
4
replies
76
views
How to pass code for options to a selector class with n options?
package lanta.utils;
import java.util.HashMap;
import java.util.Scanner;
public class MenuConstructor {
public HashMap<Integer, String> options;
public int option;
public ...