Logtalk reference manual
Built-in predicate: threaded_engine_destroy/1
Contents > Reference Manual > Built-in Predicates > threaded_engine_destroy/1

## threaded_engine_destroy/1

#### Description

    threaded_engine_destroy(Engine)

Stops an engine.

#### Template and modes

    threaded_engine_destroy(@nonvar)

#### Errors

Engine is a variable:
  `instantiation_error`
Engine is neither a variable nor the name of an existing engine:
  `existence_error(engine, Engine)`

#### Examples

Stop an engine named `worker_1`:
  `threaded_engine_destroy(worker_1)`
Stop all engines:
  `forall(threaded_engine(Engine), threaded_engine_destroy(Engine))`

#### See also

`threaded_engine_create/3`, `threaded_engine_self/1`, `threaded_engine/1`