You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
689 B

  1. package lsat
  2. import (
  3. "github.com/btcsuite/btclog"
  4. "github.com/lightningnetwork/lnd/build"
  5. )
  6. // Subsystem defines the sub system name of this package.
  7. const Subsystem = "LSAT"
  8. // log is a logger that is initialized with no output filters. This
  9. // means the package will not perform any logging by default until the caller
  10. // requests it.
  11. var log btclog.Logger
  12. // The default amount of logging is none.
  13. func init() {
  14. UseLogger(build.NewSubLogger(Subsystem, nil))
  15. }
  16. // UseLogger uses a specified Logger to output package logging info.
  17. // This should be used in preference to SetLogWriter if the caller is also
  18. // using btclog.
  19. func UseLogger(logger btclog.Logger) {
  20. log = logger
  21. }