Forum |  HardWare.fr | News | Articles | PC | S'identifier | S'inscrire | Shop Recherche
3777 connectés 

  FORUM HardWare.fr
  Programmation
  Java

  programmation

 


 Mot :   Pseudo :  
 
Bas de page
Auteur Sujet :

programmation

n°1225301
salmaensi
Posté le 18-10-2005 à 13:03:05  profilanswer
 

j'ai un problème sans doute simple mais dont je ne mesors pas :et j'ai besoin d'une réponse rapide(cas urgent)
comment faire 'attendre' pendant une certaine période l'execution d'une commande.
Une commande équivalente à sleep().

mood
Publicité
Posté le 18-10-2005 à 13:03:05  profilanswer
 

n°1225307
Taz
bisounours-codeur
Posté le 18-10-2005 à 13:16:18  profilanswer
 

Thread.sleep

n°1225308
Profil sup​primé
Posté le 18-10-2005 à 13:17:12  answer
 

Code :
  1. public void sleep(long secondes){
  2.    long t1=System.currentTimeMillis();
  3.    while((System.currentTimeMillis()-t1)<(secondes*1000)){
  4.       ;
  5.    }
  6. }


 
Problème déjà abordé, le minimum aurait été de cliquer sur le bontou "rechercher" ...

n°1225310
Taz
bisounours-codeur
Posté le 18-10-2005 à 13:17:57  profilanswer
 

mais biensur ...

n°1225315
sircam
I Like Trains
Posté le 18-10-2005 à 13:23:55  profilanswer
 

iohack> Tu veux deux giffles ? [:itm]


---------------
Now Playing: {SYNTAX ERROR AT LINE 1210}
n°1225317
salmaensi
Posté le 18-10-2005 à 13:37:20  profilanswer
 

merci pour la reponse et surtout les conseils

n°1225318
elianor
bannie 17 fois
Posté le 18-10-2005 à 13:38:37  profilanswer
 


 
pelle à clous ?


---------------
JE JE SUIS LIBERTINEEEEEEEEEEE JE SUIS UNE CATINNNNNNNNN §§§§§§§§
n°1225344
souk
Tourist
Posté le 18-10-2005 à 14:06:55  profilanswer
 


 
[:mlc]  
 
 
 :sweat:

n°1225345
sircam
I Like Trains
Posté le 18-10-2005 à 14:08:05  profilanswer
 

Pelle à clous + 2 giffles + BAN ? [:dawa]


---------------
Now Playing: {SYNTAX ERROR AT LINE 1210}
n°1225348
nraynaud
lol
Posté le 18-10-2005 à 14:11:18  profilanswer
 

ben quoi ? on trouve bien cet algo dans le noyau Linux, c'est qu'il doit être correct non ? [:dawa]


---------------
trainoo.com, c'est fini
mood
Publicité
Posté le 18-10-2005 à 14:11:18  profilanswer
 

n°1225349
nerisson
Pic-pic
Posté le 18-10-2005 à 14:12:24  profilanswer
 


 [:psywalk]


---------------
Light is right
n°1225351
the real m​oins moins
Posté le 18-10-2005 à 14:13:45  profilanswer
 


[:rofl]    
    [:rofl]
           [:rofl]
                   [:rofl]
 
 
 
ha ben s'il a déjà été abordé, t'as pas du être là.. ou alors on aurait bien ri http://marinenet.mite.com.au/images/naked.gif


---------------
Hey toi, tu veux acheter des minifigurines Lego, non ?
n°1225359
chrisbk
-
Posté le 18-10-2005 à 14:16:20  profilanswer
 

[:el g]

n°1225366
Taiche
(╯°□°)╯︵ ┻━┻
Posté le 18-10-2005 à 14:19:55  profilanswer
 

http://www.lgml.net/HFR/owned/wtf13.jpg


---------------
Everyone thinks of changing the world, but no one thinks of changing himself  |  It is the peculiar quality of a fool to perceive the faults of others and to forget his own  |  Early clumsiness is not a verdict, it’s an essential ingredient.
n°1225474
Harkonnen
Modérateur
Un modo pour les bannir tous
Posté le 18-10-2005 à 15:37:25  profilanswer
 


 
Serial Coder ? c'est toi ?


---------------
J'ai un string dans l'array (Paris Hilton)
n°1225477
the real m​oins moins
Posté le 18-10-2005 à 15:39:17  profilanswer
 

[:rofl]


---------------
Hey toi, tu veux acheter des minifigurines Lego, non ?
n°1225497
masklinn
í dag viðrar vel til loftárása
Posté le 18-10-2005 à 15:57:48  profilanswer
 


http://masklinnscans.free.fr/4chan/you_master.gif
 
(edit: accessoirement, rechercher simplement "Java sleep" dans google donne la bonne info dès la première réponse hein [:pingouino])


Message édité par masklinn le 18-10-2005 à 16:00:02

---------------
I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box by throwing away the limits imposed by overbearing genetic regulations? Isn't that a good thing?

Aller à :
Ajouter une réponse
  FORUM HardWare.fr
  Programmation
  Java

  programmation

 

Sujets relatifs
Programmation d'application Java pour téléphone portableConseil choix formation programmation
Question sur la programmation C++Cours programmation X
Qu'est-ce que la programmation object ?programmation systeme en c
Jeu (mmorpg) programmation ?Qu'es ce que la programmation EXACTEMENT ???
Programmation sous Motorola 6809blabla@web
Plus de sujets relatifs à : programmation


Copyright © 1997-2025 Groupe LDLC (Signaler un contenu illicite / Données personnelles)