en:toolworks:docs:apparatus:enchaining

Enchaining

Enchaining is the process of selecting a subset of Chunks (or Belts) based on a certain Filter criteria. Once enchained Belts and Chunks become locked, the structural changes become minimized for the sake of consistent iterating.

That’s pretty basic, really. You don’t create (instantiate) Chains manually but those are actually managed by the Machine class. Assuming you’ve already assembled the needed Filter all you have to do is to call a global Mechanism method named Enchain passing it the applied filter.

FChain* Chain = Mechanism->Enchain(Filter);

You’re now ready to iterate or operate the resulting Chain, but there is more.

You can also enchain to a special type of Chains called solid. Solid chains provide some additional features like getting direct references to Traits and Concurrency but they also limit the operations possible on the Subjects to only non-structural ones. That is, you can’t add or remove any traits to/from the Subjects during some active solid enchainings. Enchaining to a solid chain is as easy as:

FSolidChain* Chain = Mechanism->EnchainSolid(Filter);

  • en/toolworks/docs/apparatus/enchaining.txt
  • Last modified: 2021/09/01 19:32
  • by vladius