Re: More efficient "global variables"

From: Paulo Moura <pmoura_at_di.ubi.pt>
Date: Thu 08 Apr 2004 07:00:51 PM GMT
Message-Id: <0E0139FA-898F-11D8-8183-003065804322@di.ubi.pt>
On 8/abr/2004, at 18:06, Tallys Hoover Yunes wrote:

>
> Hi,
>
>   I'm using calls to assert and retract inside an Eclipse
>   code to keep track of some intermediate data (numbers,
>   lists, etc.) that needs to be accessed at different stages
>   of the execution of my program.
>
>   In other words, I'm using dynamic predicates to emulate
>   global variables.

You might consider encapsulating your dynamic data inside an object 
(using Logtalk) or inside a module (using the native ECLiPSe module 
system). Object and modules are global and so may be accessed from 
different parts of your program.

Cheers,

Paulo


-----------------------------------------------------------
Paulo Jorge Lopes de Moura
Dep. of Informatics                   Office 4.3  Ext. 3257
University of Beira Interior          Phone: +351 275319700
6201-001 Covilhã                      Fax:   +351 275319891
Portugal

<mailto:pmoura@di.ubi.pt>
<http://www.di.ubi.pt/~pmoura>     <http://www.logtalk.org>
-----------------------------------------------------------
Received on Thu Apr 08 20:06:19 2004

This archive was generated by hypermail 2.1.8 : Wed 16 Nov 2005 06:07:28 PM GMT GMT