Questions tagged as 'java'

2
answers

Integrate Java application with Nagios

I'm developing an application that monitors assets (air conditioners, lamps, etc.) in a certain room and the floor plan of that room is illustrated in Nagios with assets in place. I would like that after my application did a status check of t...
asked by 05.11.2014 / 19:50
2
answers

Use the hardware back button for another function

I have an app with several Activitys, whenever I change from Activity I execute the following commands: Intent intent = new Intent(gerenciar2.this, excluir.class); intent.putExtra("tabbanco", tabbanco); intent.p...
asked by 07.11.2014 / 18:02
2
answers

Inheritance and manipulation of methods of a superclass

Inheritance is said that a subclass inherits all methods from a superclass. But when doing class Soma{ private double total; public void setSoma(double s1, double s2) { total = s1+s2; } public double getSoma() {...
asked by 28.02.2015 / 13:55
3
answers

how to change the color of the button via code in android?

How to change the color of the button via code, because when touching the button I want it to change the color, the color is inside the drawable.     
asked by 18.02.2015 / 18:49
1
answer

Can not find symbol - variable calories

Because of this error if I am setting the calories in ifs ? import java.util.Scanner; public class Alimentos { public static void main(String args[]){ Scanner in = new Scanner(System.in); System.out.println("\nDigite...
asked by 22.03.2015 / 21:36
1
answer

How to change a dynamic content of a template when the user clicks a button?

I would like the middle of the page to be changed when the user clicks "login" or "registry". Can someone explain to me how I can do this? If you know tutorials that teach how to log in and if you can leave the links, I would appreciate it....
asked by 01.09.2015 / 18:31
2
answers

How to avoid automatic closing in DialogFragment? [duplicate]

I developed a login screen, as shown in the figure below, following the " Creating a Custom Layout " section of official documentation . TheonlyproblemIamfacingisthatdialogclosesregardlessoftheoptionIclickon.HowdoIpreventautocompletionfro...
asked by 07.09.2015 / 22:39
1
answer

How to manipulate Iterator position

I need to compare all the elements of a list 2 to 2 I'm doing in the following way: List: 1, 2, 3, 4. Comparison: 1 and 2, 1 and 3, 1 and 4, 2 and 1, 2 and 3 ... I'm using this way: Iterator<Policie> p1Iterator = setOfPolici...
asked by 15.09.2015 / 15:42
2
answers

How to call a Java method using jQuery?

I need to call a method that adds a ArrayList to what the user reported in dynamically generated tags when they click "add". Any suggestion? I was trying to do it using AJAX, but I have not been successful yet. The value entered by the...
asked by 16.10.2014 / 20:34
2
answers

verification function always returning true

I have a layout with several edittext (16) and wanted to do a check if it was changed. when I call this layout I load all my edittexts with data from the database, having the user the option to save /, change pages, exit, among others I wanted t...
asked by 24.10.2014 / 21:16