All Downloads are FREE. Search and download functionalities are using the official Maven repository.

de.saumya.mojo.jruby.MojoLogger Maven / Gradle / Ivy

There is a newer version: 2.0.1
Show newest version
/**
 * 
 */
package de.saumya.mojo.jruby;

import org.apache.maven.plugin.logging.Log;

import de.saumya.mojo.ruby.Logger;

public class MojoLogger implements Logger {

    private final boolean verbose;

    private final Log log;

    public MojoLogger(final boolean verbose, final Log log) {
        this.verbose = verbose;
        this.log = log;
    }

    public void debug(final CharSequence content) {
        if (this.verbose) {
            this.log.info(content);
        } else {
            this.log.debug(content);
        }
    }

    public void info(final CharSequence content) {
        this.log.info(content);
    }

    public void warn(final CharSequence content) {
        this.log.warn(content);
    }

    public void error(final CharSequence content) {
        this.log.error(content);
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy