/* tslint:disable */ /* eslint-disable */ /** * Sonatype Lifecycle Public REST API * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 1.207.0-01 * * * 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 { ApiReportPolicyViolationDTOV2 } from './ApiReportPolicyViolationDTOV2'; import { ApiReportPolicyViolationDTOV2FromJSON, ApiReportPolicyViolationDTOV2FromJSONTyped, ApiReportPolicyViolationDTOV2ToJSON, ApiReportPolicyViolationDTOV2ToJSONTyped, } from './ApiReportPolicyViolationDTOV2'; import type { ApiComponentIdentifierDTOV2 } from './ApiComponentIdentifierDTOV2'; import { ApiComponentIdentifierDTOV2FromJSON, ApiComponentIdentifierDTOV2FromJSONTyped, ApiComponentIdentifierDTOV2ToJSON, ApiComponentIdentifierDTOV2ToJSONTyped, } from './ApiComponentIdentifierDTOV2'; import type { ApiDependencyDataDTO } from './ApiDependencyDataDTO'; import { ApiDependencyDataDTOFromJSON, ApiDependencyDataDTOFromJSONTyped, ApiDependencyDataDTOToJSON, ApiDependencyDataDTOToJSONTyped, } from './ApiDependencyDataDTO'; /** * * @export * @interface ApiReportComponentPolicyViolationsDTOV2 */ export interface ApiReportComponentPolicyViolationsDTOV2 { /** * * @type {ApiComponentIdentifierDTOV2} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ componentIdentifier?: ApiComponentIdentifierDTOV2; /** * * @type {ApiDependencyDataDTO} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ dependencyData?: ApiDependencyDataDTO; /** * * @type {string} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ displayName?: string; /** * * @type {string} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ hash?: string; /** * * @type {string} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ matchState?: string; /** * * @type {string} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ originalPurl?: string; /** * * @type {string} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ packageUrl?: string; /** * * @type {Array} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ pathnames?: Array; /** * * @type {boolean} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ proprietary?: boolean; /** * * @type {string} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ sha256?: string; /** * * @type {boolean} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ thirdParty?: boolean; /** * * @type {Array} * @memberof ApiReportComponentPolicyViolationsDTOV2 */ violations?: Array; } /** * Check if a given object implements the ApiReportComponentPolicyViolationsDTOV2 interface. */ export function instanceOfApiReportComponentPolicyViolationsDTOV2(value: object): value is ApiReportComponentPolicyViolationsDTOV2 { return true; } export function ApiReportComponentPolicyViolationsDTOV2FromJSON(json: any): ApiReportComponentPolicyViolationsDTOV2 { return ApiReportComponentPolicyViolationsDTOV2FromJSONTyped(json, false); } export function ApiReportComponentPolicyViolationsDTOV2FromJSONTyped(json: any, ignoreDiscriminator: boolean): ApiReportComponentPolicyViolationsDTOV2 { if (json == null) { return json; } return { 'componentIdentifier': json['componentIdentifier'] == null ? undefined : ApiComponentIdentifierDTOV2FromJSON(json['componentIdentifier']), 'dependencyData': json['dependencyData'] == null ? undefined : ApiDependencyDataDTOFromJSON(json['dependencyData']), 'displayName': json['displayName'] == null ? undefined : json['displayName'], 'hash': json['hash'] == null ? undefined : json['hash'], 'matchState': json['matchState'] == null ? undefined : json['matchState'], 'originalPurl': json['originalPurl'] == null ? undefined : json['originalPurl'], 'packageUrl': json['packageUrl'] == null ? undefined : json['packageUrl'], 'pathnames': json['pathnames'] == null ? undefined : json['pathnames'], 'proprietary': json['proprietary'] == null ? undefined : json['proprietary'], 'sha256': json['sha256'] == null ? undefined : json['sha256'], 'thirdParty': json['thirdParty'] == null ? undefined : json['thirdParty'], 'violations': json['violations'] == null ? undefined : ((json['violations'] as Array).map(ApiReportPolicyViolationDTOV2FromJSON)), }; } export function ApiReportComponentPolicyViolationsDTOV2ToJSON(json: any): ApiReportComponentPolicyViolationsDTOV2 { return ApiReportComponentPolicyViolationsDTOV2ToJSONTyped(json, false); } export function ApiReportComponentPolicyViolationsDTOV2ToJSONTyped(value?: ApiReportComponentPolicyViolationsDTOV2 | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'componentIdentifier': ApiComponentIdentifierDTOV2ToJSON(value['componentIdentifier']), 'dependencyData': ApiDependencyDataDTOToJSON(value['dependencyData']), 'displayName': value['displayName'], 'hash': value['hash'], 'matchState': value['matchState'], 'originalPurl': value['originalPurl'], 'packageUrl': value['packageUrl'], 'pathnames': value['pathnames'], 'proprietary': value['proprietary'], 'sha256': value['sha256'], 'thirdParty': value['thirdParty'], 'violations': value['violations'] == null ? undefined : ((value['violations'] as Array).map(ApiReportPolicyViolationDTOV2ToJSON)), }; }