Class JDBCLogger
- java.lang.Object
-
- org.nuxeo.ecm.core.storage.sql.jdbc.JDBCLogger
-
public class JDBCLogger extends Object
Logger used for debugging.
-
-
Field Summary
Fields Modifier and Type Field Description static int
DEBUG_MAX_ARRAY
static int
DEBUG_MAX_STRING
String
instance
static Log
log
-
Constructor Summary
Constructors Constructor Description JDBCLogger(String instance)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
error(String message)
void
error(String message, Throwable t)
String
formatMessage(String message)
void
info(String message)
boolean
isLogEnabled()
void
log(String message)
void
logCount(int count)
static String
loggedValue(Object value)
Returns a loggable value using pseudo-SQL syntax.void
logIds(List<Serializable> ids, boolean countTotal, long totalSize)
void
logMap(Map<String,Serializable> map)
void
logMaps(List<Map<String,Serializable>> maps, boolean countTotal, long totalSize)
void
logResultSet(ResultSet rs, List<Column> columns)
void
logSQL(String sql, Collection<? extends Serializable> values)
void
logSQL(String sql, List<Column> columns, Row row)
void
logSQL(String sql, List<Column> columns, Row row, List<Column> whereColumns, Map<String,Serializable> conditions)
void
warn(String message)
-
-
-
Field Detail
-
log
public static final Log log
-
DEBUG_MAX_STRING
public static final int DEBUG_MAX_STRING
- See Also:
- Constant Field Values
-
DEBUG_MAX_ARRAY
public static final int DEBUG_MAX_ARRAY
- See Also:
- Constant Field Values
-
instance
public final String instance
-
-
Constructor Detail
-
JDBCLogger
public JDBCLogger(String instance)
-
-
Method Detail
-
isLogEnabled
public boolean isLogEnabled()
-
error
public void error(String message)
-
warn
public void warn(String message)
-
info
public void info(String message)
-
log
public void log(String message)
-
logCount
public void logCount(int count)
-
logResultSet
public void logResultSet(ResultSet rs, List<Column> columns) throws SQLException
- Throws:
SQLException
-
logMap
public void logMap(Map<String,Serializable> map) throws SQLException
- Throws:
SQLException
-
logMaps
public void logMaps(List<Map<String,Serializable>> maps, boolean countTotal, long totalSize)
-
logIds
public void logIds(List<Serializable> ids, boolean countTotal, long totalSize)
-
logSQL
public void logSQL(String sql, List<Column> columns, Row row, List<Column> whereColumns, Map<String,Serializable> conditions)
-
logSQL
public void logSQL(String sql, Collection<? extends Serializable> values)
-
-