/* tslint:disable */
/* eslint-disable */
/**
 * chomestatus API
 * The API for chromestatus.com. chromestatus.com is the official tool used for tracking feature launches in Blink (the browser engine that powers Chrome and many other web browsers). This tool guides feature owners through our launch process and serves as a primary source for developer information that then ripples throughout the web developer ecosystem. More details at: https://github.com/GoogleChrome/chromium-dashboard
 *
 * 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.
 */

import { mapValues } from '../runtime';
/**
 * Editorial curation review state for a specific Chromium release milestone.
 * @export
 * @interface MilestoneCurationResponse
 */
export interface MilestoneCurationResponse {
    /**
     * Target Chromium milestone number.
     * @type {number}
     * @memberof MilestoneCurationResponse
     */
    milestone: number;
    /**
     * Editorial review status of the milestone curation workflow:
     * - PENDING: Milestone curation has not started
     * - IN_REVIEW: Milestone curation is under active editorial review
     * - COMPLETED: Milestone curation review is completed (updates last_reviewed timestamp)
     * 
     * @type {string}
     * @memberof MilestoneCurationResponse
     */
    status: MilestoneCurationResponseStatusEnum;
    /**
     * List of editor email addresses assigned to curate release notes for this milestone.
     * @type {Array<string>}
     * @memberof MilestoneCurationResponse
     */
    curator_emails: Array<string>;
    /**
     * UTC timestamp when milestone curation was last reviewed or completed. Null if unreviewed.
     * @type {Date}
     * @memberof MilestoneCurationResponse
     */
    last_reviewed?: Date;
}


/**
 * @export
 */
export const MilestoneCurationResponseStatusEnum = {
    PENDING: 'PENDING',
    IN_REVIEW: 'IN_REVIEW',
    COMPLETED: 'COMPLETED'
} as const;
export type MilestoneCurationResponseStatusEnum = typeof MilestoneCurationResponseStatusEnum[keyof typeof MilestoneCurationResponseStatusEnum];


/**
 * Check if a given object implements the MilestoneCurationResponse interface.
 */
export function instanceOfMilestoneCurationResponse(value: object): value is MilestoneCurationResponse {
    if (!('milestone' in value) || value['milestone'] === undefined) return false;
    if (!('status' in value) || value['status'] === undefined) return false;
    if (!('curator_emails' in value) || value['curator_emails'] === undefined) return false;
    return true;
}

export function MilestoneCurationResponseFromJSON(json: any): MilestoneCurationResponse {
    return MilestoneCurationResponseFromJSONTyped(json, false);
}

export function MilestoneCurationResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): MilestoneCurationResponse {
    if (json == null) {
        return json;
    }
    return {
        
        'milestone': json['milestone'],
        'status': json['status'],
        'curator_emails': json['curator_emails'],
        'last_reviewed': json['last_reviewed'] == null ? undefined : (new Date(json['last_reviewed'])),
    };
}

export function MilestoneCurationResponseToJSON(value?: MilestoneCurationResponse | null): any {
    if (value == null) {
        return value;
    }
    return {
        
        'milestone': value['milestone'],
        'status': value['status'],
        'curator_emails': value['curator_emails'],
        'last_reviewed': value['last_reviewed'] == null ? undefined : ((value['last_reviewed'] as any).toISOString()),
    };
}

