/* tslint:disable */ /* eslint-disable */ /** * Keycloak Admin REST API * This is a REST API reference for the Keycloak Admin * * The version of the OpenAPI document: 1 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { exists, mapValues } from '../runtime'; import { ClientPolicyConditionRepresentation, ClientPolicyConditionRepresentationFromJSON, ClientPolicyConditionRepresentationFromJSONTyped, ClientPolicyConditionRepresentationToJSON, } from './'; /** * * @export * @interface ClientPolicyRepresentation */ export interface ClientPolicyRepresentation { /** * * @type {Array} * @memberof ClientPolicyRepresentation */ conditions?: Array; /** * * @type {string} * @memberof ClientPolicyRepresentation */ description?: string; /** * * @type {boolean} * @memberof ClientPolicyRepresentation */ enabled?: boolean; /** * * @type {string} * @memberof ClientPolicyRepresentation */ name?: string; /** * * @type {Array} * @memberof ClientPolicyRepresentation */ profiles?: Array; } export function ClientPolicyRepresentationFromJSON(json: any): ClientPolicyRepresentation { return ClientPolicyRepresentationFromJSONTyped(json, false); } export function ClientPolicyRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientPolicyRepresentation { if ((json === undefined) || (json === null)) { return json; } return { 'conditions': !exists(json, 'conditions') ? undefined : ((json['conditions'] as Array).map(ClientPolicyConditionRepresentationFromJSON)), 'description': !exists(json, 'description') ? undefined : json['description'], 'enabled': !exists(json, 'enabled') ? undefined : json['enabled'], 'name': !exists(json, 'name') ? undefined : json['name'], 'profiles': !exists(json, 'profiles') ? undefined : json['profiles'], }; } export function ClientPolicyRepresentationToJSON(value?: ClientPolicyRepresentation | null): any { if (value === undefined) { return undefined; } if (value === null) { return null; } return { 'conditions': value.conditions === undefined ? undefined : ((value.conditions as Array).map(ClientPolicyConditionRepresentationToJSON)), 'description': value.description, 'enabled': value.enabled, 'name': value.name, 'profiles': value.profiles, }; }