Java (not to be confused with JavaScript) 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. Use this ...

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

0
votes
0answers
2 views

How to validate execution request parameter from spring web flow

I had a security report where they said that somebody can take advantage of the "execution" request parameter of spring webflow to crash my web application. I'm new with spring webflow and I was ...
0
votes
0answers
2 views

How to copy file from local master to hdfs(data node of slave machines)

I have set up a hadoop cluster of 4 machines, 1 master and 3 slaves. The master is only running the resource manager and the name node. Besides, right now the client(me) is colocated with the master ...
0
votes
0answers
2 views

Intellij automatically closes opened browsers when TestNG run is done

I love using Intellij IDEA, however there's a problem when using it for running selenium webdriver via testNG. As soon as the run is done, I guess Intellij performs some kind of cleanup and ...
0
votes
0answers
5 views

Eclipse fresh install doesn't start up

I installed eclipse mars on my new workstation, it is failing to startup. During startup I get these logs after which the eclipse window becomes blank. org.eclipse.m2e.logback.configuration: The ...
0
votes
0answers
2 views

RTSP video streaming mediaplayer “Couldn't open file on client side, trying server side”

I want to know how can I run RTSP OR RTP stream in my android application. I tried to set up first in VLC using the RTSP in streaming video. I open the another instance of vlc and input the valid url ...
0
votes
0answers
5 views

How to map one-to-many relationship with JAXB and JPA

I am using Apache Camel to retrieve information from a webservice. The retrieved information are unmarshalled with JAXB and mapped to an entity class to persist the information into a relational ...
0
votes
0answers
3 views

Solr grouping and highlighting

We are using SolrTemplate in spring to intergrate solr with our application. For a particular case we would like to have results by grouping on a field and highlighting the matched content in all the ...
0
votes
0answers
14 views

Unclicking listview elements

I am creating a listview where people can tick off books on the listview as they read them. When they select a book the alpha of the row goes to 0.2f and a toast appears telling them they read the ...
0
votes
0answers
4 views

TimerTask hangs

I am trying to launch a period task from main() via the TimerTask functionality in Java and the run() task is hanging. The code after the Timer is a REPL. The code looks like this: public static void ...
1
vote
0answers
10 views

Return 1 to 7 days of a week from any given interval of dates

I want to return a map of days from an interval of dates : From 1 to 7 days : From: "2016-02-09" to To: "2016-02-09" -> return : [Tue] From: "2016-02-09" to To: "2016-02-12" -> ...
0
votes
0answers
3 views

Set proper column title in my CSV using Jackson

I try to create a CSV file using jackson-dataformat-csv as described in this tutorial (Jackson Annotation method). Here is the definition of my Csv lines : @JsonPropertyOrder(value = {"foo", "bar"}) ...
1
vote
0answers
17 views

Can't convert string to date in Java, wrong timezone after conversion

I have an array of Strings with the dates e.g.: Tue, 09 Feb 2016 14:07:00 GMT; Tue, 09 Feb 2016 19:55:00 GMT. Now I want to find the most recent date on this list. In order to do that, I try to ...
-3
votes
1answer
31 views

Java - Array Shuffle from Array1 to Array 2

Im using Eclipes Android. So here's my array1, and I want it to transfer to another array(array2) randomly. I've been working on it for hours but I can't get it right. > int array1[]= > ...
0
votes
0answers
4 views

File on FTP server modified by different sessions

I am using "org.apache.commons.net.ftp.*" to edit a text file placed on an FTP server. I have a few different java applications that connect to that FTP server and append lines to that text file. ...
0
votes
0answers
6 views

Render ArrayTable java object on jsp in GridFormat

I am trying to find a way to render ArrayTable java object to render on jsp page in grid format. Does anybody has idea about this. Technology I am working on is struts.
0
votes
0answers
8 views

Populate TableView<T> with limited number of columns in reference to <T> number of fields

