org.eclipse.xpand2.output
Class OutputImpl
java.lang.Object
org.eclipse.xpand2.output.OutputImpl
- All Implemented Interfaces:
- InsertionPointSupport, Output
- Direct Known Subclasses:
- BlankLineSkippingOutput, TracingOutput
public class OutputImpl
- extends java.lang.Object
- implements Output, InsertionPointSupport
*
- Author:
- Sven Efftinge (http://www.efftinge.de) *
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
OutputImpl
public OutputImpl()
setAutomaticHyphens
public void setAutomaticHyphens(boolean automaticHyphenation)
addOutlet
public void addOutlet(Outlet outlet)
- Specified by:
addOutlet
in interface Output
getOutlet
public Outlet getOutlet(java.lang.String name)
- Specified by:
getOutlet
in interface Output
current
protected FileHandle current()
current__testONLY
public FileHandle current__testONLY()
- DO NOT CALL THIS METHOD - FOR TESTS ONLY
write
public void write(java.lang.String bytes)
- Specified by:
write
in interface Output
removeWSAfterLastNewline
public void removeWSAfterLastNewline(java.lang.CharSequence cs)
isNewLine
protected boolean isNewLine(char c)
trimUntilNewline
public java.lang.String trimUntilNewline(java.lang.String bytes)
resolveOutlet
public static Pair<Outlet,java.lang.String> resolveOutlet(java.util.Map<java.lang.String,Outlet> allOutlets,
java.lang.String path,
java.lang.String outletName)
openFile
public void openFile(java.lang.String path,
java.lang.String outletName)
- Specified by:
openFile
in interface Output
closeFile
public void closeFile()
- Specified by:
closeFile
in interface Output
pushStatement
public void pushStatement(SyntaxElement stmt,
XpandExecutionContext ctx)
- Specified by:
pushStatement
in interface Output
popStatement
public SyntaxElement popStatement()
- Specified by:
popStatement
in interface Output
getFileHandles
protected java.util.Stack<FileHandle> getFileHandles()
activateInsertionPoint
public void activateInsertionPoint(Statement stmt)
- Specified by:
activateInsertionPoint
in interface InsertionPointSupport
deactivateInsertionPoint
public void deactivateInsertionPoint(Statement stmt)
- Specified by:
deactivateInsertionPoint
in interface InsertionPointSupport
registerInsertionPoint
public void registerInsertionPoint(Statement stmt)
- Specified by:
registerInsertionPoint
in interface InsertionPointSupport