org.erights.e.elang.interp
Class Loop

java.lang.Object
  |
  +--org.erights.e.elang.interp.Loop

public class Loop
extends Object

Safe: An StaticMaker on this class is the function named "__loop" in the universalScope (and therefore also in the safeScope).

This wrapper is used as the E language's primitive looping construct. When called as a one-argument function, it just repeatedly calls its argument as a zero-argument, bool-returning function until that function returns 'false'.

Author:
Mark S. Miller.

Field Summary
static Loop THE_ONE
          Enabled:
 
Constructor Summary
private Loop()
           
 
Method Summary
 void run(LoopBody loopBody)
          Enabled: Keep calling loopBody until it returns false.
 String toString()
          Suppressed:
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

THE_ONE

public static final Loop THE_ONE
Enabled:

Constructor Detail

Loop

private Loop()
Method Detail

run

public void run(LoopBody loopBody)
Enabled: Keep calling loopBody until it returns false.


toString

public String toString()
Suppressed:

Overrides:
toString in class Object
Returns:
a string representation of the object.


comments?