I have CustomTableView class: public class CustomTableView<T> extends TableView<T> { public CustomTableView(String[] columnsNames, String[] fieldsNames, ObservableList<T> data) ...
0
votes
0answers
7 views

EWS java.lang.NoSuchMethodError: org.joda.time.format.DateTimeFormatter.withZoneUTC

My application is trying to get a email from the inbox in java with the API EWS and I have a exception java.lang.NoSuchMethodError: ...
0
votes
1answer
3 views

Netty putting concurrent requests on queue

I have a problem with netty, I have a server with FutureChannel and Handlers ServerBootstrap b = new ServerBootstrap(); b.group(bossGroup, workerGroup) ...
0
votes
1answer
6 views

What is the best way to determin HSSF or XSSF is needed in Apache Poi?

I implement an upload service for Microsoft Excel files and can not be sure what kind of file is uploaded. Sometimes users upload files with xls extension that contain xlsx content. To parse the files ...
1
vote
0answers
3 views

created .owl (using Jena and Java) ontology file dosen't show in protage

I have created simple ontology using Jena and Java in Eclipse. It has 3 classess. "Information" is super class and "Book Information" and "Food Information" is 2 sub classes. I used following code for ...
-2
votes
0answers
19 views

(Java) Split up a range into smaller ranges

I'm working on a project where i need to split up a pot of "money"(or credits if you will) into different sizes, depending on the amount of money a player bets. It's a kind of jackpot system where ...
0
votes
0answers
17 views

Mutex with priority in JAVA

I need to build what I call an "Unfair Semaphore" with priority. For example : When a thread with "priority == 1" wants to acquire the semaphore, it just has to wait that other thread with the same ...
-1
votes
0answers
9 views

OpenMP and Pthread, Code?

We have a 2000*2000 Matrix Multiplication. at first we want to apply first decomposition via OpenMP and Pthread. Pattern Map I think that this is LU-Decomposition. Am i right?
0
votes
0answers
10 views

How do I update info in a class when I edit the jTable linked to it?

I'm working on an app which has a database object consisting of employee objects. The employees are represented as rows in a jTable. If you double-click on a row, a dialog with employee info pops up. ...
0
votes
0answers
9 views

Memoy access error in tess4j java

I am writting a program using tess4j.jar. The program is extrecting text and it's location from/in image. I recive this problem: Exception in thread "main" java.lang.Error: Invalid memory access at ...
0
votes
0answers
11 views

How to map an xsd element to owl elements graphically

Imagine a Java app converting one kind of xml file to another, for example, xsd to owl. There is library to display xml elements like a tree, you click on an element, the element either expands ...
0
votes
0answers
35 views

Java replace “\” in string doesnt work as expected

How can I replace \ with \\ in Java String? System.out.println(CSV_DIRECTORY+file.getOriginalFilename()); prints : C:\Documents\tmp String path = ...
-1
votes
0answers
7 views

War exploded: Error during artifact deployment. See server log for details

I try to implement spring security module in my test project, using this tutorial - http://websystique.com/spring-security/spring-security-4-hibernate-annotation-example/ The only difference is that ...
0
votes
0answers
11 views

How to access context.xml parameter?

I am developing an application and deploying it in Tomcat 7. I have defined some parameters in /etc/tomcat7/context.xml. How can I access them from my Java application? context.xml <Context> ...
0
votes
1answer
24 views

How to keep the application window alive even after running?

I have created a java program. Exported it as an JAR via Eclipse and then using Launch4j I converted the jar file to an exe file with an header type of Console. The program runs successfully asks the ...
1
vote
0answers
22 views

How to convert cron expression to date or time

I am trying to convert the cron expression to date. for example this is 0 0 23 1 1-12 ? expression. I want to convert to corresponding date. How do I achieve this? This is what I tried but it just ...
0
votes
0answers
7 views

maven site throws cannot find symbol

I've an E4 project that build (mvn install) and launches fine inside eclipse and as a stand alone product. When I run a mvn site I get the following error [ERROR] Failed to execute goal ...
0
votes
0answers
14 views

how to build session based shopping cart using jsp, servlet and DAO

cant figure out how to go about building a shopping cart using jsp, servlet and DAO. like when a using clicks on add to cart button, it should display number of items in the shopping cart, and total ...
1
vote
0answers
8 views

Instantiate child object with params from parent object being deserialized with GSON and use generics?

I have roughly the following structure class MyDeserialParent<T extends MyChildInterface> { MyChildInterface mSerialChild; ... //some other fields (not 'type') } But it's ...
0
votes
0answers
5 views

Upstream messaging in Android Studio using Google Cloud Messaging(GCM) module with Google App Engine

I'm currently trying to make use of the 'Google Cloud Messaging(GCM)' in my Android application project. Specifically, I'm working on making the 'backend' with the Google App Engine(GAE) and have ...
-3
votes
0answers
17 views

Android Studio: App unfortunately stopped

I'm trying to write a simple maths app to get used to Android Studio. But I already have a problem. When I want to start the app on the emulator a message pops up and tells me that the app stopped. ...
1
vote
0answers
25 views

Reading numbers from excel file - Java - Swing

I created a tool that I can upload and get some numbers from excel file public static void main( String[] args ) throws Exception { JFileChooser fc = new JFileChooser(); int returnVal = ...
1
vote
2answers
39 views

Getting nullpointerexception despite assinging a value to it

I am creating a basic android app. I am creating a TextView object called mathexpresionTV and assigning to the value of the id of the textview I want it to reference to. TextView mathExpressionTV = ...
-1
votes
0answers
8 views

ServerSocket stuck on accepting clients

I'm trying to develop host/client communication on android using ServerSocket. I used the following webpage which I found here on SO as source: ...
-2
votes
0answers
15 views

Finch: Can't find the JAR File

I try to find JAR of Finch class, any JAR file for this Class
0
votes
2answers
30 views

How to create a simple game loop that doesn't need drawing

I'm still having a lot of trouble wrapping my head around game loops and where the code actually sits in the program. To learn the basics, I would like to add a very simple loop to this activity, but ...
0
votes
0answers
7 views

Difference between dimensions and matrices in google analytics

I am new to google analytics and have started to learn how to form a query on a profile, I was not getting the difference between dimensions and matrices in the Query. Also, how do we concatenate 2 ...
0
votes
0answers
6 views

Registering multiple styles of an external font in java swing

I want to include a font as a resource file in my deployed application. To use it in swing, I know that I can import a font like this: InputStream is_regular = ...
0
votes
0answers
11 views

Java JRE versions install and use multiple on windows

I have two Applications one works best with JRE 1.6, on JRE higher than this it has some bugs. The another one is JavaFX application With ".exe" launcher. I have installed JRE 1.8.0_73 and JRE ...
-2
votes
0answers
19 views

StringBuilder taking time to store String value

I have my logs being stored into a StringBuilder Object . There are almost 214873 lines that are getting stored. Each time when the code finds an error , the error message is stored in StringBuilder ...
-3
votes
0answers
16 views

TextToSpeech without Internet

Is there any code or API for converting text to speech without internet connectivity? I have tried SpeechSynthesisUtterance, also google text to speech Api it doesn't work these days.
0
votes
0answers
7 views

TrueZip - How to get Size of a Folder within an Zip Archive

is there a way to get the Size of a folder with TrueZip without doing it myself recursively? I'm concerned about the runtime since I'm dealing with Archives that contain lots of files. Using TrueZip ...
0
votes
0answers
9 views

Android Data Binding layout_width and layout_height

I need to be able to dynamically set an EditText's height property. I am using data binding for other properties throughout my app, so I would love to be able to use data binding to control the height ...
0
votes
0answers
6 views

Animate checkmark drawing

I have a ProgressBar in my app which runs while I do some tasks in the background. When these tasks are finished, I want the ProgressBar to turn into a checkmark. The checkmark should'nt just appear ...
2
votes
0answers
19 views

I can't send a JSON object to JAX-RS (Jersey) service with POST

I devlop an Angular application and I will consume the Restfull service developped by Java (JAX-RS - Jersey). This is my service: @POST @Path("/add") @Consumes(MediaType.APPLICATION_JSON) ...