/* 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 { ComponentDetailDocument } from './ComponentDetailDocument'; import { ComponentDetailDocumentFromJSON, ComponentDetailDocumentFromJSONTyped, ComponentDetailDocumentToJSON, ComponentDetailDocumentToJSONTyped, } from './ComponentDetailDocument'; /** * * @export * @interface ApiSearchResponseComponentDetailDocument */ export interface ApiSearchResponseComponentDetailDocument { /** * * @type {{ [key: string]: { [key: string]: number; }; }} * @memberof ApiSearchResponseComponentDetailDocument */ aggregations?: { [key: string]: { [key: string]: number; }; }; /** * * @type {Array} * @memberof ApiSearchResponseComponentDetailDocument */ hits?: Array; /** * * @type {number} * @memberof ApiSearchResponseComponentDetailDocument */ limit?: number; /** * * @type {number} * @memberof ApiSearchResponseComponentDetailDocument */ offset?: number; /** * * @type {number} * @memberof ApiSearchResponseComponentDetailDocument */ total?: number; } /** * Check if a given object implements the ApiSearchResponseComponentDetailDocument interface. */ export function instanceOfApiSearchResponseComponentDetailDocument(value: object): value is ApiSearchResponseComponentDetailDocument { return true; } export function ApiSearchResponseComponentDetailDocumentFromJSON(json: any): ApiSearchResponseComponentDetailDocument { return ApiSearchResponseComponentDetailDocumentFromJSONTyped(json, false); } export function ApiSearchResponseComponentDetailDocumentFromJSONTyped(json: any, ignoreDiscriminator: boolean): ApiSearchResponseComponentDetailDocument { if (json == null) { return json; } return { 'aggregations': json['aggregations'] == null ? undefined : json['aggregations'], 'hits': json['hits'] == null ? undefined : ((json['hits'] as Array).map(ComponentDetailDocumentFromJSON)), 'limit': json['limit'] == null ? undefined : json['limit'], 'offset': json['offset'] == null ? undefined : json['offset'], 'total': json['total'] == null ? undefined : json['total'], }; } export function ApiSearchResponseComponentDetailDocumentToJSON(json: any): ApiSearchResponseComponentDetailDocument { return ApiSearchResponseComponentDetailDocumentToJSONTyped(json, false); } export function ApiSearchResponseComponentDetailDocumentToJSONTyped(value?: ApiSearchResponseComponentDetailDocument | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'aggregations': value['aggregations'], 'hits': value['hits'] == null ? undefined : ((value['hits'] as Array).map(ComponentDetailDocumentToJSON)), 'limit': value['limit'], 'offset': value['offset'], 'total': value['total'], }; }