The idea is that an interrupt should be handled once. If an explicit InterruptedException
did not clear the “interrupt” flag then most catchers for InterruptedException
would have to explicitly clear that flag. Conversely, you can “unclear” the flag by self-interruption (Thread.currentThread().interrupt()
). Java’s designers went for the semantics which would save keystrokes most of the time (i.e. you more often want to clear the flag than keep it set).