next up previous
Next: 19 BinProlog's C-interface Up: BinProlog 5.75 User Previous: 17.2 Handling regular expressions

18 Objects

AGs as well as the Extended DCGs available in other logic languages intend to overcome a major deficiency of declarative languages gif everyone knows about and nobody says it: the lack of OBJECTS.

The package library(objects) is BinProlog's first attempt to get it right. It's a mixture of ideas and syntax from Java, SELF. It's prototype (not class!) based and dynamic. As objects ultimately benefit from dynamic recompilation the package should not be unusually slow, although no effort has been made to optimize it.

Take a look at file obtest.pl which calls library(objects) and library(obtools).

A tentative distributed version is given in file library(dobjects) which keeps distributed state using Multi-BinProlog's Linda blackboard.



next up previous
Next: 19 BinProlog's C-interface Up: BinProlog 5.75 User Previous: 17.2 Handling regular expressions



Paul Tarau
Thu Apr 3 10:26:39 AST 1997