Category "java"

Why do I need Comparable for PriorityQueue?

I'm learning about Queue Collection and I don't understand why do I need to implement Comparable interface if I use PriorityQueue? I have used Comparable and Co

java regex for UUID

I want to parse a String which has UUID in the below format "<urn:uuid:4324e9d5-8d1f-442c-96a4-6146640da7ce>" I have tried it parsing in below

SpringBoot - Generate pdf using flying-saucer-pdf result into empty file

I'am tying to export a pdf file from html using fly-saucer, but the file is always empty and therefore can not be opened. Can anyone tell me what i am doing wro

Call recording, call multiple(repetitive) telephonic stages and creates multiple audio files

I have created one service and broadcast receiver to get telephony state. Below is my code : @Override public int onStartCommand(Intent intent, int fla

A character string to numeric conversion failed while using syntax like 'OPE' =?

I try to run this query using Spring JDBC Template public static String FIND_CNC_OPE_GRAPPE_BY_FCT_ID = "SELECT " +"EXPO.COD_NA

hasKey doesn't see the field in the response

I have test: @Test public void sixTest() { FlowerList flowerList = new FlowerList(); Specification.installSpec(Specification.requestSpec(),

How to remove Header title in bottom nav bar - Android Studio

My objective is removing the orange bar thar has the label "App name". Currently I have a top_app_bar and bottom_nav_bar. As far as I know the orange bar is gen

Cannot access org.springframework.data from my Java Classes

I'm working on an online tutorial, and in the step where I need to work with databases and add jpa, I cannot access it in my project. I have successfully put t

How to pass environment variables to the gradle wrapper build using only command line?

I am trying to pass env variables locally with strictly a command line command. At deploy, these variables get passed into the docker container, but when runnin

Strange empty bar above fragment on BottomNavigationView

This is how it is supposed to look: https://i.stack.imgur.com/4bLy5.png This is how it looks: https://i.stack.imgur.com/oSUjF.png Strange white space appears

How to configure jackson with spring globally?

To serialize deserialize object I am useing Jackson as flow @JsonSerialize(using = LocalDateSerializer.class) @JsonDeserialize(using = LocalDateDeserializer.cl

JavaFX - Making a post request using org.apache.httpcomponents fails

When making a post request to my backend, I get the following error. I can't really find a fix online and am very new to Java. Here is the error: Caused by: jav

Visual Studio Code, Java Extension, how to add a JAR to classpath?

In Eclipse IDE, I add a JAR library using Project > Build Path > Configure Build Path... What is the equivalent in VisualStudioCode? I had a look into l

How to remove controller list from Swagger UI

I'm using springfox-swagger-ui 2.8.0 which ships with Swagger UI 3.7.0. I want to get rid of the controller list in front of the api documentation page, pretty

Primefaces 5.1 start ajaxStatus during preRenderView

In primefaces is possible start "ajax status" from a method of a backing beans? I have the following view: <ui:composition xmlns="http://www.w3.org/1999/xhtm

Why log4j stop running MDC logic if Java version is 11, 11.1x, etc

I use MDC for helping log4j loging more information. Everything works well until I updated java version to 11. This is my log4j config (pseodo code) log4j.appen

Portable Eclipse : impossible to add software

I installed Eclipse on my office pc, using this procedure (64 bit): https://portableapps.com/node/53284 But when i want to create a new project, it does not pro

Enable xinclude processing for Ants `schemavalidate` task

I'm using the schemavalidate task of Ant to validate XML documents. <schemavalidate noNamespaceFile="${user.input.xsd}" file="${user.input.xml}"> <

Spring Boot : execute a job at a particular Date entered by the user

Im trying to manage scheduled tasks using spring boot. I want to execute my job only one time at a particular date ( specified by the user ). Here is my Job :

Check that each Color field has a color value (format string "#FFFFFF")

I have task: "Check that each Color field has a color value (format string "#FFFFFF")". I have a solution: @Test public void sixTest() { Specification.insta