From: Lo?c C. <lo...@us...> - 2001-12-10 22:53:45
|
Update of /cvsroot/phpmychat/phpMyChat-0.15/chat/lib/database In directory usw-pr-cvs1:/tmp/cvs-serv11557/chat/lib/database Modified Files: mysql.lib.php3 oci8.lib.php3 odbc.lib.php3 pgsql.lib.php3 Log Message: PEAR codding standards (capitalized constants) Index: mysql.lib.php3 =================================================================== RCS file: /cvsroot/phpmychat/phpMyChat-0.15/chat/lib/database/mysql.lib.php3,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** mysql.lib.php3 2001/04/19 21:05:04 1.3 --- mysql.lib.php3 2001/12/10 22:53:40 1.4 *************** *** 31,35 **** if (!defined('_LIB_PMCDB_LOADED')) { ! define('_LIB_PMCDB_LOADED', true); /** --- 31,35 ---- if (!defined('_LIB_PMCDB_LOADED')) { ! define('_LIB_PMCDB_LOADED', 1); /** *************** *** 38,42 **** * @const _LIB_PMCDB_MYSQL_SHOW_ERROR_MESSAGES */ ! define('_LIB_PMCDB_MYSQL_SHOW_ERROR_MESSAGES', true); --- 38,42 ---- * @const _LIB_PMCDB_MYSQL_SHOW_ERROR_MESSAGES */ ! define('_LIB_PMCDB_MYSQL_SHOW_ERROR_MESSAGES', 1); *************** *** 192,196 **** { $this->updateError('pmcDB::connect() - mysql_connect'); ! return false; } $selectResult = @mysql_select_db($this->dbName, $this->linkId); --- 192,196 ---- { $this->updateError('pmcDB::connect() - mysql_connect'); ! return FALSE; } $selectResult = @mysql_select_db($this->dbName, $this->linkId); *************** *** 198,205 **** { $this->updateError('pmcDB::connect() - mysql_select_db'); ! return false; } } ! return true; } // end of the 'connect()' method --- 198,205 ---- { $this->updateError('pmcDB::connect() - mysql_select_db'); ! return FALSE; } } ! return TRUE; } // end of the 'connect()' method *************** *** 246,250 **** @mysql_free_result($this->queryId); $this->queryId = 0; ! return false; } $this->currentRow++; --- 246,250 ---- @mysql_free_result($this->queryId); $this->queryId = 0; ! return FALSE; } $this->currentRow++; *************** *** 314,320 **** { @mysql_freeresult($this->queryId); ! return true; } ! return false; } // end of the 'cleanResults()' method --- 314,320 ---- { @mysql_freeresult($this->queryId); ! return TRUE; } ! return FALSE; } // end of the 'cleanResults()' method *************** *** 332,338 **** { @mysql_close($this->linkId); ! return true; } ! return false; } // end of the 'close()' method } // end of the 'pmcDB' class --- 332,338 ---- { @mysql_close($this->linkId); ! return TRUE; } ! return FALSE; } // end of the 'close()' method } // end of the 'pmcDB' class Index: oci8.lib.php3 =================================================================== RCS file: /cvsroot/phpmychat/phpMyChat-0.15/chat/lib/database/oci8.lib.php3,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** oci8.lib.php3 2001/06/10 15:20:56 1.5 --- oci8.lib.php3 2001/12/10 22:53:40 1.6 *************** *** 33,37 **** if (!defined('_LIB_PMCDB_LOADED')) { ! define('_LIB_PMCDB_LOADED', true); /** --- 33,37 ---- if (!defined('_LIB_PMCDB_LOADED')) { ! define('_LIB_PMCDB_LOADED', 1); /** *************** *** 40,44 **** * @const _LIB_PMCDB_OCI8_SHOW_ERROR_MESSAGES */ ! define('_LIB_PMCDB_OCI8_SHOW_ERROR_MESSAGES', true); --- 40,44 ---- * @const _LIB_PMCDB_OCI8_SHOW_ERROR_MESSAGES */ ! define('_LIB_PMCDB_OCI8_SHOW_ERROR_MESSAGES', 1); *************** *** 209,216 **** { $this->updateError('pmcDB::connect() - OCILogon'); ! return false; } } ! return true; } // end of the 'connect()' method --- 209,216 ---- { $this->updateError('pmcDB::connect() - OCILogon'); ! return FALSE; } } ! return TRUE; } // end of the 'connect()' method *************** *** 266,270 **** @ocifreestatement($this->queryId); $this->queryId = 0; ! return false; } $this->currentRow++; --- 266,270 ---- @ocifreestatement($this->queryId); $this->queryId = 0; ! return FALSE; } $this->currentRow++; *************** *** 299,303 **** $GLOBALS['currentError']['message'] = 'Invalid statement: number of rows can\'t be returned for the last query'; $this->updateError('pmcDB::numRows()'); ! return false; } // numRows() is a valid function for the previous query --- 299,303 ---- $GLOBALS['currentError']['message'] = 'Invalid statement: number of rows can\'t be returned for the last query'; $this->updateError('pmcDB::numRows()'); ! return FALSE; } // numRows() is a valid function for the previous query *************** *** 383,389 **** { @ocifreestatement($this->queryId); ! return true; } ! return false; } // end of the 'cleanResults()' method --- 383,389 ---- { @ocifreestatement($this->queryId); ! return TRUE; } ! return FALSE; } // end of the 'cleanResults()' method *************** *** 401,407 **** { @OCILogoff($this->linkId); ! return true; } ! return false; } // end of the 'close()' method } // end of the 'pmcDB' class --- 401,407 ---- { @OCILogoff($this->linkId); ! return TRUE; } ! return FALSE; } // end of the 'close()' method } // end of the 'pmcDB' class Index: odbc.lib.php3 =================================================================== RCS file: /cvsroot/phpmychat/phpMyChat-0.15/chat/lib/database/odbc.lib.php3,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** odbc.lib.php3 2001/04/19 21:05:04 1.5 --- odbc.lib.php3 2001/12/10 22:53:40 1.6 *************** *** 32,36 **** if (!defined('_LIB_PMCDB_LOADED')) { ! define('_LIB_PMCDB_LOADED', true); /** --- 32,36 ---- if (!defined('_LIB_PMCDB_LOADED')) { ! define('_LIB_PMCDB_LOADED', 1); /** *************** *** 39,43 **** * @const _LIB_PMCDB_ODBC_SHOW_ERROR_MESSAGES */ ! define('_LIB_PMCDB_ODBC_SHOW_ERROR_MESSAGES', true); --- 39,43 ---- * @const _LIB_PMCDB_ODBC_SHOW_ERROR_MESSAGES */ ! define('_LIB_PMCDB_ODBC_SHOW_ERROR_MESSAGES', 1); *************** *** 213,220 **** { $this->updateError('pmcDB::connect() - odbc_connect'); ! return false; } } ! return true; } // end of the 'connect()' method --- 213,220 ---- { $this->updateError('pmcDB::connect() - odbc_connect'); ! return FALSE; } } ! return TRUE; } // end of the 'connect()' method *************** *** 283,287 **** @odbc_free_result($this->queryId); $this->queryId = 0; ! return false; } else --- 283,287 ---- @odbc_free_result($this->queryId); $this->queryId = 0; ! return FALSE; } else *************** *** 331,335 **** { $this->updateError('pmcDB::metadata(' . $table . ') - odbc_exec'); ! return false; } $count = odbc_num_fields($id); --- 331,335 ---- { $this->updateError('pmcDB::metadata(' . $table . ') - odbc_exec'); ! return FALSE; } $count = odbc_num_fields($id); *************** *** 422,426 **** return (isset($this->record[strtolower($fieldName)])) ? $this->record[strtolower($fieldName)] ! : false; } // end of the 'fieldValue()' method --- 422,426 ---- return (isset($this->record[strtolower($fieldName)])) ? $this->record[strtolower($fieldName)] ! : FALSE; } // end of the 'fieldValue()' method *************** *** 480,486 **** { @odbc_freeresult($this->queryId); ! return true; } ! return false; } // end of the 'cleanResults()' method --- 480,486 ---- { @odbc_freeresult($this->queryId); ! return TRUE; } ! return FALSE; } // end of the 'cleanResults()' method *************** *** 498,504 **** { @odbc_close($this->linkId); ! return true; } ! return false; } // end of the 'close()' method } // end of the 'pmcDB' class --- 498,504 ---- { @odbc_close($this->linkId); ! return TRUE; } ! return FALSE; } // end of the 'close()' method } // end of the 'pmcDB' class Index: pgsql.lib.php3 =================================================================== RCS file: /cvsroot/phpmychat/phpMyChat-0.15/chat/lib/database/pgsql.lib.php3,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** pgsql.lib.php3 2001/04/19 21:05:04 1.3 --- pgsql.lib.php3 2001/12/10 22:53:40 1.4 *************** *** 31,35 **** if (!defined('_LIB_PMCDB_LOADED')) { ! define('_LIB_PMCDB_LOADED', true); /** --- 31,35 ---- if (!defined('_LIB_PMCDB_LOADED')) { ! define('_LIB_PMCDB_LOADED', 1); /** *************** *** 38,42 **** * @const _LIB_PGSQL_SHOW_ERROR_MESSAGES */ ! define('_LIB_PMCDB_PGSQL_SHOW_ERROR_MESSAGES', true); --- 38,42 ---- * @const _LIB_PGSQL_SHOW_ERROR_MESSAGES */ ! define('_LIB_PMCDB_PGSQL_SHOW_ERROR_MESSAGES', 1); *************** *** 209,216 **** { $this->updateError('pmcDB::connect() - pg_Connect'); ! return false; } } ! return true; } // end of the 'connect()' method --- 209,216 ---- { $this->updateError('pmcDB::connect() - pg_Connect'); ! return FALSE; } } ! return TRUE; } // end of the 'connect()' method *************** *** 257,261 **** @pg_freeresult($this->queryId); $this->queryId = 0; ! return false; } $this->currentRow++; --- 257,261 ---- @pg_freeresult($this->queryId); $this->queryId = 0; ! return FALSE; } $this->currentRow++; *************** *** 325,331 **** { @pg_FreeResult($this->queryId); ! return true; } ! return false; } // end of the 'cleanResults()' method --- 325,331 ---- { @pg_FreeResult($this->queryId); ! return TRUE; } ! return FALSE; } // end of the 'cleanResults()' method *************** *** 343,349 **** { @pg_close($this->linkId); ! return true; } ! return false; } // end of the 'close()' method } // end of the 'pmcDB' class --- 343,349 ---- { @pg_close($this->linkId); ! return TRUE; } ! return FALSE; } // end of the 'close()' method } // end of the 'pmcDB' class |