<?php
namespace App\Galileo\NDCLineParser\Types; class Data_PassengerFare extends \App\Galileo\LineParser\Types\GalileoBase { protected $extractRegexp = "/^(?P<rawData>FT-#TAS[0-9]+#P[0-9]+[A-Z]{3}\/[0-9\.]+\/[0-9\.]+\/[0-9\.]+)$/"; protected $useCustomRegexp = true; protected $children = [ [ 'key'=>'FT', 'type'=>'Constant', 'val'=> 'FT-', 'label'=>'DOCI-FREETEXT-#' ], [ 'key'=>'TAS', 'type'=>'Constant', 'val'=> '#TAS', ], [ 'key'=>'fareNumber', 'type'=>'Integer', 'len'=>2, ], [ 'key'=>'separator', 'type'=>'Constant', 'val'=> '#', ], [ 'key'=>'P', 'type'=>'Constant', 'val'=> 'P', ], [ 'key'=>'passengerIdentifier', 'type'=>'Integer', 'len'=>2, ], [ 'key'=>'passengerTypeCode', 'type'=>'StringTrim', 'len'=>3, ], [ 'key'=>'separator', 'type'=>'Constant', 'val'=> '/', ], [ 'key'=>'baseFare', 'type'=>'Price', ], [ 'key'=>'separator', 'type'=>'Constant', 'val'=> '/', ], [ 'key'=>'tax', 'type'=>'Price', ], [ 'key'=>'separator', 'type'=>'Constant', 'val'=> '/', ], [ 'key'=>'total', 'type'=>'Price', ], ]; } 