SetLogCallback sets a user-provided callback function. The callback is called at the end of OnAfterEvent.
(callback func(entry *LogEntry) error)
| 106 | // SetLogCallback sets a user-provided callback function. |
| 107 | // The callback is called at the end of OnAfterEvent. |
| 108 | func (l *DefaultLogger) SetLogCallback(callback func(entry *LogEntry) error) error { |
| 109 | l.logCallback = callback |
| 110 | return nil |
| 111 | } |
| 112 | |
| 113 | // writeLog writes the log entry to the configured output. |
| 114 | func (l *DefaultLogger) writeLog(entry *LogEntry) error { |
no outgoing calls