Class MapperAnnotatedFormattingMessenger
java.lang.Object
org.mapstruct.ap.internal.processor.MapperAnnotatedFormattingMessenger
- All Implemented Interfaces:
FormattingMessager
Handles redirection of errors/warnings so that they're shown on the mapper instead of hidden on a superclass.
- Author:
- Ben Zegveld
-
Constructor Summary
ConstructorsConstructorDescriptionMapperAnnotatedFormattingMessenger(FormattingMessager delegateMessager, TypeElement mapperTypeElement, TypeUtils typeUtils) -
Method Summary
Modifier and TypeMethodDescriptionbooleanvoidJust log as plain notevoidprintMessage(Element e, AnnotationMirror a, AnnotationValue v, Message msg, Object... args) Prints a message of the specified kind at the location of the annotation value inside the annotation positionHint of the annotated element.voidprintMessage(Element e, AnnotationMirror a, Message msg, Object... args) Prints a message of the specified kind at the location of the annotation positionHint of the annotated element.voidprintMessage(Element e, Message msg, Object... args) Prints a message of the specified kind at the location of the element.voidprintMessage(Message msg, Object... args) Prints a message of the specified kind.
-
Constructor Details
-
MapperAnnotatedFormattingMessenger
public MapperAnnotatedFormattingMessenger(FormattingMessager delegateMessager, TypeElement mapperTypeElement, TypeUtils typeUtils)
-
-
Method Details
-
printMessage
Description copied from interface:FormattingMessagerPrints a message of the specified kind.- Specified by:
printMessagein interfaceFormattingMessager- Parameters:
msg- the messageargs- Arguments referenced by the format specifiers in the format string. If there are more arguments than format specifiers, the extra arguments are ignored
-
printMessage
Description copied from interface:FormattingMessagerPrints a message of the specified kind at the location of the element.- Specified by:
printMessagein interfaceFormattingMessager- Parameters:
e- the element to use as a position hintmsg- the messageargs- Arguments referenced by the format specifiers in the format string. If there are more arguments than format specifiers, the extra arguments are ignored
-
printMessage
Description copied from interface:FormattingMessagerPrints a message of the specified kind at the location of the annotation positionHint of the annotated element.- Specified by:
printMessagein interfaceFormattingMessager- Parameters:
e- the annotated elementa- the annotation to use as a position hint (can be null)msg- the messageargs- Arguments referenced by the format specifiers in the format string. If there are more arguments than format specifiers, the extra arguments are ignored
-
printMessage
public void printMessage(Element e, AnnotationMirror a, AnnotationValue v, Message msg, Object... args) Description copied from interface:FormattingMessagerPrints a message of the specified kind at the location of the annotation value inside the annotation positionHint of the annotated element.- Specified by:
printMessagein interfaceFormattingMessager- Parameters:
e- the annotated elementa- the annotation containing the annotation valuev- the annotation value to use as a position hintmsg- the messageargs- Arguments referenced by the format specifiers in the format string. If there are more arguments than format specifiers, the extra arguments are ignored
-
note
Description copied from interface:FormattingMessagerJust log as plain note- Specified by:
notein interfaceFormattingMessager- Parameters:
level- nesting levellog- the log messageargs- the arguments
-
isErroneous
public boolean isErroneous()- Specified by:
isErroneousin interfaceFormattingMessager
-