Interface defining a message part parser.
- author Zaahid Bateson
Methods |
public abstract canParse(ZBateson Called by the ParserManager to determine if the passed PartBuilder is a part handled by this IParser. |
public abstract getParserMessageProxyFactory() : ZBateson Returns the ParserPartProxyFactory responsible for creating IMessage parts for this parser. This is called by ParserManager after 'canParse' if it returns true so a ParserPartProxy can be created out of the PartBuilder. |
public abstract getParserPartProxyFactory() : ZBateson Returns the ParserPartProxyFactory responsible for creating IMessagePart parts for this parser. This is called by ParserManager after 'canParse' if it returns true so a ParserPartProxy can be created out of the PartBuilder. |
public abstract parseContent(ZBateson Performs read operations for content from the stream of the passed ParserPartProxy, and setting content bounds for the part in the passed ParserPartProxy. The implementation should call $proxy->setStreamContentStartPos() and $proxy->setStreamContentAndPartEndPos() so an IMessagePart can return content from the raw message. Reading should stop once the end of the current part's content has been reached or the end of the message has been reached. If the end of the message has been reached $proxy->setEof() should be called in addition to setStreamContentAndPartEndPos(). |
public abstract parseNextChild(ZBateson Performs read operations to read children from the passed $proxy, using its stream, and reading up to (and not including) the beginning of the child's content if another child exists. The implementation should:
The method should then return the ParserPartProxy returned by the ParserManager, or null if there are no more children to read.
|
public abstract setParserManager(ZBateson Sets up the passed ParserManager as the ParserManager for this part, which should be used when a new part is created (after its headers are read and a PartBuilder is created from it.)
|