<?php
namespace App\Utils\BaseParser\TextParser\Types;

/**
 * String, any text, containing any character, spanning 1 line
 * @author Lucian Sirbu
 */
class WholeLine extends \App\Utils\BaseParser\TextParser\BlockRegexpAbstract
{
	protected $extractRegexp = "/^(?P<rawData>.*(\r\n|\r|\n|$))/m";

	protected function _extract_value(\App\Utils\BaseParser\TextParser\ExtractedBlock $ret, $originalRawData)
	{
		$x = parent::_extract_value($ret, $originalRawData);
		$x->extractedData = rtrim($x->extractedData, "\n");
		return $x;
	}
}
