001package org.slf4j.helpers;
002
003
004import org.slf4j.Marker;
005
006import java.lang.annotation.*;
007
008/**
009 * <p>Used to annotate methods in the {@link org.slf4j.spi.LoggingEventBuilder} interface
010 * which return an instance of LoggingEventBuilder (usually as <code>this</code>). Such
011 * methods should be followed by one of the terminating <code>log()</code> methods returning
012 * <code>void</code>.</p>
013 * <p></p>
014 * <p>IntelliJ IDEA supports a check for annotations named as <code>CheckReturnValue</code>
015 * regardless of the containing package. For more information on this feature in IntelliJ IDEA,
016 * select File &#8594; Setting &#8594; Editor &#8594; Inspections and then Java &#8594; Probable Bugs &#8594;
017 * Result of method call ignored. </p>
018 * <p></p>
019 *
020 * <p>As for Eclipse, this feature has been requested in
021 * <a href="https://bugs.eclipse.org/bugs/show_bug.cgi?id=572496">bug 572496</a></p>
022 *
023 * @author Ceki G&uuml;lc&uuml;
024 * @since 2.0.0-beta1
025 */
026@Documented
027@Target( { ElementType.METHOD })
028@Retention(RetentionPolicy.RUNTIME)
029public @interface CheckReturnValue {
030}