/* 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 { ApiLabelDTO } from './ApiLabelDTO'; import { ApiLabelDTOFromJSON, ApiLabelDTOFromJSONTyped, ApiLabelDTOToJSON, ApiLabelDTOToJSONTyped, } from './ApiLabelDTO'; /** * * @export * @interface LabelsByOwner */ export interface LabelsByOwner { /** * * @type {Array} * @memberof LabelsByOwner */ labels?: Array; /** * * @type {string} * @memberof LabelsByOwner */ ownerId?: string; /** * * @type {string} * @memberof LabelsByOwner */ ownerName?: string; /** * * @type {string} * @memberof LabelsByOwner */ ownerType?: LabelsByOwnerOwnerTypeEnum; } /** * @export */ export const LabelsByOwnerOwnerTypeEnum = { Application: 'application', Organization: 'organization', RepositoryContainer: 'repository_container', RepositoryManager: 'repository_manager', Repository: 'repository', HostedRepositoryComponent: 'hosted_repository_component', Global: 'global' } as const; export type LabelsByOwnerOwnerTypeEnum = typeof LabelsByOwnerOwnerTypeEnum[keyof typeof LabelsByOwnerOwnerTypeEnum]; /** * Check if a given object implements the LabelsByOwner interface. */ export function instanceOfLabelsByOwner(value: object): value is LabelsByOwner { return true; } export function LabelsByOwnerFromJSON(json: any): LabelsByOwner { return LabelsByOwnerFromJSONTyped(json, false); } export function LabelsByOwnerFromJSONTyped(json: any, ignoreDiscriminator: boolean): LabelsByOwner { if (json == null) { return json; } return { 'labels': json['labels'] == null ? undefined : ((json['labels'] as Array).map(ApiLabelDTOFromJSON)), 'ownerId': json['ownerId'] == null ? undefined : json['ownerId'], 'ownerName': json['ownerName'] == null ? undefined : json['ownerName'], 'ownerType': json['ownerType'] == null ? undefined : json['ownerType'], }; } export function LabelsByOwnerToJSON(json: any): LabelsByOwner { return LabelsByOwnerToJSONTyped(json, false); } export function LabelsByOwnerToJSONTyped(value?: LabelsByOwner | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'labels': value['labels'] == null ? undefined : ((value['labels'] as Array).map(ApiLabelDTOToJSON)), 'ownerId': value['ownerId'], 'ownerName': value['ownerName'], 'ownerType': value['ownerType'], }; }