xrayLogHandler 实现 xrayCommonLog.Handler 接口, 接管 xray-core 全局 log handler 后同时写 stdout 和 manager 日志缓冲区。
| 804 | // xrayLogHandler 实现 xrayCommonLog.Handler 接口, |
| 805 | // 接管 xray-core 全局 log handler 后同时写 stdout 和 manager 日志缓冲区。 |
| 806 | type xrayLogHandler struct { |
| 807 | stdout xrayCommonLog.Handler |
| 808 | ch chan<- string |
| 809 | } |
| 810 | |
| 811 | func (h *xrayLogHandler) Handle(msg xrayCommonLog.Message) { |
| 812 | if gm, ok := msg.(*xrayCommonLog.GeneralMessage); ok && gm.Severity == xrayCommonLog.Severity_Debug { |
nothing calls this directly
no outgoing calls
no test coverage detected