MCPcopy Create free account
hub / github.com/Vector35/binaryninja-api / log

Function log

python/log.py:41–61  ·  view source on GitHub ↗

``log`` writes messages to the log console for the given log level. ============ ======== ======================================================================= LogLevelName LogLevel Description ============ ======== =======================================================================

(level: LogLevel, text: Any, logger: str = "", session: int = 0)

Source from the content-addressed store, hash-verified

39
40
41def log(level: LogLevel, text: Any, logger: str = "", session: int = 0):
42 """
43 ``log`` writes messages to the log console for the given log level.
44
45 ============ ======== =======================================================================
46 LogLevelName LogLevel Description
47 ============ ======== =======================================================================
48 DebugLog 0 Logs debugging information messages to the console.
49 InfoLog 1 Logs general information messages to the console.
50 WarningLog 2 Logs message to console with **Warning** icon.
51 ErrorLog 3 Logs message to console with **Error** icon, focusing the error console.
52 AlertLog 4 Logs message to pop up window.
53 ============ ======== =======================================================================
54
55 :param LogLevel level: Log level to use
56 :param str text: message to print
57 :rtype: None
58 """
59 if not isinstance(text, str):
60 text = str(text)
61 core.BNLogString(session, level, logger, threading.current_thread().ident, text)
62
63
64def log_debug(text: Any, logger: str = ""):

Callers 6

logMethod · 0.70
log_debugMethod · 0.70
log_infoMethod · 0.70
log_warnMethod · 0.70
log_errorMethod · 0.70
log_alertMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected