Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Notifier Class Reference
Public Member Functions | |
def | notify |
def | info |
def | debug |
def | progress |
def | tool_error |
def | var |
Detailed Description
Notifiers send build system events to a front end or may implement a front end themselves, displaying warnings and errors for a user. This is different from a logger in a few ways: * The structure of the events are defined by this interface. * A "progress" level is included allowing signaling completion status to users. * It's tailored to providing events from a build system. The structure of a message is a dict with a 'type' key. The type key determines the remaining keys as follows: type | description and remaining keys ---------- | ------------------------------ info | A simple message. The 'message' key contains the message debug | Another simple message; this one is less useful when compiles | are working. Again, the 'message' key contains the message progress | A progress indicator, which may include progress as a | percentage. The action key includes what action was taken to | make this progress, the file key what file was used to make | this progress, and the percent key, when present, indicates | how far along the build is. tool_error | When a compile fails, this contains the entire output of the | compiler. var | Provides a key, in the 'key' key, and a value, in the 'value' | key, for use in a UI. At the time of writing it's used to | communicate the binary location to the online IDE.
Definition at line 21 of file notifier/__init__.py.
Member Function Documentation
def debug | ( | self, | |
message | |||
) |
Send a debug message to the user.
Definition at line 66 of file notifier/__init__.py.
def info | ( | self, | |
message | |||
) |
Send the user a simple message.
Definition at line 60 of file notifier/__init__.py.
def notify | ( | self, | |
event | |||
) |
Send the user a notification specified in the event.
Definition at line 54 of file notifier/__init__.py.
def progress | ( | self, | |
action, | |||
file, | |||
percent = None |
|||
) |
Indicate compilation progress to a user.
Definition at line 87 of file notifier/__init__.py.
def tool_error | ( | self, | |
message | |||
) |
Communicate a full fatal error to a user.
Definition at line 96 of file notifier/__init__.py.
def var | ( | self, | |
key, | |||
value | |||
) |
Update a UI with a key, value pair
Definition at line 102 of file notifier/__init__.py.
Generated on Tue Jul 12 2022 17:12:48 by
