CORE/docs/references/Logger.md
JeremyStarTM 99703cf03e CORE rewrite (#1)
Reviewed-on: StarOpenSource/core#1

Rewrote CORE and improved the startup process and startup time significantly. The documentation has been beefed up too and is now much better. Existing projects may need major refactoring however.
Co-authored-by: JeremyStarTM <jeremystartm@staropensource.de>
Co-committed-by: JeremyStarTM <jeremystartm@staropensource.de>
2023-08-25 14:34:57 +02:00

2.5 KiB

hide
navigation

Logger (/root/CORE/Logger)

The CORE logger implementation (with formatting support!)

Signals

logevent

  • emitted on log message
  • argument type (type String, can be DIAG, INFO, WARN or ERR!)
  • argument script (type String)
  • argument message (type String)
  • argument logmessage (type String, description The full log message as printed in console)

Methods

diag()

  • returns void
  • description Prints a diagnostic message
    • argument script
      • type String
      • mandatory yes
      • description The script where the log message is coming from
    • argument message
      • type String
      • mandatory yes
      • description Your log message
    • argument preproc
      • type bool
      • mandatory no, default value is true
      • description If the log message should be run through the preprocessor. If false formatting will be disabled for that log message.

info()

  • returns void
  • description Prints a informational message
    • argument script
      • type String
      • mandatory yes
      • description The script where the log message is coming from
    • argument message
      • type String
      • mandatory yes
      • description Your log message
    • argument preproc
      • type bool
      • mandatory no, default value is true
      • description If the log message should be run through the preprocessor. If false formatting will be disabled for that log message.

warn()

  • returns void
  • description Prints a warning message
    • argument script
      • type String
      • mandatory yes
      • description The script where the log message is coming from
    • argument message
      • type String
      • mandatory yes
      • description Your log message
    • argument preproc
      • type bool
      • mandatory no, default value is true
      • description If the log message should be run through the preprocessor. If false formatting will be disabled for that log message.

error()

  • returns void
  • description Prints a error message
    • argument script
      • type String
      • mandatory yes
      • description The script where the log message is coming from
    • argument message
      • type String
      • mandatory yes
      • description Your log message
    • argument preproc
      • type bool
      • mandatory no, default value is true
      • description If the log message should be run through the preprocessor. If false formatting will be disabled for that log message.