"use strict";
/* tslint:disable */
/* eslint-disable */
/**
 * Octane API
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 1.0.0
 *
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */
Object.defineProperty(exports, "__esModule", { value: true });
exports.CustomerPortalPaymentMethodToJSON = exports.CustomerPortalPaymentMethodFromJSONTyped = exports.CustomerPortalPaymentMethodFromJSON = void 0;
const runtime_1 = require("../runtime");
const BankAccountInfo_1 = require("./BankAccountInfo");
const CardInfo_1 = require("./CardInfo");
function CustomerPortalPaymentMethodFromJSON(json) {
    return CustomerPortalPaymentMethodFromJSONTyped(json, false);
}
exports.CustomerPortalPaymentMethodFromJSON = CustomerPortalPaymentMethodFromJSON;
function CustomerPortalPaymentMethodFromJSONTyped(json, ignoreDiscriminator) {
    if ((json === undefined) || (json === null)) {
        return json;
    }
    return {
        'paymentMethodType': !(0, runtime_1.exists)(json, 'payment_method_type') ? undefined : json['payment_method_type'],
        'bankAccountInfo': !(0, runtime_1.exists)(json, 'bank_account_info') ? undefined : (0, BankAccountInfo_1.BankAccountInfoFromJSON)(json['bank_account_info']),
        'cardInfo': !(0, runtime_1.exists)(json, 'card_info') ? undefined : (0, CardInfo_1.CardInfoFromJSON)(json['card_info']),
    };
}
exports.CustomerPortalPaymentMethodFromJSONTyped = CustomerPortalPaymentMethodFromJSONTyped;
function CustomerPortalPaymentMethodToJSON(value) {
    if (value === undefined) {
        return undefined;
    }
    if (value === null) {
        return null;
    }
    return {
        'payment_method_type': value.paymentMethodType,
        'bank_account_info': (0, BankAccountInfo_1.BankAccountInfoToJSON)(value.bankAccountInfo),
        'card_info': (0, CardInfo_1.CardInfoToJSON)(value.cardInfo),
    };
}
exports.CustomerPortalPaymentMethodToJSON = CustomerPortalPaymentMethodToJSON;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlI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