Model Setup/ HierarchicalBlock
Block Name: HierarchicalBlock 

Code File Location: VisualSim/actor/TypedCompositeActor

Block Overview

o       A hierarchical block is used to aggregate multiple basic or hierarchical blocks into a single higher-level block.  

o       If there are no components placed within the hierarchical block, then there wont be any activity within the hierarchical block.

Description

The Hierarchical block enables easy organization of the model content into bins.  The definitions within the block can contain blocks and FSM.  Typically, one adds a hierarchical block for each block in the conceptual block diagram and adds input and output ports to match the flow in conceptual block diagram.  The block can be saved as a sub model for reuse in other models.

To create a hierarchical block, drag "Hierarchical Block" from the Library Folder Model->Hierarchical_Blocks into an existing BDE window.  To view the blocks inside the Hierarchical block, right-click on the icon and select “Open Block”. Click the input and output Icons on the toolbar to add input and output ports to a hierarchical block.  These will show as input/output ports at the parent level model.  

An alternate way to create a Hierarchical block is to draw box around a set of blocks including the links and parameters.  This will highlight the blocks and the links attached.  From the Menu, select Edit->Create Hierarchy.  Note that if the included Parameters are used within this Hierarchy set and other blocks in the model, you will get an error while trying to create a Hierarchical block.

The Parameters and Ports in this block are user-defined. To add a parameter, drag a Parameter from Model -> Parameter Folder. Enter a value for this parameter. To add a port, select Configure -> Ports and click addPorts. Now provide a name, select whether the port is input, output or multi-port and specify the type. Set the type to General, or to a specific type, if required.

NOTE: Class files can also be built using HierarchicalBlock. If the class file was not documented, then this documentation by default will be available for the class blocks.

Refer Hierarchical_params Demo Model.