Add "registerCronFile" method to the plugin class

This commit is contained in:
Julio Cesar Laura
2013-11-25 13:01:30 -04:00
parent ad2c91fe53
commit e97a04943f
3 changed files with 86 additions and 19 deletions

View File

@@ -97,7 +97,6 @@ class PMPlugin
$oPluginRegistry->registerDashlets($this->sNamespace);
}
/**
* With this function we can register the report
* param
@@ -360,6 +359,17 @@ class PMPlugin
$oPluginRegistry =& PMPluginRegistry::getSingleton();
$oPluginRegistry->unregisterRestService($this->sNamespace, $classname, $path);
}
/**
* With this function we can register a cron file
* param string $cronFile
* @return void
*/
public function registerCronFile($cronFile)
{
$oPluginRegistry =& PMPluginRegistry::getSingleton();
$oPluginRegistry->registerCronFile($this->sNamespace, $cronFile);
}
}
class menuDetail
@@ -682,3 +692,20 @@ class dashboardPage
}
}
class cronFile
{
public $namespace;
public $cronFile;
/**
* This function is the constructor of the cronFile class
* param string $namespace
* param string $cronFile
* @return void
*/
public function __construct($namespace, $cronFile)
{
$this->namespace = $namespace;
$this->cronFile = $cronFile;
}
}