/*
 * Copyright 2008-2012 Xebia and the original author or authors.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package org.jmxexporter.output;

/**
 * @author <a href="mailto:cleclerc@xebia.fr">Cyrille Le Clerc</a>
 */
public class Slf4jWriter extends AbstractOutputWriter {
}

@@ -661,137 +661,955 @@
 t;%0A%0A
-/**%0A * @author %3Ca href=%22mailto:cleclerc@xebia.fr%22%3ECyrille Le Clerc%3C/a%3E%0A */%0Apublic class Slf4jWriter extends AbstractOutputWriter %7B
+import org.jmxexporter.QueryResult;%0Aimport org.slf4j.Logger;%0Aimport org.slf4j.LoggerFactory;%0A%0A/**%0A * %3Ca href=%22http://www.slf4j.org/%22%3ESLF4J%3C/a%3E based %7B@linkplain OutputWriter%7D implementation.%0A * %3Cp/%3E%0A * Supported attributes:%0A * %3Ctable%3E%0A *     %3Ctr%3E%0A *         %3Cth%3EAttribute%3C/th%3E%0A *         %3Cth%3EDescription%3C/th%3E%0A *         %3Cth%3E%3C/th%3E%0A *     %3C/tr%3E%0A * %3C/table%3E%0A *%0A * @author %3Ca href=%22mailto:cleclerc@xebia.fr%22%3ECyrille Le Clerc%3C/a%3E%0A */%0Apublic class Slf4jWriter extends AbstractOutputWriter %7B%0A%0A    private Logger logger = LoggerFactory.getLogger(getClass());%0A%0A    @Override%0A    public void start() %7B%0A        super.start();%0A        logger = LoggerFactory.getLogger(getStringSetting(%22logger%22, getClass().getName()));%0A    %7D%0A%0A    @Override%0A    public void write(Iterable%3CQueryResult%3E results) %7B%0A        for (QueryResult result : results) %7B%0A            logger.info(result.getName() + %22%5Ct%22 + result.getEpochInMillis() + %22%5Ct%22 + result.getValue());%0A        %7D%0A    %7D
 %0A%7D%0A

Slf4j OutputWriter