log.warn: Difference between revisions

From RPTools Wiki
Jump to navigation Jump to search
(Created page with "{{MacroFunction |name=log.warn |trusted=true |version=1.5.2 |description= Writes a message to the log at the WARN logging level. |usage= <source lang="mtmacro" line> log.warn...")
 
No edit summary
Line 23: Line 23:
Empty string to calling macro.  Output is in log file.
Empty string to calling macro.  Output is in log file.
<source lang="mtmacro" line>
<source lang="mtmacro" line>
2019-04-19 08:59:39.211 [AWT-EventQueue-0] WARN  macro-logger - Go away or I shall taunt you a second time!
1975-03-14 08:59:39.211 [AWT-EventQueue-0] WARN  macro-logger - Go away or I shall taunt you a second time!
</source>
</source>
|also=
|also=

Revision as of 15:29, 19 April 2019

log.warn() Function

 Note: This function can only be used in a Trusted Macro

Introduced in version 1.5.2
Writes a message to the log at the WARN logging level.

Usage

log.warn(message)

Parameters

  • message - A string containing the message to be logged.

Example

Output a message to the macro-logger at the WARN level.
[h: log.warn("Go away or I shall taunt you a second time!")]

Returns:

Empty string to calling macro. Output is in log file.

1975-03-14 08:59:39.211 [AWT-EventQueue-0] WARN  macro-logger - Go away or I shall taunt you a second time!

See Also