The marker is checked by the underlying Filter which could be a MarkerFilter or a ScriptFilter or some custom filter (all our other filters ignore the marker).
On 28 June 2016 at 10:52, Gary Gregory <[email protected]> wrote: > On Tue, Jun 28, 2016 at 8:48 AM, Mikael Ståldal <[email protected] > > wrote: > >> The Javadoc for the Logger.isEnabled methods looks a bit odd. I just >> fixed a few obvious errors, but some questions: >> >> - I guess that the note about Level.OFF applies to both of them? >> > > I would guess yes and I hope we have a unit test just for that! ;-) Do you > mind checking, I am about to go AFK. > > >> >> - Is the marker optional? >> >> - I guess that the marker param should not be formulated like it is? >> > > Kind of hard to explain without explaining markers eh? ;-) But if we talk > about "checking the level" we should also talk about "checking" the marker. > In both cases it would be nice to say what we are checking _against_! > > Gary > >> >> /** >> * Checks whether this Logger is enabled for the given Level. >> * <p> >> * Note that passing in {@link Level#OFF OFF} always returns {@code true}. >> * </p> >> * >> * @param level the Level to check >> * @return boolean - {@code true} if this Logger is enabled for level, >> {@code false} otherwise. >> */ >> boolean isEnabled(Level level); >> >> /** >> * Checks whether this Logger is enabled for the given Level and an optional >> Marker. >> * >> * @param level The Level to check >> * @param marker The marker data specific to this log statement. >> * @return boolean - {@code true} if this Logger is enabled for level and >> marker, {@code false} otherwise. >> */ >> boolean isEnabled(Level level, Marker marker); >> >> >> -- >> [image: MagineTV] >> >> *Mikael Ståldal* >> Senior software developer >> >> *Magine TV* >> [email protected] >> Grev Turegatan 3 | 114 46 Stockholm, Sweden | www.magine.com >> >> Privileged and/or Confidential Information may be contained in this >> message. If you are not the addressee indicated in this message >> (or responsible for delivery of the message to such a person), you may >> not copy or deliver this message to anyone. In such case, >> you should destroy this message and kindly notify the sender by reply >> email. >> > > > > -- > E-Mail: [email protected] | [email protected] > Java Persistence with Hibernate, Second Edition > <http://www.manning.com/bauer3/> > JUnit in Action, Second Edition <http://www.manning.com/tahchiev/> > Spring Batch in Action <http://www.manning.com/templier/> > Blog: http://garygregory.wordpress.com > Home: http://garygregory.com/ > Tweet! http://twitter.com/GaryGregory > -- Matt Sicker <[email protected]>
