Guest User

Untitled

a guest
Oct 20th, 2018
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. public class Server implements Runnable{
  2. ...
  3. public void run(){
  4. long period = 45000L;
  5. long start = System.currentTimeMillis();
  6. while (System.currentTimeMillis() - start < period) {
  7. ...
  8. String input = readInput(); // - Execution gets "paused" since user is asked to enter input
  9. while (true){
  10. ...perform some other commands...
  11. }
  12. }
Add Comment
Please, Sign In to add comment