Trending questions in Java

0 votes
1 answer

How to implement draggable tab using Java Swing?

Hello kartik, setAcceptor(TabAcceptor a_acceptor) should let the consumer code ...READ MORE

Apr 21 in Java by Niroj
• 20,510 points
15 views
0 votes
1 answer

How to set AUTO-SCROLLING of JTextArea in Java GUI?

Hii kartik, When you click anywhere over JTextArea, ...READ MORE

Apr 21 in Java by Niroj
• 20,510 points
19 views
0 votes
1 answer

How can I set JFrame to appear centered, regardless of monitor resolution?

Hello @kartik, Use setLocationRelativeTo(null) This method has a special effect ...READ MORE

Apr 21 in Java by Niroj
• 20,510 points
17 views
0 votes
1 answer

How to open warning/information/error dialog in swing?

Hello, You can try out : import javax.swing.JFrame; import javax.swing.JOptionPane; public ...READ MORE

Apr 21 in Java by Niroj
• 20,510 points
11 views
0 votes
1 answer

What is definition of an invalid literal?

Hi, @ Stephen, I will explain to you ...READ MORE

Apr 20 in Java by Gitika
• 28,810 points
34 views
0 votes
1 answer

HttpServletRequest get JSON POST data

Normally you can GET and POST parameters ...READ MORE

Nov 29, 2018 in Java by Sushmita
• 6,890 points
21,868 views
0 votes
0 answers

How to Download the Certificate for completion?

How Can I download the the Course ...READ MORE

Apr 16 in Java by Ajaaypranav
• 120 points
94 views
0 votes
2 answers

How to generate a class at runtime?

Yes, I recently met this library which ...READ MORE

Apr 15 in Java by Edureka
• 500 points
47 views
0 votes
0 answers

Write a program that uses a while loop to read 10 integer numbers from file

Write a program that uses a while ...READ MORE

Apr 15 in Java by MIH
• 160 points
103 views
0 votes
0 answers

HOw can i do this?

The department of History has just bought ...READ MORE

Apr 15 in Java by MIH
• 160 points
64 views
0 votes
1 answer

How to convert InputStream to byte array in Java?

Hello @kartik, You need to read each byte ...READ MORE

Apr 9 in Java by Niroj
• 20,510 points
262 views
0 votes
1 answer

JsonMappingException: No suitable constructor found for type [simple type, class ]: can not instantiate from JSON object?

Hello @kartik, his happens for these reasons: your inner ...READ MORE

Apr 8 in Java by Niroj
• 20,510 points
195 views
0 votes
1 answer

Convert data in List<JsonNode> to Map <String,String> in Java

Hi, @Jyra, Basically, you can use the object mapper to ...READ MORE

Apr 7 in Java by Gitika
• 28,810 points
206 views
0 votes
0 answers

how to send a pdf file as a response to frontend?

when a user upload a file to ...READ MORE

Apr 11 in Java by Abhishek
• 120 points
49 views
0 votes
1 answer

How to run a Java program from the command line on Windows?

Hello @kartik, In case your Java class is ...READ MORE

Apr 9 in Java by Niroj
• 20,510 points
71 views
0 votes
1 answer

Error: Unable to run mksdcard SDK tool in java?

Hello, If you use  Ubuntu, you can try: sudo apt-get ...READ MORE

Apr 9 in Java by Niroj
• 20,510 points
42 views
0 votes
1 answer

How can we activate JMX on my JVM for access with jconsole?

Hello @kartik, Run your java application with the ...READ MORE

Apr 9 in Java by Niroj
• 20,510 points
37 views
0 votes
1 answer

how to get latest modified object or folder in s3 bucket in java.

Here's what you could probably try: List all ...READ MORE

Apr 6 in Java by Liana
178 views
0 votes
1 answer

Error:“java.lang.OutOfMemoryError: Java heap space” ?

Hii, Possible causes: Simple configuration issue, where the specified ...READ MORE

Apr 8 in Java by Niroj
• 20,510 points
54 views
0 votes
1 answer

How to pass an object from one activity to another on Android?

Hello @kartik, Implement your class with Serializable. Let's ...READ MORE

Apr 8 in Java by Niroj
• 20,510 points
34 views
0 votes
1 answer

What is the reason for no ConcurrentHashSet against ConcurrentHashMap?

Hello, There's no built in type for ConcurrentHashSet because you ...READ MORE

Apr 8 in Java by Niroj
• 20,510 points
28 views
0 votes
1 answer

How to automatically deploy a jar from s3 to aws lambda?

You could probably create a lambda function ...READ MORE

Apr 2 in Java by Jake
227 views
+1 vote
3 answers

How to take input using BufferedReader in Java?

yupp i am explaining every thing .. We ...READ MORE

Feb 1 in Java by Rohan
• 180 points
9,819 views
0 votes
0 answers

If statement not working in AWS Lamnda - S3Event code

Hi, I am using below  lambda function with ...READ MORE

Apr 4 in Java by Abhishek
• 280 points
42 views
0 votes
1 answer

java path not found in window 7

