I'm creating a plugin system. and here is what it's like
$handle['draw'] = 'draw';
//etc.... a lot of handles
//call the functions...
foreach($foo as $bar){
$func = $handle[$bar['name']];
$result[] = $func($bar['args']);
}
so a plugin will be a function that uses a handle.
But what if the plugin is not a function? if it is a class? or a static class?
Then what do I need to modify to allow it access method inside different classes?