lithium\g11n\catalog\adapter\Code::_readMessageTemplate()

protected method

Extracts data from files within configured path recursively.

Parameters

  • string $path

    Base path to start extracting from.

Returns

array

Source

	protected function _readMessageTemplate($path) {
		$base = new RecursiveDirectoryIterator($path);
		$iterator = new RecursiveIteratorIterator($base);
		$data = [];

		foreach ($iterator as $item) {
			$file = $item->getPathname();

			switch (pathinfo($file, PATHINFO_EXTENSION)) {
				case 'php':
					$data += $this->_parsePhp($file);
				break;
			}
		}
		return $data;
	}