Questions tagged as 'java'

1
answer

How to print only numbers that are repeated between two different formulas?

I have two 50-number formulas. One has multiples of 3 and the other multiples of 7 . Code: public static void main(String[] args) { BigInteger start = new BigInteger("1"); BigInteger limit = new BigInteger("5...
asked by 13.02.2018 / 02:40
2
answers

problems with query in hql

I'm doing a registration project. The goal is to register and consult clients and employees, however, it is already possible to save the data, the problem is to consult. for query I made JPanel forms (I'm using netbeans), where to query one must...
asked by 13.03.2018 / 20:20
1
answer

Help with leveling system (RPG)

Hello, I'm trying to build a leveling system (like an RPG). So far I have this: Math.floor(1000 * Math.pow(level, 1.5F)); Here I enter the level, and I get the EXP needed to reach it. But now I need to do the opposite, I need to enter the E...
asked by 17.02.2018 / 19:18
1
answer

How do I start by editing a JFrame on hand and continue the final adjustments through the Netbeans "dashboard"? [closed]

I was able to create by writing the code or generating a new file of type javaswing + JFrame , but I would like to do writing the code and continue editing with the "panel", without needing to add a "new file.     
asked by 17.02.2018 / 22:17
2
answers

How the item.setOnClickListener works (view - method ())

How does this item.setOnClickListener(view -> method()); work? I had never seen this type of call, I saw it today and I was curious about this view , where does it come from? How does this type of call work? @Override publi...
asked by 20.04.2018 / 07:01
2
answers

Enum getting next code in Java

I have a class in java that one of its attributes is an enum and has the following values: HIPERTROFIA(1, "Hipertrofia"), DEFINICAO(2, "Definição"), RESISTENCIA(3, "Resistência"), OUTROS(4, "Outros"); When I send the value 0...
asked by 29.03.2018 / 15:59
1
answer

How to create browser tabs in Android Studio

Hello, I'm creating a browser for Android using Android Studio I'm trying to create a resource that has in all browsers that are multiple tabs like Google Chrome, but I'm out of luck and all my attempts are failing, does anyone know how to create...
asked by 10.04.2018 / 02:59
2
answers

JSON Infinite when using @ManyToMany GET

I have two classes, which has a @ManyToMany relationship generating the third table described in the code below: Card package br.com.rpgnext.deck.critical.model; import com.fasterxml.jackson.annotation.*; import javax.persistence.*; imp...
asked by 10.04.2018 / 16:16
1
answer

Stopping a while loop

I'm developing a system with JFrame from a pharmacy. It's a matter of faculty. In the box operator enters the quantity X of product that the customer chooses from a list of n products and then with the unit value of each product that is worth Y....
asked by 17.04.2018 / 18:00
1
answer

Null object in array - Android Base adapter

Hello I was doing a gallery, I created the Adapter, it worked normally, then proceed to the step of listing files in a directory and then put it in the list: ArrayList<GalleryItem>items = new ArrayList<>(); File pa...
asked by 18.01.2018 / 15:23