Java is a high-level, platform-independent, object-oriented programming language originally developed by Sun Microsystems. Java is currently owned by Oracle, which purchased Sun in 2010.

learn more… | top users | synonyms

1
vote
5answers
358 views

Fixing bugs in other peoples code

I'm working with another programmer and we are always having issues with refactoring or changing each others code. Recently I had to fix a bug, but I pushed the changes before notifying him. He was ...
0
votes
1answer
35 views

Should I seperate a web api from the webserver?

Lets say I'm building a site similar to this or Quora (or some arbitrary blog-like site). I need a real-time component that will be using web-sockets/long-polling to notify the user of new posts, ...
0
votes
2answers
34 views

SOAP message testing

I am working in Scala, but the question is also relevant for Java indeed. I'm testing the messaging infrastructure of a part of my system that I did several years ago with CXF and Java. Today I ...
0
votes
1answer
58 views

Broadcast receiver Or Services

I am creating an "Alarm Clock" app in Android. I learned that we can implement OnReciever() method and write those things which we want the alarm to do after an intent is fired. But I have now come ...
1
vote
2answers
278 views

Is it necessary to memorize every line of code when it comes to game development?

I am currently following along a youtube tutorial here and from what I understand we are starting out by creating an engine to run the game. Should I be able to implement all of this by myself without ...
1
vote
1answer
33 views

How to allow multiple plugins to provide data for multiple aggregation processes?

I'm working on a Java project in which we want to have data collection plugins that collect data to be processed by one or more data aggregation modules. The plugins will all written in-house. Say for ...
0
votes
1answer
128 views

Dynamic query in Mysql

I'm doing a J2EE web application with Struts2, Mybatis and a MySQL database, so what I want to allow to the user is to be free to choose different parameters to perform a select to a table in the ...
-1
votes
0answers
16 views

Problem in integrating JFXPanel in an existing java swing project [on hold]

java.lang.UnsatisfiedLinkError: com.sun.glass.ui.gtk.GtkTimer._start(Ljava/lang/Runnable;I)J at com.sun.glass.ui.gtk.GtkTimer._start(Native Method) at ...
1
vote
3answers
142 views

Filtering a List

I will try to simplify my problem. Let say I have a collection (more specifically a List) with different types of elements, for explanation purpose let say we have objects "Person" with different age ...
0
votes
1answer
515 views

Java: How to manage UDP client-server state

I am trying to write a Java application that works similar to MapReduce. There is a server and several workers. Workers may come and go as they please and the membership to the group has a soft-state. ...
-2
votes
0answers
34 views

Learning Android programming [on hold]

I have tried to learn Android with Eclipse for a month, and im trying to learn how to make a strategy game, and need to learn how to make days pass and you get different messages. Is there any ...
0
votes
0answers
122 views

Is Tomcat smart enough to make use of multi core processor?

I am developing a tool using servlets. In order to make something to work way faster I have to do multi-threading in Java. My question is can the Tomcat server do it behind a scene? On another ...
0
votes
0answers
44 views

Java swing - fading in a component by alpha setBackground, correct synchronization [migrated]

I am making my first GUI, for a project of mine. I made the first page, login for it. Now I have a login button which should let the controller know when it's clicked and pass the username and ...
0
votes
2answers
112 views

DTO - service layer - statelessness best practices interfering with each other

I am designing a REST API coupled with a service layer that takes DTOs as input and produces them as output. This works fine for most service calls where the DTO is used to access an underlying ...
36
votes
2answers
19k views

When not to use Google Web Toolkit? [closed]

I'm considering use of GWT on a major in-house web app development project, namely it's major advantage in my eyes is the cross-compilation to Javascript which would (at least theoretically) help my ...
-3
votes
0answers
51 views

Fastest means of communication within a WIFI network [on hold]

I'm looking for a way by which two devices could communicate multiple zipped files within the network. I'm planning to do it as a http service call using a server, but it might be slow when compared ...
0
votes
0answers
24 views

docker-izing a classical db-based webapp - single or multiple containers?

