private void reportViolation()

in src/main/java/org/apache/sling/feature/analyser/task/impl/CheckContentPackages.java [127:147]


    private void reportViolation(AnalyserTaskContext ctx, ContentPackageDescriptor cp, ValidationViolation violation, 
            Path artifactPath, ValidationMessageSeverity severity) {
        String msg = getDetailMessage(violation, artifactPath);
        ArtifactId id = cp.getArtifact().getId();
        switch (severity) {
        case ERROR:
            log.error(msg);
            ctx.reportArtifactError(id, msg);
            break;
        case WARN:
            log.warn(msg);
            ctx.reportArtifactWarning(id, msg);
            break;
        case INFO:
            log.info(msg);
            break;
        default:
            log.debug(msg);
            break;
        }
    }