View Single Post
Old Jun 23rd, 2005, 11:10 AM   #1
powah
Newbie
 
Join Date: Jun 2005
Posts: 1
Rep Power: 0 powah is on a distinguished road
change the empty function from the old format to the new format

I have about 300 files which has the function getDBBackend().
How to write a program to change the empty function from the old format to the new format?

Old empty function format are either:
function getDBBackend()
{
// Not available
} // getDBBackend


or:
function getDBBackend()
{

} // getDBBackend


New empty function format is:
function getDBBackend()
{
// DB backend not applicable, use test backend
getTestObject();
} // getDBBackend


If the function is not empty, then it will not be changed:
function getDBBackend() {
$msg = db_start_dget(MIO_DGET_DATA);
//...
}
powah is offline   Reply With Quote