/* tslint:disable */ /* eslint-disable */ /** * Mubicon v1 API * Api with Swagger, Swashbuckle, and Manual API versioning. * * The version of the OpenAPI document: 1 * Contact: support@mubicloud.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { mapValues } from '../runtime'; import type { ApplicationUser } from './ApplicationUser'; import { ApplicationUserFromJSON, ApplicationUserFromJSONTyped, ApplicationUserToJSON, ApplicationUserToJSONTyped, } from './ApplicationUser'; import type { PlaylistFeed } from './PlaylistFeed'; import { PlaylistFeedFromJSON, PlaylistFeedFromJSONTyped, PlaylistFeedToJSON, PlaylistFeedToJSONTyped, } from './PlaylistFeed'; import type { CalendarDay } from './CalendarDay'; import { CalendarDayFromJSON, CalendarDayFromJSONTyped, CalendarDayToJSON, CalendarDayToJSONTyped, } from './CalendarDay'; /** * * @export * @interface Feed */ export interface Feed { /** * * @type {number} * @memberof Feed */ feedId?: number; /** * * @type {string} * @memberof Feed */ name: string; /** * * @type {string} * @memberof Feed */ duration?: string; /** * * @type {CalendarDay} * @memberof Feed */ calendarDay?: CalendarDay; /** * * @type {Date} * @memberof Feed */ calendarDate?: Date | null; /** * * @type {string} * @memberof Feed */ jsDate?: string | null; /** * * @type {boolean} * @memberof Feed */ random?: boolean; /** * * @type {boolean} * @memberof Feed */ stopPlay?: boolean; /** * * @type {Date} * @memberof Feed */ createDate?: Date; /** * * @type {Date} * @memberof Feed */ changeDate?: Date; /** * * @type {ApplicationUser} * @memberof Feed */ applicationUser?: ApplicationUser; /** * * @type {Array} * @memberof Feed */ playlistFeeds?: Array | null; } /** * Check if a given object implements the Feed interface. */ export function instanceOfFeed(value: object): value is Feed { if (!('name' in value) || value['name'] === undefined) return false; return true; } export function FeedFromJSON(json: any): Feed { return FeedFromJSONTyped(json, false); } export function FeedFromJSONTyped(json: any, ignoreDiscriminator: boolean): Feed { if (json == null) { return json; } return { 'feedId': json['FeedId'] == null ? undefined : json['FeedId'], 'name': json['Name'], 'duration': json['Duration'] == null ? undefined : json['Duration'], 'calendarDay': json['CalendarDay'] == null ? undefined : CalendarDayFromJSON(json['CalendarDay']), 'calendarDate': json['CalendarDate'] == null ? undefined : (new Date(json['CalendarDate'])), 'jsDate': json['JsDate'] == null ? undefined : json['JsDate'], 'random': json['Random'] == null ? undefined : json['Random'], 'stopPlay': json['StopPlay'] == null ? undefined : json['StopPlay'], 'createDate': json['CreateDate'] == null ? undefined : (new Date(json['CreateDate'])), 'changeDate': json['ChangeDate'] == null ? undefined : (new Date(json['ChangeDate'])), 'applicationUser': json['ApplicationUser'] == null ? undefined : ApplicationUserFromJSON(json['ApplicationUser']), 'playlistFeeds': json['PlaylistFeeds'] == null ? undefined : ((json['PlaylistFeeds'] as Array).map(PlaylistFeedFromJSON)), }; } export function FeedToJSON(json: any): Feed { return FeedToJSONTyped(json, false); } export function FeedToJSONTyped(value?: Feed | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'FeedId': value['feedId'], 'Name': value['name'], 'Duration': value['duration'], 'CalendarDay': CalendarDayToJSON(value['calendarDay']), 'CalendarDate': value['calendarDate'] == null ? undefined : ((value['calendarDate'] as any).toISOString()), 'JsDate': value['jsDate'], 'Random': value['random'], 'StopPlay': value['stopPlay'], 'CreateDate': value['createDate'] == null ? undefined : ((value['createDate']).toISOString()), 'ChangeDate': value['changeDate'] == null ? undefined : ((value['changeDate']).toISOString()), 'ApplicationUser': ApplicationUserToJSON(value['applicationUser']), 'PlaylistFeeds': value['playlistFeeds'] == null ? undefined : ((value['playlistFeeds'] as Array).map(PlaylistFeedToJSON)), }; }