Create New Item
Item Type
File
Folder
Item Name
Search file in folder and subfolders...
Are you sure you want to rename?
SAFE MODE
/
application
/
vendor
/
zbateson
/
mail-mime-parser
/
src
/
Header
/
Consumer
/
Received
:
ReceivedDateConsumer.php
Advanced Search
Upload
New Item
Settings
Back
Back Up
Advanced Editor
Save
<?php /** * This file is part of the ZBateson\MailMimeParser project. * * @license http://opensource.org/licenses/bsd-license.php BSD */ namespace ZBateson\MailMimeParser\Header\Consumer\Received; use ZBateson\MailMimeParser\Header\Consumer\DateConsumer; /** * Parses the date portion of a Received header into a DatePart. * * The only difference between DateConsumer and ReceivedDateConsumer is the * addition of a start token, ';', and a token separator (also ';'). * * @author Zaahid Bateson */ class ReceivedDateConsumer extends DateConsumer { /** * Returns true if the token is a ';' * * @param string $token * @return boolean */ protected function isStartToken($token) { return ($token === ';'); } /** * Returns an array containing ';'. * * @return string[] an array of regex pattern matchers */ protected function getTokenSeparators() { return [';']; } }