<?php
namespace App\Amadeus\FileParser;

class Line_TTR extends \App\Amadeus\FileParser\LineAbstract
{
	/**
	 * 4.46. TTR Amadeus Tours Server : Transportation Data Line
	 * see page 143(185)
	 *
	 * Used to store the transportation-related data contained in a New Automated Amadeus Tours segment
	 * 	for which the master booking is is in the Amadeus Tours Server (ATS). This data is stored in the ATS.
	 */
	protected $structure = [
		['name'=> 'MSGTAG',  'val' => 'TTR',   'type' => 'AN',   'req' => 'M',  'len' => 3,],                          // 1 : Message Tag (TTR)
		['name'=> 'TTONBR',                    'type' => 'N',    'req' => 'M',  'len' => 3,],                          // 2 : Tattoo Number in the PNR
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 3 : Delimiter (Constant value of ';')
		['name'=> 'SEGNBR',                    'type' => 'N',    'req' => 'M',  'len' => 3,],                          // 4 : Segment Number in the PNR
		['name'=> 'DELIM',   'val' => ' ',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 5 : Delimiter (Constant value of blank)
		['name'=> 'TURPRV',                    'type' => 'AN',   'req' => 'M',  'len_min' => 1,   'len_max' => 3,],    // 6 : Tour provider code
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 7 : Delimiter (Constant value of ';')
		['name'=> 'TURPRD',                    'type' => 'AN',   'req' => 'M',],                                       // 8 : Product's name or code
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 9 : Delimiter (Constant value of ';')
		['name'=> 'ITEMNUM',                   'type' => 'AN',   'req' => 'M',  'len_min' => 1,   'len_max' => 3,],    // 10 : Item number in Tour product. Internal reference.
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 11 : Delimiter (Constant value of ';')
		['name'=> 'SVCID',                     'type' => 'AN',                  'len' => 3,],                          // 12 : Service Type Identifier. FLT : flight, BUS : bus, CAR : car hire, RAL : rail, FER : ferry and OTH : other.
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 13 : Delimiter (Constant value of ';')
		['name'=> 'CIECDE',                    'type' => 'AN',   'req' => 'M',],                                       // 14 : Company operating the service (exp for flights, Carrier Code)
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 15 : Delimiter (Constant value of ';')
		['name'=> 'PRDID',                     'type' => 'AN',   'req' => 'M',],                                       // 16 : Product identification : Flight number, ferry code…
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 17 : Delimiter (Constant value of ';')
		['name'=> 'EQUIP',                     'type' => 'AN',   'req' => 'M',],                                       // 18 : Equipment name or code.
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 19 : Delimiter (Constant value of ';')
		['name'=> 'SVCLASS',                   'type' => 'AN',   'req' => 'M',],                                       // 20 : Service Class
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 21 : Delimiter (Constant value of ';')
		['name'=> 'DEPCTR',                    'type' => 'AN',                  'len' => 2,],                          // 22 : Departure Country Code
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 23 : Delimiter (Constant value of ';')
		['name'=> 'DEPCTY',                    'type' => 'AN',   'req' => 'M',  'len' => 3,],                          // 24 : Departure airport/city
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 25 : Delimiter (Constant value of ';')
		['name'=> 'DEPCTYTRANS',               'type' => 'AN',   'req' => 'M',],                                       // 26 : Departure airport/city translation
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 27 : Delimiter (Constant value of ';')
		['name'=> 'ARRCTR',                    'type' => 'AN',                  'len' => 2,],                          // 28 : Arrival Country Code
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 29 : Delimiter (Constant value of ';')
		['name'=> 'ARRCTY',                    'type' => 'AN',   'req' => 'M',  'len' => 3,],                          // 30 : Arrival airport/city
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 31 : Delimiter (Constant value of ';')
		['name'=> 'ARRCTYTRANS',               'type' => 'AN',   'req' => 'M',],                                       // 32 : Arrival airport/city translation
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 33 : Delimiter (Constant value of ';')
		['name'=> 'DEPDTE',                    'type' => 'D:DDMMM:PNRDTE',      'len' => 5,],                          // 34 : Departure Date (DDMMM)
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 35 : Delimiter (Constant value of ';')
		['name'=> 'DEPTIM',                    'type' => 'AN',                  'len' => 5,],                          // 36 : Departure Time
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 37 : Delimiter (Constant value of ';')
		['name'=> 'DEPDAYWE',                  'type' => 'N',                   'len' => 1,],                          // 38 : Day of the week (0 to 6 from SUN to SAT)
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 39 : Delimiter (Constant value of ';')
		['name'=> 'ARRDTE',                    'type' => 'D:DDMMM:PNRDTE',      'len' => 5,],                          // 40 : Arrival Date (DDMMM)
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 41 : Delimiter (Constant value of ';')
		['name'=> 'ARRTIM',                    'type' => 'AN',                  'len' => 5,],                          // 42 : Arrival Time
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 43 : Delimiter (Constant value of ';')
		['name'=> 'ARRDAYWE',                  'type' => 'N',                   'len' => 1,],                          // 44 : Day of the week (0 to 6 from SUN to SAT)
		['name'=> 'DELIM',   'val' => ';',     'type' => 'AN',   'req' => 'M',  'len' => 1,],                          // 45 : Delimiter (Constant value of ';')
		['name'=> 'DURTME',                    'type' => 'AN',                  'len_min' => 1,   'len_max' => 5,],    // 46 : Duration time. Format nnnXX, nnn = duration, XX = Time unit (DY: day, HR: hour, MH: month, MN: minute, NT: night, WK: week, YR: year)
	];
}
