public class Slf4JLogger extends FormattedLogger
strategy
Constructor and Description |
---|
Slf4JLogger() |
Modifier and Type | Method and Description |
---|---|
boolean |
isCategoryEnabled(Category category) |
void |
logException(Exception e)
Logs the stacktrace of the exception.
|
void |
logSQL(int connectionId,
String now,
long elapsed,
Category category,
String prepared,
String sql)
Logs the
SQL . |
void |
logText(String text)
Logs the text.
|
setStrategy
public void logException(Exception e)
P6Logger
e
- exception holding the stacktrace to be logged.public void logText(String text)
P6Logger
text
- to be loggedpublic void logSQL(int connectionId, String now, long elapsed, Category category, String prepared, String sql)
P6Logger
SQL
.logSQL
in interface P6Logger
logSQL
in class FormattedLogger
connectionId
- connection identifier.now
- current time.category
- the category to be used for logging.prepared
- the prepared statement to be logged.sql
- the SQL
to be logged.public boolean isCategoryEnabled(Category category)
category
- the category to be evaluated.true
if category is enabled. Otherwise returns
false
Copyright © 2002-2015 P6Spy. All Rights Reserved.