Rete.Network.Node.Accumulate (Rete v0.1.0)

Copy Markdown View Source

A collection binding: gathers every element matching the token into a list.

:propagates_empty? records the empty-collection rule. A pattern introducing no new variables has every variable fixed by the token, so it has exactly one group and propagates [] when nothing matches. A pattern that introduces one groups by it, and a group only exists where a fact created it, so there is no empty group to propagate.

Summary

Types

t()

@type t() :: %Rete.Network.Node.Accumulate{
  alpha_code: atom(),
  coll_binding: atom() | nil,
  id: non_neg_integer() | nil,
  join_bind: [atom()],
  new_bind: [atom()],
  propagates_empty?: boolean(),
  type: atom()
}