Methods |
| constructor | Creates a new DB Engine database object |
| |
Tables |
| create | Creates a new table |
| exists | Checks if a table exists |
| verify | Verifies a table | (unique, numeric or non-numeric fields) |
| clear | Clears a table |
| drop | Deletes a table |
| |
Records |
| fetch | Fetches records | (accepts Where clauses, Sorts and Joints) |
| insert | Inserts a new record | (accepts auto-increment fields) |
| update | Updates records | (accepts Where clauses and Joints) |
| delete | Deletes records | (accepts Where clauses and Joints) |
| fastFetch | Fetches records | (faster with low ressources) |
| fastUpdate | Updates records | (faster with low ressources) |
| count | Counts records | |
| |
Locks |
| lock | Locks tables |
| unlock | Unlocks tables |
| |
Information |
| Tables | Returns information on the tables |
| FieldNames | Returns field names |
|
Debug |
| DBE_Tables | Returns HTML with tables information | (for debug purpose) |
| DBE_Table | Returns HTML with table content | (for debug purpose) |
| DBE_Styles | Return CSS for the DBE_Style class | (for debug purpose) |
|
Syntaxes |
| Where clauses | Where clauses syntax | (accepts Joints) |
| Sorts | Sorts syntax | (accepts Joints) |
| Joints | Joints syntax |
| Updates | Updates syntax |
|
Constants |
| DBE_VERSION | DB Engine version |
| DBE_CREATE | Creates a new database | (for constructor) |
| DBE_DEBUG | Debug mode: show warnings | (for constructor) |
| DBE_OVERWRITE | Overwrites existing tables | (for create method) |
| DBE_UNIQUE | Requests a unique record result | (for fastFetch method) |
| DBE_FS | Field separator |
| DBE_RS | Record separator |
| DBE_SUBDIR | Scans sub-directories | (for Table method) |
|
Reserved names |
| DBE_FILEHANDLE | constant name | (internal use only) |
| DBE_FILELOCKED | constant name | (internal use only) |
| DBE_FIELDNAMES | constant name | (internal use only) |
| DBE_FIELDINDEXES | constant name | (internal use only) |
| DBE_RECORDSIZE | constant name | (internal use only) |
| DBE_LOGSIZE | constant name | (internal use only) |
| |
| DBE_clean | function name | (internal use only) |
| DBE_cleanField | function name | (internal use only) |
| DBE_cleanFieldName | function name | (internal use only) |
| DBE_transpose | function name | (internal use only) |
|
Usage | include ('dbengine.inc.php');
include ('dbengine.debug.inc.php'); // optionnal
$iDBE = new DBE_Database('database/');
echo '<pre>';
print_r ($iDBE->Tables());
echo '</pre>';
echo DBE_Tables ($iDBE);
|