Questions tagged as 'java'

1
answer

The program can not call the set method of another class, even with it instantiated

When I call the setNomedoMetodo() method in another class, even with it instantiated, it appears:   The method setNaipe (String []) is undefined for the type Deck. I can not put a value in this method. Nor can I mix the cards. Here...
asked by 01.05.2018 / 22:11
1
answer

Sort a linked list with Selection algorithm in Java

I'm working with sorting algorithms. I implemented by ordering with Bubble sort, however, must be implemented with an example where the algorithm is not stable (Selection, Quicksort, Heapsort or Introsort). The idea is to sort a list of integers...
asked by 02.05.2018 / 15:33
1
answer

How to declare class list?

I have a class Usuario that will have a list of class Pastas , and this class will have a list of class Questão . public class Usuario{ String nome; ArrayList< Pasta > listaPasta; } My problem is not know...
asked by 30.04.2018 / 03:31
1
answer

Difficulties Session Hibernate

My web application uses Hibernate 4.3 and does Connection Pool control using C3P0. Difficulties happen on a recurring basis and unfortunately I can not seem to find the problem that causes such errors. Here's one of the errors: org.hiber...
asked by 30.04.2018 / 13:40
2
answers

String conversion to int

My xml ' <android.support.design.widget.AppBarLayout android:id="@+id/appBarLayout" android:layout_width="match_parent" android:layout_height="wrap_content" android:theme="@style/AppTheme.AppBarOverlay" app:layout_const...
asked by 27.04.2018 / 17:25
2
answers

Transaction control application rest in spring

I was studying a bit about the @Transactional annotation (Spring version), and I had a question. According to a publication made in DevMedia , the way more correct "to use is noting in our business method, because there can have several acti...
asked by 25.05.2018 / 19:09
1
answer

Json via POST giving error

Hello! I am sending a Json through an HttpClient and it is returning an error about header. Does anyone know what it can be? JsonDeDados = sender.sendMessageDATA(); List<NameValuePair> urlParameters = new ArrayList<NameVal...
asked by 11.06.2018 / 21:06
1
answer

How to show only folders in JFileChooser?

I have JFileChooser and I need it to show only the folders, however I can only display at least one file type or show all types. Here is sample code where I make the restriction for a file type: package NewClass; import javax.swing.file...
asked by 11.06.2018 / 02:32
1
answer

My client can not find my HttpServer?

This is my client's code: public static void main(String[] args) throws IOException, InterruptedException { SendData sender = new SendData(); String JsonDeDados; String infos = "informacoes"; Ht...
asked by 11.06.2018 / 22:37
1
answer

Textfield JavaFX with dynamic mask for monetary values

I'm trying to create a textfield java FX for a financial application. I would like this texfield to follow the same pattern as the numerical fields found in electronic banking boxes. For example: in ATM the initial value in the value field is "0...
asked by 12.04.2018 / 04:57