/* tslint:disable */ /* eslint-disable */ // @ts-nocheck /** * Audius API * * The version of the OpenAPI document: 1.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { ExtendedPurchaseGate, instanceOfExtendedPurchaseGate, ExtendedPurchaseGateFromJSON, ExtendedPurchaseGateFromJSONTyped, ExtendedPurchaseGateToJSON, } from './ExtendedPurchaseGate'; import { FollowGate, instanceOfFollowGate, FollowGateFromJSON, FollowGateFromJSONTyped, FollowGateToJSON, } from './FollowGate'; import { TipGate, instanceOfTipGate, TipGateFromJSON, TipGateFromJSONTyped, TipGateToJSON, } from './TipGate'; import { TokenGate, instanceOfTokenGate, TokenGateFromJSON, TokenGateFromJSONTyped, TokenGateToJSON, } from './TokenGate'; /** * @type ExtendedAccessGate * * @export */ export type ExtendedAccessGate = ExtendedPurchaseGate | FollowGate | TipGate | TokenGate; export function ExtendedAccessGateFromJSON(json: any): ExtendedAccessGate { return ExtendedAccessGateFromJSONTyped(json, false); } export function ExtendedAccessGateFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExtendedAccessGate { if ((json === undefined) || (json === null)) { return json; } return { ...ExtendedPurchaseGateFromJSONTyped(json, true), ...FollowGateFromJSONTyped(json, true), ...TipGateFromJSONTyped(json, true), ...TokenGateFromJSONTyped(json, true) }; } export function ExtendedAccessGateToJSON(value?: ExtendedAccessGate | null): any { if (value === undefined) { return undefined; } if (value === null) { return null; } if (instanceOfExtendedPurchaseGate(value)) { return ExtendedPurchaseGateToJSON(value as ExtendedPurchaseGate); } if (instanceOfFollowGate(value)) { return FollowGateToJSON(value as FollowGate); } if (instanceOfTipGate(value)) { return TipGateToJSON(value as TipGate); } if (instanceOfTokenGate(value)) { return TokenGateToJSON(value as TokenGate); } return {}; }