Package: Simulink
Suppress diagnostic messages from a specified block
A Simulink.SuppressedDiagnostic
object contains information related to
diagnostic warnings or errors that are suppressed from being thrown during
simulation.
The Diagnostic Viewer in Simulink® includes an option to suppress certain diagnostics. This feature enables
you to suppress warnings or errors for specific objects in your model. Click the
Suppress button next to the warning in the Diagnostic Viewer
to suppress the warning from the specified source. This action creates a
Simulink.SuppressedDiagnostic
object. You can access this object
at the MATLAB® command line using the Simulink.getSuppressedDiagnostics
function. You can add a comment for
the suppressed diagnostic. You can restore the diagnostic by clicking
Restore.
creates a suppressed diagnostic object. The object suppresses all instances of
diagnostics represented by DiagnosticObject
= Simulink.SuppressedDiagnostic(source
, message_id
)message_id
thrown by the blocks specified
by source
.
restore | Remove specified diagnostic suppressions |
suppress | Suppress diagnostic specified by
Simulink.SuppressedDiagnostic object |
Handle. To learn how handle classes affect copy operations, see Copying Objects.
restore
| Simulink.getSuppressedDiagnostics
| Simulink.restoreDiagnostic
| Simulink.suppressDiagnostic
| Simulink.SuppressedDiagnostic