rawValue = $value; if (!$isLiteral) { $this->value = \preg_replace(['/(\r|\n)+(\s)/', '/(\r|\n)+/'], ['$2', ' '], $value); if (!$preserveSpaces) { $this->value = \preg_replace('/^\s+$/m', ' ', $this->value); } } $this->isSpace = ($this->value === '' || (!$isLiteral && \preg_match('/^\s*$/m', $this->value) === 1)); $this->canIgnoreSpacesBefore = $this->canIgnoreSpacesAfter = $this->isSpace; } /** * Returns the part's representative value after any necessary processing * has been performed. For the raw value, call getRawValue(). */ public function getValue() : string { return $this->convertEncoding($this->value); } /** * Returns the part's raw value. */ public function getRawValue() : string { return $this->rawValue; } }