org.eclipse.xtext.xtend2.richstring
Class RichStringProcessor.Implementation

java.lang.Object
  extended by org.eclipse.xtext.xtend2.richstring.util.ProcessedRichStringSwitch<java.lang.Boolean>
      extended by org.eclipse.xtext.xtend2.richstring.RichStringProcessor.Implementation
Enclosing class:
RichStringProcessor

public static class RichStringProcessor.Implementation
extends ProcessedRichStringSwitch<java.lang.Boolean>


Field Summary
 
Fields inherited from class org.eclipse.xtext.xtend2.richstring.util.ProcessedRichStringSwitch
modelPackage
 
Constructor Summary
RichStringProcessor.Implementation(IRichStringPartAcceptor acceptor, IRichStringIndentationHandler indentationHandler)
           
 
Method Summary
 void announceIndentation()
           
 void announceSemanticLinebreak(LineBreak lineBreak)
           
protected  void announceSemanticText(java.lang.CharSequence text, RichStringLiteral origin)
           
protected  void announceTemplateLinebreak(LineBreak lineBreak)
           
 void announceTemplateText(java.lang.CharSequence text, RichStringLiteral origin)
           
 java.lang.Boolean caseElseIfCondition(ElseIfCondition object)
          Returns the result of interpreting the object as an instance of 'Else If Condition'
 java.lang.Boolean caseElseStart(ElseStart object)
          Returns the result of interpreting the object as an instance of 'Else Start'
 java.lang.Boolean caseEndIf(EndIf object)
          Returns the result of interpreting the object as an instance of 'End If'
 java.lang.Boolean caseForLoopEnd(ForLoopEnd object)
          Returns the result of interpreting the object as an instance of 'For Loop End'
 java.lang.Boolean caseForLoopStart(ForLoopStart object)
          Returns the result of interpreting the object as an instance of 'For Loop Start'
 java.lang.Boolean caseIfConditionStart(IfConditionStart object)
          Returns the result of interpreting the object as an instance of 'If Condition Start'
 java.lang.Boolean caseLineBreak(LineBreak object)
          Returns the result of interpreting the object as an instance of 'Line Break'
 java.lang.Boolean caseLiteral(Literal object)
          Returns the result of interpreting the object as an instance of 'Literal'
 java.lang.Boolean casePrintedExpression(PrintedExpression object)
          Returns the result of interpreting the object as an instance of 'Printed Expression'
 java.lang.Boolean caseProcessedRichString(ProcessedRichString object)
          Returns the result of interpreting the object as an instance of 'Processed Rich String'
 java.lang.String computeInitialIndentation(RichString object)
           
protected  void computeNextPart(LinePart part)
           
 java.lang.Boolean doSwitch(org.eclipse.emf.ecore.EObject theEObject)
          Calls caseXXX for each class of the model until one returns a non null result; it yields that result
protected  boolean isTemplateLine(Line line)
           
protected  void popIndentation()
           
protected  void popIndentationTwice()
           
protected  void pushSemanticIndentation(java.lang.CharSequence line)
           
protected  void pushTemplateIndentation(java.lang.CharSequence indentation)
           
protected  void pushTemplateIndentationTwice(java.lang.CharSequence indentation)
           
 
Methods inherited from class org.eclipse.xtext.xtend2.richstring.util.ProcessedRichStringSwitch
caseLine, caseLinePart, defaultCase, doSwitch, doSwitch
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RichStringProcessor.Implementation

public RichStringProcessor.Implementation(IRichStringPartAcceptor acceptor,
                                          IRichStringIndentationHandler indentationHandler)
Method Detail

doSwitch

public java.lang.Boolean doSwitch(org.eclipse.emf.ecore.EObject theEObject)
Description copied from class: ProcessedRichStringSwitch
Calls caseXXX for each class of the model until one returns a non null result; it yields that result.

Overrides:
doSwitch in class ProcessedRichStringSwitch<java.lang.Boolean>
Returns:
the first non-null result returned by a caseXXX call.

caseProcessedRichString

public java.lang.Boolean caseProcessedRichString(ProcessedRichString object)
Description copied from class: ProcessedRichStringSwitch
Returns the result of interpreting the object as an instance of 'Processed Rich String'. This implementation returns null; returning a non-null result will terminate the switch.

Overrides:
caseProcessedRichString in class ProcessedRichStringSwitch<java.lang.Boolean>
Parameters:
object - the target of the switch.
Returns:
the result of interpreting the object as an instance of 'Processed Rich String'.
See Also:
doSwitch(EObject)

computeNextPart

protected void computeNextPart(LinePart part)

caseForLoopStart

public java.lang.Boolean caseForLoopStart(ForLoopStart object)
Description copied from class: ProcessedRichStringSwitch
Returns the result of interpreting the object as an instance of 'For Loop Start'. This implementation returns null; returning a non-null result will terminate the switch.

Overrides:
caseForLoopStart in class ProcessedRichStringSwitch<java.lang.Boolean>
Parameters:
object - the target of the switch.
Returns:
the result of interpreting the object as an instance of 'For Loop Start'.
See Also:
doSwitch(EObject)

caseForLoopEnd

