org.erights.e.elang.syntax
Class QuasiFeeder

java.lang.Object
  |
  +--org.erights.e.elang.syntax.QuasiFeeder
All Implemented Interfaces:
LineFeeder

public class QuasiFeeder
extends Object
implements LineFeeder

Untamed: Like LineFeeder, but collapses @@ to @ and $$ to $. For use as input to the E lexer/parser used as a quasi-parser.

Author:
Mark S. Miller

Field Summary
private  LineFeeder myWrapped
           
 
Constructor Summary
QuasiFeeder(LineFeeder wrapped)
          Enabled:
 
Method Summary
 Twine optNextLine(boolean atTop, boolean quoted, int indent, char closer, int closeIndent)
          Enabled: Like LineFeeder.optNextLine, but collapses every doubled @ or $ to a single one.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

myWrapped

private final LineFeeder myWrapped
Constructor Detail

QuasiFeeder

public QuasiFeeder(LineFeeder wrapped)
Enabled:

Method Detail

optNextLine

public Twine optNextLine(boolean atTop,
                         boolean quoted,
                         int indent,
                         char closer,
                         int closeIndent)
                  throws IOException
Enabled: Like LineFeeder.optNextLine, but collapses every doubled @ or $ to a single one.

Specified by:
optNextLine in interface LineFeeder
Parameters:
atTop - Is this the beginning of a top-level unit (typically, a top-level expression)?
quoted - Will this next line be taken as literal text? If so, then it should not be trimmed or indented. 'quoted' is true between double quotes, or between quasi-quotes when not inside a $ or @ hole.
indent - The suggested indentation level for the next line, unless the next line begins with closer.
closer - The character that would close the most recent unclosed openner.
closeIndent - The suggested indentation level for the next line if it does begin (after trimming) with closer.
IOException


comments?