summaryrefslogtreecommitdiff
path: root/internal/log
diff options
context:
space:
mode:
Diffstat (limited to 'internal/log')
-rw-r--r--internal/log/log.go10
1 files changed, 9 insertions, 1 deletions
diff --git a/internal/log/log.go b/internal/log/log.go
index 1992a88..f8326eb 100644
--- a/internal/log/log.go
+++ b/internal/log/log.go
@@ -21,7 +21,9 @@ type LogLevel int8
const (
// No level set, not allowed
LOG_NOTSET LogLevel = iota
- // Log info, this message is not an error
+ // Log debug, this message is not an error but is there for debugging
+ LOG_DEBUG
+ // Log info, this message is not an error but is there for additional information
LOG_INFO
// Log only to provide a warning, the app still functions
LOG_WARNING
@@ -35,6 +37,8 @@ func (e LogLevel) String() string {
switch e {
case LOG_NOTSET:
return "NOTSET"
+ case LOG_DEBUG:
+ return "DEBUG"
case LOG_INFO:
return "INFO"
case LOG_WARNING:
@@ -86,6 +90,10 @@ func (logger *FileLogger) Inherit(label string, err error) {
}
}
+func (logger *FileLogger) Debug(msg string) {
+ logger.log(LOG_DEBUG, msg)
+}
+
func (logger *FileLogger) Info(msg string) {
logger.log(LOG_INFO, msg)
}