Client   F
last analyzed

Complexity

Total Complexity 116

Size/Duplication

Total Lines 2051
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 4
Bugs 0 Features 0
Metric Value
wmc 116
eloc 251
c 4
b 0
f 0
dl 0
loc 2051
rs 2
ccs 306
cts 306
cp 1

113 Methods

Rating   Name   Duplication   Size   Complexity  
A fareGetFareFamilyDescription() 0 7 1
A getLastResponseHeaders() 0 3 1
A getConsumerId() 0 3 1
A pnrSplit() 0 7 1
A securityAuthenticate() 0 11 1
A pnrChangeElement() 0 5 1
A setConsumerId() 0 4 1
A fareMasterPricerExpertSearch() 0 7 1
A farePriceUpsellWithoutPnr() 0 7 1
A fareGetFareRules() 0 5 1
A securitySignOut() 0 9 1
A getLastRequestHeaders() 0 3 1
A pnrIgnore() 0 5 1
A pnrNameChange() 0 5 1
A pnrCreatePnr() 0 5 1
A queueMoveItem() 0 5 1
A offerConfirmHotel() 0 5 1
A fareMasterPricerTravelBoardSearch() 0 7 1
A queueList() 0 5 1
A queueRemoveItem() 0 5 1
A offerCreate() 0 5 1
A setStateful() 0 3 1
A fareInformativeBestPricingWithoutPnr() 0 7 1
A pnrTransferOwnership() 0 5 1
A offerConfirmCar() 0 5 1
A pnrRetrieveAndDisplay() 0 5 1
A offerConfirmAir() 0 5 1
A farePricePnrWithLowestFare() 0 7 1
A offerVerify() 0 5 1
A pnrDisplayHistory() 0 5 1
A fareMasterPricerCalendar() 0 7 1
A getLastRequest() 0 3 1
A isStateful() 0 3 1
A getSessionData() 0 3 1
A __construct() 0 6 1
A queuePlacePnr() 0 5 1
A farePricePnrWithLowerFares() 0 7 1
A getLastResponse() 0 3 1
A pnrAddMultiElements() 0 5 1
A fareInformativePricingWithoutPnr() 0 7 1
A pnrRetrieve() 0 5 1
A setSessionData() 0 3 1
A farePricePnrWithBookingClass() 0 7 1
A pnrCancel() 0 5 1
A fareCheckRules() 0 5 1
A ticketDisplayTSMP() 0 5 1
A ticketInitRefund() 0 7 1
A priceXplorerExtremeSearch() 0 7 1
A callMessage() 0 25 2
A ticketProcessEDoc() 0 5 1
A ticketAtcShopperMasterPricerCalendar() 0 7 1
A fopValidateFOP() 0 5 1
A serviceIntegratedPricing() 0 7 1
A salesReportsDisplayNetRemitReport() 0 7 1
A pointOfRefSearch() 0 5 1
A miniRuleGetFromPricingRec() 0 7 1
A infoEncodeDecodeCity() 0 5 1
A docIssuanceIssueTicket() 0 7 1
A salesReportsDisplayDailyOrSummarizedReport() 0 7 1
A miniRuleGetFromETicket() 0 7 1
A airSellFromRecommendation() 0 7 1
A fareTLAGetFareRules() 0 5 1
A payGetVirtualCardDetails() 0 5 1
A travelServiceList() 0 5 1
A serviceBookPriceProduct() 0 7 1
A miniRuleGetFromRec() 0 5 1
A docRefundIgnoreRefund() 0 7 1
A ticketCreateTSMFromPricing() 0 7 1
A ticketProcessETicket() 0 5 1
A ticketDisplayTST() 0 5 1
A serviceIntegratedCatalogue() 0 7 1
A makeMessageOptions() 0 16 3
A commandCryptic() 0 5 1
A docIssuanceIssueMiscellaneousDocuments() 0 7 1
A travelOrderCancel() 0 5 1
A ticketProcessRefund() 0 7 1
A ticketCreateTSMFareElement() 0 7 1
A ticketRepricePnrWithBookingClass() 0 7 1
A ticketAtcShopperMasterPricerTravelBoardSearch() 0 7 1
A airFlightInfo() 0 5 1
A fopCreateFormOfPayment() 0 5 1
A docIssuanceIssueCombined() 0 7 1
A payListVirtualCards() 0 5 1
A airMultiAvailability() 0 7 1
A ticketUpdateRefund() 0 7 1
A ticketCreateTASF() 0 7 1
A travelOrderPay() 0 5 1
A travelOrderChange() 0 5 1
A miniRuleGetFromPricing() 0 7 1
A ticketIgnoreRefund() 0 7 1
A ticketReissueConfirmedPricing() 0 7 1
A ticketDisplayTSMFareElement() 0 7 1
A travelSeatAvailability() 0 5 1
A travelOfferPrice() 0 5 1
A airRebookAirSegment() 0 5 1
A airRetrieveSeatMap() 0 5 1
A docRefundUpdateRefund() 0 7 1
A ticketDeleteTSMP() 0 5 1
A ticketDeleteTST() 0 5 1
A travelOrderCreate() 0 5 1
A payGenerateVirtualCard() 0 5 1
A ticketCancelDocument() 0 7 1
A docRefundProcessRefund() 0 7 1
A fareConvertCurrency() 0 5 1
A salesReportsDisplayQueryReport() 0 7 1
A travelOrderRetrieve() 0 5 1
A payDeleteVirtualCard() 0 5 1
A ticketRetrieveListOfTSM() 0 7 1
A serviceStandaloneCatalogue() 0 7 1
A ticketCheckEligibility() 0 7 1
A docRefundInitRefund() 0 7 1
A serviceBookPriceService() 0 7 1
A ticketCreateTSTFromPricing() 0 7 1

How to fix   Complexity   

Complex Class

Complex classes like Client often do a lot of different things. To break such a class down, we need to identify a cohesive component within that class. A common approach to find such a component is to look for fields/methods that share the same prefixes, or suffixes.

Once you have determined the fields that belong together, you can apply the Extract Class refactoring. If the component makes sense as a sub-class, Extract Subclass is also a candidate, and is often faster.

While breaking up the class, it is a good idea to analyze how other classes use Client, and based on these observations, apply Extract Interface, too.

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