UNPKG

wallee

Version:
36 lines (35 loc) 1.57 kB
import { PaymentAppChargeAttemptTargetStateFromJSON, PaymentAppChargeAttemptTargetStateToJSON, } from './PaymentAppChargeAttemptTargetState'; /** * Check if a given object implements the PaymentAppChargeAttemptUpdate interface. */ export function instanceOfPaymentAppChargeAttemptUpdate(value) { return true; } export function PaymentAppChargeAttemptUpdateFromJSON(json) { return PaymentAppChargeAttemptUpdateFromJSONTyped(json, false); } export function PaymentAppChargeAttemptUpdateFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { 'reference': json['reference'] == null ? undefined : json['reference'], 'targetState': json['targetState'] == null ? undefined : PaymentAppChargeAttemptTargetStateFromJSON(json['targetState']), 'failureReason': json['failureReason'] == null ? undefined : json['failureReason'], 'endUserFailureMessage': json['endUserFailureMessage'] == null ? undefined : json['endUserFailureMessage'], }; } export function PaymentAppChargeAttemptUpdateToJSON(json) { return PaymentAppChargeAttemptUpdateToJSONTyped(json, false); } export function PaymentAppChargeAttemptUpdateToJSONTyped(value, ignoreDiscriminator = false) { if (value == null) { return value; } return { 'reference': value['reference'], 'targetState': PaymentAppChargeAttemptTargetStateToJSON(value['targetState']), 'failureReason': value['failureReason'], 'endUserFailureMessage': value['endUserFailureMessage'], }; }