Java перезапуск во время петли

//use continue keyword

while (true) {
  //do stuff
  if (condition) continue; //goes to the top of while loop
  //do other stuff
}
Lazy Lemur