Get the array config value.

@param string $key     The config key
@param array  $default The default value

@return array
480570
public function getArray($key, array $default = array())
    {
        $value = $this->get($key, null);

        return null !== $value ? (array) $value : (array) $default;
    }
1109011
public static function getValueOfArray(array $array, $key, $default = null)
    {
        if (null === $key) {
            return $array;
        }

        if (\array_key_exists($key, $array)) {
            return $array[$key];
        }

        if (!\strpos($key, '.')) {
            return $default;
        }

        foreach (\explode('.', $key) as $segment) {
            if (\is_array($array) && \array_key_exists($segment, $array)) {
                $array = $array[$segment];
            } else {
                return $default;
            }
        }

        return $array;
    }
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);
    }
272821
public function getCfgValue($key, $default = null)
    {
        $value = $default;

        $cfg = $this->config->getCfg();

        if ($cfg) {
            $value = $cfg->get($key, $default);
        }

        return $value;
    }
381578
public function getArray(string $key, array $default = []): array
    {
        if (\array_key_exists($key, $this->data)) {
            if (\is_array($this->data[$key])) {
                return \array_values($this->data[$key]);
            }
            
            return (array) $this->data[$key];
        }
        
        return (array) $default;
    }
1095994
public static function get($arr, $key, $default=null) {
        if ( !is_array($arr) ) return $default;
        if ( !isset($key) ) return $default;
        if ( !isset($arr[$key]) ) return $default;
        return $arr[$key];
    }
812725
public function config(string $key = null, $default = null)
    {
        $key = $key ? sprintf('%s.%s', $this->getId(), $key) : $this->getId();

        return config($key, $default);
    }
136425
public function get($key, $default = null)
    {
        $config = $this->config;

        array_map(function ($key) use (&$config, $default) {
            $config = $config[$key] ?? $default;
        }, explode('.', $key));

        return $config;
    }
116100
public static function get(array $array, string $key = null, $default = null)
    {
        if ($key === null) {
            return $array;
        }

        if ($array === []) {
            return $default;
        }

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

        foreach (\explode('.', $key) as $segment) {
            if (\is_array($array) && isset($array[$segment])) {
                $array = $array[$segment];
            } else {
                return $default;
            }
        }

        return $array;
    }
226830
public static function get($key, $default = null) {
        $value = Hash::get(static::$_config, $key);

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

        return $value;
    }
724222
public function value($key, $default = null)
    {
        return array_key_exists($key, $this->values)
            ? $this->values[$key]
            : $default;
    }
621335
static function getArray($arr,$key,$default=array())
    {
        $value = Utility::get($arr, $key);
        return ($value!=null)?explode(',', $value):$default;
    }
1297806
public static function get(array $array, $key, $default = null)
    {
        if (array_key_exists($key, $array)) {
            return $array[$key];
        }

        if (strpos($key, '.') === false) {
            return $default;
        }

        foreach (explode('.', $key) as $segment) {
            if (is_array($array) && array_key_exists($segment, $array)) {
                $array = $array[$segment];
            } else {
                return $default;
            }
        }

        return $array;
    }
1095571
public static function getConfiguredStyles($key, $default = null)
    {
        $instance = static::instance();

        $value = $instance->get($key);

        $defaultValue = $instance->getDefaultValue($key);

        if (is_array($value)) {
            $value = array_build($value, function ($key, $value) {
                return [array_get($value, 'class_name'), array_get($value, 'class_label')];
            });
        }

        return $value != $defaultValue ? $value : $default;
    }
1002396
function get($key, $default = null)
    {
        $index = array_search($key, $this->keys);

        if ($index !== false) {
            return $this->values[$index];
        } else {
            return $default;
        }
    }
232206
public function getAsArray($key, array $default = array())
    {
        $value = parent::get($key, $default);
        if (is_array($value) && !$value) $value = $default;
        return (array)$value;
    }
701121
public function get($key, $default = null) {
		$this->loadIfNeeded();

		return isset($this->array[$key]) ? $this->array[$key] : $default;
	}