org.eclipse.xtext.xbase.compiler.output
Class FakeTreeAppendable

java.lang.Object
  extended by org.eclipse.xtext.xbase.compiler.StringBuilderBasedAppendable
      extended by org.eclipse.xtext.xbase.compiler.output.FakeTreeAppendable
All Implemented Interfaces:
ITraceRegionProvider, IAppendable, ITreeAppendable

@NonNullByDefault
public class FakeTreeAppendable
extends StringBuilderBasedAppendable
implements ITreeAppendable

Author:
Sebastian Zarnekow - Initial contribution and API

Constructor Summary
FakeTreeAppendable()
           
FakeTreeAppendable(ImportManager typeSerializer)
           
FakeTreeAppendable(ImportManager typeSerializer, java.lang.String indentation, java.lang.String lineSeparator)
           
 
Method Summary
 ITreeAppendable append(java.lang.CharSequence string)
           
 ITreeAppendable append(JvmType type)
           
 ITreeAppendable decreaseIndentation()
           
 AbstractTraceRegion getTraceRegion()
          Returns the a trace region.
 ITreeAppendable increaseIndentation()
           
 ITreeAppendable newLine()
           
 ITreeAppendable trace(org.eclipse.emf.ecore.EObject object)
          same as trace(object, false)
 ITreeAppendable trace(org.eclipse.emf.ecore.EObject object, boolean useForDebugging)
           
 ITreeAppendable trace(org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int indexInList)
           
 ITreeAppendable trace(ILocationData location)
           
 ITreeAppendable trace(ILocationData location, boolean useForDebugging)
           
 ITreeAppendable trace(java.lang.Iterable<? extends org.eclipse.emf.ecore.EObject> objects)
           
 
Methods inherited from class org.eclipse.xtext.xbase.compiler.StringBuilderBasedAppendable
appendType, charAt, closeScope, declareSyntheticVariable, declareVariable, getContent, getImportManager, getImports, getIndentationString, getLineSeparator, getName, getObject, hasName, hasObject, length, openPseudoScope, openScope, setScopeStack, subSequence, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.eclipse.xtext.xbase.compiler.IAppendable
closeScope, declareSyntheticVariable, declareVariable, getContent, getImports, getName, getObject, hasName, hasObject, length, openPseudoScope, openScope, toString
 

Constructor Detail

FakeTreeAppendable

public FakeTreeAppendable()

FakeTreeAppendable

public FakeTreeAppendable(ImportManager typeSerializer,
                          java.lang.String indentation,
                          java.lang.String lineSeparator)

FakeTreeAppendable

public FakeTreeAppendable(ImportManager typeSerializer)
Method Detail

append

public ITreeAppendable append(JvmType type)
Specified by:
append in interface IAppendable
Specified by:
append in interface ITreeAppendable
Overrides:
append in class StringBuilderBasedAppendable

append

public ITreeAppendable append(java.lang.CharSequence string)
Specified by:
append in interface IAppendable
Specified by:
append in interface ITreeAppendable
Overrides:
append in class StringBuilderBasedAppendable

decreaseIndentation

public ITreeAppendable decreaseIndentation()
Specified by:
decreaseIndentation in interface IAppendable
Specified by:
decreaseIndentation in interface ITreeAppendable
Overrides:
decreaseIndentation in class StringBuilderBasedAppendable

increaseIndentation

public ITreeAppendable increaseIndentation()
Specified by:
increaseIndentation in interface IAppendable
Specified by:
increaseIndentation in interface ITreeAppendable
Overrides:
increaseIndentation in class StringBuilderBasedAppendable

newLine

public ITreeAppendable newLine()
Specified by:
newLine in interface IAppendable
Specified by:
newLine in interface ITreeAppendable
Overrides:
newLine in class StringBuilderBasedAppendable

getTraceRegion

public AbstractTraceRegion getTraceRegion()
Description copied from interface: ITraceRegionProvider
Returns the a trace region.

Specified by:
getTraceRegion in interface ITraceRegionProvider

trace

public ITreeAppendable trace(org.eclipse.emf.ecore.EObject object,
                             boolean useForDebugging)
Specified by:
trace in interface ITreeAppendable
Parameters:
object - the object this part should be associated with
useForDebugging - whether the part is relevant for debugging

trace

public ITreeAppendable trace(ILocationData location)
Specified by:
trace in interface ITreeAppendable

trace

public ITreeAppendable trace(ILocationData location,
                             boolean useForDebugging)
Specified by:
trace in interface ITreeAppendable
Parameters:
location - the location that should be traced
useForDebugging - whether the part is relevant for debugging

trace

public ITreeAppendable trace(java.lang.Iterable<? extends org.eclipse.emf.ecore.EObject> objects)
Specified by:
trace in interface ITreeAppendable
Parameters:
objects - the iterable of EObjects that contribute output. May not be empty.

trace

public ITreeAppendable trace(org.eclipse.emf.ecore.EObject object,
                             org.eclipse.emf.ecore.EStructuralFeature feature,
                             int indexInList)
Specified by:
trace in interface ITreeAppendable

trace

public ITreeAppendable trace(org.eclipse.emf.ecore.EObject object)
Description copied from interface: ITreeAppendable
same as trace(object, false)

Specified by:
trace in interface ITreeAppendable