Passed
Push — master ( f4145f...eee8ec )
by Artem
03:30
created

Client::fareTLAGetFareRules()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
eloc 2
c 0
b 0
f 0
dl 0
loc 5
rs 10
ccs 2
cts 2
cp 1
cc 1
nc 1
nop 2
crap 1
1
<?php
2
/**
3
 * amadeus-ws-client
4
 *
5
 * Copyright 2015 Amadeus Benelux NV
6
 *
7
 * Licensed under the Apache License, Version 2.0 (the "License");
8
 * you may not use this file except in compliance with the License.
9
 * You may obtain a copy of the License at
10
 *
11
 * http://www.apache.org/licenses/LICENSE-2.0
12
 *
13
 * Unless required by applicable law or agreed to in writing, software
14
 * distributed under the License is distributed on an "AS IS" BASIS,
15
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
 * See the License for the specific language governing permissions and
17
 * limitations under the License.
18
 *
19
 * @package Amadeus
20
 * @license https://opensource.org/licenses/Apache-2.0 Apache 2.0
21
 */
22
23
namespace Amadeus;
24
25
use Amadeus\Client\Base;
26
use Amadeus\Client\Exception;
27
use Amadeus\Client\Params;
28
use Amadeus\Client\RequestOptions;
29
use Amadeus\Client\Result;
30
31
/**
32
 * Amadeus Web Service Client.
33
 *
34
 * TODO:
35
 * - support older versions of SoapHeader (1)
36
 *
37
 * @package Amadeus
38
 * @author Dieter Devlieghere <[email protected]>
39
 */
