3 declare(strict_types=1);
33 private static $discriminatorClasses = [
34 'addInterfaceInteraction' => PaymentAddInterfaceInteractionActionModel::class,
35 'addTransaction' => PaymentAddTransactionActionModel::class,
36 'changeAmountPlanned' => PaymentChangeAmountPlannedActionModel::class,
37 'changeTransactionInteractionId' => PaymentChangeTransactionInteractionIdActionModel::class,
38 'changeTransactionState' => PaymentChangeTransactionStateActionModel::class,
39 'changeTransactionTimestamp' => PaymentChangeTransactionTimestampActionModel::class,
40 'setAnonymousId' => PaymentSetAnonymousIdActionModel::class,
41 'setCustomField' => PaymentSetCustomFieldActionModel::class,
42 'setCustomType' => PaymentSetCustomTypeActionModel::class,
43 'setCustomer' => PaymentSetCustomerActionModel::class,
44 'setInterfaceId' => PaymentSetInterfaceIdActionModel::class,
45 'setKey' => PaymentSetKeyActionModel::class,
46 'setMethodInfoInterface' => PaymentSetMethodInfoInterfaceActionModel::class,
47 'setMethodInfoMethod' => PaymentSetMethodInfoMethodActionModel::class,
48 'setMethodInfoName' => PaymentSetMethodInfoNameActionModel::class,
49 'setStatusInterfaceCode' => PaymentSetStatusInterfaceCodeActionModel::class,
50 'setStatusInterfaceText' => PaymentSetStatusInterfaceTextActionModel::class,
51 'setTransactionCustomField' => PaymentSetTransactionCustomFieldActionModel::class,
52 'setTransactionCustomType' => PaymentSetTransactionCustomTypeActionModel::class,
53 'transitionState' => PaymentTransitionStateActionModel::class,
71 if (is_null($this->action)) {
73 $data = $this->
raw(self::FIELD_ACTION);
77 $this->action = (string) $data;
94 if (is_object($value) && isset($value->$fieldName)) {
96 $discriminatorValue = $value->$fieldName;
97 if (isset(self::$discriminatorClasses[$discriminatorValue])) {
98 return self::$discriminatorClasses[$discriminatorValue];
101 if (is_array($value) && isset($value[$fieldName])) {
103 $discriminatorValue = $value[$fieldName];
104 if (isset(self::$discriminatorClasses[$discriminatorValue])) {
105 return self::$discriminatorClasses[$discriminatorValue];
110 $type = PaymentUpdateActionModel::class;