Main Content


Advanced functions for manipulating and querying models, charts, and elements directly

These utility functions enable advanced users to manipulate and query Simulink models and Stateflow charts and elements of those models and charts.


expand all

slreportgen.utils.hasDiagramCheck if object has diagram
slreportgen.utils.isBusSelector Check if Bus Selector block
slreportgen.utils.isDocBlock Check if DocBlock
slreportgen.utils.isLookupTable Check if lookup table block
slreportgen.utils.isMATLABFunction Check if MATLAB function block or object
slreportgen.utils.isModelCheck if object is model
slreportgen.utils.isModelReferenceBlockCheck if object is Model block
slreportgen.utils.isStateTransitionTableBlock Check if object is Transition Table block
slreportgen.utils.isTestSequenceCheck if Test Sequence block or object
slreportgen.utils.isTruthTable Check if object is Truth Table
slreportgen.utils.isModelLoaded Check if model is loaded
slreportgen.utils.loadAllSystems Load all systems
slreportgen.utils.getModelHandleGet Simulink model
slreportgen.utils.getSlSfHandleGet Simulink handle or Stateflow object
slreportgen.utils.block2chartGet Stateflow chart object from containing block
slreportgen.utils.getObjectID Generate link target ID for Simulink or Stateflow object
slreportgen.utils.isSID Check if name is Simulink Identifier (SID) string
slreportgen.utils.isValidSlSystem Check if system is valid Simulink system
slreportgen.utils.pathJoin Combine two diagram path parts
slreportgen.utils.pathParts Split diagram path into parent and diagram parts
slreportgen.utils.pathSplit Split diagram path into array of diagram parts
slreportgen.utils.getCurrentEditorViewGet current editor view area
slreportgen.utils.getDisplayIcon Get Simulink or Stateflow icon file name
slreportgen.utils.HierarchyNumberGenerate number that represents subsystem position in model hierarchy
slreportgen.utils.traceSignal Trace signal to source or destination
slreportgen.utils.getResolvedParamValue Evaluate parameter value expression
slreportgen.utils.isMaskedSystemCheck if system is masked subsystem block
slreportgen.utils.isCommentedCheck if object is commented out