Questions tagged as 'java'

1
answer

Count lines Scanner

Could someone explain to me how to count the lines of a Scanner text so that after counting it can return to the starting line?     
asked by 22.04.2014 / 20:02
1
answer

How to change the default schema of postgresql in persistence.xml in a java application

I'm developing an application and I'm having a hard time changing the default application schema. I'm using PostgreSQL in a Java application with JPA and Hibernate as an implementation. persistence.xml <persistence-unit name="comu...
asked by 19.04.2014 / 23:38
3
answers

Get an array in JAVA

I am new to java, because of this I have the following situation, I would like to get the array in my case 2 of switch , the problem is that it says that the value was not initialized , but I first enter the values and size based...
asked by 20.08.2016 / 21:43
1
answer

Unable to create managed bean

I have a problem here in java that I do not know how to solve nor what it may be because I am learning to program with java for the web and I do not know the possible causes of the following error javax.servlet.ServletException: Unable to cr...
asked by 26.08.2015 / 17:47
1
answer

How do I check if my spring application is in the production environment?

When in production, when I fall into an exception, send an email to the support but only in production, in development I do not want it to perform this task.     
asked by 19.08.2015 / 20:55
2
answers

Updating values in a ListView

I add values that are within 3 arrays in hashMap to insert in listview : ArrayList<HashMap<String, String>> lista = new ArrayList<HashMap<String,String>>(); for(int i=0; i<tema.length; i++ )...
asked by 06.02.2014 / 18:07
2
answers

Primefaces, button requires two clicks to perform action

When I execute the code below, I have to double-click the button so that the delete action happens, I saw many with similar problems, but no effective solution: <h:form id="TablePais" prependId="false" > <p:dataTable id="tbPa...
asked by 01.04.2014 / 02:32
3
answers

Java 8 + Android

Is it possible to use the full potential of the Java 8 API (lambda queries and etc) on Android systems? If yes, is it worth the migration already?     
asked by 29.03.2014 / 11:48
2
answers

Loop with options

How do I create a loop with options in Java? For example: "type 1 to save and 2 to delete". And when doing the commands of each option, go back to the: "type 1 to save and 2 to delete". import java.io.*; public class CadastroPessoa{ public...
asked by 04.04.2014 / 22:53
1
answer

How to create a project with JSF, Primefaces and Tomcat that runs in Eclipse and Netbeans at the same time?

How can I create a Maven project with JSF, Primefaces and Apache Tomcat so it runs in both Eclipse and Netbeans without any problems? (Preferably with the latest versions of the technologies)?     
asked by 02.05.2014 / 03:19