Questions tagged as 'java'

1
answer

Arrange labels vertically

I wanted to put panels in specific positions, so I tried combining some layout managers, but I still have not got the result I need. I tried to use gridLayout , so components would not be stretched, but I'm not sure if I'm making a bad...
asked by 01.04.2018 / 21:58
1
answer

The text file does not appear completely in JTextArea

I put it to show the packages, so you can tell me if I'm making the correct use of MVC If I save in txt: [Maria;32] ; [Joao;44] e [Luna,12]' It only shows me Nome: Maria Idade 32 and Nome Joao , the rest it ignores.    C...
asked by 18.12.2017 / 05:42
1
answer

How does the life cycle dependency injection work?

How does the 3 life cycles of a dependency injection work such as singleton, transient and scope?     
asked by 13.12.2017 / 23:22
1
answer

Two id in hibernate table

Is there a possibility of two fields being id in a hibernate table? I have two ids that need to be unique in pair on the table. But I do not know how to implement it.     
asked by 15.12.2017 / 00:25
1
answer

RecyclerView scroll position with Firebase

I'm listing Firebase data in a RecyclerView , but when adding data or removing, the data repeats in the list. I used clear(); or lista.removeAll(lista); to clear before filling only that the list is updated and returns the s...
asked by 11.12.2017 / 22:27
1
answer

Remove an ImageView

Is there any way to remove an image in an ImageView or leave it empty via code? For example: I "hedge" img1.setImageResource(R.drawable.icon_circpreto); How do you remove it via code?     
asked by 31.10.2017 / 04:52
1
answer

Manipulating a JSON with the GSON library

This is json: { "professor": [ { "latitude": -23.1843473, "longitude": -45.8840718, "title": "Microcamp", "endereco": "rua vilaça 2010" }, { "latitude": -23.1843473, "longitude": -45.8840718, "title": "Microcamp", "endereco": "...
asked by 30.10.2017 / 13:09
1
answer

Transfer objects between methods in a bean

I'm developing a web application using the framework bootsfaces in Java WEB On one of my screens I have a datafile of bootsfaces that when one of the lines is clicked, is selected by activating the method selectUser. This method receives a...
asked by 30.08.2017 / 14:50
1
answer

Boolean Array for Integer

How can I transform a boolean array, boolean[] bits into its corresponding Integer ? I have a function that does exactly the opposite, but I did not understand it enough to be able to invert it. int input = 62; boolean[] bits...
asked by 31.08.2017 / 21:13
1
answer

Doubt about the operation of the AudioRecord class

I am a beginner and I was trying to understand how to record an audio using android and how it processes that audio. And during the searches I found this site: Audio Record The example works perfectly. But I did not really understand how this...
asked by 22.09.2017 / 02:04