Visual Prolog Features
Visual Prolog 7.5 is the newest generation of the Visual Prolog logical programming language that might be used for creating industrial strength application for sthe Microsoft Windows platform (Windows 7, Windows Vista, Windows XP, Windows Server 2008, Windows Server 2003).
It is a strongly typed object oriented programming language based on the Prolog programming language.
- Language features
- Integrated Development Environment (IDE)
- Examples included in Visual Prolog
The main characteristics/notions of the Visual Prolog programming language are:
- based on logical programming with Horn clauses
- fully object oriented
- object predicate values (delegates)
- strongly typed
- algebraic data types
- pattern matching and unification
- controlled non-determinism
- fully integrated fact databases
- supports parametric polymorphism
- automatic memory management
- supports direct linkage with C/C++
- supports direct calling of Win32 API functions
The object system is constructed for loose coupling between a provider and a user. Objects can only be accessed through interfaces, and interfaces are only loosely coupled to implementations. Any class can implement any interface with or without inheriting implementation from other classes.
The combination of strong type check, no-need-for-pointer-arithmetic, and automatic memory management practically removed access violations.
Visual Prolog has a long reputation for not producing access violations. As one of our good users once said: That kind of errors is just not an option in Visual Prolog. We intend to keep it that way and Visual Prolog 7 family is no exception from this principle. Our goal is that you will have to interface to foreign code or insist on making pointer arithmetic to provoke access violations.
Algebraic data types, fact databases and pattern matching combined with non-deterministic search makes Visual Prolog very well suited for dealing with complex structured knowledge.
All Visual Prolog data except predicate values and objects have a human readable textual representation that can be written and read back into programs.
Integrated Development Environment (IDE)
Visual Prolog Integrated Development Environment (IDE) is designed to make it easy, convenient and fast to develop, test, and modify applications written in Visual Prolog.
It might be especially useful in developing of large projects.
- Tree representation of modules, include files, and resources in the Project window helps to group project items into packages and thus gives an extra level of abstraction.
- The Text Editor supports convenient text editing and browsing to declarations and implementations.
- The Dialog Editor provides standard controls to design dialogs.
- The Menu Editor allows to create both pull-down and pop-up menus.
- The Toolbar Editor allows to create various kinds of toolbars.
- The Graphics Editor is a convenient tool for creating, viewing and editing icons, cursors and small bitmaps.
- The Build Facility supports inserting of necessary packages and include directives.
- The Browse Facilities supports search for specific entities, "go to definition" and "go to declaration"
Please see Environment Overview for detailed information and screenshots.
The Visual Prolog compiler is a successor of the Turbo Prolog compiler created in 1980s that was the first Prolog compiler. Since that time the Prolog Development Center has been developing and improving its compiler. Currently Visual Prolog compiler is a powerful and efficient compiler that can:
- create object files for creating standalone executables or DLLs;
- resolve cross references among declarations;
- validate predicate mode;
- perform powerful type checking;
- validate facts initialization in constructors;
- perform predicate resolution.
Visual Prolog contains a powerful linker that can:
- create EXE and DLL files;
- use LIB files, generated by the latest Microsoft Visual C compilers.
The Visual Prolog Development Environment contains a built-in graphical debugger that can:
- show usual debugger views: memory, stack, variables;
- show class and object facts with their values;
- perform step into, step over, etc;
- including extra stepping: step out, run to prolog code;
- visualize fail and exit.
Examples included in Visual Prolog
Both Visual Prolog Personal and Commercial editions include a number of example projects that demonstrate various Visual Prolog features.
The examples include samples corresponding to the online tutorials, which are found in the _tutorials subdirectory in the examples directory.