Class AbstractRichStringPartAcceptor
- java.lang.Object
-
- org.eclipse.xtend.core.richstring.AbstractRichStringPartAcceptor
-
- All Implemented Interfaces:
IRichStringPartAcceptor
- Direct Known Subclasses:
AbstractRichStringPartAcceptor.ForLoopOnce
public abstract class AbstractRichStringPartAcceptor extends java.lang.Object implements IRichStringPartAcceptor
No-op implementation of theIRichStringPartAcceptor
. Clients should inherit from this class if they do not want to implement all methods. It is mandatory to implementforLoopHasNext()
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AbstractRichStringPartAcceptor.ForLoopOnce
-
Constructor Summary
Constructors Constructor Description AbstractRichStringPartAcceptor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
acceptElse()
Announces that anvoid
acceptElseIfCondition(org.eclipse.xtext.xbase.XExpression condition)
Announces that anvoid
acceptEndFor(org.eclipse.xtext.xbase.XExpression after, java.lang.CharSequence indentation)
Announces that anvoid
acceptEndIf()
Announces that anvoid
acceptExpression(org.eclipse.xtext.xbase.XExpression expression, java.lang.CharSequence indentation)
Announces that anvoid
acceptForLoop(org.eclipse.xtext.common.types.JvmFormalParameter parameter, org.eclipse.xtext.xbase.XExpression expression)
Announces that avoid
acceptIfCondition(org.eclipse.xtext.xbase.XExpression condition)
Announces that anvoid
acceptSemanticLineBreak(int charCount, RichStringLiteral origin, boolean controlStructureSeen)
Indicates a semantic line break in a rich string literal.void
acceptSemanticText(java.lang.CharSequence text, RichStringLiteral origin)
void
acceptTemplateLineBreak(int charCount, RichStringLiteral origin)
Indicates a template line break in a rich string literal.void
acceptTemplateText(java.lang.CharSequence text, RichStringLiteral origin)
void
announceNextLiteral(RichStringLiteral object)
Announces that a next literal will be processed.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.eclipse.xtend.core.richstring.IRichStringPartAcceptor
forLoopHasNext
-
-
-
-
Method Detail
-
acceptSemanticText
public void acceptSemanticText(java.lang.CharSequence text, RichStringLiteral origin)
- Specified by:
acceptSemanticText
in interfaceIRichStringPartAcceptor
- Parameters:
text
- the semantic text. May not benull
.origin
- the value holder for the full text or null, if unknown.
-
acceptTemplateText
public void acceptTemplateText(java.lang.CharSequence text, RichStringLiteral origin)
- Specified by:
acceptTemplateText
in interfaceIRichStringPartAcceptor
- Parameters:
text
- the template text. May not benull
.origin
- the value holder for the full text or null, if unknown.
-
acceptSemanticLineBreak
public void acceptSemanticLineBreak(int charCount, RichStringLiteral origin, boolean controlStructureSeen)
Description copied from interface:IRichStringPartAcceptor
Indicates a semantic line break in a rich string literal.- Specified by:
acceptSemanticLineBreak
in interfaceIRichStringPartAcceptor
- Parameters:
charCount
- the number of characters in the line break.origin
- the instance holding the complete text value that contains the line break.controlStructureSeen
- whether or not the line break occurs in a line that contains a control structure.
-
acceptTemplateLineBreak
public void acceptTemplateLineBreak(int charCount, RichStringLiteral origin)
Description copied from interface:IRichStringPartAcceptor
Indicates a template line break in a rich string literal.- Specified by:
acceptTemplateLineBreak
in interfaceIRichStringPartAcceptor
- Parameters:
charCount
- the number of characters in the line break.origin
- the instance holding the complete text value that contains the line break.
-
acceptIfCondition
public void acceptIfCondition(org.eclipse.xtext.xbase.XExpression condition)
Description copied from interface:IRichStringPartAcceptor
Announces that an«IF condition»
has been consumed.- Specified by:
acceptIfCondition
in interfaceIRichStringPartAcceptor
- Parameters:
condition
- the condition of anRichStringIf
.
-
acceptElseIfCondition
public void acceptElseIfCondition(org.eclipse.xtext.xbase.XExpression condition)
Description copied from interface:IRichStringPartAcceptor
Announces that an«ELSEIF condition»
has been consumed.- Specified by:
acceptElseIfCondition
in interfaceIRichStringPartAcceptor
- Parameters:
condition
- the condition of anRichStringElseIf
.
-
acceptElse
public void acceptElse()
Description copied from interface:IRichStringPartAcceptor
Announces that an«ELSE»
has been consumed.- Specified by:
acceptElse
in interfaceIRichStringPartAcceptor
-
acceptEndIf
public void acceptEndIf()
Description copied from interface:IRichStringPartAcceptor
Announces that an«ENDIF»
has been consumed.- Specified by:
acceptEndIf
in interfaceIRichStringPartAcceptor
-
acceptForLoop
public void acceptForLoop(org.eclipse.xtext.common.types.JvmFormalParameter parameter, org.eclipse.xtext.xbase.XExpression expression)
Description copied from interface:IRichStringPartAcceptor
Announces that a«FOR parameter: expression»
has been consumed.- Specified by:
acceptForLoop
in interfaceIRichStringPartAcceptor
- Parameters:
parameter
- the declared parameter in the for-loop.expression
- the expression that produces anIterable
.
-
acceptEndFor
public void acceptEndFor(org.eclipse.xtext.xbase.XExpression after, java.lang.CharSequence indentation)
Description copied from interface:IRichStringPartAcceptor
Announces that an«ENDFOR»
has been consumed.- Specified by:
acceptEndFor
in interfaceIRichStringPartAcceptor
- Parameters:
after
- the expression that should be evaluated after the last item of the loop, if any.indentation
- the additional indentation for any line besides the first one.
-
acceptExpression
public void acceptExpression(org.eclipse.xtext.xbase.XExpression expression, java.lang.CharSequence indentation)
Description copied from interface:IRichStringPartAcceptor
Announces that an«expression»
has been consumed. If the expression's evaluation result contains more than one line, any line besides the first one may be prefixed with the given indentation.- Specified by:
acceptExpression
in interfaceIRichStringPartAcceptor
- Parameters:
expression
- the consumed expression. May not benull
.indentation
- the additional indentation for any line besides the first one.
-
announceNextLiteral
public void announceNextLiteral(RichStringLiteral object)
Description copied from interface:IRichStringPartAcceptor
Announces that a next literal will be processed.- Specified by:
announceNextLiteral
in interfaceIRichStringPartAcceptor
- Parameters:
object
- the literal.
-
-