Composition

See how nested blocks, propagated inputs, merged scope, and reusable assemblies let simple parts scale into larger systems.

What to keep in mind

  • Composition is how simple blocks become larger systems.
  • Nested block references evaluate with parent context plus their own resolved inputs.
  • Parameter propagation supports literals, references, expressions, and inherited values.
  • Merged scope lets child geometry and directives resolve against evaluated parent context.
  • Assemblies scale by reusing one behavioral model through multiple levels of nesting.

Composition turns reusable parts into systems

Composition is how simple blocks become full systems.

A block can contain nested block references, and those nested references are resolved using the same logic system as top-level references.

Nested references are evaluated recursively through the evaluation engine.

When a block contains another block reference, the child does not evaluate in isolation. It evaluates within a merged scope that includes parent-resolved parameters and variables plus the child's own resolved inputs.

This is what makes assembly behavior possible. A parent block can compute values once and pass them into multiple nested children without duplicating logic in every child instance.

Why composition matters in real systems

  • It enables assemblies, coordinated subsystems, and full multi-level systems.
  • It avoids duplication by letting smaller definitions participate in larger systems.
  • It matters whenever parent-level decisions must stay coordinated across many child instances.
  • It makes systems scalable because reuse and evaluation can operate across nested levels.

Without composition, a larger system tends to turn into copied geometry plus copied logic. With composition, the system remains modular while still behaving as a coordinated whole.

Composition connects local behavior into larger runtime systems

  • Built from Blocks: block definitions define behavior at each reusable level.
  • Driven by Logic: parent and child logic both contribute relationships.
  • Executed in Evaluation: nested references are evaluated in stacked runtime contexts.
  • Defined here: composition determines how values and scopes flow between nested systems.
  • Reflected in Outputs: outputs are derived from evaluated instances at all nested levels.

Parent context and child context resolve together

Parameter propagation happens by name and by authored reference values. A child parameter can receive a raw literal, a direct token such as {Width}, an expression, or an inherited same-named value from parent scope when the child instance leaves that parameter unspecified.

This allows nested blocks to remain reusable while still participating in larger assemblies.

During realization, the engine merges parent context with child-resolved values. Geometry, directives, and injectable fields inside the nested block are then resolved against that merged context before the result is transformed into its final position.

The result is not simple insertion. It is evaluated composition.

Static placement is not the same as evaluated systems

Static insertion places something inside something else. Composition goes further. The child system is evaluated with knowledge of the parent context, inherited values, and parent-driven expressions.

That distinction is what allows coordinated systems to stay coordinated. The child is not just positioned. It is resolved.

Simple block to assembly to full system

  • Simple level: one block nests another reusable detail.
  • Assembly level: one block coordinates several children into a subsystem.
  • System level: multiple assemblies combine into a larger evaluated product or document-wide model.

Systems scale by composition, not duplication

A useful mental model is to think of each block as a self-contained system fragment that can participate in a larger system without losing its identity.

Instead of copying geometry and formulas into bigger and bigger drawings, LogiDraft scales by evaluating nested systems together. Composition keeps definitions modular while letting them behave as one coordinated whole.

Evaluation context stacks and overrides remain local

Composition introduces context stacking. A child block resolves its own parameters and variables, but it does so while parent-resolved values are already available for inheritance, expressions, and later injection.

This means parent-to-child propagation is not just data copying. It is context formation. Each nested level adds another evaluation frame that can contribute values to the next level down.

The subtle behavior is that child-specific values still stay local. A child can override what it needs to override while inherited values continue to flow where no child-specific value is supplied. This is what allows assemblies to stay both reusable and coordinated.

Ways composition is commonly used

  • Build assemblies by chaining reusable definitions together instead of creating one oversized block.
  • Push shared dimensions or classifications from a parent into several children.
  • Use nested detail blocks when repeated behavior should stay modular and independently reusable.

A control power assembly is a concrete example. A parent block can determine load-related values once, then flow those values into transformer, fuse, and labeling child blocks so the whole subsystem resolves together.

For the non-visual results produced by composed systems, continue to Outputs. For exact directive properties and command behavior, use Reference. To see nested assemblies in a working system, use Help or open the Control Power Panel example.

Keep exploring

Outputs

See how evaluated instances become aligned drawings, BOMs, schedules, and structured exports.

Help

Follow a guided example to watch these ideas update in a working LogiDraft model.

Reference

Use the reference when you want exact syntax, commands, function signatures, and field names.

Control Power Panel Example

See nested assemblies inherit context while still resolving their own logic.