Package org.photonvision.common.logging
Class Logger
java.lang.Object
org.photonvision.common.logging.Logger
TODO: get rid of static {} blocks and refactor to singleton pattern
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
addFileAppender
(Path logFilePath) static void
static void
void
void
void
void
Logs an error message with the stack trace of a Throwable.void
static String
static String
getDate()
void
void
void
static void
static void
boolean
void
void
void
void
-
Field Details
-
ANSI_RESET
- See Also:
-
ANSI_BLACK
- See Also:
-
ANSI_RED
- See Also:
-
ANSI_GREEN
- See Also:
-
ANSI_YELLOW
- See Also:
-
ANSI_BLUE
- See Also:
-
ANSI_PURPLE
- See Also:
-
ANSI_CYAN
- See Also:
-
ANSI_WHITE
- See Also:
-
MAX_LOGS_TO_KEEP
public static final int MAX_LOGS_TO_KEEP- See Also:
-
-
Constructor Details
-
Logger
-
Logger
-
-
Method Details
-
getDate
-
format
-
addFileAppender
-
closeAllLoggers
public static void closeAllLoggers() -
cleanLogs
-
setLevel
-
sendConnectedBacklog
public static void sendConnectedBacklog() -
shouldLog
-
log
-
error
-
error
-
error
Logs an error message with the stack trace of a Throwable. The stacktrace will only be printed if the current LogLevel is TRACE- Parameters:
message
-t
-
-
warn
-
warn
-
info
-
info
-
debug
-
debug
-
trace
-
trace
-