/* 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 { PolicyRepresentation, PolicyRepresentationFromJSON, PolicyRepresentationFromJSONTyped, PolicyRepresentationToJSON, ResourceRepresentation, ResourceRepresentationFromJSON, ResourceRepresentationFromJSONTyped, ResourceRepresentationToJSON, } from './'; /** * * @export * @interface ScopeRepresentation */ export interface ScopeRepresentation { /** * * @type {string} * @memberof ScopeRepresentation */ displayName?: string; /** * * @type {string} * @memberof ScopeRepresentation */ iconUri?: string; /** * * @type {string} * @memberof ScopeRepresentation */ id?: string; /** * * @type {string} * @memberof ScopeRepresentation */ name?: string; /** * * @type {Array} * @memberof ScopeRepresentation */ policies?: Array; /** * * @type {Array} * @memberof ScopeRepresentation */ resources?: Array; } export function ScopeRepresentationFromJSON(json: any): ScopeRepresentation { return ScopeRepresentationFromJSONTyped(json, false); } export function ScopeRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ScopeRepresentation { if ((json === undefined) || (json === null)) { return json; } return { 'displayName': !exists(json, 'displayName') ? undefined : json['displayName'], 'iconUri': !exists(json, 'iconUri') ? undefined : json['iconUri'], 'id': !exists(json, 'id') ? undefined : json['id'], 'name': !exists(json, 'name') ? undefined : json['name'], 'policies': !exists(json, 'policies') ? undefined : ((json['policies'] as Array).map(PolicyRepresentationFromJSON)), 'resources': !exists(json, 'resources') ? undefined : ((json['resources'] as Array).map(ResourceRepresentationFromJSON)), }; } export function ScopeRepresentationToJSON(value?: ScopeRepresentation | null): any { if (value === undefined) { return undefined; } if (value === null) { return null; } return { 'displayName': value.displayName, 'iconUri': value.iconUri, 'id': value.id, 'name': value.name, 'policies': value.policies === undefined ? undefined : ((value.policies as Array).map(PolicyRepresentationToJSON)), 'resources': value.resources === undefined ? undefined : ((value.resources as Array).map(ResourceRepresentationToJSON)), }; }