Get Config data in form of an array or ArrayObject

@param bool $asArrayObject (Optional) Defaults to false

@return array|ArrayObject Config data array or ArrayObject
506937
public function toArray($asArrayObject = false)
    {
        $data = [];
        foreach ($this->data as $k => $v) {
            $data[$k] = $this->isInstanceOf($v, $this) ? $v->toArray() : $v;
        }

        return $asArrayObject ? $this->arr($data) : $data;
    }
860505
public static function config_get_configuration_array($data) {
        $config = array();

        if (isset($data->path)) {
            $config['path'] = $data->path;
        }
        if (isset($data->autocreate)) {
            $config['autocreate'] = $data->autocreate;
        }
        if (isset($data->singledirectory)) {
            $config['singledirectory'] = $data->singledirectory;
        }
        if (isset($data->prescan)) {
            $config['prescan'] = $data->prescan;
        }

        return $config;
    }
1112058
public function asArray(bool $decodeJSON = true) : array
    {
        if(!$decodeJSON) {
            return $this->_data;
        }

        $return = [];
        foreach($this->_data as $key => $value) {
            $decoded = json_decode($value);

            $return[$key] = $decoded;
            if(
                !is_array($decoded)  &&
                !is_object($decoded)
            ) {
                $return[$key] = $value;
            }
        }

        return $return;
    }
224888
public function asArray($depth = INF)
    {
        if (!$depth || $depth <= 0) {
            return $this->data;
        }

        $results = [];

        foreach (parent::asArray() as $key => $data) {
            $results[$key] =
                $data instanceof self ?
                    $data->asArray(\is_bool($depth) ? INF : --$depth) :
                    $data;
        }

        return $results;
    }
113345
public function getArray()
    {
        $config = @include $this->location;
        if (!is_array($config)) {
            throw new \Exception('Config not found');
        }

        $this->config = $config;

        return $config;
    }
59438
public function toArray()
    {
        $array = array();
        $data  = $this->_data;
        foreach ($data as $key => $value) {
            if ($value instanceof AnConfig) {
                $array[$key] = $value->toArray();
            } else {
                $array[$key] = $value;
            }
        }

        return $array;
    }
1098704
public static function configGetAll()
    {
		$data = self::getDbConnection()->fetchAll('SELECT * FROM config WHERE `class` = ?', array( get_called_class() ));
		$res = array();
		foreach ($data as $id => $v)
		{
			$res[$v['key']] = unserialize($v['value']);
		}
		return $res;
    }
117034
protected function _getConf()
    {
        // retrieve and cache config
        $services = $this->services();

        /** @var aSapi $config */
        $config   = $services->get('/sapi');
        $orig = $config   = $config->config();
        /** @var DataEntity $config */
        $config   = $config->get(\Module\Authorization\Module::CONF, array());

        if (!isset($config[self::CONF]) && !is_array($config[self::CONF]))
            return null;


        $config   = $config[self::CONF];
        return $config;
    }
155265
public function getJsonData() : array
    {
        $config = ['enabled' => $this->isEnabled, 'actions' => []];
        foreach ($this->actions as $action) {
            $config['actions'][] = $action->getJsonData();
        }
        return $config;
    }
679996
public function getAdded($asArray = true)
    {
        $return = array();
        if ($asArray && $this->added) {
            foreach ($this->added as $file) {
                $return[] = $file->toArray();
            }
        }

        return $asArray ? $return : $this->added;
    }
667262
protected function getProfileConfig()
    {
        $configCallable = $this->config;
        $config = $configCallable($this->getProfileConfigKey());

        if (!is_array($config)) {
            $config = [$config];
        }

        return array_filter($config);
    }
368308
public static function getByAttribute($attribute, $value, $asArray = false)
    {
        if (isset(self::$uniqueAttributeToId[$attribute][$value])) {
            return static::getById(self::$uniqueAttributeToId[$attribute][$value], $asArray);
        }
        $row = static::find()
            ->where([$attribute => $value])
            ->asArray($asArray)
            ->one();
        static::addRowToMap($row);
        return $row;
    }
606118
public function getDirectory($asArray = false)
    {
        $asArray   = (bool) $asArray;
        $directory = (string) $this->_directory;
        if ($asArray) {
            $directory = explode(',', $directory);
        }

        return $directory;
    }
1113931
public static function config_get_configuration_array($data) {
        return array(
            'server' => $data->server,
            'prefix' => $data->prefix,
            'password' => $data->password,
            'serializer' => $data->serializer
        );
    }
1368650
public function getLanguageValues($asArray = null)
    {
        if (!$this->owner->getIsNewRecord() && $this->_languageValues === null) {
            $this->_languageValues = [];

            /* @var ActiveRecord $language */
            foreach ($this->owner->{$this->languageRelation} as $language) {
                $this->_languageValues[] = $language->getAttribute($this->languageValueAttribute);
            }
        }

        if ($asArray === null) {
            $asArray = $this->languageValuesAsArray;
        }

        if ($asArray) {
            return $this->_languageValues === null ? [] : $this->_languageValues;
        } else {
            return $this->_languageValues === null ? '' : implode(', ', $this->_languageValues);
        }
    }
1366607
public static function getConfig( array $local = array() )
	{
		$name = 'Aimeos\Aimeos\Base\Config';

		if( isset( $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['aimeos']['aimeos_config'] ) ) {
			if( ( $name = $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['aimeos']['aimeos_config'] ) instanceof \Closure ) {
				return $name( self::getAimeos()->getConfigPaths(), $local );
			}
		}

		return $name::get( self::getAimeos()->getConfigPaths(), $local );
	}
1330874
public function parseGetConfigurationResponse( array $aResponseData )
    {
        $aConfigurationData = array();
        $iKey               = 1;
        $iMaxIterations     = 10000;

        while ( !empty( $aResponseData["pm_configuration_${iKey}_key"] ) and ( $iKey <= $iMaxIterations ) ) {
            $aConfigurationData[$aResponseData["pm_configuration_${iKey}_key"]] =
                isset( $aResponseData["pm_configuration_${iKey}_value"] )
                    ? trim( (string) $aResponseData["pm_configuration_${iKey}_value"] )
                    : '';
            $iKey++;
        }

        return $aConfigurationData;
    }