Questions tagged as 'java'

1
answer

Leave some data from a non-mandatory java interface

I use interfaces to call android. public interface CallbackUsuario { void resultadoSalvar(boolean b); void resultadoTrazer(Usuario u); void resultadoListar(List<Usuario> lista); void resultadoExcluir(boolean b); void...
asked by 22.10.2016 / 14:20
1
answer

Return numbers from a String

I am programmer PHP and maintaining a project Java I saw myself with the need to return only numbers contained in a certain String . I did not find any questions about this in SOpt and I found it in SOen, so I bring this q...
asked by 10.11.2016 / 18:38
1
answer

Doubt About Socket Logic

I have a question regarding identifying socket. Suppose I have 2 "socket types", a client and an attendant. Where is the chat of the 2, I can have several clients and several attendants, but my question is, how to identify each one? I'm doing...
asked by 31.10.2016 / 05:08
1
answer

How to modify an attribute of an object in an ArrayList?

I created a ArrayList(objetoQueCriei) , and I would like during program execution to change the value of the attributes of those objects in the array. Do you have any commands to do this? I tried to use the set command, but would...
asked by 22.10.2016 / 01:50
1
answer

Change the Actionbar title in old versions

Hello, I have four screens in my android application and I want every screen in the action bar to have a different name. I tried changing the title using getActionBar().setTile() : Only as I have API 9 as a minimum version and I c...
asked by 13.11.2016 / 21:53
2
answers

Many to One Hibernate Java

I have 2 entities:    Contracts, which has only id, number       Additive, which has id, number, contract The additive contract is a foreign key, in the database it is working right works like this: 1 contract may have several additiv...
asked by 10.11.2016 / 11:48
1
answer

How can I get the style effect of listView?

I have a layout and I want to display the data in this ListView but I need it to be white background without stripes and no click enabled when it is played. Can I do it this way ??     
asked by 31.01.2017 / 03:17
1
answer

How to display the date and time "at runtime"?

I would like to know how to display the current date and time of the computer, and the time must be updated at run time. I thought of passing an object to a label, but it did not. I will not save that date, I just want it to be displayed, I want...
asked by 04.02.2017 / 13:50
1
answer

Calendar is not working correctly

My conversion from timestamp to calendar was apparently successful, since the data presented appears correct except for the day of the week.    data = (java.util.GregorianCalendar)   java.util.GregorianCalendar [time = -125784706799416, areFi...
asked by 31.01.2017 / 02:37
1
answer

How to get back to the activity and execute a method? [duplicate]

I have a Profile.class activity and it shows my photos, when clicking on it, opens a fragmentDialog showing the photo in slideshow ... but when deleting the photo, I need to go back to my profile and update my photos, running photos (myID);...
asked by 29.09.2016 / 21:07