40
class Client extends Base
41
{
42
    /**
43
     * Amadeus SOAP header version 1
44
     */
45
    const HEADER_V1 = "1";
46
    /**
47
     * Amadeus SOAP header version 2
48
     */
49
    const HEADER_V2 = "2";
50
    /**
51
     * Amadeus SOAP header version 4
52
     */
53
    const HEADER_V4 = "4";
54
55
    /**
56
     * Version string
57
     *
58
     * @var string
59
     */
60
    const VERSION = "2.1.0";
61
62
    /**
63
     * An identifier string for the library (to be used in Received From entries)
64
     *
65
     * @var string
66
     */
67
    const RECEIVED_FROM_IDENTIFIER = "amabnl-amadeus-ws-client";
68
69
    /**
70
     * @var string
71
     */
72
    protected $lastMessage;
73
74
    /**
75
     * Set the session as stateful (true) or stateless (false)
76
     *
77
     * @param bool $newStateful
78
     */
79
    public function setStateful($newStateful)
80 5
    {
81
        $this->sessionHandler->setStateful($newStateful);
82 5
    }
83 5
84
    /**
85
     * @return bool
86
     */
87
    public function isStateful()
88 15
    {
89
        return $this->sessionHandler->isStateful();
90 15
    }
91
92
    /**
93
     * Get TransactionFlowLink Consumer Id
94
     *
95
     * @return string|null
96
     */
97
    public function getConsumerId()
98 5
    {
99
        return $this->sessionHandler->getConsumerId();
100 5
    }
101
102
    /**
103
     * Set TransactionFlowLink Consumer Id
104
     *
105
     * @throws UnsupportedOperationException when used on unsupported WSAP versions
106
     * @param string $id
107
     * @return void
108
     */
109
    public function setConsumerId($id)
110 5
    {
111
        $this->sessionHandler->setTransactionFlowLink(true);
112 5
        $this->sessionHandler->setConsumerId($id);
113 5
    }
114 5
115
    /**
116
     * Get the last raw XML message that was sent out
117
     *
118
     * @return string|null
119
     */
120
    public function getLastRequest()
121 5
    {
122
        return $this->sessionHandler->getLastRequest($this->lastMessage);
123 5
    }
124
125
    /**
126
     * Get the last raw XML message that was received
127
     *
128
     * @return string|null
129
     */
130
    public function getLastResponse()
131 5
    {
132
        return $this->sessionHandler->getLastResponse($this->lastMessage);
133 5
    }
134
135
    /**
136
     * Get the request headers for the last SOAP message that was sent out
137
     *
138
     * @return string|null
139
     */
140
    public function getLastRequestHeaders()
141 5
    {
142
        return $this->sessionHandler->getLastRequestHeaders($this->lastMessage);
143 5
    }
144
145
    /**
146
     * Get the response headers for the last SOAP message that was received
147
     *
148
     * @return string|null
149
     */
150
    public function getLastResponseHeaders()
151 5
    {
152
        return $this->sessionHandler->getLastResponseHeaders($this->lastMessage);
153 5
    }
154
155
    /**
156
     * Get session information for authenticated session
157
     *
158
     * - sessionId
159
     * - sequenceNr
160
     * - securityToken
161
     *
162
     * @return array|null
163
     */
164
    public function getSessionData()
165 5
    {
166
        return $this->sessionHandler->getSessionData();
167 5
    }
168
169
    /**
170
     * Restore a previously used session
171
     *
172
     * To be used when implementing your own session pooling system on legacy Soap Header 2 applications.
173
     *
174
     * @param array $sessionData
175
     * @return bool
176
     */
177
    public function setSessionData(array $sessionData)
178 5
    {
179
        return $this->sessionHandler->setSessionData($sessionData);
180 5
    }
181
182
    /**
183
     * Construct Amadeus Web Services client
184
     *
185
     * @param Params $params
186
     */
187
    public function __construct(Params $params)
188 500
    {
189
        $this->loadClientParams(
190 500
            $params,
191 500
            self::RECEIVED_FROM_IDENTIFIER,
192 500
            self::VERSION
193 300
        );
194 200
    }
195 495
196
    /**
197
     * Authenticate.
198
     *
199
     * Authentication Parameters were provided at construction time (authParams)
200
     *
201
     * @return Result
202
     * @throws Exception
203
     */
204
    public function securityAuthenticate()
205 10
    {
206
        $msgName = 'Security_Authenticate';
207 10
208
        return $this->callMessage(
209 10
            $msgName,
210 10
            new RequestOptions\SecurityAuthenticateOptions(
211 10
                $this->authParams
212 10
            ),
213 4
            [],
214 10
            false
215 6
        );
216 4
    }
217
218
    /**
219
     * Terminate a session - only applicable to non-stateless mode.
220
     *
221
     * @return Result
222
     * @throws Exception
223
     */
224
    public function securitySignOut()
225 5
    {
226
        $msgName = 'Security_SignOut';
227 5
228
        return $this->callMessage(
229 5
            $msgName,
230 5
            new RequestOptions\SecuritySignOutOptions(),
231 5
            [],
232 5
            true
233 3
        );
234 2
    }
235
236
    /**
237
     * PNR_Retrieve - Retrieve an Amadeus PNR by record locator
238
     *
239
     * @param RequestOptions\PnrRetrieveOptions $options
240
     * @param array $messageOptions (OPTIONAL)
241
     * @return Result
242
     * @throws Client\InvalidMessageException
243
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
244
     * @throws Exception
245
     */
246
    public function pnrRetrieve(RequestOptions\PnrRetrieveOptions $options, $messageOptions = [])
247 5
    {
248
        $msgName = 'PNR_Retrieve';
249 5
250
        return $this->callMessage($msgName, $options, $messageOptions);
251 5
    }
252
253
    /**
254
     * PNR_Split
255
     *
256
     * @param RequestOptions\PnrSplitOptions $options
257
     * @param array $messageOptions (OPTIONAL)
258
     * @return Result
259
     * @throws Client\InvalidMessageException
260
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
261
     * @throws Exception
262
     */
263
    public function pnrSplit(
264 5
        RequestOptions\PnrSplitOptions $options,
265
        $messageOptions = []
266
    ) {
267
        $msgName = 'PNR_Split';
268 5
269
        return $this->callMessage($msgName, $options, $messageOptions);
270 5
    }
271
272
    /**
273
     * Create a PNR using PNR_AddMultiElements
274
     *
275
     * @param RequestOptions\PnrCreatePnrOptions $options
276
     * @param array $messageOptions (OPTIONAL)
277
     * @return Result
278
     * @throws Client\InvalidMessageException
279
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
280
     * @throws Exception
281
     */
282
    public function pnrCreatePnr(RequestOptions\PnrCreatePnrOptions $options, $messageOptions = [])
283 5
    {
284
        $msgName = 'PNR_AddMultiElements';
285 5
286
        return $this->callMessage($msgName, $options, $messageOptions);
287 5
    }
288
289
    /**
290
     * PNR_AddMultiElements - Create a new PNR or update an existing PNR.
291
     *
292
     * https://webservices.amadeus.com/extranet/viewService.do?id=25&flavourId=1&menuId=functional
293
     *
294
     * @param RequestOptions\PnrAddMultiElementsOptions $options
295
     * @param array $messageOptions (OPTIONAL)
296
     * @return Result
297
     * @throws Client\InvalidMessageException
298
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
299
     * @throws Exception
300
     */
301
    public function pnrAddMultiElements(RequestOptions\PnrAddMultiElementsOptions $options, $messageOptions = [])
302 10
    {
303
        $msgName = 'PNR_AddMultiElements';
304 10
305
        return $this->callMessage($msgName, $options, $messageOptions);
306 10
    }
307
308
    /**
309
     * PNR_RetrieveAndDisplay - Retrieve an Amadeus PNR by record locator including extra info
310
     *
311
     * This extra info is info you cannot see in the regular PNR, like Offers.
312
     *
313
     * https://webservices.amadeus.com/extranet/viewService.do?id=1922&flavourId=1&menuId=functional
314
     *
315
     * @param RequestOptions\PnrRetrieveAndDisplayOptions $options Amadeus Record Locator for PNR
316
     * @param array $messageOptions (OPTIONAL)
317
     * @return Result
318
     * @throws Client\InvalidMessageException
319
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
320
     * @throws Exception
321
     **/
322
    public function pnrRetrieveAndDisplay(RequestOptions\PnrRetrieveAndDisplayOptions $options, $messageOptions = [])
323 5
    {
324
        $msgName = 'PNR_RetrieveAndDisplay';
325 5
326
        return $this->callMessage($msgName, $options, $messageOptions);
327 5
    }
328
329
    /**
330
     * PNR_Cancel
331
     *
332
     * @param RequestOptions\PnrCancelOptions $options
333
     * @param array $messageOptions (OPTIONAL)
334
     * @return Result
335
     * @throws Client\InvalidMessageException
336
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
337
     * @throws Exception
338
     */
339
    public function pnrCancel(RequestOptions\PnrCancelOptions $options, $messageOptions = [])
340 5
    {
341
        $msgName = 'PNR_Cancel';
342 5
343
        return $this->callMessage($msgName, $options, $messageOptions);
344 5
    }
345
346
    /**
347
     * PNR_ChangeElement
348
     *
349
     * @param RequestOptions\PnrChangeElementOptions $options
350
     * @param array $messageOptions (OPTIONAL)
351
     * @return Result
352
     * @throws Client\InvalidMessageException
353
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
354
     * @throws Exception
355
     */
356
    public function pnrChangeElement(RequestOptions\PnrChangeElementOptions $options, $messageOptions = [])
357 5
    {
358
        $msgName = 'PNR_ChangeElement';
359 5
360
        return $this->callMessage($msgName, $options, $messageOptions);
361 5
    }
362
363
    /**
364
     * PNR_DisplayHistory
365
     *
366
     * @param RequestOptions\PnrDisplayHistoryOptions $options
367
     * @param array $messageOptions (OPTIONAL)
368
     * @return Result
369
     * @throws Client\InvalidMessageException
370
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
371
     * @throws Exception
372
     */
373
    public function pnrDisplayHistory(RequestOptions\PnrDisplayHistoryOptions $options, $messageOptions = [])
374 5
    {
375
        $msgName = 'PNR_DisplayHistory';
376 5
377
        return $this->callMessage($msgName, $options, $messageOptions);
378 5
    }
379
380
    /**
381
     * PNR_TransferOwnership
382
     *
383
     * @param RequestOptions\PnrTransferOwnershipOptions $options
384
     * @param array $messageOptions (OPTIONAL)
385
     * @return Result
386
     * @throws Client\InvalidMessageException
387
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
388
     * @throws Exception
389
     */
390
    public function pnrTransferOwnership(RequestOptions\PnrTransferOwnershipOptions $options, $messageOptions = [])
391 5
    {
392
        $msgName = 'PNR_TransferOwnership';
393 5
394
        return $this->callMessage($msgName, $options, $messageOptions);
395 5
    }
396
397
    /**
398
     * PNR_NameChange
399
     *
400
     * @param RequestOptions\PnrNameChangeOptions $options
401
     * @param array $messageOptions (OPTIONAL)
402
     * @return Result
403
     * @throws Client\InvalidMessageException
404
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
405
     * @throws Exception
406
     */
407
    public function pnrNameChange(RequestOptions\PnrNameChangeOptions $options, $messageOptions = [])
408
    {
409
        $msgName = 'PNR_NameChange';
410 5
411
        return $this->callMessage($msgName, $options, $messageOptions);
412 5
    }
413
414 5
    /**
415
     * Queue_List - get a list of all PNR's on a given queue
416
     *
417
     * https://webservices.amadeus.com/extranet/viewService.do?id=52&flavourId=1&menuId=functional
418
     *
419
     * @param RequestOptions\QueueListOptions $options
420
     * @param array $messageOptions (OPTIONAL)
421
     * @return Result
422
     * @throws Client\InvalidMessageException
423
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
424
     * @throws Exception
425
     */
426
    public function queueList(RequestOptions\QueueListOptions $options, $messageOptions = [])
427 5
    {
428
        $msgName = 'Queue_List';
429 5
430
        return $this->callMessage($msgName, $options, $messageOptions);
431 5
    }
432
433
    /**
434
     * Queue_PlacePNR - Place a PNR on a given queue
435
     *
436
     * @param RequestOptions\QueuePlacePnrOptions $options
437
     * @param array $messageOptions (OPTIONAL)
438
     * @return Result
439
     * @throws Client\InvalidMessageException
440
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
441
     * @throws Exception
442
     */
443
    public function queuePlacePnr(RequestOptions\QueuePlacePnrOptions $options, $messageOptions = [])
444 5
    {
445
        $msgName = 'Queue_PlacePNR';
446 5
447
        return $this->callMessage($msgName, $options, $messageOptions);
448 5
    }
449
450
    /**
451
     * PNR_Ignore - Ignore an Amadeus PNR by record locator
452
     *
453
     * @param RequestOptions\PnrIgnoreOptions $options
454
     * @param array $messageOptions (OPTIONAL)
455
     * @return Result
456
     * @throws Client\InvalidMessageException
457
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
458
     * @throws Exception
459
     */
460
    public function pnrIgnore(RequestOptions\PnrIgnoreOptions $options, $messageOptions = [])
461
    {
462 5
        $msgName = 'PNR_Ignore';
463
464 5
        return $this->callMessage($msgName, $options, $messageOptions);
465
    }
466 5
467
468
    /**
469
     * Queue_RemoveItem - remove an item (a PNR) from a given queue
470
     *
471
     * @param RequestOptions\QueueRemoveItemOptions $options
472
     * @param array $messageOptions (OPTIONAL)
473
     * @return Result
474
     * @throws Client\InvalidMessageException
475
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
476
     * @throws Exception
477
     */
478
    public function queueRemoveItem(RequestOptions\QueueRemoveItemOptions $options, $messageOptions = [])
479 5
    {
480
        $msgName = 'Queue_RemoveItem';
481 5
482
        return $this->callMessage($msgName, $options, $messageOptions);
483 5
    }
484
485
    /**
486
     * Queue_MoveItem - move an item (a PNR) from one queue to another.
487
     *
488
     * @param RequestOptions\QueueMoveItemOptions $options
489
     * @param array $messageOptions (OPTIONAL)
490
     * @return Result
491
     * @throws Client\InvalidMessageException
492
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
493
     * @throws Exception
494
     */
495
    public function queueMoveItem(RequestOptions\QueueMoveItemOptions $options, $messageOptions = [])
496 5
    {
497
        $msgName = 'Queue_MoveItem';
498 5
499
        return $this->callMessage($msgName, $options, $messageOptions);
500 5
    }
501
502
    /**
503
     * Offer_CreateOffer
504
     *
505
     * @param RequestOptions\OfferCreateOptions $options
506
     * @param array $messageOptions (OPTIONAL)
507
     * @return Result
508
     * @throws Client\InvalidMessageException
509
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
510
     * @throws Exception
511
     */
512
    public function offerCreate(RequestOptions\OfferCreateOptions $options, $messageOptions = [])
513
    {
514
        $msgName = 'Offer_CreateOffer';
515 5
516
        return $this->callMessage($msgName, $options, $messageOptions);
517 5
    }
518
519 5
    /**
520
     * Offer_VerifyOffer
521
     *
522
     * To be called in the context of an open PNR
523
     *
524
     * @param RequestOptions\OfferVerifyOptions $options
525
     * @param array $messageOptions (OPTIONAL)
526
     * @return Result
527
     * @throws Client\InvalidMessageException
528
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
529
     * @throws Exception
530
     */
531
    public function offerVerify(RequestOptions\OfferVerifyOptions $options, $messageOptions = [])
532 5
    {
533
        $msgName = 'Offer_VerifyOffer';
534 5
535
        return $this->callMessage($msgName, $options, $messageOptions);
536 5
    }
537
538
    /**
539
     * Offer_ConfirmAirOffer
540
     *
541
     * @param RequestOptions\OfferConfirmAirOptions $options
542
     * @param array $messageOptions (OPTIONAL)
543
     * @return Result
544
     * @throws Client\InvalidMessageException
545
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
546
     * @throws Exception
547
     */
548
    public function offerConfirmAir(RequestOptions\OfferConfirmAirOptions $options, $messageOptions = [])
549 5
    {
550
        $msgName = 'Offer_ConfirmAirOffer';
551 5
552
        return $this->callMessage($msgName, $options, $messageOptions);
553 5
    }
554
555
    /**
556
     * Offer_ConfirmHotelOffer
557
     *
558
     * @param RequestOptions\OfferConfirmHotelOptions $options
559
     * @param array $messageOptions (OPTIONAL)
560
     * @return Result
561
     * @throws Client\InvalidMessageException
562
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
563
     * @throws Exception
564
     */
565
    public function offerConfirmHotel(RequestOptions\OfferConfirmHotelOptions $options, $messageOptions = [])
566 5
    {
567
        $msgName = 'Offer_ConfirmHotelOffer';
568 5
569
        return $this->callMessage($msgName, $options, $messageOptions);
570 5
    }
571
572
    /**
573
     * Offer_ConfirmCarOffer
574
     *
575
     * @param RequestOptions\OfferConfirmCarOptions $options
576
     * @param array $messageOptions (OPTIONAL)
577
     * @return Result
578
     * @throws Client\InvalidMessageException
579
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
580
     * @throws Exception
581
     */
582
    public function offerConfirmCar(RequestOptions\OfferConfirmCarOptions $options, $messageOptions = [])
583 5
    {
584
        $msgName = 'Offer_ConfirmCarOffer';
585
586
        return $this->callMessage($msgName, $options, $messageOptions);
587 5
    }
588
589 5
    /**
590
     * Fare_MasterPricerExpertSearch
591
     *
592
     * @param RequestOptions\FareMasterPricerExSearchOptions $options
593
     * @param array $messageOptions (OPTIONAL)
594
     * @return Result
595
     * @throws Client\InvalidMessageException
596
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
597
     * @throws Exception
598
     */
599
    public function fareMasterPricerExpertSearch(
600
        RequestOptions\FareMasterPricerExSearchOptions $options,
601
        $messageOptions = []
602
    ) {
603 5
        $msgName = 'Fare_MasterPricerExpertSearch';
604
605
        return $this->callMessage($msgName, $options, $messageOptions);
606
    }
607 5
608
609 5
    /**
610
     * Fare_MasterPricerTravelBoardSearch
611
     *
612
     * @param RequestOptions\FareMasterPricerTbSearch $options
613
     * @param array $messageOptions (OPTIONAL)
614
     * @return Result
615
     * @throws Client\InvalidMessageException
616
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
617
     * @throws Exception
618
     */
619
    public function fareMasterPricerTravelBoardSearch(
620
        RequestOptions\FareMasterPricerTbSearch $options,
621
        $messageOptions = []
622 5
    ) {
623
        $msgName = 'Fare_MasterPricerTravelBoardSearch';
624
625
        return $this->callMessage($msgName, $options, $messageOptions);
626 5
    }
627
628 5
    /**
629
     * Fare_MasterPricerCalendar
630
     *
631
     * @param RequestOptions\FareMasterPricerCalendarOptions $options
632
     * @param array $messageOptions (OPTIONAL)
633
     * @return Result
634
     * @throws Client\InvalidMessageException
635
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
636
     * @throws Exception
637
     */
638
    public function fareMasterPricerCalendar(
639
        RequestOptions\FareMasterPricerCalendarOptions $options,
640
        $messageOptions = []
641 10
    ) {
642
        $msgName = 'Fare_MasterPricerCalendar';
643
644
        return $this->callMessage($msgName, $options, $messageOptions);
645 10
    }
646
647 10
    /**
648
     * Fare_PricePnrWithBookingClass
649
     *
650
     * @param RequestOptions\FarePricePnrWithBookingClassOptions $options
651
     * @param array $messageOptions (OPTIONAL)
652
     * @return Result
653
     * @throws Client\InvalidMessageException
654
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
655
     * @throws Exception
656
     */
657
    public function farePricePnrWithBookingClass(
658
        RequestOptions\FarePricePnrWithBookingClassOptions $options,
659
        $messageOptions = []
660 10
    ) {
661
        $msgName = 'Fare_PricePNRWithBookingClass';
662
663
        return $this->callMessage($msgName, $options, $messageOptions);
664 10
    }
665
666 10
    /**
667
     * Fare_PricePnrWithLowerFares
668
     *
669
     * @param RequestOptions\FarePricePnrWithLowerFaresOptions $options
670
     * @param array $messageOptions (OPTIONAL)
671
     * @return Result
672
     * @throws Client\InvalidMessageException
673
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
674
     * @throws Exception
675
     */
676
    public function farePricePnrWithLowerFares(
677
        RequestOptions\FarePricePnrWithLowerFaresOptions $options,
678
        $messageOptions = []
679 10
    ) {
680
        $msgName = 'Fare_PricePNRWithLowerFares';
681
682
        return $this->callMessage($msgName, $options, $messageOptions);
683 10
    }
684
685 10
    /**
686
     * Fare_PricePnrWithLowestFare
687
     *
688
     * @param RequestOptions\FarePricePnrWithLowestFareOptions $options
689
     * @param array $messageOptions (OPTIONAL)
690
     * @return Result
691
     * @throws Client\InvalidMessageException
692
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
693
     * @throws Exception
694
     */
695
    public function farePricePnrWithLowestFare(
696
        RequestOptions\FarePricePnrWithLowestFareOptions $options,
697
        $messageOptions = []
698 5
    ) {
699
        $msgName = 'Fare_PricePNRWithLowestFare';
700
701
        return $this->callMessage($msgName, $options, $messageOptions);
702 5
    }
703
704 5
    /**
705
     * Fare_InformativePricingWithoutPNR
706
     *
707
     * @param RequestOptions\FareInformativePricingWithoutPnrOptions $options
708
     * @param array $messageOptions (OPTIONAL)
709
     * @return Result
710
     * @throws Client\InvalidMessageException
711
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
712
     * @throws Exception
713
     */
714
    public function fareInformativePricingWithoutPnr(
715
        RequestOptions\FareInformativePricingWithoutPnrOptions $options,
716
        $messageOptions = []
717 5
    ) {
718
        $msgName = 'Fare_InformativePricingWithoutPNR';
719
720
        return $this->callMessage($msgName, $options, $messageOptions);
721 5
    }
722
723 5
    /**
724
     * Fare_PriceUpsellWithoutPNR
725
     *
726
     * @param RequestOptions\FarePriceUpsellWithoutPnrOptions $options
727
     * @param array $messageOptions (OPTIONAL)
728
     * @return Result
729
     * @throws Client\InvalidMessageException
730
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
731
     * @throws Exception
732
     */
733
    public function farePriceUpsellWithoutPnr(
734
        RequestOptions\FarePriceUpsellWithoutPnrOptions $options,
735
        $messageOptions = []
736 5
    ) {
737
        $msgName = 'Fare_PriceUpsellWithoutPNR';
738 5
739
        return $this->callMessage($msgName, $options, $messageOptions);
740 5
    }
741
742
    /**
743
     * Fare_GetFareFamilyDescription
744
     *
745
     * @param RequestOptions\FareGetFareFamilyDescriptionOptions $options
746
     * @param array $messageOptions (OPTIONAL)
747
     * @return Result
748
     * @throws Client\InvalidMessageException
749
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
750
     * @throws Exception
751
     */
752
    public function fareGetFareFamilyDescription(
753 5
        RequestOptions\FareGetFareFamilyDescriptionOptions $options,
754
        $messageOptions = []
755 5
    ) {
756
        $msgName = 'Fare_GetFareFamilyDescription';
757 5
758
        return $this->callMessage($msgName, $options, $messageOptions);
759
    }
760
761
    /**
762
     * Fare_InformativeBestPricingWithoutPNR
763
     *
764
     * @param RequestOptions\FareInformativeBestPricingWithoutPnrOptions $options
765
     * @param array $messageOptions (OPTIONAL)
766
     * @return Result
767
     * @throws Client\InvalidMessageException
768
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
769
     * @throws Exception
770 5
     */
771
    public function fareInformativeBestPricingWithoutPnr(
772 5
        RequestOptions\FareInformativeBestPricingWithoutPnrOptions $options,
773
        $messageOptions = []
774 5
    ) {
775
        $msgName = 'Fare_InformativeBestPricingWithoutPNR';
776
777
        return $this->callMessage($msgName, $options, $messageOptions);
778
    }
779
780
    /**
781
     * Fare_CheckRules
782
     *
783
     * @param RequestOptions\FareCheckRulesOptions $options
784
     * @param array $messageOptions (OPTIONAL)
785
     * @return Result
786
     * @throws Client\InvalidMessageException
787 5
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
788
     * @throws Exception
789
     */
790
    public function fareCheckRules(RequestOptions\FareCheckRulesOptions $options, $messageOptions = [])
791 5
    {
792
        $msgName = 'Fare_CheckRules';
793 5
794
        return $this->callMessage($msgName, $options, $messageOptions);
795
    }
796
797
    /**
798
     * Fare_GetFareRules
799
     *
800
     * @param RequestOptions\FareGetFareRulesOptions $options
801
     * @param array $messageOptions (OPTIONAL)
802
     * @return Result
803
     * @throws Client\InvalidMessageException
804
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
805
     * @throws Exception
806 5
     */
807
    public function fareGetFareRules(RequestOptions\FareGetFareRulesOptions $options, $messageOptions = [])
808
    {
809
        $msgName = 'Fare_GetFareRules';
810 5
811
        return $this->callMessage($msgName, $options, $messageOptions);
812 5
    }
813
814
    /**
815
     * Fare_TLAGetFareRules
816
     *
817
     * @param RequestOptions\FareTLAGetFareRulesOptions $options
818
     * @param array $messageOptions (OPTIONAL)
819
     * @return Result
820
     * @throws Client\InvalidMessageException
821
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
822
     * @throws Exception
823
     */
824
    public function fareTLAGetFareRules(RequestOptions\FareTLAGetFareRulesOptions $options, $messageOptions = [])
825 5
    {
826
        $msgName = 'Fare_TLAGetFareRules';
827 5
828
        return $this->callMessage($msgName, $options, $messageOptions);
829 5
    }
830
831
    /**
832
     * Fare_ConvertCurrency
833
     *
834
     * @param RequestOptions\FareConvertCurrencyOptions $options
835
     * @param array $messageOptions (OPTIONAL)
836
     * @return Result
837
     * @throws Client\InvalidMessageException
838
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
839
     * @throws Exception
840
     */
841
    public function fareConvertCurrency(RequestOptions\FareConvertCurrencyOptions $options, $messageOptions = [])
842 5
    {
843
        $msgName = 'Fare_ConvertCurrency';
844 5
845
        return $this->callMessage($msgName, $options, $messageOptions);
846 5
    }
847
848
    /**
849
     * Air_MultiAvailability
850
     *
851
     * @param RequestOptions\AirMultiAvailabilityOptions $options
852
     * @param array $messageOptions (OPTIONAL)
853
     * @return Result
854
     * @throws Client\InvalidMessageException
855
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
856
     * @throws Exception
857
     */
858
    public function airMultiAvailability(
859 5
        RequestOptions\AirMultiAvailabilityOptions $options,
860
        $messageOptions = []
861 5
    ) {
862
        $msgName = 'Air_MultiAvailability';
863 5
864
        return $this->callMessage($msgName, $options, $messageOptions);
865
    }
866
867
    /**
868
     * Air_SellFromRecommendation
869
     *
870
     * @param RequestOptions\AirSellFromRecommendationOptions $options
871
     * @param array $messageOptions (OPTIONAL)
872
     * @return Result
873
     * @throws Client\InvalidMessageException
874
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
875
     * @throws Exception
876 5
     */
877
    public function airSellFromRecommendation(
878 5
        RequestOptions\AirSellFromRecommendationOptions $options,
879
        $messageOptions = []
880 5
    ) {
881
        $msgName = 'Air_SellFromRecommendation';
882
883
        return $this->callMessage($msgName, $options, $messageOptions);
884
    }
885
886
    /**
887
     * Air_FlightInfo
888
     *
889
     * @param RequestOptions\AirFlightInfoOptions $options
890
     * @param array $messageOptions (OPTIONAL)
891
     * @return Result
892
     * @throws Client\InvalidMessageException
893 5
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
894
     * @throws Exception
895
     */
896
    public function airFlightInfo(RequestOptions\AirFlightInfoOptions $options, $messageOptions = [])
897 5
    {
898
        $msgName = 'Air_FlightInfo';
899 5
900
        return $this->callMessage($msgName, $options, $messageOptions);
901
    }
902
903
    /**
904
     * Air_RetrieveSeatMap
905
     *
906
     * @param RequestOptions\AirRetrieveSeatMapOptions $options
907
     * @param array $messageOptions (OPTIONAL)
908
     * @return Result
909
     * @throws Client\InvalidMessageException
910
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
911
     * @throws Exception
912 5
     */
913
    public function airRetrieveSeatMap(RequestOptions\AirRetrieveSeatMapOptions $options, $messageOptions = [])
914
    {
915
        $msgName = 'Air_RetrieveSeatMap';
916 5
917
        return $this->callMessage($msgName, $options, $messageOptions);
918 5
    }
919
920
    /**
921
     * Air_RebookAirSegment
922
     *
923
     * @param RequestOptions\AirRebookAirSegmentOptions $options
924
     * @param array $messageOptions (OPTIONAL)
925
     * @return Result
926
     * @throws Client\InvalidMessageException
927
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
928
     * @throws Exception
929
     */
930
    public function airRebookAirSegment(RequestOptions\AirRebookAirSegmentOptions $options, $messageOptions = [])
931 5
    {
932
        $msgName = 'Air_RebookAirSegment';
933
934
        return $this->callMessage($msgName, $options, $messageOptions);
935 5
    }
936
937 5
    /**
938
     * Command_Cryptic
939
     *
940
     * @param RequestOptions\CommandCrypticOptions $options
941
     * @param array $messageOptions (OPTIONAL)
942
     * @return Result
943
     * @throws Client\InvalidMessageException
944
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
945
     * @throws Exception
946
     */
947
    public function commandCryptic(RequestOptions\CommandCrypticOptions $options, $messageOptions = [])
948
    {
949
        $msgName = 'Command_Cryptic';
950 5
951
        return $this->callMessage($msgName, $options, $messageOptions);
952 5
    }
953
954 5
    /**
955
     * MiniRule_GetFromRec
956
     *
957
     * @param RequestOptions\MiniRuleGetFromRecOptions $options
958
     * @param array $messageOptions (OPTIONAL)
959
     * @return Result
960
     * @throws Client\InvalidMessageException
961
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
962
     * @throws Exception
963
     */
964
    public function miniRuleGetFromRec(RequestOptions\MiniRuleGetFromRecOptions $options, $messageOptions = [])
965
    {
966
        $msgName = 'MiniRule_GetFromRec';
967 5
968
        return $this->callMessage($msgName, $options, $messageOptions);
969 5
    }
970
971 5
    /**
972
     * MiniRule_GetFromPricingRec
973
     *
974
     * @param RequestOptions\MiniRuleGetFromPricingRecOptions $options
975
     * @param array $messageOptions (OPTIONAL)
976
     * @return Result
977
     * @throws Client\InvalidMessageException
978
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
979
     * @throws Exception
980
     */
981
    public function miniRuleGetFromPricingRec(
982
        RequestOptions\MiniRuleGetFromPricingRecOptions $options,
983
        $messageOptions = []
984
    ) {
985 5
        $msgName = 'MiniRule_GetFromPricingRec';
986
987
        return $this->callMessage($msgName, $options, $messageOptions);
988
    }
989 5
990
    /**
991 5
     * MiniRule_GetFromPricing
992
     *
993
     * @param RequestOptions\MiniRuleGetFromPricingOptions $options
994
     * @param array $messageOptions (OPTIONAL)
995
     * @return Result
996
     * @throws Client\InvalidMessageException
997
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
998
     * @throws Exception
999
     */
1000
    public function miniRuleGetFromPricing(
1001
        RequestOptions\MiniRuleGetFromPricingOptions $options,
1002
        $messageOptions = []
1003
    ) {
1004 5
        $msgName = 'MiniRule_GetFromPricing';
1005
1006
        return $this->callMessage($msgName, $options, $messageOptions);
1007
    }
1008 5
1009
    /**
1010 5
     * MiniRule_GetFromETicket
1011
     *
1012
     * @param RequestOptions\MiniRuleGetFromETicketOptions $options
1013
     * @param array $messageOptions (OPTIONAL)
1014
     * @return Result
1015
     * @throws Client\InvalidMessageException
1016
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1017
     * @throws Exception
1018
     */
1019
    public function miniRuleGetFromETicket(
1020
        RequestOptions\MiniRuleGetFromETicketOptions $options,
1021
        $messageOptions = []
1022
    ) {
1023 5
        $msgName = 'MiniRule_GetFromETicket';
1024
1025
        return $this->callMessage($msgName, $options, $messageOptions);
1026
    }
1027 5
1028
    /**
1029 5
     * Info_EncodeDecodeCity
1030
     *
1031
     * @param RequestOptions\InfoEncodeDecodeCityOptions $options
1032
     * @param array $messageOptions (OPTIONAL)
1033
     * @return Result
1034
     * @throws Client\InvalidMessageException
1035
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1036
     * @throws Exception
1037
     */
1038
    public function infoEncodeDecodeCity(RequestOptions\InfoEncodeDecodeCityOptions $options, $messageOptions = [])
1039
    {
1040
        $msgName = 'Info_EncodeDecodeCity';
1041
1042 5
        return $this->callMessage($msgName, $options, $messageOptions);
1043
    }
1044
1045
    /**
1046 5
     * PointOfRef_Search
1047
     *
1048 5
     * @param RequestOptions\PointOfRefSearchOptions $options
1049
     * @param array $messageOptions (OPTIONAL)
1050
     * @return Result
1051
     * @throws Client\InvalidMessageException
1052
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1053
     * @throws Exception
1054
     */
1055
    public function pointOfRefSearch(RequestOptions\PointOfRefSearchOptions $options, $messageOptions = [])
1056
    {
1057
        $msgName = 'PointOfRef_Search';
1058
1059
        return $this->callMessage($msgName, $options, $messageOptions);
1060
    }
1061 5
1062
1063 5
    /**
1064
     * Ticket_CreateTSTFromPricing
1065 5
     *
1066
     * @param RequestOptions\TicketCreateTstFromPricingOptions $options
1067
     * @param array $messageOptions (OPTIONAL)
1068
     * @return Result
1069
     * @throws Client\InvalidMessageException
1070
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1071
     * @throws Exception
1072
     */
1073
    public function ticketCreateTSTFromPricing(
1074
        RequestOptions\TicketCreateTstFromPricingOptions $options,
1075
        $messageOptions = []
1076
    ) {
1077
        $msgName = 'Ticket_CreateTSTFromPricing';
1078 5
1079
        return $this->callMessage($msgName, $options, $messageOptions);
1080 5
    }
1081
1082 5
    /**
1083
     * Ticket_CreateTSMFromPricing
1084
     *
1085
     * @param RequestOptions\TicketCreateTsmFromPricingOptions $options
1086
     * @param array $messageOptions (OPTIONAL)
1087
     * @return Result
1088
     * @throws Client\InvalidMessageException
1089
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1090
     * @throws Exception
1091
     */
1092
    public function ticketCreateTSMFromPricing(
1093
        RequestOptions\TicketCreateTsmFromPricingOptions $options,
1094
        $messageOptions = []
1095 5
    ) {
1096
        $msgName = 'Ticket_CreateTSMFromPricing';
1097 5
1098
        return $this->callMessage($msgName, $options, $messageOptions);
1099 5
    }
1100
1101
    /**
1102
     * Ticket_CreateTSMFareElement
1103
     *
1104
     * @param RequestOptions\TicketCreateTsmFareElOptions $options
1105
     * @param array $messageOptions (OPTIONAL)
1106
     * @return Result
1107
     * @throws Client\InvalidMessageException
1108
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1109
     * @throws Exception
1110
     */
1111
    public function ticketCreateTSMFareElement(
1112 5
        RequestOptions\TicketCreateTsmFareElOptions $options,
1113
        $messageOptions = []
1114 5
    ) {
1115
        $msgName = 'Ticket_CreateTSMFareElement';
1116 5
1117
        return $this->callMessage($msgName, $options, $messageOptions);
1118
    }
1119
1120
    /**
1121
     * Ticket_CreateTASF
1122
     *
1123
     * @param RequestOptions\TicketCreateTasfOptions $options
1124
     * @param array $messageOptions (OPTIONAL)
1125
     * @return Result
1126
     * @throws Client\InvalidMessageException
1127
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1128
     * @throws Exception
1129 5
     */
1130
    public function ticketCreateTASF(
1131
        RequestOptions\TicketCreateTasfOptions $options,
1132
        $messageOptions = []
1133 5
    ) {
1134
        $msgName = 'Ticket_CreateTASF';
1135 5
1136
        return $this->callMessage($msgName, $options, $messageOptions);
1137
    }
1138
1139
    /**
1140
     * Ticket_DeleteTST
1141
     *
1142
     * @param RequestOptions\TicketDeleteTstOptions $options
1143
     * @param array $messageOptions (OPTIONAL)
1144
     * @return Result
1145
     * @throws Client\InvalidMessageException
1146
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1147
     * @throws Exception
1148 5
     */
1149
    public function ticketDeleteTST(RequestOptions\TicketDeleteTstOptions $options, $messageOptions = [])
1150
    {
1151
        $msgName = 'Ticket_DeleteTST';
1152 5
1153
        return $this->callMessage($msgName, $options, $messageOptions);
1154 5
    }
1155
1156
    /**
1157
     * Ticket_DeleteTSMP
1158
     *
1159
     * @param RequestOptions\TicketDeleteTsmpOptions $options
1160
     * @param array $messageOptions (OPTIONAL)
1161
     * @return Result
1162
     * @throws Client\InvalidMessageException
1163
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1164
     * @throws Exception
1165
     */
1166
    public function ticketDeleteTSMP(RequestOptions\TicketDeleteTsmpOptions $options, $messageOptions = [])
1167 5
    {
1168
        $msgName = 'Ticket_DeleteTSMP';
1169
1170
        return $this->callMessage($msgName, $options, $messageOptions);
1171 5
    }
1172
1173 5
    /**
1174
     * Ticket_DisplayTST
1175
     *
1176
     * @param RequestOptions\TicketDisplayTstOptions $options
1177
     * @param array $messageOptions (OPTIONAL)
1178
     * @return Result
1179
     * @throws Client\InvalidMessageException
1180
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1181
     * @throws Exception
1182
     */
1183
    public function ticketDisplayTST(RequestOptions\TicketDisplayTstOptions $options, $messageOptions = [])
1184
    {
1185
        $msgName = 'Ticket_DisplayTST';
1186 5
1187
        return $this->callMessage($msgName, $options, $messageOptions);
1188
    }
1189
1190 5
    /**
1191
     * Ticket_DisplayTSMP
1192 5
     *
1193
     * @param RequestOptions\TicketDisplayTsmpOptions $options
1194
     * @param array $messageOptions (OPTIONAL)
1195
     * @return Result
1196
     * @throws Client\InvalidMessageException
1197
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1198
     * @throws Exception
1199
     */
1200
    public function ticketDisplayTSMP(RequestOptions\TicketDisplayTsmpOptions $options, $messageOptions = [])
1201
    {
1202
        $msgName = 'Ticket_DisplayTSMP';
1203
1204
        return $this->callMessage($msgName, $options, $messageOptions);
1205 5
    }
1206
1207
    /**
1208
     * Ticket_RetrieveListOfTSM
1209 5
     *
1210
     * @param RequestOptions\TicketRetrieveListOfTSMOptions $options
1211 5
     * @param array $messageOptions (OPTIONAL)
1212
     * @return Result
1213
     * @throws Client\InvalidMessageException
1214
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1215
     * @throws Exception
1216
     */
1217
    public function ticketRetrieveListOfTSM(
1218
        RequestOptions\TicketRetrieveListOfTSMOptions $options,
1219
        $messageOptions = []
1220
    ) {
1221
        $msgName = 'Ticket_RetrieveListOfTSM';
1222
1223
        return $this->callMessage($msgName, $options, $messageOptions);
1224 5
    }
1225
1226
    /**
1227
     * Ticket_DisplayTSMFareElement
1228 5
     *
1229
     * @param RequestOptions\TicketDisplayTsmFareElOptions $options
1230 5
     * @param array $messageOptions (OPTIONAL)
1231
     * @return Result
1232
     * @throws Client\InvalidMessageException
1233
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1234
     * @throws Exception
1235
     */
1236
    public function ticketDisplayTSMFareElement(
1237
        RequestOptions\TicketDisplayTsmFareElOptions $options,
1238
        $messageOptions = []
1239
    ) {
1240
        $msgName = 'Ticket_DisplayTSMFareElement';
1241
1242
        return $this->callMessage($msgName, $options, $messageOptions);
1243 5
    }
1244
1245
    /**
1246
     * Ticket_CheckEligibility
1247 5
     *
1248
     * @param RequestOptions\TicketCheckEligibilityOptions $options
1249 5
     * @param array $messageOptions (OPTIONAL)
1250
     * @return Result
1251
     * @throws Client\InvalidMessageException
1252
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1253
     * @throws Exception
1254
     */
1255
    public function ticketCheckEligibility(
1256
        RequestOptions\TicketCheckEligibilityOptions $options,
1257
        $messageOptions = []
1258
    ) {
1259
        $msgName = 'Ticket_CheckEligibility';
1260
1261
        return $this->callMessage($msgName, $options, $messageOptions);
1262 5
    }
1263
1264 5
    /**
1265
     * Ticket_ATCShopperMasterPricerTravelBoardSearch
1266 5
     *
1267
     * @param RequestOptions\TicketAtcShopperMpTbSearchOptions $options
1268
     * @param array $messageOptions (OPTIONAL)
1269
     * @return Result
1270
     * @throws Client\InvalidMessageException
1271
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1272
     * @throws Exception
1273
     */
1274
    public function ticketAtcShopperMasterPricerTravelBoardSearch(
1275
        RequestOptions\TicketAtcShopperMpTbSearchOptions $options,
1276
        $messageOptions = []
1277
    ) {
1278
        $msgName = 'Ticket_ATCShopperMasterPricerTravelBoardSearch';
1279 5
1280
        return $this->callMessage($msgName, $options, $messageOptions);
1281 5
    }
1282
1283 5
    /**
1284
     * Ticket_ATCShopperMasterPricerCalendar
1285
     *
1286
     * @param RequestOptions\TicketAtcShopperMpCalendarOptions $options
1287
     * @param array $messageOptions (OPTIONAL)
1288
     * @return Result
1289
     * @throws Client\InvalidMessageException
1290
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1291
     * @throws Exception
1292
     */
1293
    public function ticketAtcShopperMasterPricerCalendar(
1294
        RequestOptions\TicketAtcShopperMpCalendarOptions $options,
1295
        $messageOptions = []
1296 5
    ) {
1297
        $msgName = 'Ticket_ATCShopperMasterPricerCalendar';
1298
1299
        return $this->callMessage($msgName, $options, $messageOptions);
1300 5
    }
1301
1302 5
    /**
1303
     * Ticket_RepricePNRWithBookingClass
1304
     *
1305
     * @param RequestOptions\TicketRepricePnrWithBookingClassOptions $options
1306
     * @param array $messageOptions (OPTIONAL)
1307
     * @return Result
1308
     * @throws Client\InvalidMessageException
1309
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1310
     * @throws Exception
1311
     */
1312
    public function ticketRepricePnrWithBookingClass(
1313
        RequestOptions\TicketRepricePnrWithBookingClassOptions $options,
1314
        $messageOptions = []
1315 5
    ) {
1316
        $msgName = 'Ticket_RepricePNRWithBookingClass';
1317
1318
        return $this->callMessage($msgName, $options, $messageOptions);
1319 5
    }
1320
1321 5
    /**
1322
     * Ticket_CancelDocument
1323
     *
1324
     * @param RequestOptions\TicketCancelDocumentOptions $options
1325
     * @param array $messageOptions (OPTIONAL)
1326
     * @return Result
1327
     * @throws Client\InvalidMessageException
1328
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1329
     * @throws Exception
1330
     */
1331
    public function ticketCancelDocument(
1332
        RequestOptions\TicketCancelDocumentOptions $options,
1333
        $messageOptions = []
1334 10
    ) {
1335
        $msgName = 'Ticket_CancelDocument';
1336
1337
        return $this->callMessage($msgName, $options, $messageOptions);
1338 10
    }
1339
1340 10
    /**
1341
     * Ticket_ReissueConfirmedPricing
1342
     *
1343
     * @param RequestOptions\TicketReissueConfirmedPricingOptions $options
1344
     * @param array $messageOptions (OPTIONAL)
1345
     * @return Result
1346
     * @throws Client\InvalidMessageException
1347
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1348
     * @throws Exception
1349
     */
1350
    public function ticketReissueConfirmedPricing(
1351
        RequestOptions\TicketReissueConfirmedPricingOptions $options,
1352
        $messageOptions = []
1353 5
    ) {
1354
        $msgName = 'Ticket_ReissueConfirmedPricing';
1355
1356
        return $this->callMessage($msgName, $options, $messageOptions);
1357 5
    }
1358
1359 5
    /**
1360
     * Ticket_ProcessEDoc
1361
     *
1362
     * @param RequestOptions\TicketProcessEDocOptions $options
1363
     * @param array $messageOptions (OPTIONAL)
1364
     * @return Result
1365
     * @throws Client\InvalidMessageException
1366
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1367
     * @throws Exception
1368
     */
1369
    public function ticketProcessEDoc(RequestOptions\TicketProcessEDocOptions $options, $messageOptions = [])
1370
    {
1371
        $msgName = 'Ticket_ProcessEDoc';
1372 5
1373
        return $this->callMessage($msgName, $options, $messageOptions);
1374
    }
1375
1376 5
    /**
1377
     * Ticket_ProcessETicket
1378 5
     *
1379
     * @param RequestOptions\TicketProcessETicketOptions $options
1380
     * @param array $messageOptions (OPTIONAL)
1381
     * @return Result
1382
     * @throws Client\InvalidMessageException
1383
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1384
     * @throws Exception
1385
     */
1386
    public function ticketProcessETicket(RequestOptions\TicketProcessETicketOptions $options, $messageOptions = [])
1387
    {
1388
        $msgName = 'Ticket_ProcessETicket';
1389
1390
        return $this->callMessage($msgName, $options, $messageOptions);
1391 5
    }
1392
1393
    /**
1394
     * DocIssuance_IssueTicket
1395 5
     *
1396
     * @param RequestOptions\DocIssuanceIssueTicketOptions $options
1397 5
     * @param array $messageOptions (OPTIONAL)
1398
     * @return Result
1399
     * @throws Client\InvalidMessageException
1400
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1401
     * @throws Exception
1402
     */
1403
    public function docIssuanceIssueTicket(
1404
        RequestOptions\DocIssuanceIssueTicketOptions $options,
1405
        $messageOptions = []
1406
    ) {
1407
        $msgName = 'DocIssuance_IssueTicket';
1408
1409
        return $this->callMessage($msgName, $options, $messageOptions);
1410 5
    }
1411
1412
    /**
1413
     * DocIssuance_IssueMiscellaneousDocuments
1414 5
     *
1415
     * @param RequestOptions\DocIssuanceIssueMiscDocOptions $options
1416 5
     * @param array $messageOptions (OPTIONAL)
1417
     * @return Result
1418
     * @throws Client\InvalidMessageException
1419
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1420
     * @throws Exception
1421
     */
1422
    public function docIssuanceIssueMiscellaneousDocuments(
1423
        RequestOptions\DocIssuanceIssueMiscDocOptions $options,
1424
        $messageOptions = []
1425
    ) {
1426
        $msgName = 'DocIssuance_IssueMiscellaneousDocuments';
1427
1428
        return $this->callMessage($msgName, $options, $messageOptions);
1429 5
    }
1430
1431
    /**
1432
     * DocIssuance_IssueCombined
1433 5
     *
1434
     * @param RequestOptions\DocIssuanceIssueCombinedOptions $options
1435 5
     * @param array $messageOptions (OPTIONAL)
1436
     * @return Result
1437
     * @throws Client\InvalidMessageException
1438
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1439
     * @throws Exception
1440
     */
1441
    public function docIssuanceIssueCombined(
1442
        RequestOptions\DocIssuanceIssueCombinedOptions $options,
1443
        $messageOptions = []
1444
    ) {
1445
        $msgName = 'DocIssuance_IssueCombined';
1446
1447
        return $this->callMessage($msgName, $options, $messageOptions);
1448 5
    }
1449
1450
    /**
1451
     * DocRefund_InitRefund
1452 5
     *
1453
     * @param RequestOptions\DocRefundInitRefundOptions $options
1454 5
     * @param array $messageOptions (OPTIONAL)
1455
     * @return Result
1456
     * @throws Client\InvalidMessageException
1457
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1458
     * @throws Exception
1459
     */
1460
    public function docRefundInitRefund(
1461
        RequestOptions\DocRefundInitRefundOptions $options,
1462
        $messageOptions = []
1463
    ) {
1464
        $msgName = 'DocRefund_InitRefund';
1465
1466
        return $this->callMessage($msgName, $options, $messageOptions);
1467 5
    }
1468
1469
    /**
1470
     * DocRefund_IgnoreRefund
1471 5
     *
1472
     * @param RequestOptions\DocRefundIgnoreRefundOptions $options
1473 5
     * @param array $messageOptions (OPTIONAL)
1474
     * @return Result
1475
     * @throws Client\InvalidMessageException
1476
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1477
     * @throws Exception
1478
     */
1479
    public function docRefundIgnoreRefund(
1480
        RequestOptions\DocRefundIgnoreRefundOptions $options,
1481
        $messageOptions = []
1482
    ) {
1483
        $msgName = 'DocRefund_IgnoreRefund';
1484
1485
        return $this->callMessage($msgName, $options, $messageOptions);
1486 5
    }
1487
1488 5
    /**
1489
     * DocRefund_UpdateRefund
1490 5
     *
1491
     * @param RequestOptions\DocRefundUpdateRefundOptions $options
1492
     * @param array $messageOptions (OPTIONAL)
1493
     * @return Result
1494
     * @throws Client\InvalidMessageException
1495
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1496
     * @throws Exception
1497
     */
1498
    public function docRefundUpdateRefund(
1499
        RequestOptions\DocRefundUpdateRefundOptions $options,
1500
        $messageOptions = []
1501
    ) {
1502
        $msgName = 'DocRefund_UpdateRefund';
1503
1504 5
        return $this->callMessage($msgName, $options, $messageOptions);
1505
    }
1506 5
1507
    /**
1508 5
     * DocRefund_ProcessRefund
1509
     *
1510
     * @param RequestOptions\DocRefundProcessRefundOptions $options
1511
     * @param array $messageOptions (OPTIONAL)
1512
     * @return Result
1513
     * @throws Client\InvalidMessageException
1514
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1515
     * @throws Exception
1516
     */
1517
    public function docRefundProcessRefund(
1518
        RequestOptions\DocRefundProcessRefundOptions $options,
1519
        $messageOptions = []
1520
    ) {
1521 5
        $msgName = 'DocRefund_ProcessRefund';
1522
1523
        return $this->callMessage($msgName, $options, $messageOptions);
1524
    }
1525 5
1526
    /**
1527 5
     * Ticket_InitRefund
1528
     *
1529
     * @param RequestOptions\TicketInitRefundOptions $options
1530
     * @param array $messageOptions (OPTIONAL)
1531
     * @return Result
1532
     * @throws Client\InvalidMessageException
1533
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1534
     * @throws Exception
1535
     */
1536
    public function ticketInitRefund(
1537
        RequestOptions\TicketInitRefundOptions $options,
1538
        $messageOptions = []
1539
    ) {
1540 5
        $msgName = 'Ticket_InitRefund';
1541
1542
        return $this->callMessage($msgName, $options, $messageOptions);
1543
    }
1544 5
1545
    /**
1546 5
     * Ticket_IgnoreRefund
1547
     *
1548
     * @param RequestOptions\TicketIgnoreRefundOptions $options
1549
     * @param array $messageOptions (OPTIONAL)
1550
     * @return Result
1551
     * @throws Client\InvalidMessageException
1552
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1553
     * @throws Exception
1554
     */
1555
    public function ticketIgnoreRefund(
1556
        RequestOptions\TicketIgnoreRefundOptions $options,
1557
        $messageOptions = []
1558
    ) {
1559 5
        $msgName = 'Ticket_IgnoreRefund';
1560
1561
        return $this->callMessage($msgName, $options, $messageOptions);
1562
    }
1563 5
1564
    /**
1565 5
     * Ticket_ProcessRefund
1566
     *
1567
     * @param RequestOptions\TicketProcessRefundOptions $options
1568
     * @param array $messageOptions (OPTIONAL)
1569
     * @return Result
1570
     * @throws Client\InvalidMessageException
1571
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1572
     * @throws Exception
1573
     */
1574
    public function ticketProcessRefund(
1575
        RequestOptions\TicketProcessRefundOptions $options,
1576
        $messageOptions = []
1577
    ) {
1578 5
        $msgName = 'Ticket_ProcessRefund';
1579
1580
        return $this->callMessage($msgName, $options, $messageOptions);
1581
    }
1582 5
1583
    /**
1584 5
     * Ticket_UpdateRefund
1585
     *
1586
     * @param RequestOptions\TicketUpdateRefundOptions $options
1587
     * @param array $messageOptions (OPTIONAL)
1588
     * @return Result
1589
     * @throws Client\InvalidMessageException
1590
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1591
     * @throws Exception
1592
     */
1593
    public function ticketUpdateRefund(
1594
        RequestOptions\TicketUpdateRefundOptions $options,
1595
        $messageOptions = []
1596
    ) {
1597 5
        $msgName = 'Ticket_UpdateRefund';
1598
1599
        return $this->callMessage($msgName, $options, $messageOptions);
1600
    }
1601 5
1602
    /**
1603 5
     * FOP_CreateFormOfPayment
1604
     *
1605
     * @param RequestOptions\FopCreateFopOptions $options
1606
     * @param array $messageOptions (OPTIONAL)
1607
     * @return Result
1608
     * @throws Client\InvalidMessageException
1609
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1610
     * @throws Exception
1611
     */
1612
    public function fopCreateFormOfPayment(RequestOptions\FopCreateFopOptions $options, $messageOptions = [])
1613
    {
1614
        $msgName = 'FOP_CreateFormOfPayment';
1615
1616 5
        return $this->callMessage($msgName, $options, $messageOptions);
1617
    }
1618
1619
1620 5
    /**
1621
     * FOP_CreateFormOfPayment
1622 5
     *
1623
     * @param RequestOptions\FopValidateFopOptions $options
1624
     * @param array $messageOptions (OPTIONAL)
1625
     * @return Result
1626
     * @throws Client\InvalidMessageException
1627
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1628
     * @throws Exception
1629
     */
1630
    public function fopValidateFOP(RequestOptions\FopValidateFopOptions $options, $messageOptions = [])
1631
    {
1632
        $msgName = 'FOP_ValidateFOP';
1633
1634
        return $this->callMessage($msgName, $options, $messageOptions);
1635
    }
1636
1637
    /**
1638
     * PriceXplorer_ExtremeSearch
1639
     *
1640 420
     * @param RequestOptions\PriceXplorerExtremeSearchOptions $options
1641
     * @param array $messageOptions (OPTIONAL)
1642 420
     * @return Result
1643
     * @throws Client\InvalidMessageException
1644 420
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1645
     * @throws Exception
1646 420
     */
1647 420
    public function priceXplorerExtremeSearch(
1648 420
        RequestOptions\PriceXplorerExtremeSearchOptions $options,
1649 420
        $messageOptions = []
1650 168
    ) {
1651 168
        $msgName = 'PriceXplorer_ExtremeSearch';
1652 168
1653 168
        return $this->callMessage($msgName, $options, $messageOptions);
1654
    }
1655 420
1656 420
    /**
1657 168
     * SalesReports_DisplayQueryReport
1658 168
     *
1659
     * @param RequestOptions\SalesReportsDisplayQueryReportOptions $options
1660 420
     * @param array $messageOptions (OPTIONAL)
1661 5
     * @return Result
1662 2
     * @throws Client\InvalidMessageException
1663
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1664 420
     * @throws Exception
1665
     */
1666
    public function salesReportsDisplayQueryReport(
1667
        RequestOptions\SalesReportsDisplayQueryReportOptions $options,
1668
        $messageOptions = []
1669
    ) {
1670
        $msgName = 'SalesReports_DisplayQueryReport';
1671
1672
        return $this->callMessage($msgName, $options, $messageOptions);
1673
    }
1674
1675
    /**
1676
     * Service_IntegratedPricing
1677
     *
1678
     * @param RequestOptions\ServiceIntegratedPricingOptions $options
1679 450
     * @param array $messageOptions (OPTIONAL)
1680
     * @return Result
1681
     * @throws Client\InvalidMessageException
1682 450
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1683 450
     * @throws Exception
1684 180
     */
1685
    public function serviceIntegratedPricing(
1686 450
        RequestOptions\ServiceIntegratedPricingOptions $options,
1687 5
        $messageOptions = []
1688 2
    ) {
1689
        $msgName = 'Service_IntegratedPricing';
1690 450
1691 15
        return $this->callMessage($msgName, $options, $messageOptions);
1692 6
    }
1693
1694 450
    /**
1695
     * Service_IntegratedCatalogue
1696
     *
1697
     * @param RequestOptions\ServiceIntegratedCatalogueOptions $options
1698
     * @param array $messageOptions (OPTIONAL)
1699
     * @return Result
1700
     * @throws Client\InvalidMessageException
1701
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1702
     * @throws Exception
1703
     */
1704
    public function serviceIntegratedCatalogue(
1705
        RequestOptions\ServiceIntegratedCatalogueOptions $options,
1706
        $messageOptions = []
1707
    ) {
1708
        $msgName = 'Service_IntegratedCatalogue';
1709
1710
        return $this->callMessage($msgName, $options, $messageOptions);
1711
    }
1712
1713
    /**
1714
     * Service_BookPriceProduct
1715
     *
1716
     * @param RequestOptions\ServiceBookPriceProductOptions $options
1717
     * @param array                          $messageOptions  (OPTIONAL)
1718
     *
1719
     * @return Result
1720
     * @throws Client\InvalidMessageException
1721
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1722
     */
1723
    public function serviceBookPriceProduct(
1724
        RequestOptions\ServiceBookPriceProductOptions $options,
1725
        $messageOptions = []
1726
    ) {
1727
        $msgName = 'Service_BookPriceProduct';
1728
1729
        return $this->callMessage($msgName, $options, $messageOptions);
1730
    }
1731
1732
    /**
1733
     * Service_BookPriceService
1734
     *
1735
     * @param RequestOptions\ServiceBookPriceServiceOptions $options
1736
     * @param array $messageOptions (OPTIONAL)
1737
     * @return Result
1738
     * @throws Client\InvalidMessageException
1739
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1740
     * @throws Exception
1741
     */
1742
    public function serviceBookPriceService(
1743
        RequestOptions\ServiceBookPriceServiceOptions $options,
1744
        $messageOptions = []
1745
    ) {
1746
        $msgName = 'Service_BookPriceService';
1747
1748
        return $this->callMessage($msgName, $options, $messageOptions);
1749
    }
1750
1751
    /**
1752
     * SalesReports_DisplayorSummarizedReport
1753
     *
1754
     * @param RequestOptions\SalesReportsDisplayDailyOrSummarizedReportOptions $options
1755
     * @param array $messageOptions (OPTIONAL)
1756
     * @return Result
1757
     * @throws Client\InvalidMessageException
1758
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1759
     * @throws Exception
1760
     */
1761
    public function salesReportsDisplayDailyOrSummarizedReport(
1762
        RequestOptions\SalesReportsDisplayDailyOrSummarizedReportOptions $options,
1763
        $messageOptions = []
1764
    ) {
1765
        $msgName = 'SalesReports_DisplayDailyOrSummarizedReport';
1766
1767
        return $this->callMessage($msgName, $options, $messageOptions);
1768
    }
1769
1770
    /**
1771
     * SalesReports_DisplayNetRemitReport
1772
     *
1773
     * @param RequestOptions\SalesReportsDisplayNetRemitReportOptions $options
1774
     * @param array $messageOptions (OPTIONAL)
1775
     * @return Result
1776
     * @throws Client\InvalidMessageException
1777
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1778
     * @throws Exception
1779
     */
1780
    public function salesReportsDisplayNetRemitReport(
1781
        RequestOptions\SalesReportsDisplayNetRemitReportOptions $options,
1782
        $messageOptions = []
1783
    ) {
1784
        $msgName = 'SalesReports_DisplayNetRemitReport';
1785
1786
        return $this->callMessage($msgName, $options, $messageOptions);
1787
    }
1788
1789
    /**
1790
     * Service_StandaloneCatalogue
1791
     *
1792
     * @param RequestOptions\ServiceStandaloneCatalogueOptions $options
1793
     * @param array $messageOptions
1794
     *            (OPTIONAL)
1795
     * @return Result
1796
     * @throws Client\InvalidMessageException
1797
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1798
     * @throws Exception
1799
     */
1800
    public function serviceStandaloneCatalogue(
1801
        RequestOptions\ServiceStandaloneCatalogueOptions $options,
1802
        $messageOptions = [],
1803
    ) {
1804
        $msgName = 'Service_StandaloneCatalogue';
1805
1806
        return $this->callMessage($msgName, $options, $messageOptions);
1807
    }
1808
1809
    /**
1810
     * Travel_OfferPrice
1811
     *
1812
     * @param RequestOptions\TravelOfferPriceOptions $options
1813
     * @param array $messageOptions
1814
     *            (OPTIONAL)
1815
     * @return Result
1816
     * @throws Client\InvalidMessageException
1817
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1818
     * @throws Exception
1819
     */
1820
    public function travelOfferPrice(RequestOptions\TravelOfferPriceOptions $options, $messageOptions = [])
1821
    {
1822
        $msgName = 'Travel_OfferPrice';
1823
1824
        return $this->callMessage($msgName, $options, $messageOptions);
1825
    }
1826
1827
    /**
1828
     * Travel_OrderCreate
1829
     *
1830
     * @param RequestOptions\TravelOrderCreateOptions $options
1831
     * @param array $messageOptions
1832
     *            (OPTIONAL)
1833
     * @return Result
1834
     * @throws Client\InvalidMessageException
1835
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1836
     * @throws Exception
1837
     */
1838
    public function travelOrderCreate(RequestOptions\TravelOrderCreateOptions $options, $messageOptions = [])
1839
    {
1840
        $msgName = 'Travel_OrderCreate';
1841
1842
        return $this->callMessage($msgName, $options, $messageOptions);
1843
    }
1844
1845
    /**
1846
     * Travel_OrderRetrieve
1847
     *
1848
     * @param RequestOptions\TravelOrderRetrieveOptions $options
1849
     * @param array $messageOptions
1850
     *            (OPTIONAL)
1851
     * @return Result
1852
     * @throws Client\InvalidMessageException
1853
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1854
     * @throws Exception
1855
     */
1856
    public function travelOrderRetrieve(RequestOptions\TravelOrderRetrieveOptions $options, $messageOptions = [])
1857
    {
1858
        $msgName = 'Travel_OrderRetrieve';
1859
1860
        return $this->callMessage($msgName, $options, $messageOptions);
1861
    }
1862
1863
    /**
1864
     * Travel_OrderPay
1865
     *
1866
     * @param RequestOptions\TravelOrderPayOptions $options
1867
     * @param array $messageOptions
1868
     *            (OPTIONAL)
1869
     * @return Result
1870
     * @throws Client\InvalidMessageException
1871
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1872
     * @throws Exception
1873
     */
1874
    public function travelOrderPay(RequestOptions\TravelOrderPayOptions $options, $messageOptions = [])
1875
    {
1876
        $msgName = 'Travel_OrderPay';
1877
1878
        return $this->callMessage($msgName, $options, $messageOptions);
1879
    }
1880
1881
    /**
1882
     * Travel_OrderPay
1883
     *
1884
     * @param RequestOptions\TravelOrderCancelOptions $options
1885
     * @param array $messageOptions
1886
     *            (OPTIONAL)
1887
     * @return Result
1888
     * @throws Client\InvalidMessageException
1889
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1890
     * @throws Exception
1891
     */
1892
    public function travelOrderCancel(RequestOptions\TravelOrderCancelOptions $options, $messageOptions = [])
1893
    {
1894
        $msgName = 'Travel_OrderCancel';
1895
1896
        return $this->callMessage($msgName, $options, $messageOptions);
1897
    }
1898
1899
    /**
1900
     * Travel_ServiceList
1901
     *
1902
     * @param RequestOptions\TravelServiceListOptions $options
1903
     * @param array $messageOptions
1904
     *            (OPTIONAL)
1905
     * @return Result
1906
     * @throws Client\InvalidMessageException
1907
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1908
     * @throws Exception
1909
     */
1910
    public function travelServiceList(RequestOptions\TravelServiceListOptions $options, $messageOptions = [])
1911
    {
1912
        $msgName = 'Travel_ServiceList';
1913
1914
        return $this->callMessage($msgName, $options, $messageOptions);
1915
    }
1916
1917
    /**
1918
     * Travel_SeatAvailability
1919
     *
1920
     * @param RequestOptions\TravelSeatAvailabilityOptions $options
1921
     * @param array $messageOptions
1922
     *            (OPTIONAL)
1923
     * @return Result
1924
     * @throws Client\InvalidMessageException
1925
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1926
     * @throws Exception
1927
     */
1928
    public function travelSeatAvailability(RequestOptions\TravelSeatAvailabilityOptions $options, $messageOptions = [])
1929
    {
1930
        $msgName = 'Travel_SeatAvailability';
1931
1932
        return $this->callMessage($msgName, $options, $messageOptions);
1933
    }
1934
1935
    /**
1936
     * Travel_OrderChange
1937
     *
1938
     * @param RequestOptions\TravelOrderChangeOptions $options
1939
     * @param array $messageOptions
1940
     *            (OPTIONAL)
1941
     * @return Result
1942
     * @throws Client\InvalidMessageException
1943
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1944
     * @throws Exception
1945
     */
1946
    public function travelOrderChange(RequestOptions\TravelOrderChangeOptions $options, $messageOptions = [])
1947
    {
1948
        $msgName = 'Travel_OrderChange';
1949
1950
        return $this->callMessage($msgName, $options, $messageOptions);
1951
    }
1952
1953
    /**
1954
     * Call a message with the given parameters
1955
     *
1956
     * @param string $messageName
1957
     * @param RequestOptions\RequestOptionsInterface $options
1958
     * @param array $messageOptions
1959
     * @param bool $endSession
1960
     * @return Result
1961
     * @throws Client\Exception
1962
     * @throws Client\Struct\InvalidArgumentException
1963
     * @throws Client\InvalidMessageException
1964
     * @throws Client\RequestCreator\MessageVersionUnsupportedException
1965
     * @throws \RuntimeException
1966
     * @throws \InvalidArgumentException
1967
     */
1968
    protected function callMessage($messageName, $options, $messageOptions, $endSession = false)
1969
    {
1970
        $messageOptions = $this->makeMessageOptions($messageOptions, $endSession);
1971
1972
        $this->lastMessage = $messageName;
1973
1974
        $sendResult = $this->sessionHandler->sendMessage(
1975
            $messageName,
1976
            $this->requestCreator->createRequest(
1977
                $messageName,
1978
                $options
1979
            ),
1980
            $messageOptions
1981
        );
1982
1983
        $response = $this->responseHandler->analyzeResponse(
1984
            $sendResult,
1985
            $messageName
1986
        );
1987
1988
        if ($messageOptions['returnXml'] === false) {
1989
            $response->responseXml = null;
1990
        }
1991
1992
        return $response;
1993
    }
1994
1995
    /**
1996
     * Make message options
1997
     *
1998
     * Message options are meta options when sending a message to the amadeus web services
1999
     * - 'endSession' (if stateful) : should we end the current session after sending this call?
2000
     * - 'returnXml' : Should we return the XML string in the Result::responseXml property?
2001
     *   (this overrides the default setting returnXml in the Amadeus\Client\Params for a single message)
2002
     *
2003
     * @param array $incoming The Message options chosen by the caller - if any.
2004
     * @param bool $endSession Switch if you want to terminate the current session after making the call.
2005
     * @return array
2006
     */
2007
    protected function makeMessageOptions(array $incoming, $endSession = false)
2008
    {
2009
        $options = [
2010
            'endSession' => $endSession,
2011
            'returnXml' => $this->returnResultXml
2012
        ];
2013
2014
        if (array_key_exists('endSession', $incoming)) {
2015
            $options['endSession'] = $incoming['endSession'];
2016
        }
2017
2018
        if (array_key_exists('returnXml', $incoming)) {
2019
            $options['returnXml'] = $incoming['returnXml'];
2020
        }
2021
2022
        return $options;
2023
    }
2024
}
2025