Get flag value for command line option.

@param      $key
@param null $default

@return mixed
765177
protected function get_flag($key, $default = null)
    {
        return \WP_CLI\Utils\get_flag_value($this->args->original(), $key, $default);
    }
352489
public function getParam($key = null, $default = null)
    {
        if (!isset($key)) {
            return $this->params;
        }

        foreach ((array) $key as $k) {
            if (isset($this->params[$k])) {
                return $this->params[$k];
            }
        }

        return $default;
    }
109512
public function get($key, $default = null)
    {
        if (!GC_CLI && isset($_SESSION)) {
            $value = gplcart_array_get($_SESSION, $key);
        }

        return isset($value) ? $value : $default;
    }
872454
public function get($key, $default = null)
    {
        $values = $this->readFileContents();

        if ($this->has($key)) {
            return $values[$key][self::VALUE];
        }

        return $default;
    }
100394
protected function _getConfigValue( $key, $default = null )
	{
		$config = $this->_item->getConfig();

		if( isset( $config[$key] ) ) {
			return $config[$key];
		}

		return $default;
	}
679601
public function getParameter($key, $default = null) {
        $parameter = array_get($this->parameters, $key, $default);

        if ($parameter === null) {
            return $default;
        }

        return $parameter;
    }
727341
public function getOption($key)
    {
        $this->checkOptionKey($key);

        return isset($this->_options[$key]) ? $this->_options[$key] : $this->defaultOptions[$key];
    }
668617
protected function getConfigValue($key, $default = null)
    {
        if (Arr::has($this->normalizedConfig, $key)) {
            return Arr::get($this->normalizedConfig, $key);
        }

        return $this->getFallbackConfigValue($key, $default);
    }
1032407
public function get( $key = null, $default = null ) {
		return func_num_args() === 0 ? $_GET : $this->app->utility->array_get( $_GET, $key, $default );
	}
1153367
public function get($key, $default = null) {

        return array_key_exists($key, $this->options) ? $this->options[$key] : $default;
    }
641694
public function getOption($key = null, $default = null)
    {
        $name = $this->current ?: 'default';

        $options = isset($this->configs[$name]['options']) ? $this->configs[$name]['options'] : [];
        if ($key === null) {
            return $options;
        }

        return isset($options[$key]) ? $options[$key] : $default;
    }
105216
static public function get($key = null, $default = null) {
        if (is_null($key)) return json_decode(json_encode(self::$_config));
        
        $config = &self::$_config;
        
        return Utils::arrayGet($config, $key, $default);
    }
1145460
protected function getFlagConfiguration($key = null)
    {
        if (null !== $key) {
            $result = (isset($this->flagConfiguration[$key])) ? $this->flagConfiguration[$key] : null;

        } else {
            $result = $this->flagConfiguration;
        }

        return $result;
    }
1131799
private function getDefaultValue($key, $default = null)
    {
        $value = null === $default && \array_key_exists($key, $this->defaults)
            ? $this->defaults[$key]
            : $default;

        return $this->getByManager($key, $value, $default);
    }
410866
public function getConfigOption($key, $default = null)
    {
        if (array_key_exists($key, $this->configuration)) {
            return $this->configuration[$key];
        }

        return $default;
    }
1035496
public function get($key = null, $default = null)
    {
        if (!empty($key)) {
            return ArrayFunc::get($this->config, $key, $default);
        }

        return $this->config;
    }
1277815
public function value($default = null)
    {
        $arguments = $this->command->arguments;

        if (is_array($arguments)) {
            return isset($arguments[$this->key]) ? $arguments[$this->key] : $default;
        }

        return $default;
    }