Package org.eclipse.xtext.validation
Class AbstractValidationMessageAcceptor
- java.lang.Object
-
- org.eclipse.xtext.validation.AbstractValidationMessageAcceptor
-
- All Implemented Interfaces:
ValidationMessageAcceptor
public abstract class AbstractValidationMessageAcceptor extends java.lang.Object implements ValidationMessageAcceptor
Abstract base class for partial message acceptor implementations. Implements all methods as no-op.
-
-
Field Summary
-
Fields inherited from interface org.eclipse.xtext.validation.ValidationMessageAcceptor
INSIGNIFICANT_INDEX
-
-
Constructor Summary
Constructors Constructor Description AbstractValidationMessageAcceptor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidacceptError(java.lang.String message, org.eclipse.emf.ecore.EObject object, int offset, int length, java.lang.String code, java.lang.String... issueData)Annotate a range of the resource with an error.voidacceptError(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index, java.lang.String code, java.lang.String... issueData)Annotate an instance, a feature value, or all feature values with an error.voidacceptInfo(java.lang.String message, org.eclipse.emf.ecore.EObject object, int offset, int length, java.lang.String code, java.lang.String... issueData)Annotate a range of the resource with an info message..voidacceptInfo(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index, java.lang.String code, java.lang.String... issueData)Annotate an instance, a feature value, or all feature values with an info message.voidacceptWarning(java.lang.String message, org.eclipse.emf.ecore.EObject object, int offset, int length, java.lang.String code, java.lang.String... issueData)Annotate a range of the resource with a warning.voidacceptWarning(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index, java.lang.String code, java.lang.String... issueData)Annotate an instance, a feature value, or all feature values with a warning.
-
-
-
Method Detail
-
acceptError
public void acceptError(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index, java.lang.String code, java.lang.String... issueData)Description copied from interface:ValidationMessageAcceptorAnnotate an instance, a feature value, or all feature values with an error.- Specified by:
acceptErrorin interfaceValidationMessageAcceptor- Parameters:
message- the error message. May not benull.object- the object or the feature holder. May not benull.feature- the feature ornullif the complete instance should be annotated.index- the index of the erroneous value or-1if all values are considered to be invalid. The index is ignored if the feature is null or the feature is a single value feature.code- the optional issue code.issueData- the optional issue data.
-
acceptError
public void acceptError(java.lang.String message, org.eclipse.emf.ecore.EObject object, int offset, int length, java.lang.String code, java.lang.String... issueData)Description copied from interface:ValidationMessageAcceptorAnnotate a range of the resource with an error.- Specified by:
acceptErrorin interfaceValidationMessageAcceptor- Parameters:
message- the error message. May not benull.offset- the absolute offset in the resource.length- the length of the erroneous range.code- the optional issue code.issueData- the optional issue data.
-
acceptWarning
public void acceptWarning(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index, java.lang.String code, java.lang.String... issueData)Description copied from interface:ValidationMessageAcceptorAnnotate an instance, a feature value, or all feature values with a warning.- Specified by:
acceptWarningin interfaceValidationMessageAcceptor- Parameters:
message- the warning message. May not benull.object- the object or the feature holder. May not benull.feature- the feature ornullif the complete instance should be annotated.index- the index of the relevant value or-1if all values are considered to be affected. The index is ignored if the feature is null or the feature is a single value feature.code- the optional issue code.issueData- the optional issue data.
-
acceptWarning
public void acceptWarning(java.lang.String message, org.eclipse.emf.ecore.EObject object, int offset, int length, java.lang.String code, java.lang.String... issueData)Description copied from interface:ValidationMessageAcceptorAnnotate a range of the resource with a warning.- Specified by:
acceptWarningin interfaceValidationMessageAcceptor- Parameters:
message- the warning message. May not benull.offset- the absolute offset in the resource.length- the length of the invalid range.code- the optional issue code.issueData- the optional issue data.
-
acceptInfo
public void acceptInfo(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index, java.lang.String code, java.lang.String... issueData)Description copied from interface:ValidationMessageAcceptorAnnotate an instance, a feature value, or all feature values with an info message.- Specified by:
acceptInfoin interfaceValidationMessageAcceptor- Parameters:
message- the info message. May not benull.object- the object or the feature holder. May not benull.feature- the feature ornullif the complete instance should be annotated.index- the index of the interesting value or-1if all values are considered to be interesting. The index is ignored if the feature is null or the feature is a single value feature.code- the optional issue code.issueData- the optional issue data.
-
acceptInfo
public void acceptInfo(java.lang.String message, org.eclipse.emf.ecore.EObject object, int offset, int length, java.lang.String code, java.lang.String... issueData)Description copied from interface:ValidationMessageAcceptorAnnotate a range of the resource with an info message..- Specified by:
acceptInfoin interfaceValidationMessageAcceptor- Parameters:
message- the info message. May not benull.offset- the absolute offset in the resource.length- the length of the annotated range.code- the optional issue code.issueData- the optional issue data.
-
-