java


access variable in inner class that extends Thread


I need to get the value of the variable seconds in the inner class below
private class secondThread extends Thread {
int seconds=0;
int maxTime = 300;
public void run(){
while(seconds<=maxTime){
if((maxTime-seconds)%60>=10){
timer.setText("Time: "+((maxTime-seconds)/60)+":"+((maxTime-seconds)%60));
seconds++;
GameField.doNothing(1000);
}
else if((maxTime-seconds)%60<10){
timer.setText("Time: "+((maxTime-seconds)/60)+":0"+((maxTime-seconds)%60));
seconds++;
GameField.doNothing(1000);
}
}
}
}
from the outer class to assign it to another variable
Thank you for your help

Related Links

Calling constructor of superclass doesn't work
connect MYSQL with netbeans 7.4
How to Continue R.raw.audio sound after completing one loop by clicking on button in android
Forward from JSP to another JSP without using a servlet between them?
why my code is returning 403 forbidden acess
How to solve this error in Android? java.net.MalformedURLException: Protocol not found: [duplicate]
Sending location via text
sessionCookiePath attribute doesn't work on my tomcat7 server
drawing an oval after clicking the mouse
How to make the program read any file when compiling
Set a CQ5 component to editable or not editable
why integer division java? [closed]
Stack and linkedlist implmentation
Spring, JUnit, Hibernate Testing
MapReduce read text files and write results in an excel file
Receive change of eth link status notification in Java (in Linux)

Categories

HOME
ms-access
netsuite
mockito
tizen
json.net
fft
grep
xmpp
rsyslog
tizen-web-app
wamp
indesign
communication
metatrader4
messages
fallback
lombok
django-admin
ef-migrations
angular-ui
aurigma
text-rendering
oxyplot
nas
functional-testing
graphicsmagick
css-animations
extjs5
buildbot
fish
url-scheme
fgetcsv
fopen
windowbuilder
c++-amp
bpel
siesta-swift
code-contracts
ghost4j
mapbox-gl
android-ble
http-digest
dartium
xcode-extension
c11
vapor
impersonation
core-plot
powershell-dsc
fakeiteasy
arena-simulation
modelmapper
acoustics
angular2-meteor
wptoolkit
outlook-2013
apache-fop
upstart
pubmed
qsslsocket
dds
blogengine.net
sage-one
powercli
drupal-6
csound
feeds
font-size
qtwebview
mako
gcsfuse
ableton-live
database-optimization
skobbler-maps
mongocsharpdriver
flash-cs5
sigabrt
qgraphicsview
dataview
livequery
natvis
lemon
marching-cubes
simple-framework
wordml
sysinternals
proj4js
javax.mail
website-monitoring
jscript.net
client-side-templating
castle
wp-query
yorick
meteor-velocity
typo3-neos
industrial
oam
spring-io
ftps
interface-orientation
android-hardware
browser-detection
venn-diagram
punbb
work-stealing
netdna-api
mercurial-server
xmlspy
xdomainrequest
pyinotify
revisions
icanhaz.js
modelstate
castle-monorail
webkit.net
virtual-functions
pascal-fc
commodore

Resources

Encrypt Message