Hey, You can follow these few steps: From the ...READ MORE

Apr 3 in Java by Gitika
• 28,810 points
44 views
0 votes
1 answer

how to do global variable declaration in java

Hello,​ Global varriable which is defined after the ...READ MORE

Apr 3 in Java by Niroj
• 20,510 points
40 views
+1 vote
1 answer

How to get Alias name of AWS Lambda function from java code?

Hey @Abhishek, you could probably use the ...READ MORE

Apr 1 in Java by Sirajul
• 52,710 points
72 views
0 votes
0 answers

Where exactly in the variable file path will I paste the javac file path?

I wrongly placed the javac file in ...READ MORE

Apr 2 in Java by anonymous
• 120 points
61 views
0 votes
1 answer

What is Modeshape. How can i use this?

ModeShape is an open-source implementation of the JSR-283 specification and ...READ MORE

Mar 30 in Java by Gitika
• 28,810 points
205 views
+1 vote
1 answer

How to generate a class at runtime in Java?

Yes: you can do it with Burningwave ...READ MORE

Mar 16 in Java by Roberto
• 370 points

edited Apr 13 by Roberto 204 views
+1 vote
2 answers

How to take multiple integer input in one line using BufferedReader in Java?

Try this in case you don't know ...READ MORE

Aug 29, 2019 in Java by Sirajul
• 52,710 points
11,827 views
+2 votes
2 answers

Using while loop i want to print 10 even numbers

public class Loops { ...READ MORE

Dec 4, 2019 in Java by One of the Simplest ways to answer you q
11,357 views
0 votes
0 answers

How to handle simultaneous requests using springboot?

A gateway and load balancer built using ...READ MORE

Feb 9 in Java by anonymous
• 10,080 points
272 views
+1 vote
4 answers

What is difference between access modifier and access specifier in java

Access Specifier:- This can be understood as ...READ MORE

Feb 14, 2019 in Java by Priyaj
• 57,530 points
14,496 views
+2 votes
1 answer

please someone tell the code to launch an instance in digital ocean using java

In order to create a digital ocean ...READ MORE

Jan 14 in Java by Sirajul
• 52,710 points
407 views
+1 vote
1 answer

Program for nth prime number without using scanner

Hi @Sneha, you could use something like ...READ MORE

Jan 13 in Java by Kalgi
• 51,850 points
324 views
0 votes
1 answer

How to find the nth prime number in Java?

Here is the code to find nth ...READ MORE

Mar 4, 2019 in Java by Priyaj
• 57,530 points
13,729 views
+1 vote
0 answers

I am getting below error "The method readerFor(Class<Map>) is undefined for the type CsvMapper"

I Have requirement to convert csv to ...READ MORE

Dec 29, 2019 in Java by anonymous
• 160 points
453 views
+1 vote
0 answers

getting below error when trying to conver csv file to json :The method readerFor(Class<Map>) is undefined for the type CsvMapper [closed]

PFB source code: import java.io.File; import java.lang.*; import java.util.Arrays; import java.util.List; import ...READ MORE

Dec 28, 2019 in Java by anonymous
• 160 points

closed Jan 14 by Kalgi 246 views
0 votes
2 answers

“Cannot find symbol” compilation error

The "Cannot find symbol" errors generally occur when you ...READ MORE

Apr 3, 2019 in Java by patricblues
• 140 points
18,204 views
+1 vote
1 answer

Is Java a compiled language or interpreted?

Compiled languages are directly converted into machine ...READ MORE

Dec 18, 2019 in Java by Hannah
• 18,040 points
264 views
+5 votes
3 answers

How to execute a python file with few arguments in java?

You can use Java Runtime.exec() to run python script, ...READ MORE

Mar 27, 2018 in Java by DragonLord999
• 8,400 points

edited Nov 6, 2018 by Omkar 21,063 views
+1 vote
1 answer

how to print this statement in java print(' '*(r-x-1)+'*'*(2*x+1)) ( logic used in python .its perfect) but java wrong output came

In ' '*(r-x-1) and '*'*(2*x+1), you used multiplication ...READ MORE

Dec 21, 2019 in Java by Utsab Bandyopadhyay
200 views
+1 vote
2 answers

Java: Nested Methods

public class ObjClass {     ObjClass anyMethod() ...READ MORE

Jan 19 in Java by zemiak
1,461 views
0 votes
2 answers

What is the difference between Map and HashMap in java?

The basic difference is : Map is ...READ MORE

Aug 28, 2019 in Java by Sirajul
• 52,710 points
5,830 views
0 votes
1 answer

GSON throwing “Expected BEGIN_OBJECT but was BEGIN_ARRAY”?

This will work: ChannelSearchEnum[] enums = gson.fromJson(yourJson, ChannelSearchEnum[].class); But ...READ MORE

Dec 26, 2018 in Java by Sushmita
• 6,890 points
14,352 views
0 votes
0 answers

java regex split string into double numbers and-letters

I am having a problem splitting something ...READ MORE

Nov 14, 2019 in Java by khs
• 120 points
322 views