Copied!

Proxy between a MessagePart and a Parser.

ParserPartProxy objects are responsible for ferrying requests from message parts to a proxy as they're requested, and for maintaining state information for a parser as necessary.

Abstract
Methods
public __construct(ZBateson\MailMimeParser\Parser\PartBuilder $partBuilder, ZBateson\MailMimeParser\Parser\IParserService $parser)
public ZBateson\MailMimeParser\Parser\PartBuilder::__destruct()
public addError(string $message, string $level) : ZBateson\MailMimeParser\Parser\Proxy\ParserPartProxy
public getHeaderContainer() : ZBateson\MailMimeParser\Message\PartHeaderContainer
public getMessageResourceHandle() : ?mixed
 
  • return resource
public getMessageResourceHandlePos() : int
public getParent() : ?ZBateson\MailMimeParser\Parser\Proxy\ParserMimePartProxy
public getPart() : ZBateson\MailMimeParser\Message\IMessagePart
 

Returns the IMessagePart associated with this proxy.

  • return \IMessagePart the part.
public getStream() : Psr\Http\Message\StreamInterface
public getStreamContentLength() : int
public getStreamContentStartPos() : ?int
public getStreamPartLength() : int
public getStreamPartStartPos() : int
public isContentParsed() : bool
public isMime() : bool
public parseAll() : static
 

Parses everything under this part.

For ParserPartProxy, this is just content, but sub-classes may override this to parse all children as well for example.

public parseContent() : static
 

Requests the parser to parse this part's content, and call setStreamContentStartPos/EndPos to setup this part's boundaries within the main message's raw stream.

The method first checks to see if the content has already been parsed, and is safe to call multiple times.

public setPart(ZBateson\MailMimeParser\Message\IMessagePart $part) : static
 

Sets the associated part.

  • param \IMessagePart $part The part
public setStreamContentStartPos(int $streamContentStartPos) : static
public setStreamPartAndContentEndPos(int $streamContentEndPos) : static
public setStreamPartEndPos(int $streamPartEndPos) : static
public setStreamPartStartPos(int $streamPartStartPos) : static
Properties
protected ZBateson\MailMimeParser\Parser\IParserService $parser
 
  • var \IParserService The parser.
protected ZBateson\MailMimeParser\Parser\PartBuilder $partBuilder
 
  • var \PartBuilder The part's PartBuilder.
Properties
private ZBateson\MailMimeParser\Message\IMessagePart $part
 
  • var \IMessagePart The part.
© 2025 Bruce Wells
Search Namespaces \ Classes
Configuration