public function registerProcedures(string $plugin, array $procedures, string $path)
    {
        /* Append the installation path before the files */
        array_walk($procedures, function(&$procedure) use ($path){
            $procedure = "$path/$procedure";
        });

        /* Create a factory from list of paths defined by plugin */
        $factory = new ProcedureFactory($this, $procedures);

        /* Get a list of all procedure names contained in file paths */ 
        foreach($factory->getNames() as $name) {
            /* Use the factory to create and register each procedure */
            $procedure = $factory->create($name);
            $this->add($procedure);
        }
    }
public function registerProcedures(string $plugin, array $procedures, string $path)
    {
        /* Append the installation path before the files */
        array_walk($procedures, function(&$procedure) use ($path){
            $procedure = "$path/$procedure";
        });

        /* Create a factory from list of paths defined by plugin */
        $factory = new ProcedureFactory($this, $procedures);

        /* Get a list of all procedure names contained in file paths */ 
        foreach($factory->getNames() as $name) {
            /* Use the factory to create and register each procedure */
            $procedure = $factory->create($name);
            $this->add($procedure);
        }
    }
public function registerProcedures ( string $ plugin , array $ procedures , string $ path ) { /* Append the installation path before the files */ array_walk ( $ procedures , function ( & $ procedure ) use ( $ path ) { $ procedure = "$path/$procedure" ; } ) ; /* Create a factory from list of paths defined by plugin */ $ factory = new ProcedureFactory ( $ this , $ procedures ) ; /* Get a list of all procedure names contained in file paths */ foreach ( $ factory -> getNames ( ) as $ name ) { /* Use the factory to create and register each procedure */ $ procedure = $ factory -> create ( $ name ) ; $ this -> add ( $ procedure ) ; } }
Register all procedures for a given plugin
Register all procedures for a given plugin