Folder-level composite

This topic provides a simple example of three Math objects chained together.

Figure 1. Simple example of folder before compositing


The objects are located in a LogicA folder. Together, they perform a Celsius to Fahrenheit conversion. A NumericWritable is also shown linked to the first Math object to test.

If this application was needed later, you could copy all tjree linked objects again and insert them in another (perhaps already crowded) wire sheet. However, the middle Multiply object reveals an intermediary result that is distracting.

Or, you could just create a new subfolder with only the three linked objects and then link directly to the child objects as needed (however, it would not be obvious from the parent’s wire sheet that links to children in that folder were established).

It would be better to encapsulate this into a single object with only a single input (degrees F) and single output (degrees C). You can do something like this by compositing the parent container, in this example folder FolderA.

In this case, you would want to delete the link from the test NumericWritable first, then open the Composite Editor for the parent component FolderA. The Composite Editor lets you expand the tree of all contained components and “expose” those items of interest.

Figure 2. Launching and using the Composite Editor


In this example, only the In A of the first math object and the Out of the third math object is selected to be exposed. The Composite Editor provides a tree pane showing slots of points and objects (by clicking the expand controls), and a slot is exposed by simply double-clicking it. Other controls in the editor are available to rename, remove, reorder and reverse exposed items, but are not used here.

After clicking OK to perform the composite, the item composited (in this example, LogicA) shows exposed slots when viewed in its parent’s wire sheet. The following image shows the test NumericWritable now linked to the composited LogicA folder.

Figure 3. Example LogicA folder showing exposed input and output


You could later reopen this folder’s Composite Editor and rename the exposed properties differently, perhaps inDegF and outDegC (to make the purpose of the composited folder clearer). This would not affect the three (child) math objects in any way.