public java.lang.Boolean caseForLoopEnd(ForLoopEnd object)
Description copied from class: ProcessedRichStringSwitch
Returns the result of interpreting the object as an instance of 'For Loop End'. This implementation returns null; returning a non-null result will terminate the switch.

Overrides:
caseForLoopEnd in class ProcessedRichStringSwitch<java.lang.Boolean>
Parameters:
object - the target of the switch.
Returns:
the result of interpreting the object as an instance of 'For Loop End'.
See Also:
doSwitch(EObject)

caseIfConditionStart

public java.lang.Boolean caseIfConditionStart(IfConditionStart object)
Description copied from class: ProcessedRichStringSwitch
Returns the result of interpreting the object as an instance of 'If Condition Start'. This implementation returns null; returning a non-null result will terminate the switch.

Overrides:
caseIfConditionStart in class ProcessedRichStringSwitch<java.lang.Boolean>
Parameters:
object - the target of the switch.
Returns:
the result of interpreting the object as an instance of 'If Condition Start'.
See Also:
doSwitch(EObject)

caseElseIfCondition

public java.lang.Boolean caseElseIfCondition(ElseIfCondition object)
Description copied from class: ProcessedRichStringSwitch
Returns the result of interpreting the object as an instance of 'Else If Condition'. This implementation returns null; returning a non-null result will terminate the switch.

Overrides:
caseElseIfCondition in class ProcessedRichStringSwitch<java.lang.Boolean>
Parameters:
object - the target of the switch.
Returns:
the result of interpreting the object as an instance of 'Else If Condition'.
See Also:
doSwitch(EObject)

caseElseStart

public java.lang.Boolean caseElseStart(ElseStart object)
Description copied from class: ProcessedRichStringSwitch
Returns the result of interpreting the object as an instance of 'Else Start'. This implementation returns null; returning a non-null result will terminate the switch.

Overrides:
caseElseStart in class ProcessedRichStringSwitch<java.lang.Boolean>
Parameters:
object - the target of the switch.
Returns:
the result of interpreting the object as an instance of 'Else Start'.
See Also:
doSwitch(EObject)

caseEndIf

public java.lang.Boolean caseEndIf(EndIf object)
Description copied from class: ProcessedRichStringSwitch
Returns the result of interpreting the object as an instance of 'End If'. This implementation returns null; returning a non-null result will terminate the switch.

Overrides:
caseEndIf in class ProcessedRichStringSwitch<java.lang.Boolean>
Parameters:
object - the target of the switch.
Returns:
the result of interpreting the object as an instance of 'End If'.
See Also:
doSwitch(EObject)

casePrintedExpression

public java.lang.Boolean casePrintedExpression(PrintedExpression object)
Description copied from class: ProcessedRichStringSwitch
Returns the result of interpreting the object as an instance of 'Printed Expression'. This implementation returns null; returning a non-null result will terminate the switch.

Overrides:
casePrintedExpression in class ProcessedRichStringSwitch<java.lang.Boolean>
Parameters:
object - the target of the switch.
Returns:
the result of interpreting the object as an instance of 'Printed Expression'.
See Also:
doSwitch(EObject)

caseLineBreak

public java.lang.Boolean caseLineBreak(LineBreak object)
Description copied from class: ProcessedRichStringSwitch
Returns the result of interpreting the object as an instance of 'Line Break'. This implementation returns null; returning a non-null result will terminate the switch.

Overrides:
caseLineBreak in class ProcessedRichStringSwitch<java.lang.Boolean>
Parameters:
object - the target of the switch.
Returns:
the result of interpreting the object as an instance of 'Line Break'.
See Also:
doSwitch(EObject)

caseLiteral

public java.lang.Boolean caseLiteral(Literal object)
Description copied from class: ProcessedRichStringSwitch
Returns the result of interpreting the object as an instance of 'Literal'. This implementation returns null; returning a non-null result will terminate the switch.

Overrides:
caseLiteral in class ProcessedRichStringSwitch<java.lang.Boolean>
Parameters:
object - the target of the switch.
Returns:
the result of interpreting the object as an instance of 'Literal'.
See Also:
doSwitch(EObject)

isTemplateLine

protected boolean isTemplateLine(Line line)

pushSemanticIndentation

protected void pushSemanticIndentation(java.lang.CharSequence line)

popIndentation

protected void popIndentation()

popIndentationTwice

protected void popIndentationTwice()

pushTemplateIndentationTwice

protected void pushTemplateIndentationTwice(java.lang.CharSequence indentation)

pushTemplateIndentation

protected void pushTemplateIndentation(java.lang.CharSequence indentation)

announceSemanticText

protected void announceSemanticText(java.lang.CharSequence text,
                                    RichStringLiteral origin)

announceTemplateText

public void announceTemplateText(java.lang.CharSequence text,
                                 RichStringLiteral origin)

announceIndentation

public void announceIndentation()

announceTemplateLinebreak

protected void announceTemplateLinebreak(LineBreak lineBreak)

announceSemanticLinebreak

public void announceSemanticLinebreak(LineBreak lineBreak)

computeInitialIndentation

public java.lang.String computeInitialIndentation(RichString object)