Category "java"

How to compare elements from an ArrayList with data from a table in MySQL

The idea is I'm making a little restaurant app in Java so in this class is given the option to make an order. It works this way: the user writes which products

Programmatically set signatures in Outlook client using JAVA

I want to set signatures for multiple address in outlook client application. I read concepts using VBA and other scripts. But I want to do it in Java. I have al

Recycler View List Sort position saving notepad app

In my program I added code to move the list items around but for example if I move shopping list above Test 123 and fully close the app the positioning resets

How do I map ASM's API version in Opcodes to Java version?

ASM's ClassVisitor constructor requires passing one of Opcodes's ASM4, ASM5, ASM6, ASM7, ASM8 or ASM9. How do I know which ASM# to use for each version of Java?

Is it possible to disable SSL certificate checking in the amazon kinesis consumer library v2?

When developing a Kinesis Consumer using Version 2 of the Kinesis Consumer Library and overriding the Dynamo DB endpoint to a localstack endpoint the library fa

Android Studio, "Unresolved Reference: activity_main"

I am following this tutorial and cannot figure out how to resolve the errors "Unresolved Reference: activity_main" and "Unresolved Reference: app_name". The tut

How to change window selenium java?

I'm trying to access iframe inside html tag.xpath is not working.How to change my window to iframe in selenium(java/maven)?

filter objects based on an ID and Date Java

I have a class that for which each instance has a unique Id, a name and update date. ID NAME UPDATE DATE 1200 ANNA* 2022-03-01 1300 JONH* 2022-04-01 1200 ANNA*

How to migrate Springfox' @Api to Springdoc's @Tag?

Manual just says replace @Api -> @Tag. But @Api has produces and consumes parameters, while @Tag has obligatory name parameter. How to migrate @Api(produces

RStudio fatal error when loading tabulizer

I recently updated R to version 4.2.0 on my Windows 10 PC. When I try to load the package tabulizer, RStudio crashes and the bomb icon with the correspondent "R

Error using SonarLint in Visual Studio Code (VsCode) and Java 11

I have a problem using SonarLint in visual studio code, I’ve been using very well this plugin in java 8 but arround last week, Vscode required java 11 as

Transaction rollback when @Async method fails

I am trying to read about Transaction but I cannot understand how would I rollback a async method call, is it even possible to do so. I am facing an issue wher

FileOutputStream in dart flutter

what's the equivalent fileoutputstream of java in dart? Java code file = new FileOutputStream(logFile, true); byte[] input = "String".getBytes(); file.write(inp

Sonarlint and Intelij: possible to run analysis only for files in a changelist?

I am currently running sonarlint plugin locally in Intelij which works well. I would like to run the plugin only for files that I have in my Changelist - before

How to get List of Objects with value in array in Spring-Boot CrudRepository

I have an Object defined that has ChildAccountList of Strings as one of the attributes. Is there a findBy method that I can use such that it will return the li

how to mock UUID?

is it possible to mock UUID? or any problem in my Source Code? Look at exmaple: MyTest Class @RunWith(PowerMockRunner.class) @PrepareForTest({UUID.class,Ac

How to convert List to Map?

Recently I have conversation with a colleague about what would be the optimal way to convert List to Map in Java and if there any specific benefits of doing so.

How to make unlimited AnchorPane's in JavaFX

I'm trying to create a program that will contains many blocks (AnchorPane's) using JavaFX. My problem is that when I created one block others don't appear becau

How do I set up a recursive, many-to-many relationship WITH an association class using JPA?

So I'm trying to create a pharmacy database that, among other things, keeps track of drug-to-drug interactions. I have a Drug entity with various members and as

How to get multiple values by index in an ojAlgo-array?

Let's say I have an ojAlgo-array defined like this ArrayAnyD<Double> regularArray = ArrayAnyD.PRIMITIVE64.make(10); regularArray.loopAll((final long[] ref