Questions tagged as 'java'

0
answers

Undocking Controller GUI

Hello. Consider: a Visio object - GUI (Graphical User Interface); a Controller object, which handles system events, GUI actions, and model objects Consider that a Vision object receives a Controller object as a parameter: Contro...
asked by 23.11.2018 / 20:44
1
answer

How to close jframe from an actionPerformed? [duplicate]

I created a login java application, but I can not close the screen during ActionPerformed of the button with this.dispose(); What do I do to make it work? Code: import java.awt.EventQueue; import javax.swing.JFrame; imp...
asked by 23.11.2018 / 19:49
1
answer

Background location android studio

---------- This is my service public class LocationMonitoringService extends Service implements GoogleApiClient.ConnectionCallbacks, GoogleApiClient.OnConnectionFailedListener, LocationListener { private static final String TAG = Loca...
asked by 21.11.2018 / 23:53
0
answers

After page expiration (session-timeout), give auto refresh to login screen

I'm developing an application in JSF, where I have a login screen that has a page filter as a business rule, where the user can access the other pages if they start a session. My application has a certain Timeout, which when hit, I would like...
asked by 10.12.2018 / 19:43
1
answer

Retrieve the containsKey ()

Good afternoon, I'm starting to use Android Studio, in the following situation I'm stopped: has the MainActivity where through a recyclerView I have a listing, when clicking on one of these step listings as parameter to page 2 such item click...
asked by 24.11.2018 / 16:02
1
answer

"Lookup failed" error when using a Glassfish Custom Resource

I am using Glassfish Custom Resource to write a property: Then,I'mtryingtogetthisvaluelikethis:newInitialContext().lookup("javax.faces.PROJECT_STAGE") but I get the following exception : Grave: javax.naming.NamingException: Looku...
asked by 19.03.2014 / 21:42
3
answers

Get external IP in Java - Android Studio

I want to get my external IP when I click a button in my app, but every time I click the button, the app closes itself. How can I do that? My code: public void onClickBtnAtualizar(View view) throws Exception { TextView txtResposta = (TextV...
asked by 20.11.2018 / 18:52
1
answer

How do I retune the amount of Spring JPA records? [duplicate]

I want to return the value of playlists records in the database, but that code did not work. public interface PlaylistDao extends JpaRepository<Playlist, Long> { @Query("select count(*) from Playlist") public int verifi...
asked by 20.11.2018 / 17:04
1
answer

Select me returns null, in the second iteration of the FOR loop, onwards

I have a database, ROOM , which makes a select shortly after returning a asyncTask . I get the return and I make a select , waiting for the return of this select . It works normally, at the first iteration of for...
asked by 20.11.2018 / 13:21
1
answer

How to pass a parameter between two views with @ViewScoped

I need to pass an id of an object between views, the beans of both are view scoped, I'm trying to pass via f: param, but I can not. The value always gets null in the other view View 1 <ui:define name="titulo"> ARTs Aptas a L...
asked by 26.11.2018 / 16:39