PHP Classes

PHP or Java Class Code Generator: Generate PHP or Java database access classes

Recommend this page to a friend!
  Info   View files View files (24)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
StarStar 39%Total: 3,564 All time: 936 This week: 90Up
Version License Categories
code_generator 1.0.0GNU General Publi...Data types, Code Generation
Description 

Author

This package is meant is automate the generation of classes to access databases in Java beans style.

It uses the Fast Template engine to process template files that define the skeleton of functions and variables of classes that store and retrieve data object property values from a given database table, getter and setter functions to access those properties and a function to delete a data object row from the respective database table.

The package comes with templates to generate classes either in PHP or Java. The PHP template defines code to access data objects in a MySQL database. The Java template defines code to access data objects in any database supported by JDBC.

Innovation Award
PHP Programming Innovation award winner
March 2004
Winner


Prize: One copy of DWeb Pro Lifetime License by Human Profile
Code generation is one way to increase software development productivity by automating the production of code components meant to execute repetitive well known tasks. Depending on the capabilies and maturity of the generator tool, the productivity increase may be huge.

Database access classes is a common application of code generation tools. Tables are abstracted by database access classes and the table rows are mapped to objects of those classes.

The approach of this code generation package is to use a well known template engine class, Fast Template, and make it process template files that define the skeleton of the database access classes to be generated.

The example templates for generating database access classes either in PHP or Java demonstrate that with a simple approach it can be provided a flexible solution for addressing a common problem especially in Web application development.

Despite the tool can be improved in many ways, it constitutes a good example of how to build your own code generation tool that may help other developers understand and become interested in this powerful approach.

Manuel Lemos
Picture of Valics Lehel
Name: Valics Lehel <contact>
Classes: 4 packages by
Country: Romania Romania
Age: 51
All time rank: 1544 in Romania Romania
Week rank: 312 Down3 in Romania Romania Up
Innovation award
Innovation award
Nominee: 1x

Winner: 1x

Details

Please configure config.inc.php

  Files folder image Files  
File Role Description
Files folder imageinclude (3 files)
Files folder imageprogramtemplates (10 files)
Accessible without login Plain text file begin.php Appl. app script
Accessible without login Plain text file CHANGELOG Doc. changelog
Accessible without login Plain text file config.inc.php Conf. Configuration file
Accessible without login Plain text file defines.inc.php Conf. defines
Accessible without login Plain text file example.php Example Example of call generated class
Accessible without login Plain text file field.php Appl. app script
Accessible without login Plain text file generate_code.php Appl. code generator PHP
Accessible without login Plain text file index.php Appl. index
Accessible without login Plain text file README.txt Data README
Accessible without login Plain text file start.php Appl. app script
Accessible without login Plain text file table.php Appl. app script

  Files folder image Files  /  include  
File Role Description
  Plain text file cls_fast_template.php Class Template system
  Plain text file cls_string.php Class Strings, verifications
  Accessible without login Plain text file connection.php Example Connection for examples

  Files folder image Files  /  programtemplates  
File Role Description
  Accessible without login HTML file template_body.html Aux. the main template
  Accessible without login HTML file template_fields.html Aux. template file
  Accessible without login HTML file template_firstpage.html Aux. template file, firstpage
  Accessible without login HTML file template_generate.html Aux. template file
  Accessible without login HTML file template_host.html Aux. template file for mysql host
  Accessible without login Plain text file template_java_code_generator.html Data template for generating for Java
  Accessible without login HTML file template_php5_code_generator.html Aux. PHP5 template
  Accessible without login Plain text file template_php_code_generator.html Data template for generating for Java
  Accessible without login HTML file template_sql.html Aux. SQL html file
  Accessible without login HTML file template_table.html Aux. tables SQL HTML

 Version Control Unique User Downloads Download Rankings  
 0%
Total:3,564
This week:0
All time:936
This week:90Up
 User Ratings  
 
 All time
Utility:62%StarStarStarStar
Consistency:79%StarStarStarStar
Documentation:-
Examples:-
Tests:-
Videos:-
Overall:39%StarStar
Rank:3822