Most basic representation of a single part of an email.

public __construct(ZBateson\MailMimeParser\Message\PartStreamContainer $streamContainer, ?ZBateson\MailMimeParser\Message\IMimePart $parent = NULL)
public __toString() : string
public attach(SplObserver $observer)
public attachContentStream(Psr\Http\Message\StreamInterface $stream, $streamCharset = 'UTF-8'ZBateson\MailMimeParser\MailMimeParser::DEFAULT_CHARSET)
public detach(SplObserver $observer)
public detachContentStream()
public getBinaryContentResourceHandle()
public getBinaryContentStream()
public abstract ZBateson\MailMimeParser\Message\IMessagePart::getCharset()

Returns the charset of the content, or null if not applicable/defined.

public getContent( $charset = 'UTF-8'ZBateson\MailMimeParser\MailMimeParser::DEFAULT_CHARSET)
public abstract ZBateson\MailMimeParser\Message\IMessagePart::getContentDisposition( $default = NULL)

Returns the content's disposition, or returns the value of $default if
not defined.

public abstract ZBateson\MailMimeParser\Message\IMessagePart::getContentId()

Returns the Content ID of the part, or null if not defined.

public getContentStream( $charset = 'UTF-8'ZBateson\MailMimeParser\MailMimeParser::DEFAULT_CHARSET)
public abstract ZBateson\MailMimeParser\Message\IMessagePart::getContentTransferEncoding( $default = NULL)

Returns the content transfer encoding used to encode the content on this
part, or the value of $default if not defined.

public abstract ZBateson\MailMimeParser\Message\IMessagePart::getContentType( $default = 'text/plain')

Returns the mime type of the content, or $default if one is not set.

public getFilename()
public getParent()
public getResourceHandle()
public getStream()
public hasContent()
public abstract ZBateson\MailMimeParser\Message\IMessagePart::isMime()

Returns true if the current part is a mime part.

public abstract ZBateson\MailMimeParser\Message\IMessagePart::isTextPart()

Returns true if the content of this part is plain text.

public notify()
public save( $filenameResourceOrStream, $filemode = 'w+')
public saveContent( $filenameResourceOrStream)
public setCharsetOverride( $charsetOverride, $onlyIfNoCharset = false)
public setContent( $resource, $charset = 'UTF-8'ZBateson\MailMimeParser\MailMimeParser::DEFAULT_CHARSET)
protected $charsetOverride
protected $ignoreTransferEncoding
  • var phpDocumentor\Reflection\Types\Boolean set to true when a user attaches a stream manually, it's
    assumed to already be decoded or to have relevant transfer encoding
    decorators attached already.
protected $observers
protected $parent
protected $partStreamContainer
© 2023 Bruce Wells
Search Namespaces \ Classes