/* tslint:disable */ /* eslint-disable */ /** * Sonatype Guide API * REST API into [Sonatype Guide](https://guide.sonatype.com). * * The version of the OpenAPI document: 202607 * * * 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 { VulnerabilityDocument } from './VulnerabilityDocument'; import { VulnerabilityDocumentFromJSON, VulnerabilityDocumentFromJSONTyped, VulnerabilityDocumentToJSON, VulnerabilityDocumentToJSONTyped, } from './VulnerabilityDocument'; /** * * @export * @interface ApiSearchResponseVulnerabilityDocument */ export interface ApiSearchResponseVulnerabilityDocument { /** * * @type {{ [key: string]: { [key: string]: number; }; }} * @memberof ApiSearchResponseVulnerabilityDocument */ aggregations?: { [key: string]: { [key: string]: number; }; }; /** * * @type {Array} * @memberof ApiSearchResponseVulnerabilityDocument */ hits?: Array; /** * * @type {number} * @memberof ApiSearchResponseVulnerabilityDocument */ limit?: number; /** * * @type {number} * @memberof ApiSearchResponseVulnerabilityDocument */ offset?: number; /** * * @type {number} * @memberof ApiSearchResponseVulnerabilityDocument */ total?: number; } /** * Check if a given object implements the ApiSearchResponseVulnerabilityDocument interface. */ export function instanceOfApiSearchResponseVulnerabilityDocument(value: object): value is ApiSearchResponseVulnerabilityDocument { return true; } export function ApiSearchResponseVulnerabilityDocumentFromJSON(json: any): ApiSearchResponseVulnerabilityDocument { return ApiSearchResponseVulnerabilityDocumentFromJSONTyped(json, false); } export function ApiSearchResponseVulnerabilityDocumentFromJSONTyped(json: any, ignoreDiscriminator: boolean): ApiSearchResponseVulnerabilityDocument { if (json == null) { return json; } return { 'aggregations': json['aggregations'] == null ? undefined : json['aggregations'], 'hits': json['hits'] == null ? undefined : ((json['hits'] as Array).map(VulnerabilityDocumentFromJSON)), 'limit': json['limit'] == null ? undefined : json['limit'], 'offset': json['offset'] == null ? undefined : json['offset'], 'total': json['total'] == null ? undefined : json['total'], }; } export function ApiSearchResponseVulnerabilityDocumentToJSON(json: any): ApiSearchResponseVulnerabilityDocument { return ApiSearchResponseVulnerabilityDocumentToJSONTyped(json, false); } export function ApiSearchResponseVulnerabilityDocumentToJSONTyped(value?: ApiSearchResponseVulnerabilityDocument | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'aggregations': value['aggregations'], 'hits': value['hits'] == null ? undefined : ((value['hits'] as Array).map(VulnerabilityDocumentToJSON)), 'limit': value['limit'], 'offset': value['offset'], 'total': value['total'], }; }