Questions tagged as 'java'

1
answer

Help ... ListView does not show Items in fragment until after entering an activity and returning

I have an activity with 2 fragments, The first fragment that is the first one that opens opens the information correctly. The second fragment has a listView that contains a format as if they were comments, this listview fills it with da...
asked by 19.10.2017 / 21:18
1
answer

NavigationView Takes Too Much Space Toolbar

Currently estimated I use NavigationView <android.support.design.widget.NavigationView android:id="@+id/nav_view" android:layout_width="330dp" android:layout_height="match_parent" android:layout_gravity="star...
asked by 03.11.2017 / 18:24
1
answer

Android Keyboard with different @ type @

Currently I find that using my MASCARA class for the amounts written, as the phone reacts differently, this is my mask class public class Mask implements TextWatcher { private DecimalFormat df; private DecimalFormat dfnd; private boolean hasF...
asked by 02.11.2017 / 16:02
1
answer

Error in android.widget.Button.setOnClickListener, "Attempt to invoke virtual method"

Why do I have the following error:    Attempt to invoke virtual method ... on a null object reference the signIn.java is public class SignIn extends AppCompatActivity { EditText edtPhone,edtPassword; Button btnSignIn;...
asked by 12.11.2017 / 15:14
1
answer

Get field with jpa

I am working with jpa and to obtain this case a user through the nickname I use the following code: @Override public User obtenerPorNick(String nickName) { return entityManager.find(User.class, nickName); } That works. I understand that...
asked by 12.11.2017 / 19:40
2
answers

Remove elements from an array that are already in another array

Dear, I have an initial student array and an array of new students. How can I do to obtain an array of new students that are not in the initial student array? This using java lambdas. UPDATE List listaFinal = new ArrayList(); for (Alum...
asked by 14.11.2017 / 23:21
1
answer

Insert a large number of records in cassandra

I need to insert 1 million records in cassandra, I'm using the datastax driver, I have a correctly mapped teacher class and a list of teachers, then using the mapper I call the save method. Cluster cluster = Cluster.builder().addContac...
asked by 13.11.2017 / 17:33
1
answer

how is a data in java valid?

For example, I ask for a whole piece of information and when I enter a letter for example, tell me that the data entered is not valid. I have put this, but it does not work for me while (teclado.hasNextInt()==false) System.out.println...
asked by 08.10.2017 / 18:53
1
answer

Change row color in TableView JavaFX according to its value

Good morning! To the point I have an interface where I show a table with two columns, the first one is Placa and the other is Mileage. What I want to do is to get that according to the value that the Mileage column has in its cell its Backgro...
asked by 06.10.2017 / 18:25
1
answer

Control error when connecting to my MySQL database

I have the following code to make the connection to my MySQL database, what I want is to control the error that appears when I try to run the program, I miss the error / warning that the Xampp is off. I would like to know if there is any way to...
asked by 22.10.2017 / 13:23