@Override
    public void warning(ANTLRMessage message) {
        ST msgST = tool.errMgr.getMessageTemplate(message);
        String outputMsg = msgST.render();
        if (tool.errMgr.formatWantsSingleLineMessage()) {
            outputMsg = outputMsg.replace('\n', ' ');
        }

        log.warn(outputMsg);

        if (message.fileName != null) {
            String text = message.getMessageTemplate(false).render();
            buildContext.addMessage(new File(message.fileName), message.line, message.charPosition, text, BuildContext.SEVERITY_WARNING, message.getCause());
        }
    }
{@inheritDoc}
<p>
This implementation passes the message to the Maven log.
</p>
@param message
antlr4-maven-plugin/src/main/java/org/antlr/mojo/antlr4/Antlr4ErrorLog.java