APICe » Publications » Tri-dimensional Multi-paradigm Programming in tuProlog 3

Tri-dimensional Multi-paradigm Programming in tuProlog 3

Enrico Denti, Roberta Calegari
tuProlog is a multi-paradigm & multi-platform Prolog system explicitly designed to promote the seamless integration between the logic/declarative and the object-oriented imperative paradigms, enabling Prolog to inter-operate with Java (and other languages) easily and naturally. The recent inclusion of key functional programming concepts and constructs in Java 8 opens the way to adding one further dimension to tuProlog’s multi-paradigm approach, enabling Prolog to manipulate and execute Java 8 lambdas (and related constructs) natively. Therefore, in this paper we discuss how such an integration can be obtained both conceptually and architecturally, moving from the key requirements down to the implementation. To this end, after recalling the current tuprolog multi-paradigm framework and the basics of the Java 8 constructs, we first discuss a general technique that exploits the built-in Java compiler via the combined use of a dynamic proxy and a dynamic class generator, and then show its practical application to the tuProlog case. The new Java/tuProlog library, built on top of this technology, is then presented, from the syntax to practical multi-paradigm programming examples. The impact on tuProlog.NET is also briefly discussed, as well as the next expected steps.
Advances in Software Engineering, August 2014
	Author = {Denti, Enrico and Calegari, Roberta},
	Issn = {1687-8655},
	Issn-Online = {1687-8663},
	Journal = {Advances in Software Engineering},
	Month = aug,
	Title = {Tri-dimensional Multi-paradigm Programming in {tuP}rolog 3},
	Year = 2014}