<?php
namespace App\Worldspan\LineParser\Types\Line;

/**
 *
 * @author Lucian Sirbu
 */
class R03 extends \App\Worldspan\LineParser\Types\WorldspanBaseLine
{
	protected $extractRegexp = "/^(?P<rawData>(0|\*)3.+)/sm";

	protected $children = [
        /**
         * This record identifies the presence of an "ARrival UNKnown" or surface segment in the PNR and is included in the pricing record
         */

        ['key'=> 'RecordIdentifier',                  'type'=> 'Set',               'len'=> 1,          'val'=> ['0', '*'], 'req'=> false,],             // Record Identifier
        ['key'=> 'key',                               'type'=> 'Constant',          'len'=> 2,     'val'=> '3\\',                'req'=> true,],              // ARUNK segment code
        ['key'=> 'ItinerarySegmentNumber',            'type'=> 'Integer',           'len'=> [1, 3],                         'req'=> false,],             // Itinerary segment number (see Note 3)
        ['key'=> '#018',                              'type'=> 'Separator',                                                      'req'=> false,],             // Field separator
        ['key'=> 'key',                               'type'=> 'Constant',          'len'=> 5,     'val'=> 'ARUNK',              'req'=> false,],             // Arrival Unknown
	];
}
