Java (not to be confused with JavaScript or JScript) is a general-purpose object-oriented programming language designed to be used in conjunction with the Java Virtual Machine (JVM). "Java platform" is the name for a computing system that has installed tools for developing and running Java programs. ...

learn more…| top users | synonyms (8)|java jobs

-3
votes
0answers
11 views

create a java application to create arguments

Please help me in my lab task that due shortly. Using the main function’s arguments, create a program that takes in a person’s name and age then print out a friendly message: Sample run 1: Java ...
0
votes
0answers
8 views

JTextArea not updating across panels/class

Why doesn't the "getTextBody" send back user input from JTextArea when called from another class (the button to trigger is on a another panel), but if i place a button with actionListener in this ...
0
votes
0answers
3 views

How to make an outbound call in Twilio with Java, using TwiML and not a URL?

I'm looking to make an outbound call in a Java application using Twilio. All of the tutorials I found used a static TwiML file hosted on a URL. I haven't been able to find any documentation on how to ...
-5
votes
1answer
21 views

Java- Extend a class which Extends another class

Is this legal in java - I do not get any IDE errorsI have a classpublic farm extends residential {andpublic residential extends properties {
0
votes
0answers
13 views

Drawing a curve in Java using mouse drag

I am new to java and I am trying to draw a curve. The functionality I am trying to implement is that the curves should be defined by a mouse drag followed by a mouse click. Once the drag action is ...
0
votes
1answer
14 views

try with resources only prints once

I have 5 records in pList in the ArrayList below but why does it only print the last record to file ? I put the try first and the for loop inside it and that worked but trying to understand the ...
-2
votes
0answers
10 views

android studio won't create content.xml file

I am using android studio 3.0.1.As of this update, I can no longer create a new activity and also have it create the content_(name).xml file anymore. It only creates the Java class and the activity_(...
0
votes
0answers
7 views

im having trouble creating a login dialog. i want a dialog box to pop up when you click on the login button

this is the main classimport java.awt.event.*;import javax.swing.*;import javax.swing.JPanel;public class Password {public static void main(String[] args) {final JFrame frame=...
-6
votes
2answers
33 views

Why won't my method store the length of each array element into my variable?

This is in Eclipse. I wrote this code that is supposed to sum each String element within the ArrayList and then return the sum cubed. The problem is that it is returning 0.0 every time the method is ...
-1
votes
0answers
12 views

Where can I find non-boxing maps for java?

I know the collections for primitives of the apache commons primitives project.However I miss maps that avoid boxing at all. Does that exist for java? In which java frameworks are they implemented?
-2
votes
0answers
5 views

loader constraint violation when building Spark SQL Context dynamically

I am getting the following exceptionException in thread "main" java.lang.LinkageError: loader constraint violation: when resolving method "org.apache.spark.sql.types.StructType$.apply(Lscala/...
0
votes
1answer
4 views

poolDataSource.getConnection() hangs. Tried using ojdbc6 and ojdbc8 jars

I am using Oracle 11g XE and java 8. I am developing a desktop application and want to do connection pooling. The application hangs while executing pds.getConnection(); I tried using simple JDBC, ...
-1
votes
0answers
11 views

Print a binary search tree as a single string

There's a practice problem that I've been working on that's been confusing me.Define a function treeLevelOrder which satisfies the following claim:If Q is a binary search tree of integers, then ...
-1
votes
0answers
7 views

i can't get set location (maps) work on OPPO phone Blocked msg target=android.app.ActivityThread$H

Hello when I try to use the app in virtual device work fine, but not on real device OPPOlogcat02-18 01:03:20.681 27579-27579/com.cog.wasselniC E/GoogleMap: Rue de Kouba Place Id: ...
-1
votes
0answers
8 views

My application crashes when I hit login with out entering password/email, I have tried some things in this code but no luck.?

Can anyone help me how to put checks in this code, Thanks/Can anyone help me how to put checks in this code, Thanks/Can anyone help me how to put checks in this code, Thanksprivate void loginUser(...
-4
votes
0answers
13 views

How to underline a word in a file there is or not the word

I want to make an application such as wordwhen user type any word search it in fileif it exists okif it doesn't exist underline it
-1
votes
2answers
30 views

Is this bad practice for passing an input file in Java?

I have a main class that expects an input file name to be provided through the command line argument; if this is not true then the program exits with an error message.We are assuming the existence ...
0
votes
1answer
15 views

need some assistance with 2d arraylists

This is the problemClass registration is an important aspect to the college students. When registering for a course, you must know the course reference number (CRN). Based on the CRN, there are a ...
-2
votes
2answers
23 views

cannot find symbol length (Java)

Given an array of numbers, I have to return the number of times that 9 appears in the array. I created a new array, where I added all the 9s from the original array. But at the end when I want to ...
0
votes
0answers
14 views

I am trying to add collision detection to this particle system I made

I am doing this in processing which is essentially java and I have never attempted anything like this before. Can't find any examples of collision detection using arrays to map the pixels. I am not ...
0
votes
1answer
16 views

How do I return rows with a specific value first and rest all the values of a table in a Alphabetic order

I need to get book_name and book_code order by book_name in alphabetic order.Input to my query is Author_code.I have three tables:Table1: Books (Independent Table which will have all the books)...
0
votes
0answers
4 views

Sending a POST request in libGDX

How would I go about sending a POST request using libGDX in order to act as if I was logging in?When I use Postman to send a POST request to my server using IP:8080/login?email=EMAIL&password=...
0
votes
0answers
9 views

How can i can freeze credit held by another account in Stellar SDK?

Anyone is familiar with Stellar.org?please i need help . i read the guide of them but still i couldn't find a solution .this is the guidehttps://www.stellar.org/developers/guides/issuing-assets....
-1
votes
1answer
27 views

Making item lottery based on chances and item ids from table

I'm trying to figure out how to select a random item with it's own given chance from a table of values like this:itemlottery (npcid, item, chance) VALUES (9100100, 1402011, 167)itemlottery (npcid, ...
-1
votes
1answer
11 views

Spring Special Beans

Can we declare a special spring bean which can be instantiated before spring checks for the Spring Profiles declarations?The challenge is to set the active spring profile from a spring bean , but it ...
0
votes
0answers
7 views

Filtering RecycleView incorrect display of results

Discription:I have an android app, and in one of parts of it user can choose his skills, like tags in https://stackoverflow.comSo when user taps on plus button, he can see all available skills and ...
0
votes
1answer
18 views

combining null layout with card layout [java]

I'm trying to combine the cardlayout function with the null layout.However when i try to run the program it doesn't work. The buttons do not appear at the boundries i tell them. Am i doing something ...
0
votes
1answer
12 views

Dequeueing from a generic type queue, null pointer exception?

I am trying to make it dequeue the front node and print it out, however I am getting the following error: Exception in thread "main" java.lang.NullPointerExceptionat MyQueue.toString(MyQueue.java:...
-1
votes
0answers
13 views

How to inject MockMvc in Spring Boot?

I am following this tutorial about integration test in Spring Boot: http://www.baeldung.com/spring-boot-testingWell, but when I try to Inject MockMvc I always get: Error creating bean with name '...
-1
votes
1answer
13 views

Processing serial communication issue

I am using Processing (java) to communicate over serial to an Arduino which controls two servos and a laser. Everything works independently, however when I turn the laser on using Processing I am ...
0
votes
0answers
12 views

hashing with salt wildfly

I need help with wildfly and salt password hashing using PBKDF2 module.I get an error in wildfly debug.log like this PB0XX.. Invalid or mispelled module option: hmacAlgorithmI set up in standalone....
0
votes
0answers
17 views

Adding spark to jar causing errors

I am trying to add some spark dependencies to Maven. Everything works as expected when I run my main class directly but when I try to package everything into a jar and run it, it fails with:/usr/lib/...
-1
votes
0answers
11 views

Java Serialization inconsistency [duplicate]

I work on a multiplayer game and I've encountered a problem with the TCP protocol.We are currently building the matchmaking interface and logic, which consists of two states: Menu : Has a Play and ...
0
votes
1answer
18 views

Android emulator not working because of an internal error

I'm getting an error on the emulator when I try to run the app on android studio, the error is:Android Emulator closed because of an internal error: Detected a hanging thread 'QEMU2 main loop'. No ...
-1
votes
0answers
13 views

How do I query DB in thread and having the results sent back to main thread for processing?

I need to query some data from a MySQL database, which can take some time so I want to do it in a thread. But when I do get the results from the thread I somehow want to give these results back to the ...
-4
votes
0answers
15 views

Hashed File using java only

please help me ! Develop a program that creates and maintancns a heap file wit the following specifications:1) record size is fixed (stdnum, std name, major)2) bucket (bin) size is fixed, number ...
2
votes
5answers
43 views

Java streams vs Iterators

I have been playing with the new and shiny functional part of Java and one of the things that puzzle me the most are streams? What is their use? On Google I mostly found explanations of how to use ...
0
votes
0answers
21 views

Combinations of a matrix (rows and columns)

Good afternoon, I'm having problems finding all the combinations of a matrix.I am testing with a 4x4 matrix but I can not get the approximate 2000 possible combinations of its elements, but I only ...
0
votes
0answers
22 views

Can't inject Service with Repository to view

Been struggling with this problem for hours now. Im getting a NullPointerException: at com.vaadincrud.TodoView.(TodoView.java:30) ~[classes/:na] I can access the NoteService from the TodoView but no ...
0
votes
0answers
10 views

In memory graph queries

I have a Java application which is doing a lot of requests to Neo4j, and I would like to relieve Neo4j a bit to perform some operations like find, filter, sort, limit directly in RAM. In this case, I ...
0
votes
0answers
8 views

Java Implementation of OpenCV::projectPoints seems broken in this basic example

When I run projectPoints function using java code below with the most simple inputs I get what I believe is incorrect answer. Did I miss something?I get this answer(x,y,z)=[{0.0, 1.0, 1.0}, {0.0,...
0
votes
0answers
11 views

JSP content downloads instead of rendering - upgrading JBoss 7 to wildfly

We are trying to migrate our application from JBoss as 7.1.1 final to wildfly. the server now renders the html files at the root context but any request for any of the jsp files ends up as a download ...
0
votes
0answers
16 views

Using POST Requests to Log in to a Website in Java

I have been trying to access the website https://app.truckstop.com/ using JSoup and POST methods. I have been able to use POST methods to log into websites like Facebook and LinkedIn, but I can't seem ...
0
votes
0answers
10 views

Getting the content of a webpage as text/string and use it a a button label

I want to get the response/content of a web page. It's a simple page that only responds with a plain text like "online" or "offline".My goal is to get this text and set it to a buttonmyButton....
0
votes
1answer
22 views

More efficient Matrix determinant method in JAVA

I have written a method to calculate the determinant of an nXn matrix recursively using the Laplace Algorithm. I am aware it performs poorly as n gets larger, and I am also aware of other algorithms ...
-1
votes
1answer
13 views

Adding objects to arrayList using a CSV file, but the values of the objects are returning null

I'm trying to use a CSV file to create a list of employee objects, but I'm currently getting null for every value. The values being: username, firstname, lastname, email, gender, race, id, and ssn. I ...
0
votes
0answers
27 views

overrode equals(),but not hashcode() (and I have my @SuppressWarnings)

I'm getting the following error everytime I do -Xlint javac List.java:List.java:9: warning: [overrides] Class List overrides equals, but neither it nor any superclass overrides hashCode method...
0
votes
0answers
27 views

Executors Threads slow down when towards to end of job

I'm using this code with 150 threads to authenticate to a website using newFixedThreadPool, it works fine with a 1500 elements list but threads slow down (then become just completely stuck) when ...
0
votes
0answers
4 views

How to generate Log/XML from Java code to Gource

I have a problem. Probably. I want to generate xml or log file to create video of progress on my java code in program Gource. Can anyone tell me how to do that? I finded I must generate XML or Log ...
0
votes
0answers
6 views

Hystrix fallback executed even though run() was successful

I'm using Hystrix via Tenacity, a dropwizard module for hystrix https://github.com/yammer/tenacity, and I'm noticing that fallback() is called even though the run() method successfully runs.Here's ...

153050per page
angop.ao, elkhabar.com, noa.al, afghanpaper.com, bbc.com, time.com, cdc.gov, nih.gov, xnxx.com, github.com,