Top Description Methods
org.eclipse.xtend.lib.macro.services

public Interface ProblemSupport

Known Direct Subinterfaces
org.eclipse.xtend.lib.macro.TransformationContext, org.eclipse.xtend.lib.macro.ValidationContext
Annotations
@Beta
Imports
java.util.List, org.eclipse.xtend.lib.macro.declaration.Element, org.eclipse.xtend.lib.macro.services.Problem.Severity, org.eclipse.xtext.xbase.lib.Procedures, com.google.common.annotations.Beta

Support for looking up and creating new Problem markers on Elements
Author
Sven Efftinge

Method Summary

Modifier and TypeMethod and Description
public void
addError(Element
the element to which associate the new problem marker
element
,
String
the message for the problem marker
message
)

Adds a problem marker with severity Severity#ERROR to the given element

public void
addWarning(Element
the element to which associate the new problem marker
element
,
String
the message for the problem marker
message
)

Adds a problem marker with severity Severity#WARNING to the given element

public List<? extends Problem>

Returns:

the problems associated with the given Element
getProblems
(Element
the element to look up problems
element
)

public void
validateLater(Procedures.Procedure0
a callback that will be executed in the validation phase, when all transformations have been done and types are inferred.
validationCallback
)

Method Detail

addErrorback to summary
public void addError(Element element, String message)

Adds a problem marker with severity Severity#ERROR to the given element

Parameters
element:Element

the element to which associate the new problem marker

message:String

the message for the problem marker

addWarningback to summary
public void addWarning(Element element, String message)

Adds a problem marker with severity Severity#WARNING to the given element

Parameters
element:Element

the element to which associate the new problem marker

message:String

the message for the problem marker

getProblemsback to summary
public List<? extends Problem> getProblems(Element element)
Parameters
element:Element

the element to look up problems

Returns:List<? extends Problem>

the problems associated with the given Element

validateLaterback to summary
public void validateLater(Procedures.Procedure0 validationCallback)
Parameters
validationCallback:Procedures.Procedure0

a callback that will be executed in the validation phase, when all transformations have been done and types are inferred.

Since
2.7