Communicating Prolog Units
extend Prolog with object oriented programming constructs
by employing meta-programming techniques to define and handle
the interaction between units of Prolog clauses. [MN86].
Communication between units is possible by using a
meta-predicate of the form
[]
where Destination represents the unit by which
the Goal must be evaluated.
The results are collected in the Answer argument.
Units act as objects, since an internal state may be represented by clauses,
and modified by asserting or retracting clauses.
A process, that is an instance of a unit, may influence
the way external requests are handled by providing synchronization
clauses of the form
[]
When a goal in a send statement unifies with the entry part
of the head of the clause, the evaluation of the body is postponed
until the accept part of the head is satisfied.
The functionality of these synchronization clauses
resembles that of a rendez-vous.
The approach followed here has resulted in a number of constructs
with great expressive power, due to the application
of meta-programming techniques.
A clear advantage is that the backtracking behavior of Prolog
is retained.
Currently, there exists only a prototype implementation in Prolog.