Rete.Network.Node.Alpha (Rete v0.2.0)

Copy Markdown View Source

Matches one condition against a single fact, independently of any token.

:fun is arity 1: (fact) -> bindings_map | nil. It matches a fact of any type, on purpose. Rete.Taxonomy's type index decides which alpha nodes a fact reaches. This is what lets derive(:premium, :customer) make a :premium fact reach a condition written against :customer.

Summary

Types

t()

@type t() :: %Rete.Network.Node.Alpha{
  code: atom(),
  fun: fun(),
  id: non_neg_integer() | nil,
  type: atom()
}