@param array $args

@return void
974884
public function handleStockItem($args)
    {
        $productId = $args['row']['product_id'];
        $isInStock = $args['row']['is_in_stock'];
        $qty = $args['row']['qty'];

        $this->stockData[$productId] = [
            'is_in_stock' => $isInStock,
            'qty'         => $qty,
        ];
    }
969931
public static function evaluateArgs(array $args)
    {

        $parsedArgs = [];

        foreach ($args as $key=>$value) {

            if ($value instanceof self) {
                $parsedArgs[$key] = static::callFast($value);
                continue;
            }
            $parsedArgs[$key] = $args[$key];
        }

        return $parsedArgs;

    }
282891
protected function handle($name, array $args = [])
    {
        if (isset($this->handlers[$name]) && is_callable($this->handlers[$name])) {
            array_unshift($args, $this);
            call_user_func_array($this->handlers[$name], $args);
        }
    }
59593
public function run($args)
	{
		$options=array(
			'fileTypes'=>array('php'),
			'exclude'=>array(
				'.gitignore',
				'/messages',
				'/views',
				'/cli',
				'/yii.php',
				'/yiit.php',
				'/yiilite.php',
				'/web/js',
				'/vendors',
				'/i18n/data',
				'/utils/mimeTypes.php',
				'/test',
				'/zii',
				'/gii',
			),
		);
		$files=CFileHelper::findFiles(YII_PATH,$options);
		$map=array();
		foreach($files as $file)
		{
			if(($pos=strpos($file,YII_PATH))!==0)
				die("Invalid file '$file' found.");
			$path=str_replace('\\','/',substr($file,strlen(YII_PATH)));
			$className=substr(basename($path),0,-4);
			if($className[0]==='C')
				$map[$path]="\t\t'$className' => '$path',\n";
		}
		ksort($map);
		$map=implode($map);

		$yiiBase=file_get_contents(YII_PATH.'/YiiBase.php');
		$newYiiBase=preg_replace('/private\s+static\s+\$_coreClasses\s*=\s*array\s*\([^\)]*\)\s*;/',"private static \$_coreClasses=array(\n{$map}\t);",$yiiBase);
		if($yiiBase!==$newYiiBase)
		{
			file_put_contents(YII_PATH.'/YiiBase.php',$newYiiBase);
			echo "YiiBase.php is updated successfully.\n";
		}
		else
			echo "Nothing changed.\n";
	}
973462
public function afterInsert(&$args) {
        $model = $args[0];
        $data = $args[1];
        $this->afterSave($model, $data);
    }
328945
public function handle($event, $args) {
		if (isset($this->callback[$event])) {
			$this->callback[$event](...$args);
		}
	}
191231
private function _parseArgs(array $args)
	{
		$arg = '';
		if(count($args) > 0)
		{
			foreach($args as $number => $argument)
			{
				if($number === 0)
				{
					$arg .= $argument;
				}
				else
				{
					$arg .= ', ' . $argument;
				}
			}
		}

		return $arg;
	}
708090
public function setArguments(array $arguments)
    {
        $this->checkStringArgument($arguments, 2);
        $this->checkStringArguments($arguments);
        $this->arguments = $arguments;
    }
507049
public function init(array $args = [])
    {
        $args += ['total' => 100, 'width' => 80];
        $this->_progress = 0;
        $this->_width = $args['width'];
        $this->_total = $args['total'];

        return $this;
    }
1281759
public function info(array $args = array()) {
        if (empty($args)) {
            Garp_Cli::errorOut('Insufficient arguments');
            Garp_Cli::lineOut('Usage: garp Db info <tablename>');
            return;
        }
        $db = new Zend_Db_Table($args[0]);
        Garp_Cli::lineOut(
            Zend_Config_Writer_Yaml::encode($db->info())
        );
        Garp_Cli::lineOut('');
    }
714700
public function handle(array $args = [])
    {
        // remove source file name from argv
        $source = array_shift($args);

        /** @var ConsoleEvent $applicationEvent */
        $applicationEvent = $this->getApplicationEvent();
        $applicationEvent->setName(self::EVENT_REQUEST_RECEIVED);
        $applicationEvent->setSourceFile($source);
        $applicationEvent->setArguments($args);
        $this->emit($applicationEvent);

        // init dispatcher
        $dispatcher = new Dispatcher($this->commands, $this->container);

        $middlewareRunner = new MiddlewareRunner($this->getMiddlewares());

        $middlewareRunner->run([$applicationEvent->getArguments()], function ($args) use ($applicationEvent, $dispatcher) {
            // dispatch command with args from cli
            $dispatcher->dispatch($args);
        });
    }
668861
public function execute(array $args = [], array $options = [])
    {
        foreach ($this->sequence as $command) {
            $command->setConfig($this->getConfig());
            $command->setConfigService($this->getConfigService());
            if ($this->hasOutput() && method_exists($command, 'setOutput')) {
                $command->setOutput($this->getOutput());
            }
            if ($this->hasInput() && method_exists($command, 'setInput')) {
                $command->setInput($this->getInput());
            }
            $command->execute($args, $options);
        }
    }
755990
protected function init_args($args)
    {
        parent::init_args($args);

        $this->env = $this->get_env_for_write_or_fail();
        $api = new Salts();

        try {
            $this->salts = $api->collect();
        } catch (Exception $e) {
            WP_CLI::error($e->getMessage());
        }
    }
815042
protected function setArgument($arg)
    {
        if ($this->checkDiscription($arg)) {
            $this->advanceArg($arg);
        } else {
            $this->simpleArg($arg);
        }
    }
771816
public function beforeInsert(&$args) {
        $model = &$args[0];
        $data  = &$args[1];
        $this->validate($data, $model);
    }
761095
protected function callAllListeners($args = [])
    {
        $args = (array) $args;
        array_map(function ($event) use ($args) {
            $this->callListeners($event, $args);
        }, array_keys($this->listeners));
    }
963754
public function afterUpdate(array &$args) {
        // Check if an email address was changed. If so, send a validation email
        $data = $args[2];
        if (array_key_exists('email', $data) && $this->_validateEmail) {
            $this->_onEmailChange($data['email'], 'update');
        }
    }