Reads a subject header.
The subject header is unique in that it doesn't include comments or quoted parts.
- author Zaahid Bateson
Methods |
public __construct(string $name, string $value, ?Psr\Log\LoggerInterface $logger = NULL, ?ZBateson |
public ZBateson\MailMimeParser\Header\AbstractHeader::__toString() : string |
public ZBateson\MailMimeParser\ErrorBag::addError(string $message, string $psrLogLevel, ?Throwable $exception = NULL) : static |
public static ZBateson\MailMimeParser\Header\AbstractHeader::from(string $nameOrLine, ?string $value = NULL) : ZBateson Parses the passed parameters into an IHeader object. The type of returned IHeader is determined by the name of the header. See {@see \HeaderFactory::newInstance} for more details. The required $nameOrLine parameter may contain either the name of a header to parse, or a full header line, e.g. From: email@example.com. If passing a full header line, the $value parameter must be set to null (the default). Note that more specific types can be called on directly. For instance an
AddressHeader may be created by calling AddressHeader::from() which will
ignore the name of the header, and always return an AddressHeader, or by
calling
|
public ZBateson\MailMimeParser\ErrorBag::getAllErrors(bool $validate = false, string $minPsrLevel = 'error'Psr\Log\LogLevel::ERROR) : array |
public ZBateson\MailMimeParser\Header\AbstractHeader::getAllParts() : array
|
public ZBateson\MailMimeParser\Header\AbstractHeader::getComments() : array
|
public ZBateson\MailMimeParser\Header\AbstractHeader::getErrorLoggingContextName() : string |
public ZBateson\MailMimeParser\ErrorBag::getErrors(bool $validate = false, string $minPsrLevel = 'error'Psr\Log\LogLevel::ERROR) : array |
public ZBateson\MailMimeParser\Header\AbstractHeader::getName() : string |
public ZBateson\MailMimeParser\Header\AbstractHeader::getParts() : array
|
public ZBateson\MailMimeParser\Header\AbstractHeader::getRawValue() : string |
public ZBateson\MailMimeParser\Header\AbstractHeader::getValue() : ?string |
public ZBateson\MailMimeParser\ErrorBag::hasAnyErrors(bool $validate = false, string $minPsrLevel = 'error'Psr\Log\LogLevel::ERROR) : bool |
public ZBateson\MailMimeParser\ErrorBag::hasErrors(bool $validate = false, string $minPsrLevel = 'error'Psr\Log\LogLevel::ERROR) : bool |
Properties |
protected array ZBateson\MailMimeParser\Header\AbstractHeader::$allParts = []
|
protected Psr\Log\LoggerInterface ZBateson\MailMimeParser\ErrorBag::$logger |
protected string ZBateson\MailMimeParser\Header\AbstractHeader::$name
|
protected array ZBateson\MailMimeParser\Header\AbstractHeader::$parts = []
|
protected string ZBateson\MailMimeParser\Header\AbstractHeader::$rawValue
|
Methods |
protected ZBateson\MailMimeParser\Header\AbstractHeader::filterAndAssignToParts() : void Filters $this->allParts into the parts required by $this->parts and assigns it. The AbstractHeader::filterAndAssignToParts method filters out CommentParts. |
protected ZBateson\MailMimeParser\Header\AbstractHeader::getErrorBagChildren() : array |
protected static ZBateson\MailMimeParser\Header\AbstractHeader::getHeaderPartsFrom(string $nameOrLine, ?string $value = NULL) : array Checks if the passed $value parameter is null, and if so tries to parse a header line from $nameOrLine splitting on first occurrence of a ':' character. The returned array always contains two elements. The first being the name (or blank if a ':' char wasn't found and $value is null), and the second being the value.
|
protected ZBateson\MailMimeParser\Header\AbstractHeader::parseHeaderValue(ZBateson Calls the consumer and assigns the parsed parts to member variables. The default implementation assigns the returned value to $this->allParts and filters out comments from it, assigning the filtered array to $this->parts by calling filterAndAssignToParts. |
protected ZBateson\MailMimeParser\Header\AbstractHeader::validate() : void |
Methods |
public static ZBateson\MailMimeParser\Header\AbstractHeader::from(string $nameOrLine, ?string $value = NULL) : ZBateson Parses the passed parameters into an IHeader object. The type of returned IHeader is determined by the name of the header. See {@see \HeaderFactory::newInstance} for more details. The required $nameOrLine parameter may contain either the name of a header to parse, or a full header line, e.g. From: email@example.com. If passing a full header line, the $value parameter must be set to null (the default). Note that more specific types can be called on directly. For instance an
AddressHeader may be created by calling AddressHeader::from() which will
ignore the name of the header, and always return an AddressHeader, or by
calling
|
protected static ZBateson\MailMimeParser\Header\AbstractHeader::getHeaderPartsFrom(string $nameOrLine, ?string $value = NULL) : array Checks if the passed $value parameter is null, and if so tries to parse a header line from $nameOrLine splitting on first occurrence of a ':' character. The returned array always contains two elements. The first being the name (or blank if a ':' char wasn't found and $value is null), and the second being the value.
|