i have a classic java webapp. its composed of a database (postgresql), a servlet container (tomcat) and my code (deployed on tomcat as a *.war file). i want to package/deploy it using docker (mostly ...
0
votes
0answers
51 views

Referencing a library in a project in a way that allows dependent libraries to reference classes in them as well?

In this specific case, I'm working with Bukkit and Forge for Minecraft. I have bukkit plugins that reference my bukkit library and forge mods that reference my forge library. Naturally, there are a ...
1
vote
2answers
139 views

Do I need to care about 'Thread safety' in java web applications

I have general understanding that what thread safety means , but I don't know much about threads in context of a java webapplication. I am just curious to know that do I need to concern about thread ...
-2
votes
0answers
54 views

Good way to improve java [on hold]

I just finished my first year in computer science and have learnt java as a core part of my course. So far I am familiar with the following: loops, conditional statements, objects, basic GUI etc ...
-3
votes
1answer
121 views

Newbie worried about starting java career [on hold]

I'm a newbie student fascinated with java its functioning and its future scope. I've already completed my college but I didn't get a job so currently I'm working as a BPO employee but I haven't given ...
0
votes
1answer
64 views

In a REST service project, where should we put code that calls a third party REST API?

My project is organized in layers like Configuration Controller Service Repository Domain Our REST Controller is in the Controller layer. We need to connect to another API via REST calls and I'm ...
1
vote
1answer
328 views

JSP Include: one large bean or bean for each include

I want to refactor a webapp that consists of very distorted JSPs and servlets. Because we can't switch to a web framework easily we have to keep JSPs and Servlets, and now we are in doubt how to ...
0
votes
4answers
123 views

Should each method have a seperate JUnit test class?

I am writing JUnit unit tests for my classes. Is it better to have a separate class for each method, or have just one test class for every actual class?
1
vote
1answer
148 views

Java and rest OOP languages - when to use super or this keywords

I have been programming java for like a year or more, and i have always used the this and super keywords. And yesterday my mate read one source of mine, and told me not to over use it unless you are ...
-2
votes
0answers
30 views

how Java Application without main method (Karel The Robot) [migrated]

I was wondering in the program like Karel the Robot. It does not use main(), but instead instead it used run() method. import stanford.karel.Karel; public class CollectNewspaperKarel extends Karel { ...
-1
votes
0answers
33 views

Android Studio 0.8 offline guide and tips before creating project [on hold]

I want to learn Android Development and I am thinking of using Android Studio. Just downloaded Android Studio 0.8 BETA. Installed it. Now, I have low bandwidth connection and building an android ...
0
votes
0answers
20 views

Using delimiter in java Scanner class to read a comma seperated file [migrated]

I am trying to assign values in a file using a comma as a delimiter. The problem arises after the first line, because there is no comma at the end of the first line, so the Scanner is reading the last ...
2
votes
2answers
293 views

Why to declare a String (as final) and then use it?

In a typical spring mvc validator class, while inserting an errorCode value in the Errors object, what difference does it make between using a String (props.somefield.req) like so ...
2
votes
0answers
138 views

How to evaluate JNI approaches with Java and Fortran? [on hold]

Right now we've got about 150k lines of Java broken into two major parts. The first contains an implementation of the algorithms we're hoping to redo in Fortran, and the second has a good chunk of GUI ...
-1
votes
6answers
403 views

How does polymorphism help a programmer? [on hold]

I have been trying to understand the importance of the concept of polymorphism in Java, and I understand that it means to use a interface's object to call subclass methods. I've been reading an ...
0
votes
1answer
134 views

Is Akka a good solution for a concurrent pipeline/workflow problem?

Disclaimer: I am brand new to Akka and the concept of Actors/Event-Driven Architectures in general. I have to implement a fairly complex problem where users can configure a "concurrent pipeline": ...
1
vote
1answer
124 views

How to design extension mechanism for java app

I have an application where I have a set of core features. The application itself HAS to work in core only mode. I would also want to make the application extensible such that, when certain ...
0
votes
3answers
120 views

How should I approach storing single boolean results for a whole table?

I previously asked this question on stack overflow. But have not received any responses that might help me. So I thought I would try here. ...
1
vote
1answer
119 views

From a DDD perspective is a report generating service a domain service or an infrastructure service?

Let assume we have the following service whose responsibility is to generate Excel reports: class ExcelReportService{ public String generateReport(String fileFormatFilePath, ResultSet data){ ...
4
votes
3answers
194 views

What is the best use case for selenium?

I've been trying to develop web applications while at the same time creating the testing. I understand unit testing, I can declare a test method and test specific methods in my application. But I ...
-1
votes
0answers
32 views

why java standards were opted for android [duplicate]

I am an android developer and was doing some work, just came across this little thing that why the java standard were opted for the android development. There are other platforms too,that was capable ...
-1
votes
0answers
31 views

Implement feedback/progress bar in JSP/Servlets [closed]

I'm changing old PHP code to Java servelets/jsp etc. I want to give the user feedback on the process going on in the back-end, some sort of progress bar. How can that be implemented with servlets? You ...
-2
votes
3answers
137 views

Trying to understand how MySQL license applies to code I wrote

I have an ERP, coded with Java and the database in MYSQL Community edition. When I was going to sell it to a client he asked me for the sources to my application (with the belief that it is GPLed). I ...
1
vote
3answers
308 views

Passing data between hundreds of objects in java [on hold]

Currently, I'm working with a group on building a model. This model simulates interactions between many "agents" in a region. Agents can be any entity such as a city, a farmer, a business etc. Each ...
0
votes
0answers
30 views

Can PhoneGap and RoboVm work in harmony?

The Goal is to make an iOS app using phonegap and java. When writing phonegap plugins that interact with native code (objective-c) would it be possible instead to make it interact with java when using ...
0
votes
1answer
109 views

What is design pattern/paradigm for ASP.NET web-apps? [on hold]

I don't actually know if my question is correct, but working on a webapp porting from ASP.NET world to Java + Spring platform I came up with this question in mind. Using Spring MVC, the new version ...
0
votes
3answers
131 views

What constitutes a good Database System(Java / SQL related) [on hold]

I've given this so much research but still couldn't come to my own conclusion, before continuing this question I would like to give you a rough idea of my current situation. I'm 18 years old and have ...
5
votes
2answers
350 views

I don't know how to understand the Wildcard type in Java

I am reading the Core Java (9th edition) by Cay S. Horstmann and Gary Cornell. After making an effort, I cannot still understand the ? super Manager. Here are some materials relating to this question. ...
7
votes
4answers
2k views

Multiple Same Object Instantiation

What exactly happens in Java when you instantiate the same object multiple times? For example: Test test = new Test(); then later on I will call it again, Test test = new Test(); again or inside a ...
-1
votes
0answers
53 views

Does an Oracle Java Certification expire? [closed]

I was recently told that "older" certifications do not expire, but the "newer" certifications do expire (they didn't clarify the cutoff between newer and older). I have not been able to find anything ...
0
votes
2answers
686 views

What techniques would you use for a next generation java web application? [closed]

I'm working at a site similar to Foursquare and Yelp, with approximately 100000 unique requests each week that generates content, growing steadily. We are currently using: Seam as Java web ...
2
votes
1answer
328 views

Is it safe to convert Windows file paths to Unix file paths with a simple replace?

So for example say I had it so that all of my files will be transferred from a windows machine to a unix machine as such: C:\test\myFile.txt to {somewhere}/test/myFile.txt (drive letter is irrelevant ...
2
votes
3answers
220 views

Duck typing in statically-typed languages

Is it a fair assumption to say that an overloaded constructor for a class can be thought of as a 'duck' for duck typing? Let's say that ClassA has an overloaded constructor, it would stand to reason ...
-3
votes
0answers
19 views

need help with Spring Integration [closed]

I have 3 web applications, client, integration service and let's call it server. I need to pass REST request from client to integration service and then redirect that to server. After that I need to ...