Example #1
0
 /**
  * 
  * @param string $sMethodName
  * @param array $aArguments
  * @return mixed
  */
 public function __call($sMethodName, $aArguments)
 {
     $mResult = false;
     if ($this->oModule instanceof AApiModule) {
         $mResult = $this->oModule->CallMethod($sMethodName, $aArguments);
     }
     return $mResult;
 }
Example #2
0
 /**
  * @param string $sInclude
  * @return bool
  */
 public function incStorage($sFileName, $bDoExitOnError = true)
 {
     static $aCache = array();
     $sFileFullPath = '';
     $sFileName = preg_replace('/[^a-z0-9\\._\\-]/', '', strtolower($sFileName));
     $sFileName = preg_replace('/[\\.]+/', '.', $sFileName);
     $sFileName = str_replace('.', '/', $sFileName);
     if (isset($aCache[$sFileName])) {
         return true;
     } else {
         $sFileFullPath = $this->oModule->GetPath() . '/managers/' . $this->GetManagerName() . '/storages/' . $sFileName . '.php';
         if (@file_exists($sFileFullPath)) {
             $aCache[$sFileName] = true;
             include_once $sFileFullPath;
             return true;
         }
     }
     if ($bDoExitOnError) {
         exit('FILE NOT EXISTS = ' . $sFileFullPath . ' File: ' . __FILE__ . ' Line: ' . __LINE__ . ' Method: ' . __METHOD__);
     }
     return false;
 }