The following languages are currently supported:
Client | Server | |
C++/Qt 4.x | yes | partial (no tables) |
PHP 5.x | planned | yes |
HTML | Documentation Target | |
XML Schema | planned/incomplete for validation and as base for SOAP | |
XML SOAP | planned/incomplete generates WSDL and Schema files for the communication layer only |
C++/Qt | A C++ compiler and at least Qt 4.7 or 5.x, modules: Core, Network, XML, optionally XMLpatterns |
PHP | PHP, at least version 5.2 |
SOAP | any compatible toolkit that can handle WSDL files |
Compiling the meta-compiler is relatively easy: just enter the woc directory and call qmake and make (or open the woc.pro file in QtCreator and compile from there). The same approach works for PACK's Qt base library. The PHP library of PACK does not need to be compiled, just include it in your project.
Layer 3 | Client, Presentation |
Communication Interface | Communication Abstraction Layer |
Layer 2 | Server Business Logic |
Data Interface | Database Abstraction Layer |
Layer 1 | Database (eg. MySQL, PostgreSQL) |
PACK currently supports MySQL and PostgreSQL as databases, but it is relatively easy to port to new SQL-based database systems. Non-SQL relational database systems may be usable, but take much more effort to create an interface driver.
The structure of the database is written up as XML statements in PACK's WOLF files - from this PACK generates the code necessary to create the database tables and to execute queries.
The Data Interface provides wrapper classes around tables which are more convenient to use than plain SQL and will also automatically use the correct SQL dialect for queries.
The business logic needs to be written by the user, but using PACK's facilities it is often very easy to do.
The Communication Interface generated by PACK contains two types of structures: communication classes and transactions. Transactions are operations that the client can execute (remotely) in the server. Each transaction has a unique name, input data and output data. This data can use primitive built-in types or project specific communication classes. These classes define structures of primitive types and other communication classes that enclose the data that is transferred between client and server. The classes also wrap the code necessary to serialize and unserialize themselves during transmission. In addition it is possible to write direct translations between database tables and communication classes to assist in some of the typical translations often performed in the business logic.