protected function iniReadExpandLevelsAndReType (array & $iniData) {
		//$this->objectTypes[''] = [0, & $this->data];
		$oldIniScannerMode = $this->_iniScannerMode === 1;
		foreach ($iniData as $rawKey => $rawValue) {
			$current = & $this->data;
			// prepare keys to build levels and configure stdClass/array types
			$rawKeys = [];
			$lastRawKey = $rawKey;
			$lastDotPos = strrpos($rawKey, '.');
			if ($lastDotPos !== FALSE) {
				$rawKeys = explode('.', substr($rawKey, 0, $lastDotPos));
				$lastRawKey = substr($rawKey, $lastDotPos + 1);
			}
			// prepare levels structure and configure stdClass or array type change where necessary
			$levelKey = '';
			$prevLevelKey = '';
			foreach ($rawKeys as $key) {
				$prevLevelKey = $levelKey;
				$levelKey .= ($levelKey ? '.' : '') . $key;
				if (!isset($current[$key])) {
					$current[$key] = [];
					$this->objectTypes[$levelKey] = [1, & $current[$key]]; // object type switch -> object by default
					if (is_numeric($key) && isset($this->objectTypes[$prevLevelKey])) {
						$this->objectTypes[$prevLevelKey][0] = 0; // object type switch -> set array if it was object
					}
				}
				$current = & $current[$key];
			}
			// set up value into levels structure and configure type into array if necessary
			if ($oldIniScannerMode) {
				$typedValue = $this->getTypedValue($rawValue);
			} else {
				$typedValue = $rawValue;
			}
			if (isset($current[$lastRawKey])) {
				$current[$lastRawKey][] = $typedValue;
				$this->objectTypes[$levelKey ? $levelKey : $lastRawKey][0] = 0; // object type switch -> set array
			} else {
				if (!is_array($current)) {
					$current = [$current];
					$this->objectTypes[$levelKey] = [0, & $current]; // object type switch -> set array
				}
				$current[$lastRawKey] = $typedValue;
				if (is_numeric($lastRawKey)) $this->objectTypes[$levelKey][0] = 0; // object type switch -> set array
			}
		}
	}
protected function iniReadExpandLevelsAndReType (array & $iniData) {
		//$this->objectTypes[''] = [0, & $this->data];
		$oldIniScannerMode = $this->_iniScannerMode === 1;
		foreach ($iniData as $rawKey => $rawValue) {
			$current = & $this->data;
			// prepare keys to build levels and configure stdClass/array types
			$rawKeys = [];
			$lastRawKey = $rawKey;
			$lastDotPos = strrpos($rawKey, '.');
			if ($lastDotPos !== FALSE) {
				$rawKeys = explode('.', substr($rawKey, 0, $lastDotPos));
				$lastRawKey = substr($rawKey, $lastDotPos + 1);
			}
			// prepare levels structure and configure stdClass or array type change where necessary
			$levelKey = '';
			$prevLevelKey = '';
			foreach ($rawKeys as $key) {
				$prevLevelKey = $levelKey;
				$levelKey .= ($levelKey ? '.' : '') . $key;
				if (!isset($current[$key])) {
					$current[$key] = [];
					$this->objectTypes[$levelKey] = [1, & $current[$key]]; // object type switch -> object by default
					if (is_numeric($key) && isset($this->objectTypes[$prevLevelKey])) {
						$this->objectTypes[$prevLevelKey][0] = 0; // object type switch -> set array if it was object
					}
				}
				$current = & $current[$key];
			}
			// set up value into levels structure and configure type into array if necessary
			if ($oldIniScannerMode) {
				$typedValue = $this->getTypedValue($rawValue);
			} else {
				$typedValue = $rawValue;
			}
			if (isset($current[$lastRawKey])) {
				$current[$lastRawKey][] = $typedValue;
				$this->objectTypes[$levelKey ? $levelKey : $lastRawKey][0] = 0; // object type switch -> set array
			} else {
				if (!is_array($current)) {
					$current = [$current];
					$this->objectTypes[$levelKey] = [0, & $current]; // object type switch -> set array
				}
				$current[$lastRawKey] = $typedValue;
				if (is_numeric($lastRawKey)) $this->objectTypes[$levelKey][0] = 0; // object type switch -> set array
			}
		}
	}
protected function iniReadExpandLevelsAndReType ( array & $ iniData ) { //$this->objectTypes[''] = [0, & $this->data]; $ oldIniScannerMode = $ this -> _iniScannerMode === 1 ; foreach ( $ iniData as $ rawKey => $ rawValue ) { $ current = & $ this -> data ; // prepare keys to build levels and configure stdClass/array types $ rawKeys = [ ] ; $ lastRawKey = $ rawKey ; $ lastDotPos = strrpos ( $ rawKey , '.' ) ; if ( $ lastDotPos !== FALSE ) { $ rawKeys = explode ( '.' , substr ( $ rawKey , 0 , $ lastDotPos ) ) ; $ lastRawKey = substr ( $ rawKey , $ lastDotPos + 1 ) ; } // prepare levels structure and configure stdClass or array type change where necessary $ levelKey = '' ; $ prevLevelKey = '' ; foreach ( $ rawKeys as $ key ) { $ prevLevelKey = $ levelKey ; $ levelKey .= ( $ levelKey ? '.' : '' ) . $ key ; if ( ! isset ( $ current [ $ key ] ) ) { $ current [ $ key ] = [ ] ; $ this -> objectTypes [ $ levelKey ] = [ 1 , & $ current [ $ key ] ] ; // object type switch -> object by default if ( is_numeric ( $ key ) && isset ( $ this -> objectTypes [ $ prevLevelKey ] ) ) { $ this -> objectTypes [ $ prevLevelKey ] [ 0 ] = 0 ; // object type switch -> set array if it was object } } $ current = & $ current [ $ key ] ; } // set up value into levels structure and configure type into array if necessary if ( $ oldIniScannerMode ) { $ typedValue = $ this -> getTypedValue ( $ rawValue ) ; } else { $ typedValue = $ rawValue ; } if ( isset ( $ current [ $ lastRawKey ] ) ) { $ current [ $ lastRawKey ] [ ] = $ typedValue ; $ this -> objectTypes [ $ levelKey ? $ levelKey : $ lastRawKey ] [ 0 ] = 0 ; // object type switch -> set array } else { if ( ! is_array ( $ current ) ) { $ current = [ $ current ] ; $ this -> objectTypes [ $ levelKey ] = [ 0 , & $ current ] ; // object type switch -> set array } $ current [ $ lastRawKey ] = $ typedValue ; if ( is_numeric ( $ lastRawKey ) ) $ this -> objectTypes [ $ levelKey ] [ 0 ] = 0 ; // object type switch -> set array } } }
Process single level array with dotted keys into tree structure
and complete object type switches about tree records
to complete journal about final `\stdClass`es or `array`s types.
@param array $iniData
@return void
Process single level array with dotted keys into tree structure and complete object type switches about tree records to complete journal about final \ stdClass es or array s types .