Availability:built-in
[det]engine_create(+Template,
:Goal, ?Engine)
[det]engine_create(+Template,
:Goal, -Engine, +Options)Create a new engine and unify Engine with a handle to it.
Template and Goal form a pair similar to findall/3:
the instantiation of Template becomes available though engine_next/2
after Goal succeeds. Options is a list of the
following options. See thread_create/3
for details.
- alias(+Name)
- Give the engine a name. Name must be an atom. If this option
is provided, Engine is unified with Name. The name
space for engines is shared with threads and mutexes.
- global(KBytes)
- Set the limit for the global stack in KBytes.
- local(KBytes)
- Set the limit for the local stack in KBytes.
- trail(KBytes)
- Set the limit for the trail stack in KBytes.
The Engine argument of engine_create/3
may be instantiated to an atom, creating an engine with the given alias.