I'm working on a framework for personal and business usage.
At this moment I do some database research, "what's is a good class model?".
So I made some start and thought it would be all right to get some feedback from somebody.
This is my model (used no image, but code):
Controller class:
Mysql/Mssql, etc driver:PHP Code:<?php
class Vis_DbController
{
function __construct(){}
public function & getInstance(){} // like factory
}
?>
and MysqlRowset:PHP Code:<?php
class Vis_MysqlDriver
{
private $Ci_ResourceID;
function __construct(){}
public function connect(){}
public function disconnect(){}
public function getResourceID(){}
public function execute( & $Ps_Sql )
{
$o_Rowset = & new Vis_MysqlRowset( & $Ps_Sql );
return $o_Rowset;
}
}
?>
Is this a well organised class model? What can be done better?PHP Code:<?php
class Vis_MysqlRowset
{
private $Ca_Query;
function __construct( & $Ps_Sql ){}
public function fetchBoth(){}
public function fetchAssoc(){}
public function fetchRow(){}
public function numRows(){}
public function affectedRows(){}
public function lastInsertID(){}
public function freeRecordSet(){}
}
?>
Thanks, Ruben







Bookmarks