Questions tagged as 'java'

1
answer

Run unit tests with dependencies that are in the exclusions group

I have a scenario where I need to run a test with JUnit on a feature that has an external dependency, but to run this functionality on the application server I need to put this external dependency in the exclusions group on my pom.xml ....
asked by 30.10.2014 / 12:33
1
answer

Move from JFrame to JDialog

I've created a frame of this genre: Butsinceitwastoshowthattheclientwashavingtroubleconnectingtoaserver,itwasbettertoswitchtoJDialogProblem:IcannotgetJDialogvisibleCode:publicclassWaitingJoptionextendsJDialog{//seforJFramefuncionadireitopubli...
asked by 03.11.2014 / 16:16
1
answer

Clustered JSF application

What does my application (JSF + Primefaces) need to have to work on a cluster? I'm doing a test in a clustered 3 Tomcat environment (with session replication) and my test application does not work. At first, I only included the <dist...
asked by 30.10.2014 / 18:12
1
answer

How to compare these 2 arrays within this while?

I am developing a game similar to Forca, where the user has to hit the word chosen by the computer in up to 8 attempts. The variable mascara is an array of characters that corresponds to the word that the user sees on the screen (which...
asked by 16.06.2015 / 22:45
1
answer

Edit Button FXML Text

I can not change the text of the button created in FXML. Even though I put it inside initialize(... butao.setText("..."); it does not change. What do I do? PersonController, intializable: @Override public void initialize(URL arg0...
asked by 17.06.2015 / 20:05
2
answers

Problems with else if in servlet

I'm messing with jsp. In my servlet I have if and else if and both send to the same page, only with different values. However, when you enter the if option (it shows the result) and then when you return the page and t...
asked by 15.01.2015 / 21:57
1
answer

Mockito-Android Test method return

I am trying to test a return from a method of my class in an Android project. I'm doing it this way: MyClass var = Mockito.mock(MyClass.class); With this, I already have my instance. Now I need to test methods of this class, I did it this w...
asked by 14.01.2015 / 21:50
1
answer

Method not found:

When I click the save button to execute the method, the following error appears in the console: Jan 15, 2015 4:12:26 PM com.sun.faces.lifecycle.InvokeApplicationPhase execute Advertência: Method not found: validacaoAjax.FuncionarioBean@37f7dcb...
asked by 15.01.2015 / 19:20
1
answer

Error Attempt to invoke virtual method 'android.view.View android.view.Window.findViewById (int)' on a null object reference

I have this error and I can not solve it, it gives every time I run the app. LogCat: 01-15 16:09:03.380 2473-2473/com.prjctt.allan.financeiro E/AndroidRuntime﹕ FATAL EXCEPTION: main Process: com.prjctt.allan.financeiro, PID: 2473...
asked by 15.01.2015 / 19:29
1
answer

Include data in the DB in Java

I'm following a distance course, but I'm having trouble logging in. It does not include, but also does not present any error, and by the examples of the teacher that I followed, did not work. I have also seen several videotapes on the Internet a...
asked by 12.06.2015 / 19:18