# GNU Prolog for Java 0.2.5 Manual

Next: Using the API, Previous: Top, Up: Top

## 1 Overview

GNU Prolog for Java (GPJ) is a Java library (gnu.prolog) which allows the use of Prolog from within Java programs. It supports part 1 of the ISO standard for Prolog with some extensions. It is licenced under the LGPLv3 which can be found in the COPYING and COPYING.LIBRARY files distributed with GNU Prolog for Java (GPJ) and published by the Free Software Foundation. For normal usage there are only a few classes which you will need to interact with. gnu.prolog.vm.Environment which provides the core of the prolog environment. gnu.prolog.vm.Interpreter which is what you use to run your prolog queries. gnu.prolog.term which contains the various types of Prolog terms which exist and which you use to construct your prolog questions if you want answers (beyond SUCCESS, SUCCESS_LAST and FAIL). The use of the API is explained in the next chapter: Using the API. If you wish to install GPJ then instructions are provided in the Installation chapter. If you wish to extend GPJ by writing your own predicates (for example to allow prolog code to make calls into your Java code) then see the chapter on Extending GPJ. Further documentation is provided in the README file and changes brought about by new versions will be detailed in the NEWS file. The http://www.gnu.org/software/gnuprologjava/api/ java API has javadoc based documentation. The gnu.prolog.demo package contains various example programs which use the API.