title="Link to this heading"></a></h2>
<p>This tool can also be applied to plain Prolog code. For example, if the
Prolog file is named <code class="docutils literal notranslate"><span class="pre">code.pl</span></code>, simply define an object including its
code and declaring as public any predicates that you want to use as
messages to the object. For example:</p>
<div class="highlight-logtalk notranslate"><div class="highlight"><pre><span></span><span class="p">:- </span><span class="k">object</span>(cod