textbender.g.lang
Class PassLimiter

java.lang.Object
  extended by PassLimiter

@ThreadRestricted(value="private")
public final class PassLimiter
extends Object

Detector of endless loops, etc.


Nested Class Summary
static class PassLimiter.ExceededException
          Thrown when a pass limit is exceeded.
 
Field Summary
(package private)  int remaining
           
 
Constructor Summary
PassLimiter(int limit)
          Creates a PassLimiter.
 
Method Summary
 void pass()
          Registers a single pass.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

remaining

int remaining
Constructor Detail

PassLimiter

public PassLimiter(int limit)
Creates a PassLimiter.

Parameters:
limit - per pass()
Method Detail

pass

public void pass()
          throws PassLimiter.ExceededException
Registers a single pass.

Throws:
PassLimiter.ExceededException - if the pass limit is exceeded