public final class Log extends Object
Log methods that take message formats and arguments use the
String.format(java.util.Locale, String, Object...) string format syntax.
| Constructor and Description |
|---|
Log(org.slf4j.Logger logger)
Create a new logger from an slf4j logger.
|
| Modifier and Type | Method and Description |
|---|---|
void |
continueContext(Collection<String> init)
Continue a log context.
|
void |
debug(String msg) |
void |
debug(String msg,
Object... args) |
void |
endUnitOfWork()
End a unit of work.
|
void |
error(String msg) |
void |
error(String msg,
Object... args) |
void |
error(Throwable t,
String msg,
Object... args) |
List<String> |
getContext()
Return the current log context.
|
static String |
getHumanReadableTimeString(long seconds)
Renders a string representation of seconds that is easier to read by showing hours, minutes and seconds.
|
void |
info(String msg) |
void |
info(String msg,
Object... args) |
static Log |
mk(Class<?> clazz)
Create a new log instance based on an slf4j logger for class
clazz. |
void |
startUnitOfWork()
Start a new unit of work.
|
void |
warn(String msg) |
void |
warn(String msg,
Object... args) |
void |
warn(Throwable t,
String msg) |
public Log(org.slf4j.Logger logger)
public static Log mk(Class<?> clazz)
clazz.LoggerFactory.getLogger(Class)public void startUnitOfWork()
public void endUnitOfWork()
public void continueContext(Collection<String> init)
public static String getHumanReadableTimeString(long seconds)
seconds - The number of seconds that you want to represent in hours, minutes and remainder seconds.public void debug(String msg)
public void info(String msg)
public void warn(String msg)
public void error(String msg)
Copyright © 2009–2020 Opencast Project. All rights reserved.