Questions tagged as 'java'

1
answer

How to write the percentage symbol in a string in Java?

How to make the string accept the percent symbol ' % '?     
asked by 23.05.2015 / 17:35
1
answer

Proxy project pattern, why use?

This example proxy pattern can be found on Wikipedia. reference: link What I want to know is this: Why should I use this pattern? When should I use it? Why is it good? What would be a wrong way to do this pattern? Are there any f...
asked by 08.06.2015 / 16:26
1
answer

How do I set a char in a PreparedStatement?

My FuelType variable is a char how to set this in the PreparedStatement? PreparedStatement ps = conexao.prepareStatement(sql); ps.setString(1, veiculo.getTipoCombustivel());     
asked by 02.06.2015 / 19:18
2
answers

Filtering records of a String Array by space-separated words in Java

How do I filter the records of a Array by using the search terms separated by spaço ? Example: I have a% of String% with the following records. bottle opener box with blue padlock 30mm brass padlock with 03 keys 100mm scre...
asked by 07.05.2015 / 20:34
1
answer

Class creation that returns a String

Hello everyone, I'm a beginner in Java and I'm having a problem, I'm trying to create a class that returns a String . I create the file .java and paste my code but it gives the following error in the declaration String : Sy...
asked by 18.05.2015 / 21:09
1
answer

Failed to execute goal org.apache.maven.plugins: maven-compiler-plugin: 2.5.1: compile (default-compile)

When I click on the install in any of my three MVC parts, it references the error quoted. ================================================================================ Scanning for projects... [INFO] [INFO] Using the builder org.ap...
asked by 19.05.2015 / 14:45
1
answer

How to clone values from an object

How can we make an object equal to an object's "values"? Since my object has other objects, and lists of other objects.     
asked by 24.09.2015 / 21:07
1
answer

How to execute a back bean method from a JavaScript function?

I'm developing a web page with canvas in HTML 5, it will be displayed in dashboards in real time, so I use ManagedBean to return their values, I have a component developed in JavaScript with its variable declared as global, and every 3 se...
asked by 20.10.2014 / 20:26
1
answer

JPA subselect in MANYTOMANY

I'm developing a system with java + jpa + mysql but now I have a question that I still can not find the answer ... Given the tables and entities below, I would like to set up a jpql to perform the following query in native SQL: SELECT * FROM p...
asked by 24.09.2015 / 20:20
2
answers

Loop Infinite Java

How do I get the Infinite Loop out of this class? Every time it is the last information from the database it continues sending email. public class Dia06 { public static final long TEMPO = (14 * 1440); protected static final String Class = n...
asked by 23.10.2014 / 02:17