Questions tagged as 'java'

1
answer

Send image to Server

When I send a [] byte converted to String to the server on the server it comes empty or bursts. I do not understand why. Bitmap photo = (Bitmap)data.getExtras().get("data"); photo = Bitmap.createScaledBitmap(photo, 800, 1...
asked by 05.12.2016 / 19:29
0
answers

Traveling salesman resolution using genetic algorithm

Friends, I'm developing a solution tailored to the traveling salesman problem using genetic algorithms, to solve the problem I got a chromosome crossing function ready on the internet, but I'm not understanding how it works, she would be doing t...
asked by 07.11.2016 / 21:23
1
answer

N x N relationship in Java objects

I have a table item (item_id (pk), descrição, ...), A vendor table (fornecedor_id (pk), nome, ...) and because it is a NxN relation I have an intermediate table vendor_list (item_id (fk), fornecedor_id (fk), codigo, ...). How do...
asked by 07.11.2016 / 19:07
0
answers

How to use setCaretPosition in JFormattedTextField?

I'm having trouble setting the cursor at the beginning of the field, using the setCaretPosition (0); in the TextField fields, it works correctly, however, in any field with masks (of type JFormattedTextField ), it does not work. Can anyone...
asked by 07.11.2016 / 13:31
2
answers

Adding new fields dynamically

I'm creating an app that calculates credits from a school report. DUVIDA : How to add a new EditText when the user clicks the next "+" button and sums the values of each EditText .     
asked by 11.09.2016 / 05:17
0
answers

Could not find or load main class

I recently formatted my computer and am having trouble running my java programs. I'm using linux mint and the settings are as follows: java -version java version "1.8.0_101" Java(TM) SE Runtime Environment (build 1.8.0_101-b13) Java HotS...
asked by 15.10.2016 / 18:29
0
answers

How to generate a list with data from an Android Checkbox?

I'm developing an Android app for pizzeria that generates a list of checked CheckBox ingredients, that is, the user gives a "check" on the items they want for their pizza like catupiry, calabresa, onion, etc., and so on. the list is mounted....
asked by 19.10.2016 / 02:11
0
answers

How to compare the day of a LocalDate in CriteriaBuilder

I have an entity that has a LocalDate field. @Entity @Table(name="feriado") public class Feriado implements Serializable{ private static final long serialVersionUID = 1L; @Id @GeneratedValue(strategy = Generatio...
asked by 19.10.2016 / 22:00
1
answer

NoClassDefFoundError - Only running via Jenkins

Hello, I have an automation project with selenium + java + maven integrated in Jenkins. Today I did a refactor on it by moving some classes to new packages. In my machine there is no problem of compilation or execution, it runs everything...
asked by 20.10.2016 / 00:23
2
answers

Random button with isEmpty ();

Hello, I'm new to programming with Java and now a little Android. I am trying to use Random to issue random messages if nothing is typed. So, my code looks like this: public class MainActivity extends AppCompatActivity { private EditTe...
asked by 25.11.2016 / 16:37